]> git.ipfire.org Git - people/ms/linux.git/log
people/ms/linux.git
4 years agodrm/i915/huc: Add fetch support for gsc-loaded HuC binary
Daniele Ceraolo Spurio [Wed, 4 May 2022 20:48:14 +0000 (13:48 -0700)] 
drm/i915/huc: Add fetch support for gsc-loaded HuC binary

On newer platforms (starting DG2 G10 B-step and G11 A-step), ownership of
HuC loading has been moved from the GuC to the GSC. As part of the
change, the header format of the HuC binary has been updated and does not
match the GuC anymore. The GSC will perform all the required checks on
the binary size, so we only need to check that the version matches.

Note that since we still haven't added any gsc-loaded FWs, the
loaded_via_gsc variable will always be kept to its initialization value
of zero.

v2: Add a note about loaded_via_gsc being zero (Alan)

Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Reviewed-by: Alan Previn <alan.previn.teres.alexis@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220504204816.2082588-3-daniele.ceraolospurio@intel.com
4 years agodrm/i915/huc: drop intel_huc_is_authenticated
Daniele Ceraolo Spurio [Wed, 4 May 2022 20:48:13 +0000 (13:48 -0700)] 
drm/i915/huc: drop intel_huc_is_authenticated

The function name is confusing, because it doesn't check the actual auth
status in HW but the SW status. Given that there is only one user (the
huc_auth function itself), just get rid of it and use the FW status
checker directly.

Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Reviewed-by: Alan Previn <alan.previn.teres.alexis@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220504204816.2082588-2-daniele.ceraolospurio@intel.com
4 years agoRevert "Merge branch 'mlxsw-line-card-model'"
Jakub Kicinski [Wed, 4 May 2022 15:40:37 +0000 (08:40 -0700)] 
Revert "Merge branch 'mlxsw-line-card-model'"

This reverts commit 5e927a9f4b9f29d78a7c7d66ea717bb5c8bbad8e, reversing
changes made to cfc1d91a7d78cf9de25b043d81efcc16966d55b3.

The discussion is still ongoing so let's remove the uAPI
until the discussion settles.

Link: https://lore.kernel.org/all/20220425090021.32e9a98f@kernel.org/
Reviewed-by: Ido Schimmel <idosch@nvidia.com>
Link: https://lore.kernel.org/r/20220504154037.539442-1-kuba@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
4 years agodrm/i915/guc: Support programming the EU priority in the GuC descriptor
Matthew Brost [Wed, 4 May 2022 23:46:36 +0000 (16:46 -0700)] 
drm/i915/guc: Support programming the EU priority in the GuC descriptor

In GuC submission mode the EU priority must be updated by the GuC rather
than the driver as the GuC owns the programming of the context descriptor.

Given that the GuC code uses the GuC priorities, we can't use a generic
function using i915 priorities for both execlists and GuC submission.
The existing function has therefore been pushed to the execlists
back-end while a new one has been added for GuC.

v2: correctly use the GuC prio.

Cc: John Harrison <john.c.harrison@intel.com>
Cc: Matt Roper <matthew.d.roper@intel.com>
Signed-off-by: Matthew Brost <matthew.brost@intel.com>
Signed-off-by: Aravind Iddamsetty <aravind.iddamsetty@intel.com>
Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Reviewed-by: John Harrison <John.C.Harrison@Intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220504234636.2119794-1-daniele.ceraolospurio@intel.com
4 years agodt-bindings: timer: Convert rda,8810pl-timer to YAML
Stanislav Jakubek [Wed, 4 May 2022 17:55:02 +0000 (19:55 +0200)] 
dt-bindings: timer: Convert rda,8810pl-timer to YAML

Convert RDA Micro Timer bindings to DT schema format.

Signed-off-by: Stanislav Jakubek <stano.jakubek@gmail.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
Reviewed-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220504175502.GA2573@standask-GA-A55M-S2HP
4 years agoima: support fs-verity file digest based version 3 signatures
Mimi Zohar [Wed, 24 Nov 2021 15:56:33 +0000 (10:56 -0500)] 
ima: support fs-verity file digest based version 3 signatures

IMA may verify a file's integrity against a "good" value stored in the
'security.ima' xattr or as an appended signature, based on policy.  When
the "good value" is stored in the xattr, the xattr may contain a file
hash or signature.  In either case, the "good" value is preceded by a
header.  The first byte of the xattr header indicates the type of data
- hash, signature - stored in the xattr.  To support storing fs-verity
signatures in the 'security.ima' xattr requires further differentiating
the fs-verity signature from the existing IMA signature.

In addition the signatures stored in 'security.ima' xattr, need to be
disambiguated.  Instead of directly signing the fs-verity digest, a new
signature format version 3 is defined as the hash of the ima_file_id
structure, which identifies the type of signature and the digest.

The IMA policy defines "which" files are to be measured, verified, and/or
audited.  For those files being verified, the policy rules indicate "how"
the file should be verified.  For example to require a file be signed,
the appraise policy rule must include the 'appraise_type' option.

appraise_type:= [imasig] | [imasig|modsig] | [sigv3]
           where 'imasig' is the original or signature format v2 (default),
           where 'modsig' is an appended signature,
           where 'sigv3' is the signature format v3.

The policy rule must also indicate the type of digest, if not the IMA
default, by first specifying the digest type:

digest_type:= [verity]

The following policy rule requires fsverity signatures.  The rule may be
constrained, for example based on a fsuuid or LSM label.

      appraise func=BPRM_CHECK digest_type=verity appraise_type=sigv3

Acked-by: Stefan Berger <stefanb@linux.ibm.com>
Signed-off-by: Mimi Zohar <zohar@linux.ibm.com>
4 years agodm: improve abnormal bio processing
Mike Snitzer [Sun, 17 Apr 2022 17:00:15 +0000 (13:00 -0400)] 
dm: improve abnormal bio processing

Read/write/flush are the most common operations, optimize switch in
is_abnormal_io() for those cases. Follows same pattern established in
block perf-wip commit ("block: optimise blk_may_split for normal rw")

Also, push is_abnormal_io() check and blk_queue_split() down from
dm_submit_bio() to dm_split_and_process_bio() and set new
'is_abnormal_io' flag in clone_info. Optimize __split_and_process_bio
and __process_abnormal_io by leveraging ci.is_abnormal_io flag.

Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: simplify bio-based IO accounting further
Mike Snitzer [Sat, 16 Apr 2022 00:08:23 +0000 (20:08 -0400)] 
dm: simplify bio-based IO accounting further

Now that io splitting is recorded prior to, or during, ->map IO
accounting can happen immediately rather than defer until after
bio splitting in dm_split_and_process_bio().

Remove the DM_IO_START_ACCT flag and also remove dm_io's map_task
member because there is no longer any need to wait for splitting to
occur before accounting.

Also move dm_io struct's 'flags' member to consolidate struct holes.

Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: put all polled dm_io instances into a single list
Ming Lei [Tue, 12 Apr 2022 08:56:16 +0000 (16:56 +0800)] 
dm: put all polled dm_io instances into a single list

Now that bio_split() isn't used by DM's bio splitting, it is a bit
overkill to link dm_io into an hlist given there is only single dm_io
in the list.

Convert to using a single list for holding all dm_io instances
associated with this bio.

Signed-off-by: Ming Lei <ming.lei@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: improve dm_io reference counting
Ming Lei [Tue, 12 Apr 2022 08:56:15 +0000 (16:56 +0800)] 
dm: improve dm_io reference counting

Currently each dm_io's reference counter is grabbed before calling
__map_bio(), this way isn't efficient since we can move this grabbing
to initialization time inside alloc_io().

Meantime it becomes typical async io reference counter model: one is
for submission side, the other is for completion side, and the io won't
be completed until both sides are done.

Signed-off-by: Ming Lei <ming.lei@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: don't grab target io reference in dm_zone_map_bio
Ming Lei [Tue, 12 Apr 2022 08:56:14 +0000 (16:56 +0800)] 
dm: don't grab target io reference in dm_zone_map_bio

dm_zone_map_bio() is only called from __map_bio in which the io's
reference is grabbed already, and the reference won't be released
until the bio is submitted, so not necessary to do it dm_zone_map_bio
any more.

Reviewed-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Tested-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: improve bio splitting and associated IO accounting
Ming Lei [Tue, 12 Apr 2022 08:56:13 +0000 (16:56 +0800)] 
dm: improve bio splitting and associated IO accounting

The current DM code (ab)uses late assignment of dm_io->orig_bio (after
__map_bio() returns and any bio splitting is complete) to indicate the
FS bio has been processed and can be accounted. This results in
awkward waiting until ->orig_bio is set in dm_submit_bio_remap().

Also the bio splitting was implemented using bio_split()+bio_chain()
-- a well-worn pattern but it requires bio cloning purely for the
benefit of more natural IO accounting.  The bio_split() result was
stored in ->orig_bio to represent the mapped part of the original FS
bio.

DM has switched to the bdev based IO accounting interface.  DM's IO
accounting can be implemented in terms of the original FS bio (now
stored early in ->orig_bio) via access to its sectors/bio_op. And
if/when splitting is needed, set a new DM_IO_WAS_SPLIT flag and use
new dm_io fields of .sector_offset & .sectors to allow IO accounting
for split bios _without_ needing to clone a new bio to store in
->orig_bio.

Signed-off-by: Ming Lei <ming.lei@redhat.com>
Co-developed-by: Mike Snitzer <snitzer@kernel.org>
Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: switch to bdev based IO accounting interfaces
Ming Lei [Tue, 12 Apr 2022 08:56:12 +0000 (16:56 +0800)] 
dm: switch to bdev based IO accounting interfaces

DM splits flush with data into empty flush followed by bio with data
payload, switch dm_io_acct() to use bdev_{start,end}_io_acct() to do
this accoiunting more naturally (rather than temporarily changing the
bio's bi_size).

This will allow DM to more easily account bios that are split (in
following commit).

Signed-off-by: Ming Lei <ming.lei@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: pass dm_io instance to dm_io_acct directly
Ming Lei [Tue, 12 Apr 2022 08:56:11 +0000 (16:56 +0800)] 
dm: pass dm_io instance to dm_io_acct directly

All the other 4 parameters are retrieved from the 'dm_io' instance, so
it's not necessary to pass all four to dm_io_acct().

Signed-off-by: Ming Lei <ming.lei@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: don't pass bio to __dm_start_io_acct and dm_end_io_acct
Ming Lei [Tue, 12 Apr 2022 08:56:10 +0000 (16:56 +0800)] 
dm: don't pass bio to __dm_start_io_acct and dm_end_io_acct

dm->orig_bio is always passed to __dm_start_io_acct and dm_end_io_acct,
so it isn't necessary to take one bio parameter for the two helpers.

Signed-off-by: Ming Lei <ming.lei@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: use bio_sectors in dm_aceept_partial_bio
Mike Snitzer [Fri, 15 Apr 2022 07:04:59 +0000 (03:04 -0400)] 
dm: use bio_sectors in dm_aceept_partial_bio

Rename 'bi_size' to 'bio_sectors' given bi_size is being stored in
sectors.  Also, use bio_sectors() rather than open-coding it.

Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: simplify basic targets
Mike Snitzer [Wed, 30 Mar 2022 17:52:10 +0000 (13:52 -0400)] 
dm: simplify basic targets

Remove needless factoring and remap bi_sector regardless of
bio_sectors() being non-zero.

Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: conditionally enable branching for less used features
Mike Snitzer [Sat, 26 Mar 2022 18:14:00 +0000 (14:14 -0400)] 
dm: conditionally enable branching for less used features

Use jump_labels to further reduce cost of unlikely branches for zoned
block devices, dm-stats and swap_bios throttling.

Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: introduce dm_{get,put}_live_table_bio called from dm_submit_bio
Mike Snitzer [Sun, 27 Mar 2022 01:08:36 +0000 (21:08 -0400)] 
dm: introduce dm_{get,put}_live_table_bio called from dm_submit_bio

If a bio is marked REQ_NOWAIT optimize dm_submit_bio()'s dm_table RCU
usage to dm_{get,put}_live_table_fast.

DM core offers protection against blocking (via suspend) if REQ_NOWAIT.

Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: move hot dm_io members to same cacheline as dm_target_io
Mike Snitzer [Sat, 26 Mar 2022 18:38:07 +0000 (14:38 -0400)] 
dm: move hot dm_io members to same cacheline as dm_target_io

Just saves some cacheline bouncing for members accessed during cloned
bio submission and completion.

Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: add local variables to clone_endio and __map_bio
Mike Snitzer [Sat, 26 Mar 2022 17:46:06 +0000 (13:46 -0400)] 
dm: add local variables to clone_endio and __map_bio

Avoid redundant dereferences in both functions.

Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: mark various branches unlikely
Mike Snitzer [Fri, 25 Mar 2022 21:20:45 +0000 (17:20 -0400)] 
dm: mark various branches unlikely

Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: simplify dm_start_io_acct
Mike Snitzer [Fri, 25 Mar 2022 18:12:47 +0000 (14:12 -0400)] 
dm: simplify dm_start_io_acct

Pull common DM_IO_ACCOUNTED check out to beginning of dm_start_io_acct.
Also, use dm_tio_is_normal (and move it to dm-core.h).

Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: simplify dm_io access in dm_split_and_process_bio
Mike Snitzer [Fri, 25 Mar 2022 17:53:23 +0000 (13:53 -0400)] 
dm: simplify dm_io access in dm_split_and_process_bio

Use local variable instead of redudant access using ci.io

Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: factor out dm_io_set_error and __dm_io_dec_pending
Mike Snitzer [Thu, 17 Mar 2022 17:52:06 +0000 (13:52 -0400)] 
dm: factor out dm_io_set_error and __dm_io_dec_pending

Also eliminate need to use errno_to_blk_status().

Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agodm: conditionally enable BIOSET_PERCPU_CACHE for dm_io bioset
Mike Snitzer [Thu, 24 Mar 2022 18:36:47 +0000 (14:36 -0400)] 
dm: conditionally enable BIOSET_PERCPU_CACHE for dm_io bioset

A bioset's per-cpu alloc cache may have broader utility in the future
but for now constrain it to being tightly coupled to QUEUE_FLAG_POLL.

Also change dm_io_complete() to use bio_clear_polled() so that it
properly clears all associated bio state on requeue.

This commit improves DM's hipri bio polling (REQ_POLLED) perf by
7 - 20% depending on the system.

Signed-off-by: Mike Snitzer <snitzer@kernel.org>
4 years agostaging: r8188eu: remove unused IEEE_* defines
Martin Kaiser [Mon, 2 May 2022 20:06:52 +0000 (22:06 +0200)] 
staging: r8188eu: remove unused IEEE_* defines

The IEEE_* defines in the driver's ieee80211.h header file are not used.
Remove them.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220502200652.143665-10-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: r8188eu: use standard category defines
Martin Kaiser [Mon, 2 May 2022 20:06:51 +0000 (22:06 +0200)] 
staging: r8188eu: use standard category defines

Replace some of the driver-specific defines for action categories with the
defines from ieee80211.h.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220502200652.143665-9-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: r8188eu: use ieee80211_mgmt for action category
Martin Kaiser [Mon, 2 May 2022 20:06:50 +0000 (22:06 +0200)] 
staging: r8188eu: use ieee80211_mgmt for action category

Use the struct ieee80211_mgmt from ieee80211.h to read the action
category. There's no need to parse the incoming frame ourselves.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220502200652.143665-8-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: r8188eu: replace OnAction_tbl with switch-case
Martin Kaiser [Mon, 2 May 2022 20:06:49 +0000 (22:06 +0200)] 
staging: r8188eu: replace OnAction_tbl with switch-case

OnAction_tbl has only three entries. It's simpler to use a switch
statement instead of iterating over the table.

We can then remove the table itself and struct action_handler, which was
used only for the table entries.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220502200652.143665-7-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: r8188eu: remove an unused category define
Martin Kaiser [Mon, 2 May 2022 20:06:48 +0000 (22:06 +0200)] 
staging: r8188eu: remove an unused category define

RTW_WLAN_CATEGORY_TDLS is not used. Remove the define.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220502200652.143665-6-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: r8188eu: remove action_handler string
Martin Kaiser [Mon, 2 May 2022 20:06:47 +0000 (22:06 +0200)] 
staging: r8188eu: remove action_handler string

Remove the unused str component from struct action_handler and the
corresponding entries in OnAction_tbl.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220502200652.143665-5-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: r8188eu: remove unused action handler prototypes
Martin Kaiser [Mon, 2 May 2022 20:06:46 +0000 (22:06 +0200)] 
staging: r8188eu: remove unused action handler prototypes

For some action categories, we removed the handler function, but we forgot
the prototypes. Remove them as well.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220502200652.143665-4-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: r8188eu: action category wmm is not used
Martin Kaiser [Mon, 2 May 2022 20:06:45 +0000 (22:06 +0200)] 
staging: r8188eu: action category wmm is not used

The r8188eu driver does not handle the wmm action category. Remove the
empty handler function, the entry in OnAction_tbl and the define for the
category.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220502200652.143665-3-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: r8188eu: action category ht is not used
Martin Kaiser [Mon, 2 May 2022 20:06:44 +0000 (22:06 +0200)] 
staging: r8188eu: action category ht is not used

The r8188eu driver does not handle the ht action category. Remove the
empty handler function, the entry in OnAction_tbl and the define for the
category.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220502200652.143665-2-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: vt6655: Replace unused return value of vt6655_get_current_tsf
Philipp Hortmann [Sun, 1 May 2022 20:25:41 +0000 (22:25 +0200)] 
staging: vt6655: Replace unused return value of vt6655_get_current_tsf

Replace unused return value with u64 to increase readability,
reduce address and dereference operators and omit pqwCurrTSF that
uses CamelCase which is not accepted by checkpatch.pl

Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com>
Link: https://lore.kernel.org/r/62c83d78627196ec0ce2f5a562cb080a1c87a05a.1651435890.git.philipp.g.hortmann@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: vt6655: Rename function CARDbGetCurrentTSF
Philipp Hortmann [Sun, 1 May 2022 20:25:35 +0000 (22:25 +0200)] 
staging: vt6655: Rename function CARDbGetCurrentTSF

The name of the function uses CamelCase which
is not accepted by checkpatch.pl

Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com>
Link: https://lore.kernel.org/r/2b92db8d67e8dd1fc85b45efe3b32d2199371190.1651435890.git.philipp.g.hortmann@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: vt6655: Added missing BE support in CARDbGetCurrentTSF
Philipp Hortmann [Sun, 1 May 2022 19:12:29 +0000 (21:12 +0200)] 
staging: vt6655: Added missing BE support in CARDbGetCurrentTSF

Added missing big-endian support in CARDbGetCurrentTSF.

Reported-by: David Laight <David.Laight@ACULAB.COM>
Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com>
Link: https://lore.kernel.org/r/25c80e3eb889ef2e530f26b4a97a9f5fe88e01ab.1651431640.git.philipp.g.hortmann@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: vt6655: Replace VNSvInPortD with ioread32
Philipp Hortmann [Sun, 1 May 2022 19:12:23 +0000 (21:12 +0200)] 
staging: vt6655: Replace VNSvInPortD with ioread32

Replace macro VNSvInPortD with ioread32 and as it was
the only user, it can now be removed.
The name of macro and the arguments use CamelCase which
is not accepted by checkpatch.pl

Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com>
Link: https://lore.kernel.org/r/3945d32053898e5f9771d6f742ae118ca56943ce.1651431640.git.philipp.g.hortmann@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: r8188eu: Remove broken rtw_p2p_get function.
Charlie Sands [Sat, 30 Apr 2022 04:28:59 +0000 (00:28 -0400)] 
staging: r8188eu: Remove broken rtw_p2p_get function.

Removes broken and unsafe rtw_p2p_get function and all of the code
associated with it from the r8188eu driver.

Signed-off-by: Charlie Sands <charlies256@protonmail.com>
Link: https://lore.kernel.org/r/Ymy7C/A2q+VzfBhO@sckzor-linux.localdomain
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: r8188eu: drop redundant check in _rtw_free_mlme_priv
Vihas Makwana [Wed, 27 Apr 2022 16:57:49 +0000 (22:27 +0530)] 
staging: r8188eu: drop redundant check in _rtw_free_mlme_priv

There's a NULL check on pmlmepriv in rtw_mlme.c:112 which makes no sense
as rtw_free_mlme_priv_ie_data() dereferences it unconditionally and it
would have already crashed at this point.
Remove this redundant check.

Signed-off-by: Vihas Makwana <makvihas@gmail.com>
Link: https://lore.kernel.org/r/20220427165748.10584-1-makvihas@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: r8188eu: remove unused else condition
Jaehee Park [Wed, 27 Apr 2022 15:32:03 +0000 (11:32 -0400)] 
staging: r8188eu: remove unused else condition

rtw_select_and_join_from_scanned_queue() cannot return '2' so this
else condition is unused. Remove this unnecessary else statement.

Suggested-by: Pavel Skripkin <paskripkin@gmail.com>
Signed-off-by: Jaehee Park <jhpark1013@gmail.com>
Link: https://lore.kernel.org/r/20220427153203.GA503502@jaehee-ThinkPad-X1-Extreme
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: r8188eu: remove unused semaphore "allrxreturnevt"
Vihas Makwana [Wed, 27 Apr 2022 19:00:54 +0000 (00:30 +0530)] 
staging: r8188eu: remove unused semaphore "allrxreturnevt"

The semaphore allrxreturnevt of struct recv_priv is initialized but not
used anywhere in the code.
Remove the initialization and the structure member.

Signed-off-by: Vihas Makwana <makvihas@gmail.com>
Link: https://lore.kernel.org/r/20220427190054.17841-1-makvihas@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: greybus: correct typo in comment
Nickalas Cason [Sat, 30 Apr 2022 23:01:39 +0000 (19:01 -0400)] 
staging: greybus: correct typo in comment

Correct misspelling in comment. Issue found with checkpatch.

Signed-off-by: Nickalas Cason <nickalas@cason.dev>
Link: https://lore.kernel.org/r/20220430230139.7i772mvejlhevamn@desktop
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agostaging: vc04_services: Re-use generic struct s32_fract
Andy Shevchenko [Wed, 4 May 2022 09:29:15 +0000 (12:29 +0300)] 
staging: vc04_services: Re-use generic struct s32_fract

Instead of custom data type re-use generic struct s32_fract.
No changes intended.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20220504092915.72021-1-andriy.shevchenko@linux.intel.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agofsl_lpuart: Don't enable interrupts too early
Indan Zupancic [Thu, 5 May 2022 11:47:50 +0000 (13:47 +0200)] 
fsl_lpuart: Don't enable interrupts too early

If an irq is pending when devm_request_irq() is called, the irq
handler will cause a NULL pointer access because initialisation
is not done yet.

Fixes: 9d7ee0e28da59 ("tty: serial: lpuart: avoid report NULL interrupt")
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Indan Zupancic <Indan.Zupancic@mep-info.com>
Link: https://lore.kernel.org/r/20220505114750.45423-1-Indan.Zupancic@mep-info.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agotty: n_gsm: fix invalid gsmtty_write_room() result
Daniel Starke [Wed, 4 May 2022 08:17:33 +0000 (10:17 +0200)] 
tty: n_gsm: fix invalid gsmtty_write_room() result

gsmtty_write() does not prevent the user to use the full fifo size of 4096
bytes as allocated in gsm_dlci_alloc(). However, gsmtty_write_room() tries
to limit the return value by 'TX_SIZE' and returns a negative value if the
fifo has more than 'TX_SIZE' bytes stored. This is obviously wrong as
'TX_SIZE' is defined as 512.
Define 'TX_SIZE' to the fifo size and use it accordingly for allocation to
keep the current behavior. Return the correct remaining size of the fifo in
gsmtty_write_room() via kfifo_avail().

Fixes: e1eaea46bb40 ("tty: n_gsm line discipline")
Cc: stable@vger.kernel.org
Signed-off-by: Daniel Starke <daniel.starke@siemens.com>
Link: https://lore.kernel.org/r/20220504081733.3494-3-daniel.starke@siemens.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agotty: n_gsm: fix mux activation issues in gsm_config()
Daniel Starke [Wed, 4 May 2022 08:17:32 +0000 (10:17 +0200)] 
tty: n_gsm: fix mux activation issues in gsm_config()

The current implementation activates the mux if it was restarted and opens
the control channel if the mux was previously closed and we are now acting
as initiator instead of responder, which is the default setting.
This has two issues.
1) No mux is activated if we keep all default values and only switch to
initiator. The control channel is not allocated but will be opened next
which results in a NULL pointer dereference.
2) Switching the configuration after it was once configured while keeping
the initiator value the same will not reopen the control channel if it was
closed due to parameter incompatibilities. The mux remains dead.

Fix 1) by always activating the mux if it is dead after configuration.
Fix 2) by always opening the control channel after mux activation.

Fixes: e1eaea46bb40 ("tty: n_gsm line discipline")
Cc: stable@vger.kernel.org
Signed-off-by: Daniel Starke <daniel.starke@siemens.com>
Link: https://lore.kernel.org/r/20220504081733.3494-2-daniel.starke@siemens.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agotty: n_gsm: fix buffer over-read in gsm_dlci_data()
Daniel Starke [Wed, 4 May 2022 08:17:31 +0000 (10:17 +0200)] 
tty: n_gsm: fix buffer over-read in gsm_dlci_data()

'len' is decreased after each octet that has its EA bit set to 0, which
means that the value is encoded with additional octets. However, the final
octet does not decreases 'len' which results in 'len' being one byte too
long. A buffer over-read may occur in tty_insert_flip_string() as it tries
to read one byte more than the passed content size of 'data'.
Decrease 'len' also for the final octet which has the EA bit set to 1 to
write the correct number of bytes from the internal receive buffer to the
virtual tty.

Fixes: 2e124b4a390c ("TTY: switch tty_flip_buffer_push")
Cc: stable@vger.kernel.org
Signed-off-by: Daniel Starke <daniel.starke@siemens.com>
Link: https://lore.kernel.org/r/20220504081733.3494-1-daniel.starke@siemens.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agoserial: 8250_mtk: Fix register address for XON/XOFF character
AngeloGioacchino Del Regno [Wed, 27 Apr 2022 13:23:28 +0000 (15:23 +0200)] 
serial: 8250_mtk: Fix register address for XON/XOFF character

The XON1/XOFF1 character registers are at offset 0xa0 and 0xa8
respectively, so we cannot use the definition in serial_port.h.

Fixes: bdbd0a7f8f03 ("serial: 8250-mtk: modify baudrate setting")
Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Cc: stable <stable@vger.kernel.org>
Link: https://lore.kernel.org/r/20220427132328.228297-4-angelogioacchino.delregno@collabora.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agoserial: 8250_mtk: Make sure to select the right FEATURE_SEL
AngeloGioacchino Del Regno [Wed, 27 Apr 2022 13:23:27 +0000 (15:23 +0200)] 
serial: 8250_mtk: Make sure to select the right FEATURE_SEL

Set the FEATURE_SEL at probe time to make sure that BIT(0) is enabled:
this guarantees that when the port is configured as AP UART, the
right register layout is interpreted by the UART IP.

Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Cc: stable <stable@vger.kernel.org>
Link: https://lore.kernel.org/r/20220427132328.228297-3-angelogioacchino.delregno@collabora.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agoserial: 8250_mtk: Fix UART_EFR register address
AngeloGioacchino Del Regno [Wed, 27 Apr 2022 13:23:26 +0000 (15:23 +0200)] 
serial: 8250_mtk: Fix UART_EFR register address

On MediaTek SoCs, the UART IP is 16550A compatible, but there are some
specific quirks: we are declaring a register shift of 2, but this is
only valid for the majority of the registers, as there are some that
are out of the standard layout.

Specifically, this driver is using definitions from serial_reg.h, where
we have a UART_EFR register defined as 2: this results in a 0x8 offset,
but there we have the FCR register instead.

The right offset for the EFR register on MediaTek UART is at 0x98,
so, following the decimal definition convention in serial_reg.h and
accounting for the register left shift of two, add and use the correct
register address for this IP, defined as decimal 38, so that the final
calculation results in (0x26 << 2) = 0x98.

Fixes: bdbd0a7f8f03 ("serial: 8250-mtk: modify baudrate setting")
Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Cc: stable <stable@vger.kernel.org>
Link: https://lore.kernel.org/r/20220427132328.228297-2-angelogioacchino.delregno@collabora.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agotty/serial: digicolor: fix possible null-ptr-deref in digicolor_uart_probe()
Yang Yingliang [Thu, 5 May 2022 12:46:21 +0000 (20:46 +0800)] 
tty/serial: digicolor: fix possible null-ptr-deref in digicolor_uart_probe()

It will cause null-ptr-deref when using 'res', if platform_get_resource()
returns NULL, so move using 'res' after devm_ioremap_resource() that
will check it to avoid null-ptr-deref.
And use devm_platform_get_and_ioremap_resource() to simplify code.

Fixes: 5930cb3511df ("serial: driver for Conexant Digicolor USART")
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Reviewed-by: Baruch Siach <baruch@tkos.co.il>
Cc: stable <stable@vger.kernel.org>
Link: https://lore.kernel.org/r/20220505124621.1592697-1-yangyingliang@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
4 years agodrm/amd/pm: pp_dpm_sclk change for smu_v13_0_7
Kenneth Feng [Tue, 19 Apr 2022 06:51:36 +0000 (14:51 +0800)] 
drm/amd/pm: pp_dpm_sclk change for smu_v13_0_7

fetch the average gfxclk according to pmfw for smu_v13_0_7

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: enable gfx pcc and soc cg on smu_v13_0_7
Kenneth Feng [Mon, 18 Apr 2022 08:03:17 +0000 (16:03 +0800)] 
drm/amd/pm: enable gfx pcc and soc cg on smu_v13_0_7

enable gfx pcc and soc cg on smu_v13_0_7

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: enable gfx ds for smu_v13_0_7
Kenneth Feng [Mon, 18 Apr 2022 06:39:02 +0000 (14:39 +0800)] 
drm/amd/pm: enable gfx ds for smu_v13_0_7

enable gfx ds for smu_v13_0_7

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Yang Wang <kevinyang.wang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/soc21: enable mmhub and athub power gating
Kenneth Feng [Fri, 15 Apr 2022 15:16:41 +0000 (11:16 -0400)] 
drm/amd/soc21: enable mmhub and athub power gating

add the pg_flag for athub and mmhub pg.

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Jack Gui <Jack.Gui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: add the pg_flag for athub and mmhub pg on smu_v13_0_7
Kenneth Feng [Fri, 15 Apr 2022 15:16:03 +0000 (11:16 -0400)] 
drm/amd/pm: add the pg_flag for athub and mmhub pg on smu_v13_0_7

add the pg_flag for athub and mmhub pg on smu_v13_0_7

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Jack Gui <Jack.Gui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: port the fan interface to smu_v13_0_7
Kenneth Feng [Fri, 15 Apr 2022 15:59:16 +0000 (11:59 -0400)] 
drm/amd/pm: port the fan interface to smu_v13_0_7

port the fan interface to smu_v13_0_7

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Jack Gui <Jack.Gui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: enable pp_dpm_vclk/dclk interface for smu_v13_0_7
Kenneth Feng [Tue, 12 Apr 2022 09:07:24 +0000 (17:07 +0800)] 
drm/amd/pm: enable pp_dpm_vclk/dclk interface for smu_v13_0_7

enable pp_dpm_vclk/dclk interface for smu_v13_0_7

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Jack Gui <Jack.Gui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm:add UMD Pstate clock settings for smu_v13_0_7
Kenneth Feng [Fri, 15 Apr 2022 15:58:02 +0000 (11:58 -0400)] 
drm/amd/pm:add UMD Pstate clock settings for smu_v13_0_7

add UMD Pstate clock settings for smu_v13_0_7

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Jack Gui <Jack.Gui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: pp_dpm_* interface for smu_v13_0_7
Kenneth Feng [Fri, 15 Apr 2022 15:56:47 +0000 (11:56 -0400)] 
drm/amd/pm: pp_dpm_* interface for smu_v13_0_7

add the sysfs pp_dpm_* interface for smu_v13_0_7

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Jack Gui <Jack.Gui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: update the features for smu_v13_0_7
Kenneth Feng [Fri, 8 Apr 2022 09:33:45 +0000 (17:33 +0800)] 
drm/amd/pm: update the features for smu_v13_0_7

Enable socclk ds, dstate, mp0clk ds, mpioclk ds, gfxclk ss,
memory temperature reading, athub and mmhub pg.

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: add SCPM support in smu v13_0_7
Kenneth Feng [Thu, 7 Apr 2022 08:42:45 +0000 (16:42 +0800)] 
drm/amd/pm: add SCPM support in smu v13_0_7

port the SCPM change from smu_v13_0_0 to smu_v13_0_7

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: enable platform features for smu_v13_0_7
Kenneth Feng [Fri, 1 Apr 2022 03:28:44 +0000 (11:28 +0800)] 
drm/amd/pm: enable platform features for smu_v13_0_7

enable throttler, AC/DC, VR hot, FW CTF, fan control for smu_v13_0_7

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Wang Yang <kevinyang.wang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: enable fclk,vcn ds and df cstate for smu_v13_0_7
Kenneth Feng [Thu, 31 Mar 2022 12:20:05 +0000 (20:20 +0800)] 
drm/amd/pm: enable fclk,vcn ds and df cstate for smu_v13_0_7

enable fclk ds, vcn ds and df cstate for smu_v13_0_7

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: enable mp0,vcn,dcn dpm on smu_v13_0_7
Kenneth Feng [Thu, 31 Mar 2022 08:37:01 +0000 (16:37 +0800)] 
drm/amd/pm: enable mp0,vcn,dcn dpm on smu_v13_0_7

enable mp0 dpm, vcn dpm, dcn dpm on smu_v13_0_7

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Jack Gui <Jack.Gui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: enable link dpm and link ds on smu_v13_0_7
Kenneth Feng [Thu, 31 Mar 2022 07:22:46 +0000 (15:22 +0800)] 
drm/amd/pm: enable link dpm and link ds on smu_v13_0_7

enable link clock dpm and link clock deep sleep on smu_v13_0_7

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Jack Gui <Jack.Gui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: add mvdd and vddio scaling in smu_v13_0_7
Kenneth Feng [Thu, 31 Mar 2022 06:45:38 +0000 (14:45 +0800)] 
drm/amd/pm: add mvdd and vddio scaling in smu_v13_0_7

add mvdd and vddio scaling in smu_v13_0_7 to follow uclk dpm

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: add features to smu_v13_0_7
Kenneth Feng [Thu, 31 Mar 2022 04:43:45 +0000 (12:43 +0800)] 
drm/amd/pm: add features to smu_v13_0_7

add prefetcher, socclk dpm, fclk dpm, uclk dpm to
smu_v13_0_7

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: support power on/off vcn/jpeg in smu v13_0_7
Kenneth Feng [Mon, 7 Mar 2022 06:29:43 +0000 (14:29 +0800)] 
drm/amd/pm: support power on/off vcn/jpeg in smu v13_0_7

add power on/off vcn&jpeg callbacks in smu_v13_0_7

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Reviewed-by: Likun Gao <Likun.Gao@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: add get enable mask function for smu v13_0_7
Likun Gao [Tue, 1 Mar 2022 09:22:14 +0000 (17:22 +0800)] 
drm/amd/pm: add get enable mask function for smu v13_0_7

Add get_enabled_mask interface for smu v13_0_7.

Signed-off-by: Likun Gao <Likun.Gao@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: add SMU_13_0_7 ppt_funcs for SMU_13_0_7
Chengming Gui [Mon, 21 Feb 2022 07:42:00 +0000 (15:42 +0800)] 
drm/amd/pm: add SMU_13_0_7 ppt_funcs for SMU_13_0_7

Add initial support for SMU 13.0.7.

V2: unify ppt name, fix copyright format, add missing break (Kenneth/Evan)
V3: Split PMFW headers as separate patch (Alex)

Signed-off-by: Chengming Gui <Jack.Gui@amd.com>
Reviewed-by: Evan Quan <evan.quan@amd.com>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu/swsmu: add smu 13.0.7 firmware
Chengming Gui [Fri, 15 Apr 2022 14:36:19 +0000 (10:36 -0400)] 
drm/amdgpu/swsmu: add smu 13.0.7 firmware

Declare smu 13.0.7 firmware.

Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Chengming Gui <Jack.Gui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amd/pm: add SMU_13_0_7 PMFW headers
Chengming Gui [Wed, 23 Feb 2022 01:23:20 +0000 (09:23 +0800)] 
drm/amd/pm: add SMU_13_0_7 PMFW headers

Add driver_if/ppsmc/pptable head files.

Signed-off-by: Chengming Gui <Jack.Gui@amd.com>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu: enable cgcg and cgls for GC 11_0_2
Likun Gao [Mon, 14 Feb 2022 06:46:41 +0000 (14:46 +0800)] 
drm/amdgpu: enable cgcg and cgls for GC 11_0_2

Enable GFX CGCG and CGLS for GFX v11_0_2.

Signed-off-by: Likun Gao <Likun.Gao@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu/discovery: set family for GC 11.0.2
Flora Cui [Fri, 15 Apr 2022 14:27:31 +0000 (10:27 -0400)] 
drm/amdgpu/discovery: set family for GC 11.0.2

Set AMDGPU_FAMILY_GC_11_0_0.

Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Flora Cui <flora.cui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu/discovery: add gfx11 support for GC 11.0.2
Flora Cui [Fri, 15 Apr 2022 14:24:36 +0000 (10:24 -0400)] 
drm/amdgpu/discovery: add gfx11 support for GC 11.0.2

Enable gfx11 support.

Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Flora Cui <flora.cui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu: update rlc ram for gc v11_0_2
Likun Gao [Sun, 27 Feb 2022 06:30:18 +0000 (14:30 +0800)] 
drm/amdgpu: update rlc ram for gc v11_0_2

Add imu rlc ram register settings for gc v11_0_2

Signed-off-by: Likun Gao <Likun.Gao@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdkfd: add asic support for GC 11.0.2
Eric Huang [Tue, 8 Feb 2022 20:22:05 +0000 (15:22 -0500)] 
drm/amdkfd: add asic support for GC 11.0.2

Changes are inherited from GC 11.0.0.

Signed-off-by: Eric Huang <jinhuieric.huang@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu: add initial GC 11.0.2 support
Flora Cui [Fri, 15 Apr 2022 14:15:09 +0000 (10:15 -0400)] 
drm/amdgpu: add initial GC 11.0.2 support

Add initial support for GC 11.0.2 to gfx_v11_0.c.

Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Flora Cui <flora.cui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu: add gc v11_0_2 imu firmware
Flora Cui [Sat, 2 Apr 2022 07:31:37 +0000 (15:31 +0800)] 
drm/amdgpu: add gc v11_0_2 imu firmware

add gc v11_0_2 imu firmware

Signed-off-by: Flora Cui <flora.cui@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu/discovery: add mes11 support for GC 11.0.2
Flora Cui [Fri, 15 Apr 2022 14:26:28 +0000 (10:26 -0400)] 
drm/amdgpu/discovery: add mes11 support for GC 11.0.2

Enable Micro Engine Scheduler support.

Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Flora Cui <flora.cui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu: add mes 11 firmware for mes 11.0.2
Flora Cui [Fri, 15 Apr 2022 14:13:43 +0000 (10:13 -0400)] 
drm/amdgpu: add mes 11 firmware for mes 11.0.2

Define firmware for MES 11.0.2.

Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Flora Cui <flora.cui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu/discovery: add sdma6 support for SDMA 6.0.2
Flora Cui [Fri, 15 Apr 2022 14:25:29 +0000 (10:25 -0400)] 
drm/amdgpu/discovery: add sdma6 support for SDMA 6.0.2

Enable sdma6 support.

Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Flora Cui <flora.cui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdkfd: add asic support for SDMA 6.0.2
Eric Huang [Tue, 8 Feb 2022 20:35:31 +0000 (15:35 -0500)] 
drm/amdkfd: add asic support for SDMA 6.0.2

It is inherited from SDMA 6.0.0.

Signed-off-by: Eric Huang <jinhuieric.huang@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu: add sdma 6.0.2 firware support
Flora Cui [Fri, 15 Apr 2022 14:12:16 +0000 (10:12 -0400)] 
drm/amdgpu: add sdma 6.0.2 firware support

define sdma 6.0.2 firmware.

Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Flora Cui <flora.cui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu/discovery: enable vcn/jpeg v4_0_4
James Zhu [Fri, 11 Feb 2022 13:17:25 +0000 (08:17 -0500)] 
drm/amdgpu/discovery: enable vcn/jpeg v4_0_4

Enable vcn/jpeg 4_0_4.

Signed-off-by: James Zhu <James.Zhu@amd.com>
Reviewed-by: Sonny Jiang <sonny.jiang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu: Enable vcn v4_0_4 sram
Sonny Jiang [Tue, 22 Feb 2022 21:24:10 +0000 (16:24 -0500)] 
drm/amdgpu: Enable vcn v4_0_4 sram

enable vcn v4_0_4 sram

Signed-off-by: Sonny Jiang <sonjiang@amd.com>
Reviewed-by: Leo Liu <leo.liu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu/vcn: enable VCN DPG mode for VCN4_0_4
James Zhu [Thu, 6 Jan 2022 01:39:49 +0000 (20:39 -0500)] 
drm/amdgpu/vcn: enable VCN DPG mode for VCN4_0_4

Enable VCN DPG mode for VCN4_0_4.

Signed-off-by: James Zhu <James.Zhu@amd.com>
Reviewed-by: Sonny Jiang <sonny.jiang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu/vcn: enable VCN PG for VCN4_0_4
James Zhu [Thu, 6 Jan 2022 01:39:06 +0000 (20:39 -0500)] 
drm/amdgpu/vcn: enable VCN PG for VCN4_0_4

Enable VCN PG for VCN4_0_4.

Signed-off-by: James Zhu <James.Zhu@amd.com>
Reviewed-by: Sonny Jiang <sonny.jiang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu/vcn: enable VCN CG for VCN4_0_4
James Zhu [Thu, 6 Jan 2022 01:38:04 +0000 (20:38 -0500)] 
drm/amdgpu/vcn: enable VCN CG for VCN4_0_4

Enable VCN CG for VCN4_0_4.

Signed-off-by: James Zhu <James.Zhu@amd.com>
Reviewed-by: Sonny Jiang <sonny.jiang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu/jpeg: enable JPEG PG for VCN4_0_4
James Zhu [Fri, 15 Apr 2022 15:50:10 +0000 (11:50 -0400)] 
drm/amdgpu/jpeg: enable JPEG PG for VCN4_0_4

Enable JPEG PG for VCN4_0_4.

Signed-off-by: James Zhu <James.Zhu@amd.com>
Reviewed-by: Sonny Jiang <sonny.jiang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu/jpeg: enable JPEG CG for VCN4_0_4
James Zhu [Thu, 6 Jan 2022 01:36:08 +0000 (20:36 -0500)] 
drm/amdgpu/jpeg: enable JPEG CG for VCN4_0_4

Enable JPEG CG for VCN4_0_4.

Signed-off-by: James Zhu <James.Zhu@amd.com>
Reviewed-by: Sonny Jiang <sonny.jiang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu: add VCN4_0_4 firmware
James Zhu [Thu, 6 Jan 2022 01:27:49 +0000 (20:27 -0500)] 
drm/amdgpu: add VCN4_0_4 firmware

Add VCN4_0_4 firmware.

Signed-off-by: James Zhu <James.Zhu@amd.com>
Reviewed-by: Sonny Jiang <sonny.jiang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu/discovery: add psp13 support for PSP 13.0.7
Chengming Gui [Fri, 15 Apr 2022 14:34:51 +0000 (10:34 -0400)] 
drm/amdgpu/discovery: add psp13 support for PSP 13.0.7

Enable psp 13 support.

Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Chengming Gui <Jack.Gui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu/psp13: add support for MP0 13.0.7
Chengming Gui [Fri, 15 Apr 2022 14:37:37 +0000 (10:37 -0400)] 
drm/amdgpu/psp13: add support for MP0 13.0.7

Enable support in psp code.

Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Chengming Gui <Jack.Gui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu/discovery: add gmc11 support for GC 11.0.2
Flora Cui [Fri, 15 Apr 2022 14:20:54 +0000 (10:20 -0400)] 
drm/amdgpu/discovery: add gmc11 support for GC 11.0.2

Enable gmc11 support.

Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Flora Cui <flora.cui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu: add GMC11 support for GC 11.0.2
Flora Cui [Fri, 15 Apr 2022 14:18:35 +0000 (10:18 -0400)] 
drm/amdgpu: add GMC11 support for GC 11.0.2

Add initial support for GC 11.0.2.

Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Flora Cui <flora.cui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
4 years agodrm/amdgpu: add UMC 8.11.0 support
Flora Cui [Fri, 15 Apr 2022 14:17:23 +0000 (10:17 -0400)] 
drm/amdgpu: add UMC 8.11.0 support

Add initial support for UMC 8.11.0.

Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Flora Cui <flora.cui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>