Commit Graph

1123600 Commits

Author SHA1 Message Date
Linus Torvalds
d649d2c49b pstore revert for v6.0-rc8
- Revert crypto acomp migration (Guilherme G. Piccoli)
 -----BEGIN PGP SIGNATURE-----
 
 iQJKBAABCgA0FiEEpcP2jyKd1g9yPm4TiXL039xtwCYFAmM3CssWHGtlZXNjb29r
 QGNocm9taXVtLm9yZwAKCRCJcvTf3G3AJl75D/42DaeB92odK/3XG9cI1Frp4YS0
 vcTIecUeheNrTf4okUjeL0kQjUJgDQLWYNxZU6O3ljNM3lItDegV14Ij4tiPJlNK
 pOg8e+ddnWmhTB6c1BrLwVIjPDUnJmhqd1L2G6D/1djlcQU2TzN/amjBE4PQYrC4
 Kyqn8nmrVt5CgCvkV4PPDuIiyeGx808bFu+rK13J6BZYDH4mTZWqky25+wFuresn
 HNBQ0Xh7otaeeIMdbdohaitANlr7xHpUOLDuHnQaZ9Od1wJdFqNFpQ0sYDwvsqhY
 aTyNAAkZig9xMp10Sr6lCDfT/ZHkHDtSNOqn30iwPrFX83QVbbnaQhRsN7EK8Caz
 v7dx2HDjP5MxkYetT+3qPW4waScc5/s7dJNXoK/3E3oWrKoFRwx2CrmZUEuHmjHC
 S1M/kG+MoizxGAWbtvB93XbxXJlULdgmv1VKQyBjZRZ9JVBP7AnQmstljKjK0yn2
 o/pgTFRduiTj7+N9iU7h7GxHNLXJm0YHwCZw1QhORc1dg14jbMkNEu6GN6ZNfuvg
 ADYs2tRN7YA7oGjACaCNAEuGxjY5/quvPAdYHdwankXBj8S8O2/BCxa02mbrPevC
 7p32nwzRtUz4G+bjJr4N/RGO1q/Qzn5IcZnzOxGUVn5TC729JxkfRUFrb/m0l0PP
 PgfmGgNjSQ4KDaYIMQ==
 =KoAn
 -----END PGP SIGNATURE-----

Merge tag 'pstore-v6.0-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/kees/linux

Pull pstore revert from Kees Cook:
 "A misbehavior with some compression backends in pstore was just
  discovered due to the recent crypto acomp migration.

  Since we're so close to release, it seems better to just simply revert
  it, and we can figure out what's going on without leaving it broken
  for a release.

   - Revert crypto acomp migration (Guilherme G. Piccoli)"

* tag 'pstore-v6.0-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/kees/linux:
  Revert "pstore: migrate to crypto acomp interface"
2022-09-30 08:54:14 -07:00
Linus Torvalds
89e10b860c gpio fixes for v6.0
- fix the check for pwm support on non-A8K platforms in gpio-mvebu
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEFp3rbAvDxGAT0sefEacuoBRx13IFAmM2uJEACgkQEacuoBRx
 13Jf9Q/+IHbeTT/EeYrurElRe/MOCKT69+QmPgrzDwhE/PeLf6Jan6h02HaB58kb
 mU6ruxMXSWmOypt8OMz/sepiR2qr263GhK/4sT5gvRLI44orx5ql8kzcMDpYZYib
 qWvnNZzyyWnF3x+SQYVWJ0GlNWQi6dZOzj5OMBLHZB2UxDbt3r8gpiqep3EHAzlR
 STiySnRYahWmbD0+/qfNtC1lUlfeuGIWDqROUaXW/wfPuOsNeo/aZtoArgqqCAYu
 5bGGY47ENbTv5t1Tc2+Eh4GvMfEDLttqgNToTXmTg1BfCBlv6rhG68+yGJS7DCoj
 ZLg+GMvspKeY7w7HiGcRbkor9fMZ5bay7wTYSuuBQEUTOG3LrLJvl+mKxK7t8VTm
 kOr2YwX9QrtZo8XCGQ5WuD9CIeXAk1weP996GxTh5PNLrHPYca9hfzCBJadK0ay0
 YgBdaVE3vt1I4Rl9NI1W2ySeNFS0pkf3JQFwhOrclDJ+HwP7GgTxwQlBue1oDVYw
 KCo17sabstTBbT56qODRTxSoXFRdgXmDj1z+emkf+/qcaeJPtDVOVZ9BJWcH6rJ+
 5gGdv8/lhBpaVBp4pB2XdD6Mf0/BvsZNyte0ytYqHiQuTH4HlNrA2dv3CBXmEnJO
 z81Vmjch4kYt6q5ZXVeJH/lfRImKwnzVzWzQZTyUlLNj+1UtS5E=
 =zdzJ
 -----END PGP SIGNATURE-----

Merge tag 'gpio-fixes-for-v6.0' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux

Pull gpio fixes from Bartosz Golaszewski:
 "One more fix for the upcoming release:

   - fix the check for pwm support on non-A8K platforms in gpio-mvebu"

* tag 'gpio-fixes-for-v6.0' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux:
  gpio: mvebu: Fix check for pwm support on non-A8K platforms
2022-09-30 08:30:10 -07:00
Guilherme G. Piccoli
40158dbf7e Revert "pstore: migrate to crypto acomp interface"
This reverts commit e4f0a7ec58.

When using this new interface, both efi_pstore and ramoops
backends are unable to properly decompress dmesg if using
zstd, lz4 and lzo algorithms (and maybe more). It does succeed
with deflate though.

The message observed in the kernel log is:

[2.328828] pstore: crypto_acomp_decompress failed, ret = -22!

The pstore infrastructure is able to collect the dmesg with
both backends tested, but since decompression fails it's
unreadable. With this revert everything is back to normal.

Fixes: e4f0a7ec58 ("pstore: migrate to crypto acomp interface")
Cc: Ard Biesheuvel <ardb@kernel.org>
Signed-off-by: Guilherme G. Piccoli <gpiccoli@igalia.com>
Signed-off-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20220929215515.276486-1-gpiccoli@igalia.com
2022-09-30 08:16:06 -07:00
Linus Torvalds
5a77386984 drm fixes for 6.0 final
amdgpu:
 - GC 11.x fixes
 - SMU 13.x fixes
 - DCN 3.1.4 fixes
 - DCN 3.2.x fixes
 - GC 9.x fix
 - Fence fix
 - SR-IOV supend/resume fix
 - PSR regression fix
 
 i915:
 - Restrict forced preemption to the active context
 - Restrict perf_limit_reasons to the supported platforms - gen11+
 
 bridge:
 - analogix: Revert earlier suspend fix
 - lt8912b: Fix corrupt display output
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEEKbZHaGwW9KfbeusDHTzWXnEhr4FAmM2NBYACgkQDHTzWXnE
 hr4lXQ//XtTakjVrp+EVX5IAff65APGUOymQJtmwpLfzMzeqgsT9FtqqR5H6ntCr
 G4z21GUtVd9PLgzwpcyetTnpevr2wc2qofKWcUhtkOCJdKLsfaH+pCSKiyshqByd
 eXfeFBdRMTiwKtNteoWynnns7FbbEUSNLi6XOvv+TzX5441+qSuwmYcfZjet+/Bs
 NS3BIwXwceRIf9ZJUvirEHSaLG+abS9UiLhljI9F714INIBMyVEiqyl6LT20O6k+
 NuPzOcD6AQVPjlDezCKrX4aeZ3wG2QudOuXg/3e7L6XtRs24Grp6kg7HGQX6yYuo
 xrmjOmnNEHsv8RSem+enmYCh8F42WRI5XZsOuLHE0sH2vXfDIxrmpibrZDCUdOYO
 AmagoYwTjRXqqjanq10kGHRNuStrhytU2wQ55RiaNoWDSEuImAqrYUJb9at+KnTW
 AtiMDeZMSZFMpy0mPjwk0iJZ2NRoLtvoT9ffGT+aMQsADgGR2Zf1r44jXBnlsljl
 G1KT40wig8q9lGVza97ZAi4lSPdCwWeCEg8JQxHPeVf+1kS5iKC1231TW77UEXiG
 Lhz+yeDNuTpPtH/bLwO6AMaIAXyx8FiXhwuq0dSn5R9dCUKdZh5Zlo/Ja5syOm/s
 jXkLSkoIecvlTaqTPGsxR4Ua282o9d+eCvEiQx935sAzpDyCSUs=
 =dSSO
 -----END PGP SIGNATURE-----

Merge tag 'drm-fixes-2022-09-30-1' of git://anongit.freedesktop.org/drm/drm

Pull drm fixes from Dave Airlie:
 "Last set of fixes for 6.0 hopefully - minor bridge fixes, i915 fixes,
  and a bunch of amdgpu fixes for new IP blocks, along with a couple of
  regression fixes. Should be all set for merge window next week.

  amdgpu:
   - GC 11.x fixes
   - SMU 13.x fixes
   - DCN 3.1.4 fixes
   - DCN 3.2.x fixes
   - GC 9.x fix
   - Fence fix
   - SR-IOV supend/resume fix
   - PSR regression fix

  i915:
   - Restrict forced preemption to the active context
   - Restrict perf_limit_reasons to the supported platforms - gen11+

  bridge:
   - analogix: Revert earlier suspend fix
   - lt8912b: Fix corrupt display output"

* tag 'drm-fixes-2022-09-30-1' of git://anongit.freedesktop.org/drm/drm: (26 commits)
  drm/amd/display: Prevent OTG shutdown during PSR SU
  drm/i915/gt: Perf_limit_reasons are only available for Gen11+
  drm/amdgpu: Add amdgpu suspend-resume code path under SRIOV
  drm/amdgpu: Remove fence_process in count_emitted
  drm/amdgpu: Correct the position in patch_cond_exec
  drm/amd/display: fill in clock values when DPM is not enabled
  drm/amd/display: Avoid unnecessary pixel rate divider programming
  drm/amd/display: Remove assert for odm transition case
  drm/amd/display: Fix typo in get_pixel_rate_div
  drm/amd/display: Fix audio on display after unplugging another
  drm/amd/display: Add explicit FIFO disable for DP blank
  drm/amd/display: Wrap OTG disable workaround with FIFO control
  drm/amd/display: Do DIO FIFO enable after DP video stream enable
  drm/amd/display: Update DCN32 to use new SR latencies
  drm/amd/display: Avoid avoid unnecessary pixel rate divider programming
  drm/amdkfd: fix dropped interrupt in kfd_int_process_v11
  drm/amdgpu: pass queue size and is_aql_queue to MES
  drm/amdkfd: fix MQD init for GFX11 in init_mqd
  drm/amd/pm: use adverse selection for dpm features unsupported by driver
  drm/amd/pm: enable gfxoff feature for SMU 13.0.0
  ...
2022-09-30 08:12:04 -07:00
Dave Airlie
6643b3836f - Restrict forced preemption to the active context (Chris)
- Restrict perf_limit_reasons to the supported platforms - gen11+ (Ashutosh)
 -----BEGIN PGP SIGNATURE-----
 
 iQEzBAABCAAdFiEEbSBwaO7dZQkcLOKj+mJfZA7rE8oFAmM1wIQACgkQ+mJfZA7r
 E8pyNgf/c137/kVem6XuCQ+vEAPMPRrWrQp5ghbJok37N7Pch1bYlYOGpeVGBbKk
 apyNymZh5TAJJrcI8BiAGkdJctumhI8w46NPuxzC4CcIi0DLenjbr4svQPk8GFvT
 uv+9yIQ6W6fJ8Zz/5A0gsgimDYJ0iVIWv1xtvEtcUFtpiuQmEa3XwZpVCNU7/E5W
 qFlJJ1jQprF/ZWArX2BxwsLb32IMOUuo2V35gPIqln7xHHEZRMtel1pRnUooho3j
 uCzar4j1bbF9kp15hIlKXgkTtSKrPsvhJAQuW6wUnRPj9rQGNvVUu/JRnbITzdvx
 OrDBpRLEpYv7nRfQpXvJ/GFvd2D9qA==
 =iXn3
 -----END PGP SIGNATURE-----

Merge tag 'drm-intel-fixes-2022-09-29' of git://anongit.freedesktop.org/drm/drm-intel into drm-fixes

- Restrict forced preemption to the active context (Chris)
- Restrict perf_limit_reasons to the supported platforms - gen11+ (Ashutosh)

Signed-off-by: Dave Airlie <airlied@redhat.com>

From: Rodrigo Vivi <rodrigo.vivi@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/YzXAkH1a32pYJD33@intel.com
2022-09-30 09:28:58 +10:00
Dave Airlie
91462afa42 Merge tag 'amd-drm-fixes-6.0-2022-09-29' of https://gitlab.freedesktop.org/agd5f/linux into drm-fixes
amd-drm-fixes-6.0-2022-09-29:

amdgpu:
- GC 11.x fixes
- SMU 13.x fixes
- DCN 3.1.4 fixes
- DCN 3.2.x fixes
- GC 9.x fix
- Fence fix
- SR-IOV supend/resume fix
- PSR regression fix

Signed-off-by: Dave Airlie <airlied@redhat.com>
From: Alex Deucher <alexander.deucher@amd.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220929144003.8363-1-alexander.deucher@amd.com
2022-09-30 09:03:03 +10:00
Dave Airlie
153a97b4e3 Short summary of fixes pull:
* bridge/analogix: Revert earlier suspend fix
  * bridge/lt8912b: Fix corrupt display output
 -----BEGIN PGP SIGNATURE-----
 
 iQEzBAABCAAdFiEEchf7rIzpz2NEoWjlaA3BHVMLeiMFAmM1rvQACgkQaA3BHVML
 eiNyWgf/YfZNvMy18CHm1F74gNN0CbihChqNtTesMYnCt/E4hwe3YfJDf/NyJHfj
 ziigcHYCyEJ+R9TVLE9ynty/3tKycINZVDYo0H484GnMlpKGBQvlgCfTTWoymwTg
 gZkdGxeo9JXLC6PXPTii+Y+UEucqe33trjJ+qEUQg2Kjsy/yrhaD7UFKnhk6UJR6
 4qbO+ierRXFglwW/nQB5UOXyyWaL2Offh3iM2UaKsusJz5sveQSq/FkP9Rh0K0ti
 nHz4vydldjxjnfvAHrPJKzT0BaqhI9IOFZeOYgX1ml8Bwq7zmaI+Z9IkOtyf9wsP
 UOLP6wQQqvt8hba6/hOzWsCJeol/6g==
 =OLW2
 -----END PGP SIGNATURE-----

Merge tag 'drm-misc-fixes-2022-09-29' of git://anongit.freedesktop.org/drm/drm-misc into drm-fixes

Short summary of fixes pull:

 * bridge/analogix: Revert earlier suspend fix
 * bridge/lt8912b: Fix corrupt display output

Signed-off-by: Dave Airlie <airlied@redhat.com>

From: Thomas Zimmermann <tzimmermann@suse.de>
Link: https://patchwork.freedesktop.org/patch/msgid/YzWvHhaqHhYirn4L@linux-uq9g
2022-09-30 08:50:34 +10:00
Linus Torvalds
987a926c1d fix for breakage in dump_user_range()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQQqUNBr3gm4hGXdBJlZ7Krx/gZQ6wUCYzXkrwAKCRBZ7Krx/gZQ
 6+BcAP4+OfgZO6qStFjroURhZ8o3qfCJpYde/fGN5S/F/5UMdAD6A+4yozxXLdMZ
 wb2oB0XhxHv33vFdFfEeodquTnn+MAQ=
 =1Mnt
 -----END PGP SIGNATURE-----

Merge tag 'pull-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs

Pull coredump fix from Al Viro:
 "Fix for breakage in dump_user_range()"

* tag 'pull-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
  [coredump] don't use __kernel_write() on kmap_local_page()
2022-09-29 14:37:45 -07:00
Linus Torvalds
511cce163b Networking fixes for 6.0-rc8, including fixes from wifi and can.
Current release - regressions:
 
  - phy: don't WARN for PHY_UP state in mdio_bus_phy_resume()
 
  - wifi: fix locking in mac80211 mlme
 
  - eth:
    - revert "net: mvpp2: debugfs: fix memory leak when using debugfs_lookup()"
    - mlxbf_gige: fix an IS_ERR() vs NULL bug in mlxbf_gige_mdio_probe
 
 Previous releases - regressions:
 
  - wifi: fix regression with non-QoS drivers
 
 Previous releases - always broken:
 
  - mptcp: fix unreleased socket in accept queue
 
  - wifi:
    - don't start TX with fq->lock to fix deadlock
    - fix memory corruption in minstrel_ht_update_rates()
 
  - eth:
    - macb: fix ZynqMP SGMII non-wakeup source resume failure
    - mt7531: only do PLL once after the reset
    - usbnet: fix memory leak in usbnet_disconnect()
 
 Misc:
 
  - usb: qmi_wwan: add new usb-id for Dell branded EM7455
 
 Signed-off-by: Paolo Abeni <pabeni@redhat.com>
 -----BEGIN PGP SIGNATURE-----
 
 iQJGBAABCAAwFiEEg1AjqC77wbdLX2LbKSR5jcyPE6QFAmM1cawSHHBhYmVuaUBy
 ZWRoYXQuY29tAAoJECkkeY3MjxOkyn4P/3sP2MK9yjBNWZ+NcjGAapXqm5MPttDX
 pTihRgVVR0ldAQCvLaKS6NtB9W/o2KnQ6znsNvba5fEE8MskKCv+kh3kIe5kzq6B
 JrpEQUHOS7XlIgQnNIUITym1n9A79CHvPWvuQzbSr+5TbaEncM2KN/0UFi+sqkrY
 Gz+2BUvJqeJShqQYtZCRQDrNxOmpKtRLHuXmskS0XlSHp0bp8nz/8zQOLEIHMnqB
 xLHRzOgpRBIXMPO3IWTP8AHkYmuyh7Pdf1IZ5uPgVhBmcfVR7UvXQUSCXt21WlhT
 SoLbOuT/zAFTbehkGY5B2S40h9qUvw2WBcHO3go59PwT9NOP2a2V1qcj6C75/rt2
 5Gnw75vT0Z5+VyuCHlyK4K2OVdiSpe/OMY8ZTYIRy8cGKXycAlK3AS5/m7Y+UG37
 SG+DrfkrBjC1GYKcFugC3zjLW1eQ+KKWY6z9j8PgWbZ3hgmWo5g9DXsRep7cDFUF
 6bzspxCQDn53WSLKnDRxIdFGPKR6bzn7Nys/qhyxaBdW59xLohXPqaF+n92K7bV8
 lkrDzq0knAsNWDKUT8sDs0ATMHx7MgzOlKwEMkkvhV9F3psiob9ISdU1Mwn4dbi1
 guWrSm5YtFxSu5iuAeOOZs0gZCtXuWtq0cJVsjnyZHnselcqO6Tfuvs2vzamI1KI
 MFnI5EZ6nY48
 =WVqg
 -----END PGP SIGNATURE-----

Merge tag 'net-6.0-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net

Pull networking fixes from Paolo Abeni:
 "Including fixes from wifi and can.

  Current release - regressions:

   - phy: don't WARN for PHY_UP state in mdio_bus_phy_resume()

   - wifi: fix locking in mac80211 mlme

   - eth:
      - revert "net: mvpp2: debugfs: fix memory leak when using debugfs_lookup()"
      - mlxbf_gige: fix an IS_ERR() vs NULL bug in mlxbf_gige_mdio_probe

  Previous releases - regressions:

   - wifi: fix regression with non-QoS drivers

  Previous releases - always broken:

   - mptcp: fix unreleased socket in accept queue

   - wifi:
      - don't start TX with fq->lock to fix deadlock
      - fix memory corruption in minstrel_ht_update_rates()

   - eth:
      - macb: fix ZynqMP SGMII non-wakeup source resume failure
      - mt7531: only do PLL once after the reset
      - usbnet: fix memory leak in usbnet_disconnect()

  Misc:

   - usb: qmi_wwan: add new usb-id for Dell branded EM7455"

* tag 'net-6.0-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (30 commits)
  mptcp: fix unreleased socket in accept queue
  mptcp: factor out __mptcp_close() without socket lock
  net: ethernet: mtk_eth_soc: fix mask of RX_DMA_GET_SPORT{,_V2}
  net: mscc: ocelot: fix tagged VLAN refusal while under a VLAN-unaware bridge
  can: c_can: don't cache TX messages for C_CAN cores
  ice: xsk: drop power of 2 ring size restriction for AF_XDP
  ice: xsk: change batched Tx descriptor cleaning
  net: usb: qmi_wwan: Add new usb-id for Dell branded EM7455
  selftests: Fix the if conditions of in test_extra_filter()
  net: phy: Don't WARN for PHY_UP state in mdio_bus_phy_resume()
  net: stmmac: power up/down serdes in stmmac_open/release
  wifi: mac80211: mlme: Fix double unlock on assoc success handling
  wifi: mac80211: mlme: Fix missing unlock on beacon RX
  wifi: mac80211: fix memory corruption in minstrel_ht_update_rates()
  wifi: mac80211: fix regression with non-QoS drivers
  wifi: mac80211: ensure vif queues are operational after start
  wifi: mac80211: don't start TX with fq->lock to fix deadlock
  wifi: cfg80211: fix MCS divisor value
  net: hippi: Add missing pci_disable_device() in rr_init_one()
  net/mlxbf_gige: Fix an IS_ERR() vs NULL bug in mlxbf_gige_mdio_probe
  ...
2022-09-29 08:32:53 -07:00
Linus Torvalds
da9eede6b2 Input updates for v6.0-rc7
- small fixes for iqs62x-keys and melfas_mip4 drivers
 
 - corrected register address in snvs_pwrkey driver
 
 - Synaptic driver will stop trying to use intertouch (native) mode on
   some Lenovo AMD devices
 -----BEGIN PGP SIGNATURE-----
 
 iJAEABYKADgWIQST2eWILY88ieB2DOtAj56VGEWXnAUCYzUgfBocZG1pdHJ5LnRv
 cm9raG92QGdtYWlsLmNvbQAKCRBAj56VGEWXnEkhAP4/cOTiILkNKTzbu3nPAFn5
 qVBp+wDpFrjN5zQKEIyOVgEAr5k7STjixjnneZnR7+ppald6Ti7LXaTESoXnqrY9
 XwY=
 =zsDx
 -----END PGP SIGNATURE-----

Merge tag 'input-for-v6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input

Pull input fixes from Dmitry Torokhov:

 - small fixes for iqs62x-keys and melfas_mip4 drivers

 - corrected register address in snvs_pwrkey driver

 - Synaptic driver will stop trying to use intertouch (native) mode on
   some Lenovo AMD devices

* tag 'input-for-v6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
  Input: snvs_pwrkey - fix SNVS_HPVIDR1 register address
  Input: synaptics - disable Intertouch for Lenovo T14 and P14s AMD G1
  Input: iqs62x-keys - drop unused device node references
  Input: melfas_mip4 - fix return value check in mip4_probe()
2022-09-29 08:22:53 -07:00
Leo Li
83ca5fb40e drm/amd/display: Prevent OTG shutdown during PSR SU
[Why]

Enabling Z10 optimizations allows DMUB to disable the OTG during PSR
link-off. This theoretically saves power by putting more of the display
hardware to sleep. However, we observe that with PSR SU, it causes
visual artifacts, higher power usage, and potential system hang.

This is partly due to an odd behavior with the VStartup interrupt used
to signal DRM vblank events. If the OTG is toggled on/off during a PSR
link on/off cycle, the vstartup interrupt fires twice in quick
succession. This generates incorrectly timed vblank events.
Additionally, it can cause cursor updates to generate visual artifacts.

Note that this is not observed with PSR1 since PSR is fully disabled
when there are vblank event requestors. Cursor updates are also
artifact-free, likely because there are no selectively-updated (SU)
frames that can generate artifacts.

[How]

A potential solution is to disable z10 idle optimizations only when fast
updates (flips & cursor updates) are committed. A mechanism to do so
would require some thoughtful design. Let's just disable idle
optimizations for PSR2 for now.

Fixes: 7cc191ee76 ("drm/amd/display: Implement MPO PSR SU")
Reported-by: August Wikerfors <git@augustwikerfors.se>
Link: https://lore.kernel.org/r/c1f8886a-5624-8f49-31b1-e42b6d20dcf5@augustwikerfors.se/
Tested-by: August Wikerfors <git@augustwikerfors.se>
Reviewed-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-29 10:07:42 -04:00
Linus Torvalds
71f1875705 ATA fixes for 6.0-rc7
Three late patches to fix problems discovered recently.
 
 * Add a horkage to disable link power management by default for the
   Pioneer BDR-207M and BDR-205 DVD drives (from Niklas).
 
 * 2 patches to fix setting the maximum queue depth of libsas owned ATA
   devices (from me).
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYKAB0WIQSRPv8tYSvhwAzJdzjdoc3SxdoYdgUCYzUUjAAKCRDdoc3SxdoY
 du6zAQD5X5JGmXppn5alNTFmfvekLj3wDswGgFcYtopZ0XLCrwD+Pf7K+3VVzhsj
 IMj45WJe0LlnWeb1J5cCviSrm6lfIwo=
 =Udns
 -----END PGP SIGNATURE-----

Merge tag 'ata-6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/dlemoal/libata

Pull ATA fixes from Damien Le Moal:
 "Three late patches to fix problems discovered recently:

   - Add a horkage to disable link power management by default for the
     Pioneer BDR-207M and BDR-205 DVD drives (from Niklas)

   - Two patches to fix setting the maximum queue depth of libsas owned
     ATA devices (from me)"

* tag 'ata-6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/dlemoal/libata:
  ata: libata-sata: Fix device queue depth control
  ata: libata-scsi: Fix initialization of device queue depth
  libata: add ATA_HORKAGE_NOLPM for Pioneer BDR-207M and BDR-205
2022-09-29 05:40:59 -07:00
Linus Torvalds
81bcd4b522 LoongArch fixes for v6.0-final
-----BEGIN PGP SIGNATURE-----
 
 iQJKBAABCAA0FiEEzOlt8mkP+tbeiYy5AoYrw/LiJnoFAmM1AJcWHGNoZW5odWFj
 YWlAa2VybmVsLm9yZwAKCRAChivD8uImekA3D/46J/vg5BVdGJxPxDXd6HUtPjX+
 lkRs/yfGwntxKr1bQeEp0/p5W1ht9M2vtLQfUuPuXL1ArTTJ0F61jqkc4Pz9Ulzw
 pcQA6pMfwXjpxJqDzNfDZ3Zq17DD5KOkQyPT7MuJpO7AbX3aiaLAZ6C+cjckrBLV
 tKNIm8nIcCfcvivOnkP+1oaazmc2ndxQBozmiTcGTuy4Gsyyj2Qyibqjm9RQvDoH
 zD87wJKpgTawKN6Gx5nd9F52v7o/HJcQdgYkowVwsnkPrnAU4Wpk9da5XcCmsJ1a
 //YSRZlLHcMDzZqoK1tUrbhTGPxQj03e11XS6uUnzWg/qGjOrvbzFmjmHYd2PJWI
 xuV5IHyXAKwpTVRibFmC184V0XGPuyo9iZJE6/7n06lT2l66+1TDTGa9FRI7EDM+
 BBX6Ye7kVOhqunEy/VXW3pcfAquyWTotGDVYJajFtrBPo/JgoCILh6tGNF4sKGc7
 xeNhZMSjrWIcaSr1C74sTifUx2yYx34f23gt42aJtLq8yCEl0w+sS/dcJ9G2Hj2I
 jKDvq6nQLpsrIw2CYPYUtnsiva4Bug/zBUKeSaWc91C2LuPPgOqZdvSj+bVaAJWz
 ulPd6DaTkAK1aoNm/3+veL0/GQlLFDUyHHI9YDpYN52BmNlZfZJ0ffV3KHkxuFkV
 dbGT6ZEXjrf0oMaHFQ==
 =q6CX
 -----END PGP SIGNATURE-----

Merge tag 'loongarch-fixes-6.0-3' of git://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson

Pull LoongArch fixes from Huacai Chen:
 "Some trivial fixes and cleanup"

* tag 'loongarch-fixes-6.0-3' of git://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson:
  LoongArch: Clean up loongson3_smp_ops declaration
  LoongArch: Fix and cleanup csr_era handling in do_ri()
  LoongArch: Align the address of kernel_entry to 4KB
2022-09-29 05:35:32 -07:00
Yanteng Si
4f196cb64b LoongArch: Clean up loongson3_smp_ops declaration
Since loongson3_smp_ops is not used in LoongArch anymore, let's remove
it for cleanup.

Fixes: f2ac457a61 ("LoongArch: Add CPU definition headers")
Signed-off-by: Yanteng Si <siyanteng@loongson.cn>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
2022-09-29 10:15:00 +08:00
Huacai Chen
06e76acec7 LoongArch: Fix and cleanup csr_era handling in do_ri()
We don't emulate reserved instructions and just send a signal to the
current process now. So we don't need to call compute_return_era() to
add 4 (point to the next instruction) to csr_era in pt_regs. RA/ERA's
backup/restore is cleaned up as well.

Signed-off-by: Jun Yi <yijun@loongson.cn>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
2022-09-29 10:15:00 +08:00
Huacai Chen
2938431e93 LoongArch: Align the address of kernel_entry to 4KB
Align the address of kernel_entry to 4KB, to avoid early tlb miss
exception in case the entry code crosses page boundary.

Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
2022-09-29 10:15:00 +08:00
Jakub Kicinski
3b04cba7ad Merge branch 'mptcp-properly-clean-up-unaccepted-subflows'
Mat Martineau says:

====================
mptcp: Properly clean up unaccepted subflows

Patch 1 factors out part of the mptcp_close() function for use by a caller
that already owns the socket lock. This is a prerequisite for patch 2.

Patch 2 is the fix that fully cleans up the unaccepted subflow sockets.
====================

Link: https://lore.kernel.org/r/20220927193158.195729-1-mathew.j.martineau@linux.intel.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-09-28 19:05:40 -07:00
Menglong Dong
30e51b923e mptcp: fix unreleased socket in accept queue
The mptcp socket and its subflow sockets in accept queue can't be
released after the process exit.

While the release of a mptcp socket in listening state, the
corresponding tcp socket will be released too. Meanwhile, the tcp
socket in the unaccept queue will be released too. However, only init
subflow is in the unaccept queue, and the joined subflow is not in the
unaccept queue, which makes the joined subflow won't be released, and
therefore the corresponding unaccepted mptcp socket will not be released
to.

This can be reproduced easily with following steps:

1. create 2 namespace and veth:
   $ ip netns add mptcp-client
   $ ip netns add mptcp-server
   $ sysctl -w net.ipv4.conf.all.rp_filter=0
   $ ip netns exec mptcp-client sysctl -w net.mptcp.enabled=1
   $ ip netns exec mptcp-server sysctl -w net.mptcp.enabled=1
   $ ip link add red-client netns mptcp-client type veth peer red-server \
     netns mptcp-server
   $ ip -n mptcp-server address add 10.0.0.1/24 dev red-server
   $ ip -n mptcp-server address add 192.168.0.1/24 dev red-server
   $ ip -n mptcp-client address add 10.0.0.2/24 dev red-client
   $ ip -n mptcp-client address add 192.168.0.2/24 dev red-client
   $ ip -n mptcp-server link set red-server up
   $ ip -n mptcp-client link set red-client up

2. configure the endpoint and limit for client and server:
   $ ip -n mptcp-server mptcp endpoint flush
   $ ip -n mptcp-server mptcp limits set subflow 2 add_addr_accepted 2
   $ ip -n mptcp-client mptcp endpoint flush
   $ ip -n mptcp-client mptcp limits set subflow 2 add_addr_accepted 2
   $ ip -n mptcp-client mptcp endpoint add 192.168.0.2 dev red-client id \
     1 subflow

3. listen and accept on a port, such as 9999. The nc command we used
   here is modified, which makes it use mptcp protocol by default.
   $ ip netns exec mptcp-server nc -l -k -p 9999

4. open another *two* terminal and use each of them to connect to the
   server with the following command:
   $ ip netns exec mptcp-client nc 10.0.0.1 9999
   Input something after connect to trigger the connection of the second
   subflow. So that there are two established mptcp connections, with the
   second one still unaccepted.

5. exit all the nc command, and check the tcp socket in server namespace.
   And you will find that there is one tcp socket in CLOSE_WAIT state
   and can't release forever.

Fix this by closing all of the unaccepted mptcp socket in
mptcp_subflow_queue_clean() with __mptcp_close().

Now, we can ensure that all unaccepted mptcp sockets will be cleaned by
__mptcp_close() before they are released, so mptcp_sock_destruct(), which
is used to clean the unaccepted mptcp socket, is not needed anymore.

The selftests for mptcp is ran for this commit, and no new failures.

Fixes: f296234c98 ("mptcp: Add handling of incoming MP_JOIN requests")
Fixes: 6aeed90450 ("mptcp: fix race on unaccepted mptcp sockets")
Cc: stable@vger.kernel.org
Reviewed-by: Jiang Biao <benbjiang@tencent.com>
Reviewed-by: Mengen Sun <mengensun@tencent.com>
Acked-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Menglong Dong <imagedong@tencent.com>
Signed-off-by: Mat Martineau <mathew.j.martineau@linux.intel.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-09-28 19:05:21 -07:00
Menglong Dong
26d3e21ce1 mptcp: factor out __mptcp_close() without socket lock
Factor out __mptcp_close() from mptcp_close(). The caller of
__mptcp_close() should hold the socket lock, and cancel mptcp work when
__mptcp_close() returns true.

This function will be used in the next commit.

Fixes: f296234c98 ("mptcp: Add handling of incoming MP_JOIN requests")
Fixes: 6aeed90450 ("mptcp: fix race on unaccepted mptcp sockets")
Cc: stable@vger.kernel.org
Reviewed-by: Jiang Biao <benbjiang@tencent.com>
Reviewed-by: Mengen Sun <mengensun@tencent.com>
Acked-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Menglong Dong <imagedong@tencent.com>
Signed-off-by: Mat Martineau <mathew.j.martineau@linux.intel.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-09-28 19:05:21 -07:00
Jakub Kicinski
3e1308a7c8 Merge branch '100GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/net-queue
Tony Nguyen says:

====================
ice: xsk: ZC changes

Maciej Fijalkowski says:

This set consists of two fixes to issues that were either pointed out on
indirectly (John was reviewing AF_XDP selftests that were testing ice's
ZC support) mailing list or were directly reported by customers.

First patch allows user space to see done descriptor in CQ even after a
single frame being transmitted and second patch removes the need for
having HW rings sized to power of 2 number of descriptors when used
against AF_XDP.

I also forgot to mention that due to the current Tx cleaning algorithm,
4k HW ring was broken and these two patches bring it back to life, so we
kill two birds with one stone.

* '100GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/net-queue:
  ice: xsk: drop power of 2 ring size restriction for AF_XDP
  ice: xsk: change batched Tx descriptor cleaning
====================

Link: https://lore.kernel.org/r/20220927164112.4011983-1-anthony.l.nguyen@intel.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-09-28 19:04:43 -07:00
Daniel Golle
c9da02bfb1 net: ethernet: mtk_eth_soc: fix mask of RX_DMA_GET_SPORT{,_V2}
The bitmasks applied in RX_DMA_GET_SPORT and RX_DMA_GET_SPORT_V2 macros
were swapped. Fix that.

Reported-by: Chen Minqiang <ptpt52@gmail.com>
Fixes: 160d3a9b19 ("net: ethernet: mtk_eth_soc: introduce MTK_NETSYS_V2 support")
Acked-by: Lorenzo Bianconi <lorenzo@kernel.org>
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Link: https://lore.kernel.org/r/YzMW+mg9UsaCdKRQ@makrotopia.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-09-28 19:03:57 -07:00
Vladimir Oltean
276d37eb44 net: mscc: ocelot: fix tagged VLAN refusal while under a VLAN-unaware bridge
Currently the following set of commands fails:

$ ip link add br0 type bridge # vlan_filtering 0
$ ip link set swp0 master br0
$ bridge vlan
port              vlan-id
swp0              1 PVID Egress Untagged
$ bridge vlan add dev swp0 vid 10
Error: mscc_ocelot_switch_lib: Port with more than one egress-untagged VLAN cannot have egress-tagged VLANs.

Dumping ocelot->vlans, one can see that the 2 egress-untagged VLANs on swp0 are
vid 1 (the bridge PVID) and vid 4094, a PVID used privately by the driver for
VLAN-unaware bridging. So this is why bridge vid 10 is refused, despite
'bridge vlan' showing a single egress untagged VLAN.

As mentioned in the comment added, having this private VLAN does not impose
restrictions to the hardware configuration, yet it is a bookkeeping problem.

There are 2 possible solutions.

One is to make the functions that operate on VLAN-unaware pvids:
- ocelot_add_vlan_unaware_pvid()
- ocelot_del_vlan_unaware_pvid()
- ocelot_port_setup_dsa_8021q_cpu()
- ocelot_port_teardown_dsa_8021q_cpu()
call something different than ocelot_vlan_member_(add|del)(), the latter being
the real problem, because it allocates a struct ocelot_bridge_vlan *vlan which
it adds to ocelot->vlans. We don't really *need* the private VLANs in
ocelot->vlans, it's just that we have the extra convenience of having the
vlan->portmask cached in software (whereas without these structures, we'd have
to create a raw ocelot_vlant_rmw_mask() procedure which reads back the current
port mask from hardware).

The other solution is to filter out the private VLANs from
ocelot_port_num_untagged_vlans(), since they aren't what callers care about.
We only need to do this to the mentioned function and not to
ocelot_port_num_tagged_vlans(), because private VLANs are never egress-tagged.

Nothing else seems to be broken in either solution, but the first one requires
more rework which will conflict with the net-next change  36a0bf4435 ("net:
mscc: ocelot: set up tag_8021q CPU ports independent of user port affinity"),
and I'd like to avoid that. So go with the other one.

Fixes: 54c3198460 ("net: mscc: ocelot: enforce FDB isolation when VLAN-unaware")
Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Link: https://lore.kernel.org/r/20220927122042.1100231-1-vladimir.oltean@nxp.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-09-28 19:03:28 -07:00
Ashutosh Dixit
7738be973f drm/i915/gt: Perf_limit_reasons are only available for Gen11+
Register GT0_PERF_LIMIT_REASONS (0x1381a8) is available only for
Gen11+. Therefore ensure perf_limit_reasons sysfs files are created only
for Gen11+. Otherwise on Gen < 5 accessing these files results in the
following oops:

<1> [88.829420] BUG: unable to handle page fault for address: ffffc90000bb81a8
<1> [88.829438] #PF: supervisor read access in kernel mode
<1> [88.829447] #PF: error_code(0x0000) - not-present page

This patch is a backport of the drm-tip commit 0d2d201095e9
("drm/i915: Perf_limit_reasons are only available for Gen11+") to
drm-intel-fixes. The backport is not identical to the original, it only
includes the sysfs portions of if. The debugfs portion is not available
in drm-intel-fixes so has not been backported.

Bspec: 20008
Bug: https://gitlab.freedesktop.org/drm/intel/-/issues/6863
Fixes: fa68bff7cf ("drm/i915/gt: Add sysfs throttle frequency interfaces")
Signed-off-by: Ashutosh Dixit <ashutosh.dixit@intel.com>
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220919162401.2077713-1-ashutosh.dixit@intel.com
(backported from commit 0d2d201095e9f141d6a9fb44320afce761f8b5c2)
2022-09-28 16:39:26 -04:00
Linus Torvalds
c3e0e1e23c Pull more irqchip fixes for 6.0 from Marc Zyngier:
- A couple of configuration fixes for the recently merged Loongarch drivers
 
   - A fix to avoid dynamic allocation of a cpumask which was causing issues
     with PREEMPT_RT and the GICv3 ITS
 
   - A tightening of an error check in the stm32 exti driver
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEzv7L6UO9uDPlPSfHEsHwGGHeVUoFAmM0DBMACgkQEsHwGGHe
 VUpyQRAAldHdGN7/Gb1KwPmZ9lHXU+pt9VRm2CsC2EnBH4XclQHNIYXVHJvhHZ8H
 K/QfdYRBdWCJsGh+tU+swIgizsmDfZ38dpqtbY6zcZbbh8JabI7LVYRUJ+AKUtCu
 fIcInQ/GLwa4HmAH17BDeXLqm3xL9PzIteB1BddUbiBgSOxkUGu4q64zPdmlkXuS
 l5fmqD8UBK8rG5RO4ZPY6olX0oKkBAJbwDj079cRDU1COx8zUXE3bq3aTQi4j2t4
 ZqAdagmVGJHjIY9Oro7su/Mxo1kdSh+i5AIQ9PvQWQM+z2/jos9DMIJyDsqSiXXG
 /N7ieSeTpdf5Dxfi5XxnR8m5WnTznX2M4vBSpA++5diZ5lSu9kHJIM9mL8QttPXQ
 +BM7Mw0PI8+HQVbhbtFUg/RG5kQYI5q8oxHFzOx4haHd275HH57prfn1FBDdrzBX
 uD/Suyrj5AovazT/GkS/EVGY6O+YhSCa8atlL8xRSAcHd4xoCAmBUFfRHfbIxst+
 jp7hVgnevaEiWbSx46p6E4wXtQmKR79Cg/KT69FIQhOiX8RlwyaXuqnMjKcRz8np
 KNgOSZ8ggUfLx4hog0N8lK/0+QJLQB1sWe03X3NhqBaD5EITya0xinF2tYRix7PT
 6qpY+OOdCmTbBwo5bYHS5XU5Zmv1jLN2oQNu1ja0H2K+90th2HU=
 =uGHJ
 -----END PGP SIGNATURE-----

Merge tag 'irq_urgent_for_v6.0' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

Pull more irqchip fixes from Borislav Petkov:
 "More irqchip fixes for 6.0 from Marc Zyngier. Stuff got left hanging
  due to the whole Plumbers and vacations commotion.

   - A couple of configuration fixes for the recently merged Loongarch
     drivers

   - A fix to avoid dynamic allocation of a cpumask which was causing
     issues with PREEMPT_RT and the GICv3 ITS

   - A tightening of an error check in the stm32 exti driver"

* tag 'irq_urgent_for_v6.0' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  irqchip/loongson-pch-lpc: Add dependence on LoongArch
  irqchip: Select downstream irqchip drivers for LoongArch CPU
  irqchip/gic-v3-its: Remove cpumask_var_t allocation
  irqchip/stm32-exti: Remove check on always false condition
2022-09-28 11:54:57 -07:00
Linus Torvalds
e817c070fd MMC core:
- Terminate infinite loop in SD-UHS voltage switch
 
 MMC host:
  - hsq: Fix kernel crash in the recovery path
  - moxart: Fix bus width configurations
  - sdhci: Fix kernel panic for cqe irq
 
 ARM_SCMI:
  - Fixup clock management by reverting "firmware: arm_scmi: Add clock
    management to the SCMI power domain"
 -----BEGIN PGP SIGNATURE-----
 
 iQJLBAABCgA1FiEEugLDXPmKSktSkQsV/iaEJXNYjCkFAmM0BoQXHHVsZi5oYW5z
 c29uQGxpbmFyby5vcmcACgkQ/iaEJXNYjCmFIw//ZhctvlbOQa2StMO2GrJfgQGi
 ELclXWN1MzyyTN2v93LRrIwu1FR3vFV8sJ/80wlt+o0l4XBuwewmlUXdxGEdKwKA
 2+Luj5f2sDf1z9wXsVLjybQ7ujD60jSrXgO6sGvF8a4cy0sCW7O3/3sytrXXHqzj
 vU5zvr4Y6aBiruEpAFXBKyGWxpj0iFjvMo+ZuJpOHgHiVSF2UWOXuLbuAn04ESG6
 Z3sn8qMZbTFI1HoE2XHF7xB10j9sYu09Urp57xAUFLuYf7Rr+MRNDqjByESnl9H7
 SZcgomCoycUyjSDSLqdrr0Z4eJ7zacyHRHEYEzX/owAanE9GQpwGDauDYrVHFn7o
 75uT6ZhJZwoLguM+6NiURYraIl75o4ijDKhFYrm+8dEmFfTi3hy9Ey86pFsr3UWm
 RC+Dxi/oY7mkrpAEwJwkixzUGKqX/42a9zBcUbejE8x1UEw8sljboz3kEzTBlaDU
 4mhdeY5//dHOhl3V8V9Oj9rQZJ7jfPJbrg0qK65EEDW5TumMTGnQzR9Zl1BfWBIA
 lzIKq3USZ+5Gm8KvZ0yYq8bHmGaYKd/aFfZ3RTHIsPPx7pXt0G81SkE+eJ/jDkRN
 FL7TU1wgWU9ovFw0N1LScr/EH/juIl+3bqhMRSuk5cBgDdVuCmKT5XS/694GfZkl
 /JUySvxena/yGlNn/Mg=
 =F5JH
 -----END PGP SIGNATURE-----

Merge tag 'mmc-v6.0-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc

Pull MMC fixes from Ulf Hansson:
 "A couple of MMC fixes. This time there is also a fix for the ARM SCMI
  firmware driver, which has been acked by Sudeep Holla, the maintainer.

  MMC core:
   - Terminate infinite loop in SD-UHS voltage switch

  MMC host:
   - hsq: Fix kernel crash in the recovery path
   - moxart: Fix bus width configurations
   - sdhci: Fix kernel panic for cqe irq

  ARM_SCMI:
   - Fixup clock management by reverting 'firmware: arm_scmi: Add clock
     management to the SCMI power domain'"

* tag 'mmc-v6.0-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc:
  mmc: hsq: Fix data stomping during mmc recovery
  Revert "firmware: arm_scmi: Add clock management to the SCMI power domain"
  mmc: core: Terminate infinite loop in SD-UHS voltage switch
  mmc: moxart: fix 4-bit bus width and remove 8-bit bus width
  mmc: sdhci: Fix host->cmd is null
2022-09-28 11:36:31 -07:00
Al Viro
06bbaa6dc5 [coredump] don't use __kernel_write() on kmap_local_page()
passing kmap_local_page() result to __kernel_write() is unsafe -
random ->write_iter() might (and 9p one does) get unhappy when
passed ITER_KVEC with pointer that came from kmap_local_page().

Fix by providing a variant of __kernel_write() that takes an iov_iter
from caller (__kernel_write() becomes a trivial wrapper) and adding
dump_emit_page() that parallels dump_emit(), except that instead of
__kernel_write() it uses __kernel_write_iter() with ITER_BVEC source.

Fixes: 3159ed5779 "fs/coredump: use kmap_local_page()"
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2022-09-28 14:28:40 -04:00
Jakub Kicinski
af2faee54d linux-can-fixes-for-6.0-20220928
-----BEGIN PGP SIGNATURE-----
 
 iQFHBAABCgAxFiEEBsvAIBsPu6mG7thcrX5LkNig010FAmM0DS0THG1rbEBwZW5n
 dXRyb25peC5kZQAKCRCtfkuQ2KDTXS8bB/0UKBWajoi4p5zhPnflDk8iHJslbfPe
 NRrLP4r7ZU9gxpa6Pbx7bIvIMlU7GbzF7zwOp20PmfbGsY+naABIzx6BOWYh4f2H
 4qbOHoHG3SpsUWYGbhRsiXatxtIB1DfvqWMTGrbl4x4bE1dco40Pi/c+TMo6DtGt
 uqKHxzoFB1LE/BRD0c1f1NFKkZ04rYrWL9TS00plxV2T7V3srmQ3eaxAAtuI9peV
 NbnUoV6zwleAKzyeOTvzdF6xsTHEuQ4S3f7rXAEMLzuoZjbm4noe3CgiKM6TurWW
 ZR7495k9s2kL2ObjmsoH+mj93J0S6Cmtu+AQWHfJbDSIaZfu5WzyllTI
 =LvG9
 -----END PGP SIGNATURE-----

Merge tag 'linux-can-fixes-for-6.0-20220928' of git://git.kernel.org/pub/scm/linux/kernel/git/mkl/linux-can

Marc Kleine-Budde says:

====================
pull-request: can 2022-09-28

The patch is by me and targets the c_can driver. It disables an
optimization in the TX path of C_CAN cores which causes problems.

* tag 'linux-can-fixes-for-6.0-20220928' of git://git.kernel.org/pub/scm/linux/kernel/git/mkl/linux-can:
  can: c_can: don't cache TX messages for C_CAN cores
====================

Link: https://lore.kernel.org/r/20220928090629.1124190-1-mkl@pengutronix.de
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-09-28 10:48:38 -07:00
Shakeel Butt
b1cab78ba3 Revert "net: set proper memcg for net_init hooks allocations"
This reverts commit 1d0403d20f.

Anatoly Pugachev reported that the commit 1d0403d20f ("net: set proper
memcg for net_init hooks allocations") is somehow causing the sparc64
VMs failed to boot and the VMs boot fine with that patch reverted. So,
revert the patch for now and later we can debug the issue.

Link: https://lore.kernel.org/all/20220918092849.GA10314@u164.east.ru/
Reported-by: Anatoly Pugachev <matorola@gmail.com>
Signed-off-by: Shakeel Butt <shakeelb@google.com>
Cc: Vasily Averin <vvs@openvz.org>
Cc: Jakub Kicinski <kuba@kernel.org>
Cc: Michal Koutný <mkoutny@suse.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: cgroups@vger.kernel.org
Cc: sparclinux@vger.kernel.org
Cc: linux-mm@kvack.org
Cc: linux-kernel@vger.kernel.org
Tested-by: Anatoly Pugachev <matorola@gmail.com>
Acked-by: Johannes Weiner <hannes@cmpxchg.org>
Fixes: 1d0403d20f ("net: set proper memcg for net_init hooks allocations")
Reviewed-by: Muchun Song <songmuchun@bytedance.com>
Acked-by: Roman Gushchin <roman.gushchin@linux.dev>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2022-09-28 09:20:37 -07:00
Damien Le Moal
141f3d6256 ata: libata-sata: Fix device queue depth control
The function __ata_change_queue_depth() uses the helper
ata_scsi_find_dev() to get the ata_device structure of a scsi device and
set that device maximum queue depth. However, when the ata device is
managed by libsas, ata_scsi_find_dev() returns NULL, turning
__ata_change_queue_depth() into a nop, which prevents the user from
setting the maximum queue depth of ATA devices used with libsas based
HBAs.

Fix this by renaming __ata_change_queue_depth() to
ata_change_queue_depth() and adding a pointer to the ata_device
structure of the target device as argument. This pointer is provided by
ata_scsi_change_queue_depth() using ata_scsi_find_dev() in the case of
a libata managed device and by sas_change_queue_depth() using
sas_to_ata_dev() in the case of a libsas managed ata device.

Signed-off-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Tested-by: John Garry <john.garry@huawei.com>
2022-09-28 20:47:31 +09:00
Damien Le Moal
6a8438de52 ata: libata-scsi: Fix initialization of device queue depth
For SATA devices supporting NCQ, drivers using libsas first initialize a
scsi device queue depth based on the controller and device capabilities,
leading to the scsi device queue_depth field being 32 (ATA maximum queue
depth) for most setup. However, if libata was loaded using the
force=[ID]]noncq argument, the default queue depth should be set to 1 to
reflect the fact that queuable commands will never be used. This is
consistent with manually setting a device queue depth to 1 through sysfs
as that disables NCQ use for the device.

Fix ata_scsi_dev_config() to honor the noncq parameter by sertting the
device queue depth to 1 for devices that do not have the ATA_DFLAG_NCQ
flag set.

Signed-off-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Tested-by: John Garry <john.garry@huawei.com>
2022-09-28 20:47:26 +09:00
Marc Kleine-Budde
81d192c2ce can: c_can: don't cache TX messages for C_CAN cores
As Jacob noticed, the optimization introduced in 387da6bc7a ("can:
c_can: cache frames to operate as a true FIFO") doesn't properly work
on C_CAN, but on D_CAN IP cores. The exact reasons are still unknown.

For now disable caching if CAN frames in the TX path for C_CAN cores.

Fixes: 387da6bc7a ("can: c_can: cache frames to operate as a true FIFO")
Link: https://lore.kernel.org/all/20220928083354.1062321-1-mkl@pengutronix.de
Link: https://lore.kernel.org/all/15a8084b-9617-2da1-6704-d7e39d60643b@gmail.com
Reported-by: Jacob Kroon <jacob.kroon@gmail.com>
Tested-by: Jacob Kroon <jacob.kroon@gmail.com>
Cc: stable@vger.kernel.org # v5.15
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2022-09-28 10:34:04 +02:00
Jakub Kicinski
44d70bb561 A few late-comer fixes:
* locking in mac80211 MLME
  * non-QoS driver crash/regression
  * minstrel memory corruption
  * TX deadlock
  * TX queues not always enabled
  * HE/EHT bitrate calculation
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEH1e1rEeCd0AIMq6MB8qZga/fl8QFAmMzAV4ACgkQB8qZga/f
 l8TLgBAAgONqYv2xbFnxue6yZY6OI+Ok3bhpqjcdlMBVKQa9iMnOGVMeB7W+M5AR
 cmMPiRnsW36WupQXVTAQB9lGUDZ6nsydDF653/bzmrEjjZO7l3vmJ4LJn37Febuj
 ecaIme6UJb9tW5YAzFEde8zpRaGnkEqZyviDMg5mDTzeLglBQcvidJC7rlAy831b
 lEUyNSIwzEUgZcZLk68wDmaMUbSDhpZ+0r1IZtrAnpd0BlP4G5sfDkZQ4Hv9dUMx
 kP5X4/1EVgzqYJihJgiEVujgKVSaqonC4nY4I6TBf3JoRuulZk1dTl94o+RORpdT
 8aZRGk2KLPWMfRCcaWsekbyqLwtdT8y8QoO9+F549Zck2uuZ64BMzVCYSjW3UDaw
 iUjjQklkG9lvQnT96egEWwE0dvx834dsru6gfBNw1JErpxqSk05otjaDRP0Ioolh
 EqYjCsvk6cbeBX6OOlAt1+73PYMqZ6ZR90c+xeF5E2gclGuZYSZ7VEwHtrWB0biy
 U2YxrRDC+00hicG71iMsxY6woRUxTCRAwZ12OnC3gI790zlAHT/SvRjFSe8WuQ5r
 Ay+EOqVqd/03zQiS3ekBuHJUv/s71a9UVKkyEVtWrUUWsZhMUGQuWc9HvYLfaYxF
 Kem2Kb0LzYkF7v8HHsqXqhj9rdt1L221vNYlgVTOvZar9to7cLo=
 =krtf
 -----END PGP SIGNATURE-----

Merge tag 'wireless-2022-09-27' of git://git.kernel.org/pub/scm/linux/kernel/git/wireless/wireless

Johannes Berg says:

====================
A few late-comer fixes:
 * locking in mac80211 MLME
 * non-QoS driver crash/regression
 * minstrel memory corruption
 * TX deadlock
 * TX queues not always enabled
 * HE/EHT bitrate calculation

* tag 'wireless-2022-09-27' of git://git.kernel.org/pub/scm/linux/kernel/git/wireless/wireless:
  wifi: mac80211: mlme: Fix double unlock on assoc success handling
  wifi: mac80211: mlme: Fix missing unlock on beacon RX
  wifi: mac80211: fix memory corruption in minstrel_ht_update_rates()
  wifi: mac80211: fix regression with non-QoS drivers
  wifi: mac80211: ensure vif queues are operational after start
  wifi: mac80211: don't start TX with fq->lock to fix deadlock
  wifi: cfg80211: fix MCS divisor value
====================

Link: https://lore.kernel.org/r/20220927135923.45312-1-johannes@sipsolutions.net
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-09-27 16:52:45 -07:00
Linus Torvalds
49c13ed031 ARM: SoC fixes for 6.0-rc7
This should be the last set of bugfixes in the SoC tree:
 
  - Two fixes for Arm integrator, dealing with a regression caused
    by invalid DT properties combined with a change in dma address
    translation, and missing device_type annotations on the PCI
    bus.
 
  - Fixes for drivers/reset/, addressing bugs in i.MX8MP, Sparx5 and
    NPCM8XX platforms.
 
  - Bjorn Andersson's email address changes in the MAINTAINERS file
 
  - Multiple minor fixes to Qualcomm dts files, and a change to the
    remoteproc firmware filename that did not match the actual
    path in the linux-firmware package.
 
  - Minor code fixes for the Allwinner/sunxi SRAM driver, and the
    broadcom STB Bus Interface Unit driver
 
  - A build fix for the sunplus sp7021 platform
 
  - Two dts fixes for TI OMAP family SoCs, addressing an extraneous
    usb4 device node and an incorrect DMA handle.
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMzbMYACgkQmmx57+YA
 GNnPnA/+IhwfCRrfLdDpzekitMNN/wWa3YcSRKc8LvIIg3lLjcHX8jt8/8bfiB5m
 L/QgfaM8s0C0fh6PN1iXBXlWQEXc/hUyYS0EcEY9qTy4S8Yx0oukByhV9W76oROE
 WeSF3J2WeLxTolj8Tli6iKJRPlv6/CjNSkhjmdECpwkrRpD5AV6Xkr/B5AJntn0X
 huPgpixJ5O6vW5D1qgtF1QejJIzKvkohQIEaWaQ4zJJwTIujXmjvv6Dt7b5/+hKt
 8qhhJe8VOVjnrZZz8FD3xoGp4+p+plkaPhG2SmMn2IdE6Wf/yVuWwzjXAF250vH7
 /IGh1IHUYG6Vbt/gKk47wre+Kjzmzlj9v9P1XpI4OlTGUvqiaFdwg9LWcgrS2cR6
 pQOfhVBmphsE+zODo7aCCCh8I9ZX0eXhcOpMIdEPeGYQgR1jjDnIOiCf8bhsZoEy
 8a8zKH6UvhHQkNO0bzUComcU/LWY1EjnKzb9OGzekEb45bwxjhRLLdIghGpcb2Sb
 dnhjQ2MFrlOonbrGxupmC5zgCmdoyoH7MlvOI58IeehAGW79LRsgVrD3hGrmJuBc
 Gu63RDmbXNn2rktOurRcl/z8JcYf/lA7saK83PcYomYHDAXqYGkhnXpwcMlEsUeQ
 CPcgkCOWSorl5yevghWAAJOCPOZmIG1bZuaqc8cD4bvYWpLAxLY=
 =3Mv6
 -----END PGP SIGNATURE-----

Merge tag 'soc-fixes-6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc

Pull ARM SoC fixes from Arnd Bergmann:
 "This should be the last set of bugfixes in the SoC tree:

   - Two fixes for Arm integrator, dealing with a regression caused by
     invalid DT properties combined with a change in dma address
     translation, and missing device_type annotations on the PCI bus

   - Fixes for drivers/reset/, addressing bugs in i.MX8MP, Sparx5 and
     NPCM8XX platforms

   - Bjorn Andersson's email address changes in the MAINTAINERS file

   - Multiple minor fixes to Qualcomm dts files, and a change to the
     remoteproc firmware filename that did not match the actual path in
     the linux-firmware package

   - Minor code fixes for the Allwinner/sunxi SRAM driver, and the
     broadcom STB Bus Interface Unit driver

   - A build fix for the sunplus sp7021 platform

   - Two dts fixes for TI OMAP family SoCs, addressing an extraneous
     usb4 device node and an incorrect DMA handle"

* tag 'soc-fixes-6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc:
  ARM: dts: integrator: Fix DMA ranges
  ARM: dts: integrator: Tag PCI host with device_type
  ARM: sunplus: fix serial console kconfig and build problems
  reset: npcm: fix iprst2 and iprst4 setting
  arm64: dts: qcom: sm8350: fix UFS PHY serdes size
  soc: bcm: brcmstb: biuctrl: Avoid double of_node_put()
  arm64: dts: qcom: sc8280xp-x13s: Update firmware location
  soc: sunxi: sram: Fix debugfs info for A64 SRAM C
  soc: sunxi: sram: Fix probe function ordering issues
  soc: sunxi: sram: Prevent the driver from being unbound
  soc: sunxi: sram: Actually claim SRAM regions
  ARM: dts: am5748: keep usb4_tm disabled
  reset: microchip-sparx5: issue a reset on startup
  reset: imx7: Fix the iMX8MP PCIe PHY PERST support
  MAINTAINERS: Update Bjorn's email address
  arm64: dts: qcom: sc7280: move USB wakeup-source property
  arm64: dts: qcom: thinkpad-x13s: Fix firmware location
  arm64: dts: qcom: sm8150: Fix fastrpc iommu values
  ARM: dts: am33xx: Fix MMCHS0 dma properties
2022-09-27 16:49:42 -07:00
Bokun Zhang
3b7329cf5a drm/amdgpu: Add amdgpu suspend-resume code path under SRIOV
- Under SRIOV, we need to send REQ_GPU_FINI to the hypervisor
  during the suspend time. Furthermore, we cannot request a
  mode 1 reset under SRIOV as VF. Therefore, we will skip it
  as it is called in suspend_noirq() function.

- In the resume code path, we need to send REQ_GPU_INIT to the
  hypervisor and also resume PSP IP block under SRIOV.

Signed-off-by: Bokun Zhang <Bokun.Zhang@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
2022-09-27 18:03:36 -04:00
Jiadong.Zhu
11e38360cc drm/amdgpu: Remove fence_process in count_emitted
The function amdgpu_fence_count_emitted used in work_hander should not call
amdgpu_fence_process which must be used in irq handler.

Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Jiadong.Zhu <Jiadong.Zhu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 18:03:09 -04:00
Jiadong.Zhu
b3e45b18e5 drm/amdgpu: Correct the position in patch_cond_exec
The current position calulated in gfx_v9_0_ring_emit_patch_cond_exec
underflows when the wptr is divisible by ring->buf_mask + 1.

Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Jiadong.Zhu <Jiadong.Zhu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 18:02:58 -04:00
Samson Tam
2d3907c152 drm/amd/display: fill in clock values when DPM is not enabled
[Why]
For individual feature testing, PMFW may not report all clock
values back. Driver will default them to 0 but this will
cause the BB table to be skipped and default to one state
with max clocks.

[How]
Add helper function to scan through initial clock values and
populate them with default clock limits so that BB table
can be built.
Add dpm_enabled flag to check when DPM is not enabled and
to trigger helper function.

Reviewed-by: Jun Lei <Jun.Lei@amd.com>
Acked-by: Jasdeep Dhillon <jdhillon@amd.com>
Signed-off-by: Samson Tam <samson.tam@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 18:00:01 -04:00
Taimur Hassan
a28acf7091 drm/amd/display: Avoid unnecessary pixel rate divider programming
[Why]
Programming pixel rate divider when FIFO is enabled can cause FIFO error.

[How]
Skip divider programming when divider values are the same to prevent FIFO
error.

Reviewed-by: Alvin Lee <alvin.lee2@amd.com>
Acked-by: Jasdeep Dhillon <jdhillon@amd.com>
Signed-off-by: Taimur Hassan <Syed.Hassan@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 17:59:07 -04:00
Eric Bernstein
8dd2e87dbd drm/amd/display: Remove assert for odm transition case
Remove assert that will hit during odm transition case, since this is a
valid case.

Signed-off-by: Eric Bernstein <eric.bernstein@amd.com>
Reviewed-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 17:58:48 -04:00
Taimur Hassan
391ce355e7 drm/amd/display: Fix typo in get_pixel_rate_div
[Why & How]
Some FIFO errors still occur due to reading wrong pixel rate divider.
Fix typo to prevent FIFO error.

Reviewed-by: Nicholas Kazlauskas <Nicholas.Kazlauskas@amd.com>
Acked-by: Jasdeep Dhillon <jdhillon@amd.com>
Signed-off-by: Taimur Hassan <Syed.Hassan@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 17:58:07 -04:00
Aric Cyr
1ec5c0e128 drm/amd/display: Fix audio on display after unplugging another
Revert "dc: skip audio setup when audio stream is enabled"

This reverts commit 65fbfb02c2

[why]
We have minimal pipe split transition method to avoid pipe
allocation outage.However, this method will invoke audio setup
which cause audio output stuck once pipe reallocate.

[how]
skip audio setup for pipelines which audio stream has been enabled

Reviewed-by: Martin Leung <Martin.Leung@amd.com>
Acked-by: Jasdeep Dhillon <jdhillon@amd.com>
Signed-off-by: Aric Cyr <aric.cyr@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 17:57:46 -04:00
Nicholas Kazlauskas
85096a73f4 drm/amd/display: Add explicit FIFO disable for DP blank
[Why]
We rely on DMCUB to do this when disabling the link but it should
actually come before we disable the DP VID stream.

If we don't then the FIFO can end up with underflow that persists
the next time it's enabled.

[How]
Add a DCN314 specific blank sequence that will disable the DIG FIFO
first.

Reviewed-by: Syed Hassan <Syed.Hassan@amd.com>
Acked-by: Jasdeep Dhillon <jdhillon@amd.com>
Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 17:56:51 -04:00
Nicholas Kazlauskas
ec669ef2e2 drm/amd/display: Wrap OTG disable workaround with FIFO control
[Why]
The DIO FIFO will underflow if we turn off the OTG before we turn
off the FIFO.

Since this happens as part of the OTG workaround and we don't reset
the FIFO afterwards we see the error persist.

[How]
Add disable FIFO before the disable CRTC and enable FIFO after enabling
the CRTC.

Reviewed-by: Syed Hassan <Syed.Hassan@amd.com>
Acked-by: Jasdeep Dhillon <jdhillon@amd.com>
Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 17:56:29 -04:00
Nicholas Kazlauskas
dd37fba90e drm/amd/display: Do DIO FIFO enable after DP video stream enable
[Why]
Avoids a race condition where DIO FIFO can underflow due to no incoming
data available.

[How]
Shift the FIFO enable below stream enable.

Make sure fullness level is written before the DIO reset takes place
and that we're not doing it twice.

Reviewed-by: Syed Hassan <Syed.Hassan@amd.com>
Acked-by: Jasdeep Dhillon <jdhillon@amd.com>
Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 17:55:44 -04:00
Alvin Lee
b6d1c39bc6 drm/amd/display: Update DCN32 to use new SR latencies
[Description]
Update to new SR latencies for DCN32

Reviewed-by: Nevenko Stupar <Nevenko.Stupar@amd.com>
Reviewed-by: Jun Lei <Jun.Lei@amd.com>
Acked-by: Jasdeep Dhillon <jdhillon@amd.com>
Signed-off-by: Alvin Lee <Alvin.Lee2@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 17:55:11 -04:00
Taimur Hassan
783d446749 drm/amd/display: Avoid avoid unnecessary pixel rate divider programming
[Why]
Programming pixel rate divider when FIFO is enabled can cause FIFO error.

[How]
Skip divider programming when divider values are the same to prevent FIFO
error.

Reviewed-by: Nicholas Kazlauskas <Nicholas.Kazlauskas@amd.com>
Acked-by: Jasdeep Dhillon <jdhillon@amd.com>
Signed-off-by: Taimur Hassan <Syed.Hassan@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 17:54:56 -04:00
Graham Sider
664883ddde drm/amdkfd: fix dropped interrupt in kfd_int_process_v11
Shader wave interrupts were getting dropped in event_interrupt_wq_v11
if the PRIV bit was set to 1. This would often lead to a hang. Until
debugger logic is upstreamed, expand comment to stop early return.

Signed-off-by: Graham Sider <Graham.Sider@amd.com>
Reviewed-by: Harish Kasiviswanathan <Harish.Kasiviswanathan@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 17:54:25 -04:00
Graham Sider
91ef6cfd30 drm/amdgpu: pass queue size and is_aql_queue to MES
Update mes_v11_api_def.h add_queue API with is_aql_queue parameter. Also
re-use gds_size for the queue size (unused for KFD). MES requires the
queue size in order to compute the actual wptr offset within the queue
RB since it increases monotonically for AQL queues.

v2: Make is_aql_queue assign clearer

Signed-off-by: Graham Sider <Graham.Sider@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 17:54:12 -04:00
Graham Sider
a9b4700279 drm/amdkfd: fix MQD init for GFX11 in init_mqd
Set remaining compute_static_thread_mgmt_se* accordingly.

Signed-off-by: Graham Sider <Graham.Sider@amd.com>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 17:54:01 -04:00
Evan Quan
b9caeadf5c drm/amd/pm: use adverse selection for dpm features unsupported by driver
It's vbios and pmfw instead of driver who decide whether some dpm features
is supported or not. Driver just de-selects those features which are not
permitted on user's request. Thus, we use adverse selects model.

Signed-off-by: Evan Quan <evan.quan@amd.com>
Reviewed-by: Lijo Lazar <lijo.lazar@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2022-09-27 17:47:07 -04:00