Commit Graph

22509 Commits

Author SHA1 Message Date
Masahiro Yamada ce697ccee1 kbuild: remove head-y syntax
Kbuild puts the objects listed in head-y at the head of vmlinux.
Conventionally, we do this for head*.S, which contains the kernel entry
point.

A counter approach is to control the section order by the linker script.
Actually, the code marked as __HEAD goes into the ".head.text" section,
which is placed before the normal ".text" section.

I do not know if both of them are needed. From the build system
perspective, head-y is not mandatory. If you can achieve the proper code
placement by the linker script only, it would be cleaner.

I collected the current head-y objects into head-object-list.txt. It is
a whitelist. My hope is it will be reduced in the long run.

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Tested-by: Nick Desaulniers <ndesaulniers@google.com>
Reviewed-by: Nicolas Schier <nicolas@fjasle.eu>
2022-10-02 18:06:03 +09:00
Masahiro Yamada 3216484550 kbuild: use obj-y instead extra-y for objects placed at the head
The objects placed at the head of vmlinux need special treatments:

 - arch/$(SRCARCH)/Makefile adds them to head-y in order to place
   them before other archives in the linker command line.

 - arch/$(SRCARCH)/kernel/Makefile adds them to extra-y instead of
   obj-y to avoid them going into built-in.a.

This commit gets rid of the latter.

Create vmlinux.a to collect all the objects that are unconditionally
linked to vmlinux. The objects listed in head-y are moved to the head
of vmlinux.a by using 'ar m'.

With this, arch/$(SRCARCH)/kernel/Makefile can consistently use obj-y
for builtin objects.

There is no *.o that is directly linked to vmlinux. Drop unneeded code
in scripts/clang-tools/gen_compile_commands.py.

$(AR) mPi needs 'T' to workaround the llvm-ar bug. The fix was suggested
by Nathan Chancellor [1].

[1]: https://lore.kernel.org/llvm/YyjjT5gQ2hGMH0ni@dev-arch.thelio-3990X/

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Tested-by: Nick Desaulniers <ndesaulniers@google.com>
Reviewed-by: Nicolas Schier <nicolas@fjasle.eu>
2022-10-02 18:04:05 +09:00
Marc Zyngier b302ca52ba Merge branch kvm-arm64/misc-6.1 into kvmarm-master/next
* kvm-arm64/misc-6.1:
  : .
  : Misc KVM/arm64 fixes and improvement for v6.1
  :
  : - Simplify the affinity check when moving a GICv3 collection
  :
  : - Tone down the shouting when kvm-arm.mode=protected is passed
  :   to a guest
  :
  : - Fix various comments
  :
  : - Advertise the new kvmarm@lists.linux.dev and deprecate the
  :   old Columbia list
  : .
  KVM: arm64: Advertise new kvmarm mailing list
  KVM: arm64: Fix comment typo in nvhe/switch.c
  KVM: selftests: Update top-of-file comment in psci_test
  KVM: arm64: Ignore kvm-arm.mode if !is_hyp_mode_available()
  KVM: arm64: vgic: Remove duplicate check in update_affinity_collection()

Signed-off-by: Marc Zyngier <maz@kernel.org>
2022-10-01 10:19:36 +01:00
Jakub Kicinski 915b96c527 wireless-next patches for v6.1
Few stack changes and lots of driver changes in this round. brcmfmac
 has more activity as usual and it gets new hardware support. ath11k
 improves WCN6750 support and also other smaller features. And of
 course changes all over.
 
 Note: in early September wireless tree was merged to wireless-next to
 avoid some conflicts with mac80211 patches, this shouldn't cause any
 problems but wanted to mention anyway.
 
 Major changes:
 
 mac80211
 
 * refactoring and preparation for Wi-Fi 7 Multi-Link Operation (MLO)
   feature continues
 
 brcmfmac
 
 * support CYW43439 SDIO chipset
 
 * support BCM4378 on Apple platforms
 
 * support CYW89459 PCIe chipset
 
 rtw89
 
 * more work to get rtw8852c supported
 
 * P2P support
 
 * support for enabling and disabling MSDU aggregation via nl80211
 
 mt76
 
 * tx status reporting improvements
 
 ath11k
 
 * cold boot calibration support on WCN6750
 
 * Target Wake Time (TWT) debugfs support for STA interface
 
 * support to connect to a non-transmit MBSSID AP profile
 
 * enable remain-on-channel support on WCN6750
 
 * implement SRAM dump debugfs interface
 
 * enable threaded NAPI on all hardware
 
 * WoW support for WCN6750
 
 * support to provide transmit power from firmware via nl80211
 
 * support to get power save duration for each client
 
 * spectral scan support for 160 MHz
 
 wcn36xx
 
 * add SNR from a received frame as a source of system entropy
 -----BEGIN PGP SIGNATURE-----
 
 iQFFBAABCgAvFiEEiBjanGPFTz4PRfLobhckVSbrbZsFAmM3BGYRHGt2YWxvQGtl
 cm5lbC5vcmcACgkQbhckVSbrbZuR3Af/XiuMlnDB6flq+M/kQHLWWvHybLw5aCJ7
 l3yXhNFWxpBl2hQXtj17JSjVCYQmxbfrgRqhbNhyACO25bpymCb5QctB9X+Y7TwL
 250JmuKvQfFx5oJNRfJ67dKTf3raloQYbdEMJNqySgebL+eSfrDskc9vaCLVDmCK
 I994fl0Q1wUbJ6fbuIFd07ti8ay6UlSS/iakv4+nEeimabtZWJWlXBWYRpKpikdP
 h9z2kPtss6yz6seaQuw6ny+qysYLi11Tp+Cued9XR3dWOOhB2X1tLHH0H02xPw76
 9OJZEJHycP2juxjMfAaktHY+VX36GPLsMLUTVusH0h/Fdy3VG8YSAw==
 =emmG
 -----END PGP SIGNATURE-----

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

Kalle Valo says:

====================
wireless-next patches for v6.1

Few stack changes and lots of driver changes in this round. brcmfmac
has more activity as usual and it gets new hardware support. ath11k
improves WCN6750 support and also other smaller features. And of
course changes all over.

Note: in early September wireless tree was merged to wireless-next to
avoid some conflicts with mac80211 patches, this shouldn't cause any
problems but wanted to mention anyway.

Major changes:

mac80211

 - refactoring and preparation for Wi-Fi 7 Multi-Link Operation (MLO)
  feature continues

brcmfmac

 - support CYW43439 SDIO chipset

 - support BCM4378 on Apple platforms

 - support CYW89459 PCIe chipset

rtw89

 - more work to get rtw8852c supported

 - P2P support

 - support for enabling and disabling MSDU aggregation via nl80211

mt76

 - tx status reporting improvements

ath11k

 - cold boot calibration support on WCN6750

 - Target Wake Time (TWT) debugfs support for STA interface

 - support to connect to a non-transmit MBSSID AP profile

 - enable remain-on-channel support on WCN6750

 - implement SRAM dump debugfs interface

 - enable threaded NAPI on all hardware

 - WoW support for WCN6750

 - support to provide transmit power from firmware via nl80211

 - support to get power save duration for each client

 - spectral scan support for 160 MHz

wcn36xx

 - add SNR from a received frame as a source of system entropy

* tag 'wireless-next-2022-09-30' of git://git.kernel.org/pub/scm/linux/kernel/git/wireless/wireless-next: (231 commits)
  wifi: rtl8xxxu: Improve rtl8xxxu_queue_select
  wifi: rtl8xxxu: Fix AIFS written to REG_EDCA_*_PARAM
  wifi: rtl8xxxu: gen2: Enable 40 MHz channel width
  wifi: rtw89: 8852b: configure DLE mem
  wifi: rtw89: check DLE FIFO size with reserved size
  wifi: rtw89: mac: correct register of report IMR
  wifi: rtw89: pci: set power cut closed for 8852be
  wifi: rtw89: pci: add to do PCI auto calibration
  wifi: rtw89: 8852b: implement chip_ops::{enable,disable}_bb_rf
  wifi: rtw89: add DMA busy checking bits to chip info
  wifi: rtw89: mac: define DMA channel mask to avoid unsupported channels
  wifi: rtw89: pci: mask out unsupported TX channels
  iwlegacy: Replace zero-length arrays with DECLARE_FLEX_ARRAY() helper
  ipw2x00: Replace zero-length array with DECLARE_FLEX_ARRAY() helper
  wifi: iwlwifi: Track scan_cmd allocation size explicitly
  brcmfmac: Remove the call to "dtim_assoc" IOVAR
  brcmfmac: increase dcmd maximum buffer size
  brcmfmac: Support 89459 pcie
  brcmfmac: increase default max WOWL patterns to 16
  cw1200: fix incorrect check to determine if no element is found in list
  ...
====================

Link: https://lore.kernel.org/r/20220930150413.A7984C433D6@smtp.kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-09-30 10:07:31 -07:00
Dmitry Torokhov bd1a665a01 arm64: dts: exynos: fix polarity of "enable" line of NFC chip in TM2
According to s3fwrn5 driver code the "enable" GPIO line is driven "high"
when chip is not in use (mode is S3FWRN5_MODE_COLD), and is driven "low"
when chip is in use.

s3fwrn5_phy_power_ctrl():

	...
	gpio_set_value(phy->gpio_en, 1);
	...
	if (mode != S3FWRN5_MODE_COLD) {
		msleep(S3FWRN5_EN_WAIT_TIME);
		gpio_set_value(phy->gpio_en, 0);
		msleep(S3FWRN5_EN_WAIT_TIME);
	}

Therefore the line described by "en-gpios" property should be annotated
as "active low".

The wakeup gpio appears to have correct polarity (active high).

Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Link: https://lore.kernel.org/r/20220929011557.4165216-1-dmitry.torokhov@gmail.com
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
2022-09-30 14:23:33 +02:00
Jianguo Zhang 7871785ce9 arm64: dts: mediatek: mt2712e: Update the name of property 'clk_csr'
Update the name of property 'clk_csr' as 'snps,clk-csr' to align with
the property name in the binding file.

Signed-off-by: Jianguo Zhang <jianguo.zhang@mediatek.com>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2022-09-30 13:04:23 +01:00
Paolo Bonzini c99ad25b0d Merge tag 'kvm-x86-6.1-2' of https://github.com/sean-jc/linux into HEAD
KVM x86 updates for 6.1, batch #2:

 - Misc PMU fixes and cleanups.

 - Fixes for Hyper-V hypercall selftest
2022-09-30 07:09:48 -04:00
Catalin Marinas 53630a1f61 Merge branch 'for-next/misc' into for-next/core
* for-next/misc:
  : Miscellaneous patches
  arm64/kprobe: Optimize the performance of patching single-step slot
  ARM64: reloc_test: add __init/__exit annotations to module init/exit funcs
  arm64/mm: fold check for KFENCE into can_set_direct_map()
  arm64: uaccess: simplify uaccess_mask_ptr()
  arm64: mte: move register initialization to C
  arm64: mm: handle ARM64_KERNEL_USES_PMD_MAPS in vmemmap_populate()
  arm64: dma: Drop cache invalidation from arch_dma_prep_coherent()
  arm64: support huge vmalloc mappings
  arm64: spectre: increase parameters that can be used to turn off bhb mitigation individually
  arm64: run softirqs on the per-CPU IRQ stack
  arm64: compat: Implement misalignment fixups for multiword loads
2022-09-30 09:18:26 +01:00
Catalin Marinas c704cf27a1 Merge branch 'for-next/alternatives' into for-next/core
* for-next/alternatives:
  : Alternatives (code patching) improvements
  arm64: fix the build with binutils 2.27
  arm64: avoid BUILD_BUG_ON() in alternative-macros
  arm64: alternatives: add shared NOP callback
  arm64: alternatives: add alternative_has_feature_*()
  arm64: alternatives: have callbacks take a cap
  arm64: alternatives: make alt_region const
  arm64: alternatives: hoist print out of __apply_alternatives()
  arm64: alternatives: proton-pack: prepare for cap changes
  arm64: alternatives: kvm: prepare for cap changes
  arm64: cpufeature: make cpus_have_cap() noinstr-safe
2022-09-30 09:18:22 +01:00
Catalin Marinas b23ec74cbd Merge branches 'for-next/doc', 'for-next/sve', 'for-next/sysreg', 'for-next/gettimeofday', 'for-next/stacktrace', 'for-next/atomics', 'for-next/el1-exceptions', 'for-next/a510-erratum-2658417', 'for-next/defconfig', 'for-next/tpidr2_el0' and 'for-next/ftrace', remote-tracking branch 'arm64/for-next/perf' into for-next/core
* arm64/for-next/perf:
  arm64: asm/perf_regs.h: Avoid C++-style comment in UAPI header
  arm64/sve: Add Perf extensions documentation
  perf: arm64: Add SVE vector granule register to user regs
  MAINTAINERS: add maintainers for Alibaba' T-Head PMU driver
  drivers/perf: add DDR Sub-System Driveway PMU driver for Yitian 710 SoC
  docs: perf: Add description for Alibaba's T-Head PMU driver

* for-next/doc:
  : Documentation/arm64 updates
  arm64/sve: Document our actual ABI for clearing registers on syscall

* for-next/sve:
  : SVE updates
  arm64/sysreg: Add hwcap for SVE EBF16

* for-next/sysreg: (35 commits)
  : arm64 system registers generation (more conversions)
  arm64/sysreg: Fix a few missed conversions
  arm64/sysreg: Convert ID_AA64AFRn_EL1 to automatic generation
  arm64/sysreg: Convert ID_AA64DFR1_EL1 to automatic generation
  arm64/sysreg: Convert ID_AA64FDR0_EL1 to automatic generation
  arm64/sysreg: Use feature numbering for PMU and SPE revisions
  arm64/sysreg: Add _EL1 into ID_AA64DFR0_EL1 definition names
  arm64/sysreg: Align field names in ID_AA64DFR0_EL1 with architecture
  arm64/sysreg: Add defintion for ALLINT
  arm64/sysreg: Convert SCXTNUM_EL1 to automatic generation
  arm64/sysreg: Convert TIPDR_EL1 to automatic generation
  arm64/sysreg: Convert ID_AA64PFR1_EL1 to automatic generation
  arm64/sysreg: Convert ID_AA64PFR0_EL1 to automatic generation
  arm64/sysreg: Convert ID_AA64MMFR2_EL1 to automatic generation
  arm64/sysreg: Convert ID_AA64MMFR1_EL1 to automatic generation
  arm64/sysreg: Convert ID_AA64MMFR0_EL1 to automatic generation
  arm64/sysreg: Convert HCRX_EL2 to automatic generation
  arm64/sysreg: Standardise naming of ID_AA64PFR1_EL1 SME enumeration
  arm64/sysreg: Standardise naming of ID_AA64PFR1_EL1 BTI enumeration
  arm64/sysreg: Standardise naming of ID_AA64PFR1_EL1 fractional version fields
  arm64/sysreg: Standardise naming for MTE feature enumeration
  ...

* for-next/gettimeofday:
  : Use self-synchronising counter access in gettimeofday() (if FEAT_ECV)
  arm64: vdso: use SYS_CNTVCTSS_EL0 for gettimeofday
  arm64: alternative: patch alternatives in the vDSO
  arm64: module: move find_section to header

* for-next/stacktrace:
  : arm64 stacktrace cleanups and improvements
  arm64: stacktrace: track hyp stacks in unwinder's address space
  arm64: stacktrace: track all stack boundaries explicitly
  arm64: stacktrace: remove stack type from fp translator
  arm64: stacktrace: rework stack boundary discovery
  arm64: stacktrace: add stackinfo_on_stack() helper
  arm64: stacktrace: move SDEI stack helpers to stacktrace code
  arm64: stacktrace: rename unwind_next_common() -> unwind_next_frame_record()
  arm64: stacktrace: simplify unwind_next_common()
  arm64: stacktrace: fix kerneldoc comments

* for-next/atomics:
  : arm64 atomics improvements
  arm64: atomic: always inline the assembly
  arm64: atomics: remove LL/SC trampolines

* for-next/el1-exceptions:
  : Improve the reporting of EL1 exceptions
  arm64: rework BTI exception handling
  arm64: rework FPAC exception handling
  arm64: consistently pass ESR_ELx to die()
  arm64: die(): pass 'err' as long
  arm64: report EL1 UNDEFs better

* for-next/a510-erratum-2658417:
  : Cortex-A510: 2658417: remove BF16 support due to incorrect result
  arm64: errata: remove BF16 HWCAP due to incorrect result on Cortex-A510
  arm64: cpufeature: Expose get_arm64_ftr_reg() outside cpufeature.c
  arm64: cpufeature: Force HWCAP to be based on the sysreg visible to user-space

* for-next/defconfig:
  : arm64 defconfig updates
  arm64: defconfig: Add Coresight as module
  arm64: Enable docker support in defconfig
  arm64: defconfig: Enable memory hotplug and hotremove config
  arm64: configs: Enable all PMUs provided by Arm

* for-next/tpidr2_el0:
  : arm64 ptrace() support for TPIDR2_EL0
  kselftest/arm64: Add coverage of TPIDR2_EL0 ptrace interface
  arm64/ptrace: Support access to TPIDR2_EL0
  arm64/ptrace: Document extension of NT_ARM_TLS to cover TPIDR2_EL0
  kselftest/arm64: Add test coverage for NT_ARM_TLS

* for-next/ftrace:
  : arm64 ftraces updates/fixes
  arm64: ftrace: fix module PLTs with mcount
  arm64: module: Remove unused plt_entry_is_initialized()
  arm64: module: Make plt_equals_entry() static
2022-09-30 09:17:57 +01:00
Liao Chang a0caebbd04 arm64/kprobe: Optimize the performance of patching single-step slot
Single-step slot would not be used until kprobe is enabled, that means
no race condition occurs on it under SMP, hence it is safe to pacth ss
slot without stopping machine.

Since I and D caches are coherent within single-step slot from
aarch64_insn_patch_text_nosync(), hence no need to do it again via
flush_icache_range().

Acked-by: Will Deacon <will@kernel.org>
Acked-by: Masami Hiramatsu (Google) <mhiramat@kernel.org>
Signed-off-by: Liao Chang <liaochang1@huawei.com>
Link: https://lore.kernel.org/r/20220927022435.129965-4-liaochang1@huawei.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-30 09:17:15 +01:00
Jakub Kicinski accc3b4a57 Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
No conflicts.

Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-09-29 14:30:51 -07:00
James Clark d56f66d2bd arm64: defconfig: Add Coresight as module
Add Coresight to defconfig so that build errors are caught.
CONFIG_CORESIGHT_SOURCE_ETM4X is excluded because it depends on
CONFIG_PID_IN_CONTEXTIDR which has a performance cost.

Signed-off-by: James Clark <james.clark@arm.com>
Link: https://lore.kernel.org/r/20220922142400.478815-2-james.clark@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-29 18:14:20 +01:00
Xiu Jianfeng 8c6e3657be ARM64: reloc_test: add __init/__exit annotations to module init/exit funcs
Add missing __init/__exit annotations to module init/exit funcs.

Signed-off-by: Xiu Jianfeng <xiujianfeng@huawei.com>
Link: https://lore.kernel.org/r/20220911034747.132098-1-xiujianfeng@huawei.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-29 18:04:25 +01:00
Mike Rapoport b9dd04a20f arm64/mm: fold check for KFENCE into can_set_direct_map()
KFENCE requires linear map to be mapped at page granularity, so that it
is possible to protect/unprotect single pages, just like with
rodata_full and DEBUG_PAGEALLOC.

Instead of repating

	can_set_direct_map() || IS_ENABLED(CONFIG_KFENCE)

make can_set_direct_map() handle the KFENCE case.

This also prevents potential false positives in kernel_page_present()
that may return true for non-present page if CONFIG_KFENCE is enabled.

Signed-off-by: Mike Rapoport <rppt@linux.ibm.com>
Reviewed-by: Anshuman Khandual <anshuman.khandual@arm.com>
Link: https://lore.kernel.org/r/20220921074841.382615-1-rppt@kernel.org
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-29 17:59:28 +01:00
Mark Rutland 8cfb08575c arm64: ftrace: fix module PLTs with mcount
Li Huafei reports that mcount-based ftrace with module PLTs was broken
by commit:

  a625357997 ("arm64: ftrace: consistently handle PLTs.")

When a module PLTs are used and a module is loaded sufficiently far away
from the kernel, we'll create PLTs for any branches which are
out-of-range. These are separate from the special ftrace trampoline
PLTs, which the module PLT code doesn't directly manipulate.

When mcount is in use this is a problem, as each mcount callsite in a
module will be initialized to point to a module PLT, but since commit
a625357997 ftrace_make_nop() will assume that the callsite has
been initialized to point to the special ftrace trampoline PLT, and
ftrace_find_callable_addr() rejects other cases.

This means that when ftrace tries to initialize a callsite via
ftrace_make_nop(), the call to ftrace_find_callable_addr() will find
that the `_mcount` stub is out-of-range and is not handled by the ftrace
PLT, resulting in a splat:

| ftrace_test: loading out-of-tree module taints kernel.
| ftrace: no module PLT for _mcount
| ------------[ ftrace bug ]------------
| ftrace failed to modify
| [<ffff800029180014>] 0xffff800029180014
|  actual:   44:00:00:94
| Initializing ftrace call sites
| ftrace record flags: 2000000
|  (0)
|  expected tramp: ffff80000802eb3c
| ------------[ cut here ]------------
| WARNING: CPU: 3 PID: 157 at kernel/trace/ftrace.c:2120 ftrace_bug+0x94/0x270
| Modules linked in:
| CPU: 3 PID: 157 Comm: insmod Tainted: G           O       6.0.0-rc6-00151-gcd722513a189-dirty #22
| Hardware name: linux,dummy-virt (DT)
| pstate: 60000005 (nZCv daif -PAN -UAO -TCO -DIT -SSBS BTYPE=--)
| pc : ftrace_bug+0x94/0x270
| lr : ftrace_bug+0x21c/0x270
| sp : ffff80000b2bbaf0
| x29: ffff80000b2bbaf0 x28: 0000000000000000 x27: ffff0000c4d38000
| x26: 0000000000000001 x25: ffff800009d7e000 x24: ffff0000c4d86e00
| x23: 0000000002000000 x22: ffff80000a62b000 x21: ffff8000098ebea8
| x20: ffff0000c4d38000 x19: ffff80000aa24158 x18: ffffffffffffffff
| x17: 0000000000000000 x16: 0a0d2d2d2d2d2d2d x15: ffff800009aa9118
| x14: 0000000000000000 x13: 6333626532303830 x12: 3030303866666666
| x11: 203a706d61727420 x10: 6465746365707865 x9 : 3362653230383030
| x8 : c0000000ffffefff x7 : 0000000000017fe8 x6 : 000000000000bff4
| x5 : 0000000000057fa8 x4 : 0000000000000000 x3 : 0000000000000001
| x2 : ad2cb14bb5438900 x1 : 0000000000000000 x0 : 0000000000000022
| Call trace:
|  ftrace_bug+0x94/0x270
|  ftrace_process_locs+0x308/0x430
|  ftrace_module_init+0x44/0x60
|  load_module+0x15b4/0x1ce8
|  __do_sys_init_module+0x1ec/0x238
|  __arm64_sys_init_module+0x24/0x30
|  invoke_syscall+0x54/0x118
|  el0_svc_common.constprop.4+0x84/0x100
|  do_el0_svc+0x3c/0xd0
|  el0_svc+0x1c/0x50
|  el0t_64_sync_handler+0x90/0xb8
|  el0t_64_sync+0x15c/0x160
| ---[ end trace 0000000000000000 ]---
| ---------test_init-----------

Fix this by reverting to the old behaviour of ignoring the old
instruction when initialising an mcount callsite in a module, which was
the behaviour prior to commit a625357997.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Fixes: a625357997 ("arm64: ftrace: consistently handle PLTs.")
Reported-by: Li Huafei <lihuafei1@huawei.com>
Link: https://lore.kernel.org/linux-arm-kernel/20220929094134.99512-1-lihuafei1@huawei.com
Cc: Ard Biesheuvel <ardb@kernel.org>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20220929134525.798593-1-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-29 17:47:54 +01:00
Li Huafei 5de2291605 arm64: module: Remove unused plt_entry_is_initialized()
Since commit f1a54ae9af ("arm64: module/ftrace: intialize PLT at load
time"), plt_entry_is_initialized() is unused anymore , so remove it.

Signed-off-by: Li Huafei <lihuafei1@huawei.com>
Acked-by: Mark Rutland <mark.rutland@arm.com>
Link: https://lore.kernel.org/r/20220929094134.99512-3-lihuafei1@huawei.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-29 17:47:18 +01:00
Li Huafei 3fb420f56c arm64: module: Make plt_equals_entry() static
Since commit 4e69ecf4da ("arm64/module: ftrace: deal with place
relative nature of PLTs"), plt_equals_entry() is not used outside of
module-plts.c, so make it static.

Signed-off-by: Li Huafei <lihuafei1@huawei.com>
Acked-by: Mark Rutland <mark.rutland@arm.com>
Link: https://lore.kernel.org/r/20220929094134.99512-2-lihuafei1@huawei.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-29 17:47:18 +01:00
Mark Rutland ba00c2a04f arm64: fix the build with binutils 2.27
Jon Hunter reports that for some toolchains the build has been broken
since commit:

  4c0bd995d7 ("arm64: alternatives: have callbacks take a cap")

... with a stream of build-time splats of the form:

|   CC      arch/arm64/kvm/hyp/vhe/debug-sr.o
| /tmp/ccY3kbki.s: Assembler messages:
| /tmp/ccY3kbki.s:1600: Error: found 'L', expected: ')'
| /tmp/ccY3kbki.s:1600: Error: found 'L', expected: ')'
| /tmp/ccY3kbki.s:1600: Error: found 'L', expected: ')'
| /tmp/ccY3kbki.s:1600: Error: found 'L', expected: ')'
| /tmp/ccY3kbki.s:1600: Error: junk at end of line, first unrecognized character
| is `L'
| /tmp/ccY3kbki.s:1723: Error: found 'L', expected: ')'
| /tmp/ccY3kbki.s:1723: Error: found 'L', expected: ')'
| /tmp/ccY3kbki.s:1723: Error: found 'L', expected: ')'
| /tmp/ccY3kbki.s:1723: Error: found 'L', expected: ')'
| /tmp/ccY3kbki.s:1723: Error: junk at end of line, first unrecognized character
| is `L'
| scripts/Makefile.build:249: recipe for target
| 'arch/arm64/kvm/hyp/vhe/debug-sr.o' failed

The issue here is that older versions of binutils (up to and including
2.27.0) don't like an 'L' suffix on constants. For plain assembly files,
UL() avoids this suffix, but in C files this gets added, and so for
inline assembly we can't directly use a constant defined with `UL()`.

We could avoid this by passing the constant as an input parameter, but
this isn't practical given the way we use the alternative macros.
Instead, just open code the constant without the `UL` suffix, and for
consistency do this for both the inline assembly macro and the regular
assembly macro.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Fixes: 4c0bd995d7 ("arm64: alternatives: have callbacks take a cap")
Reported-by: Jon Hunter <jonathanh@nvidia.com>
Link: https://lore.kernel.org/linux-arm-kernel/3cecc3a5-30b0-f0bd-c3de-9e09bd21909b@nvidia.com/
Tested-by: Jon Hunter <jonathanh@nvidia.com>
Cc: Ard Biesheuvel <ardb@kernel.org>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20220929150227.1028556-1-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-29 17:43:32 +01:00
Wei-Lin Chang 43b233b158 KVM: arm64: Fix comment typo in nvhe/switch.c
Fix the comment of __hyp_vgic_restore_state() from saying VEH to VHE,
also change the underscore to a dash to match the comment
above __hyp_vgic_save_state().

Signed-off-by: Wei-Lin Chang <r09922117@csie.ntu.edu.tw>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20220929042839.24277-1-r09922117@csie.ntu.edu.tw
2022-09-29 09:07:08 +01:00
Arnd Bergmann 302c9454e4 Merge branch 'uniphier/dt' into arm/dt
Updates from Kunihiko Hayashi via email:

 "Update devicetree sources for UniPhier armv8 SoCs to remove dtschema
  warnings, add support existing features that haven't yet been
  described, and replace constants with macros."

* uniphier/dt:
  arm64: dts: uniphier: Add L2 cache node
  arm64: dts: uniphier: Remove compatible "snps,dw-pcie" from pcie node
  arm64: dts: uniphier: Fix opp-table node name for LD20
  arm64: dts: uniphier: Add USB-device support for PXs3 reference board
  arm64: dts: uniphier: Add ahci controller nodes for PXs3
  arm64: dts: uniphier: Use GIC interrupt definitions
  arm64: dts: uniphier: Rename gpio-hog nodes
  arm64: dts: uniphier: Rename usb-glue node for USB3 to usb-controller
  arm64: dts: uniphier: Rename usb-phy node for USB2 to usb-controller
  arm64: dts: uniphier: Rename pvtctl node to thermal-sensor
  ARM: dts: uniphier: Remove compatible "snps,dw-pcie-ep" from pcie-ep node
  ARM: dts: uniphier: Move interrupt-parent property to each child node in uniphier-support-card
  ARM: dts: uniphier: Add ahci controller nodes for PXs2
  ARM: dts: uniphier: Add ahci controller nodes for Pro4
  ARM: dts: uniphier: Use GIC interrupt definitions
  ARM: dts: uniphier: Rename gpio-hog node
  ARM: dts: uniphier: Rename usb-glue node for USB3 to usb-controller
  ARM: dts: uniphier: Rename usb-phy node for USB2 to usb-controller
  ARM: dts: uniphier: Rename pvtctl node to thermal-sensor
2022-09-28 22:42:25 +02:00
Kunihiko Hayashi 5381a96cd9
arm64: dts: uniphier: Add L2 cache node
Add a L2 cache node referenced from CPU nodes as the missing cache hierarchy
information because the following warning was issued.

  cacheinfo: Unable to detect cache hierarchy for CPU 0
  Early cacheinfo failed, ret = -2

Signed-off-by: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
Link: https://lore.kernel.org/r/20220913042321.4817-11-hayashi.kunihiko@socionext.com'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-28 22:41:48 +02:00
Kunihiko Hayashi d93ecbf569
arm64: dts: uniphier: Remove compatible "snps,dw-pcie" from pcie node
The generic platform driver pcie-designware-plat.c doesn't work for
UniPhier PCIe host controller, because the controller has some
necessary initialization sequence for the controller-specific logic.

Currently the controller doesn't use "snps,dw-pcie" compatible,
so this is no longer needed. Remove the compatible string from the
pcie node.

Signed-off-by: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
Link: https://lore.kernel.org/r/20220913042321.4817-10-hayashi.kunihiko@socionext.com'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-28 22:41:47 +02:00
Kunihiko Hayashi 4ff64e7089
arm64: dts: uniphier: Fix opp-table node name for LD20
To fix dtbs_check warning:

uniphier-ld20-akebi96.dt.yaml: opp-table0: $nodename:0: 'opp-table0' does not match '^opp-table(-[a-z0-9]+)?$'
        From schema: Documentation/devicetree/bindings/opp/opp-v2.yaml

Signed-off-by: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
Link: https://lore.kernel.org/r/20220913042321.4817-9-hayashi.kunihiko@socionext.com'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-28 22:41:47 +02:00
Kunihiko Hayashi 19fee1a109
arm64: dts: uniphier: Add USB-device support for PXs3 reference board
PXs3 reference board can change each USB port 0 and 1 to device mode
with jumpers. Prepare devicetree sources for USB port 0 and 1.

This specifies dr_mode, pinctrl, and some quirks and removes nodes for
unused phys and vbus-supply properties.

Signed-off-by: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
Link: https://lore.kernel.org/r/20220913042321.4817-8-hayashi.kunihiko@socionext.com'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-28 22:41:47 +02:00
Kunihiko Hayashi 23e001e75d
arm64: dts: uniphier: Add ahci controller nodes for PXs3
Add ahci core controller and glue layer nodes including reset-controller
and sata-phy.

This supports for PXs3 and the boards.

Signed-off-by: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
Link: https://lore.kernel.org/r/20220913042321.4817-7-hayashi.kunihiko@socionext.com'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-28 22:41:47 +02:00
Kunihiko Hayashi 5ba95e8ec2
arm64: dts: uniphier: Use GIC interrupt definitions
Use human-readable definitions for GIC interrupt type and flag, instead of
hard-coding the numbers. No functional change.

Signed-off-by: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
Link: https://lore.kernel.org/r/20220913042321.4817-6-hayashi.kunihiko@socionext.com'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-28 22:41:46 +02:00
Kunihiko Hayashi 173b9b8e5f
arm64: dts: uniphier: Rename gpio-hog nodes
According to gpio-hog schema, should add the suffix "-hog" to the node
names including gpio-hog to fix the following warning.

  uniphier-ld11-ref.dtb: gpio@55000000: 'xirq0' does not match any of the regexes: '^.+-hog(-[0-9+)?$', 'pinctrl-[0-9]+'
      From schema: Documentation/devicetree/bindings/gpio/socionext,uniphier-gpio.yaml

This applies to the devicetre for LD11, LD20 and PXs3 SoCs.

Signed-off-by: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
Link: https://lore.kernel.org/r/20220913042321.4817-5-hayashi.kunihiko@socionext.com'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-28 22:41:46 +02:00
Kunihiko Hayashi 4cc752a88c
arm64: dts: uniphier: Rename usb-glue node for USB3 to usb-controller
This "usb-glue" stands for an external controller associated with USB core,
however, this is not common. So rename to "usb-controller".

Signed-off-by: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
Link: https://lore.kernel.org/r/20220913042321.4817-4-hayashi.kunihiko@socionext.com'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-28 22:41:46 +02:00
Kunihiko Hayashi 8fa3e65857
arm64: dts: uniphier: Rename usb-phy node for USB2 to usb-controller
Actual phy nodes are each child node. The parent node should be
usb-controller node as a representation of the phy integration.
This applies to the devicetree for LD11 SoC.

Signed-off-by: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
Link: https://lore.kernel.org/r/20220913042321.4817-3-hayashi.kunihiko@socionext.com'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-28 22:41:46 +02:00
Kunihiko Hayashi 2dfb62d6ce
arm64: dts: uniphier: Rename pvtctl node to thermal-sensor
The pvtctl node belongs to thermal-sensor, so the node name should be
renamed to thermal-sensor.

Signed-off-by: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
Link: https://lore.kernel.org/r/20220913042321.4817-2-hayashi.kunihiko@socionext.com'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-28 22:41:46 +02:00
Arnd Bergmann 25631f1fec Enable Synopsys DWC MSHC (sdhci) driver in the defconfig.
-----BEGIN PGP SIGNATURE-----
 
 iQFEBAABCAAuFiEE7v+35S2Q1vLNA3Lx86Z5yZzRHYEFAmMvDc0QHGhlaWtvQHNu
 dGVjaC5kZQAKCRDzpnnJnNEdgeyOB/4jXuunRX3GpLIvr+5+INkD30RraGeKi/SA
 g7HOD9qMPz2/0pDSlv53p+3+YedWbhFMeesrRUBlybv1h+JL+sn0u6QJ30l2MwCk
 dd+elngztE6JLEx5Q24cN4weuw0MW+a3rbLM6ydn3QQUkwkVnvc9nTd9Z7TVySxX
 RdhP+5PR5wHl1mZlll+o4wRuwEZDlUyD7e++OgWP0dFzHcWW9BwL7YCWo4sGDi+B
 Kgt5wTuBS20/jkged6j4y+GREQvH782lxbjORWNamW0KoTq47Ezkm3aNfpGLML2M
 aYxrokZ3OALSOTzYTd6FS8VJ7+Ffp7eqtiJdGhjqove0CdZi/QJP
 =fTwy
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmM0sAMACgkQmmx57+YA
 GNnK9Q//fEPtPvPEk7ztlnbBfys8NHUu7wr+07KfBdiOmf4fBWk1OZW+H22FN1k9
 mG9QOCbTDlBvaAMlCYcFXX6567XAexeu8KuTOvsVJxUGSLhSlAxYOkibcUi2Qkja
 aGkQ8wV3UpbSsgMCYlJLhY35y7NxTCXXMOUwS4CYTBRZ+eSLy7D0XFzFSVC+YGV/
 /eax8j8lBJY8bSzw8O7//m223alJRNnFVWQjSm9CtpEzGEDFMnWHwPFjLxRr5eWW
 r+r31CvV8BLr7Z1YveBvbIk4rL8K52dPQNyzNRCkIwvW6YRiGzvbcaBxbgXZ/PhK
 N2c5DPduuKW1akYJQpD28nv2jcDvHnocWDEDpL1ojLKAU4R5rjo0AOe1KF9pAdSu
 76AoBOybZPgF0vMG6nv+Js5HXz/lOY8C1FK8P0X3JgZ9VqerDS6hn2slitTqU0Gg
 Th4wfvsJXJr8Kp9qiH0mbbxRdxktFu71n+OMtMrMUplE++zOWT7XCdZIQKIXD3Rc
 2L4pCAFmN7ZBjkxriXIoFjpKQnjRdSwHEgb/qptM0rZvdSbJYSxkvTyrhUrnqjzS
 J2egehnNYzSsiQQXzS5gHEqYXjJrkFml19l5kR9ULB9V1tPUjOEX345PayrAoK9O
 7v0ySiNz7AbyGNN4oEcYGWVZJKLxPa+4nclHwYEDzQRohUylsV4=
 =g8YU
 -----END PGP SIGNATURE-----

Merge tag 'v6.1-rockchip-defconfig64-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into arm/defconfig

Enable Synopsys DWC MSHC (sdhci) driver in the defconfig.

* tag 'v6.1-rockchip-defconfig64-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip:
  arm64: defconfig: Enable Synopsys DWC MSHC driver

Link: https://lore.kernel.org/r/1989419.QkHrqEjB74@phil
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-28 22:35:15 +02:00
Arnd Bergmann 286c1d1c30 RK3399-Nanopi-R4S-enterprise as variant board, Gru-Scarlet SKU variants,
DSI support for rk356x, display-gamma-control for rk3399, display
 output for quartz64-b and rk3566-roc-pc, hdmi supplies for rk3399-roc-pc,
 some pinctrl improvements for the px30-evb and a number of changes to
 bring rk3399 rock4 and rock-pi4 structure closer to names used in schematics.
 -----BEGIN PGP SIGNATURE-----
 
 iQFEBAABCAAuFiEE7v+35S2Q1vLNA3Lx86Z5yZzRHYEFAmMvDVkQHGhlaWtvQHNu
 dGVjaC5kZQAKCRDzpnnJnNEdgdM7B/0XJOFHfOczgScJ/U0lGKOSdyunaBKxjzJ5
 Hdz9Zy7SaW0NztHJA8F5TY+Llw6VKR0jULhcJ/HFxQlAlVKlLyQBpL0K71+9evo/
 3EKugxgwWTXVUeCycVRIBcHTCB0F2lrITCTudTyA3C+sJWOOX9NJyccQXnwFtf/D
 ScQpIEXGB6/iiU9mTup/JY48HiojnXeJLQsXGos+4D+nY9Pm+KwKhpGlBLvNjf/D
 wvmGJTgcuDkoXoPHQ15vvUjUbYrqIIehV7s3zKJSTVjZ7upOcDXsnN/CZBtrYiac
 HghziTm5Bn66aNY2Q5/iQ8u3a5Vgxx7+li1SR3+iwCr1YERIDjEA
 =nNLu
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmM0re0ACgkQmmx57+YA
 GNk5pw/9EShdi6HdhH60llnYSH3tAwnLFNUCKkQ0ZrDyINRcGLCyiEgxayy1pVyU
 zc6yTlpH1Irjc3nv5pNPme8mOItw5V78Jb04rA1g/Oie/hQ/hLA6JOP86fzdiDEN
 Rbt24llOSExStEBePBFwV87Adt60K6HCIE5MNfX+qW97YMpacyiTSbbee19AcliN
 mhYskbZPmuMSO3yMYkHYbJa9yzYqxq+ccipz8AcJFLXvlTIrM/MfgYSp+zCHnaRW
 /6r0ApfA7FvUXMkBKXNeAL4yh5jKmfFB+wQuYY9z0AvB53oBxGKmDubMrY3IdT2Q
 LBaoiIQG/5oz3DBWRZe9RxWusIyacgyInaNBcAYiPMnInb2dL9XCgMlOemPRTQLO
 NavC1cA+TXXAMmgISTnGFeVCYcIY8F8KkfWWAobpjnzKrdic6axncl8eiAK80JOT
 yM6yS7lDnWtIWCUq4zgkJxCnFD4PtUHOwusz0wurrwiSz5TveESKDyOnQ6evSqry
 ka6UdN2DtX8Dd7c6vTtu0labY8o2Qdz6r2N+ooRAhaujhh9tYA59Yxrp9pV8cwJe
 ysHvbJBJLpE/lEbHYNPWqz2lOyPJ+JWj9s3aPn7jDv+gOxmP8z1NdbTVpcSRJj0B
 T4c6cMoQ6PyF5P11vUg7nKJ0JNH8/dUYUgPur/qL60O6JIbiFXE=
 =oYll
 -----END PGP SIGNATURE-----

Merge tag 'v6.1-rockchip-dts64-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into arm/dt

RK3399-Nanopi-R4S-enterprise as variant board, Gru-Scarlet SKU variants,
DSI support for rk356x, display-gamma-control for rk3399, display
output for quartz64-b and rk3566-roc-pc, hdmi supplies for rk3399-roc-pc,
some pinctrl improvements for the px30-evb and a number of changes to
bring rk3399 rock4 and rock-pi4 structure closer to names used in schematics.

* tag 'v6.1-rockchip-dts64-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip:
  arm64: dts: rockchip: use pin constant for reset-gpios on px30-evb
  arm64: dts: rockchip: add pinctrl for mipi-pdn pin on px30-evb
  arm64: dts: rockchip: set max drive-strength for cif_clkout_m0 on px30-evb
  arm64: dts: rockchip: add avdd-0v9-supply and avdd-1v8-supply on rk3399 rock 4c and pi4
  arm64: dts: rockchip: sort nodes/properties on rk3399-rock-4
  arm64: dts: rockchip: fix regulator name on rk3399-rock-4
  arm64: dts: rockchip: sort nodes/properties on rk3399-rock-4c-plus
  arm64: dts: rockchip: fix regulator structure on rk3399-rock-4c-plus
  arm64: dts: rockchip: connect vcca_1v8 to APIO5_VDD on rk3399-rock-4c-plus
  arm64: dts: rockchip: Add DSI and DSI-DPHY nodes to rk356x
  arm64: dts: rockchip: Enable HDMI and GPU on quartz64-b
  arm64: dts: rockchip: Add RK3399 NanoPi R4S Enterprise Edition
  dt-bindings: Add doc for FriendlyARM NanoPi R4S Enterprise Edition
  arm64: dts: rockchip: add i2s0 I2S/PDM/TDM 8ch controller to px30
  arm64: dts: rockchip: Add HDMI supplies on rk3399-roc-pc
  arm64: dts: rockchip: Support gru-scarlet sku{2,4} variants
  dt-bindings: arm: rockchip: Add gru-scarlet sku{2,4} variants
  arm64: dts: rockchip: enable gamma control on RK3399
  arm64: dts: rockchip: Enable video output on rk3566-roc-pc

Link: https://lore.kernel.org/r/38114097.10thIPus4b@phil
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-28 22:26:21 +02:00
Li kunyu d5ebde1e2b hyperv: simplify and rename generate_guest_id
The generate_guest_id function is more suitable for use after the
following modifications.

1. The return value of the function is modified to u64.
2. Remove the d_info1 and d_info2 parameters from the function, keep the
   u64 type kernel_version parameter.
3. Rename the function to make it clearly a Hyper-V related function,
   and modify it to hv_generate_guest_id.

Signed-off-by: Li kunyu <kunyu@nfschina.com>
Reviewed-by: Michael Kelley <mikelley@microsoft.com>
Link: https://lore.kernel.org/r/20220928064046.3545-1-kunyu@nfschina.com
Signed-off-by: Wei Liu <wei.liu@kernel.org>
2022-09-28 13:36:56 +00: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
Liam R. Howlett ef770d180e arm64: Change elfcore for_each_mte_vma() to use VMA iterator
Rework for_each_mte_vma() to use a VMA iterator instead of an explicit
linked-list.

Link: https://lkml.kernel.org/r/20220906194824.2110408-32-Liam.Howlett@oracle.com
Signed-off-by: Liam R. Howlett <Liam.Howlett@oracle.com>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Link: https://lore.kernel.org/r/20220218023650.672072-1-Liam.Howlett@oracle.com
Signed-off-by: Will Deacon <will@kernel.org>
Reviewed-by: Davidlohr Bueso <dave@stgolabs.net>
Tested-by: Yu Zhao <yuzhao@google.com>
Cc: David Hildenbrand <david@redhat.com>
Cc: David Howells <dhowells@redhat.com>
Cc: "Matthew Wilcox (Oracle)" <willy@infradead.org>
Cc: SeongJae Park <sj@kernel.org>
Cc: Sven Schnelle <svens@linux.ibm.com>
Cc: Vlastimil Babka <vbabka@suse.cz>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
2022-09-26 19:46:19 -07:00
Matthew Wilcox (Oracle) de2b84d24b arm64: remove mmap linked list from vdso
Use the VMA iterator instead.

Link: https://lkml.kernel.org/r/20220906194824.2110408-31-Liam.Howlett@oracle.com
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Signed-off-by: Liam R. Howlett <Liam.Howlett@Oracle.com>
Acked-by: Vlastimil Babka <vbabka@suse.cz>
Reviewed-by: Davidlohr Bueso <dave@stgolabs.net>
Tested-by: Yu Zhao <yuzhao@google.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: David Hildenbrand <david@redhat.com>
Cc: David Howells <dhowells@redhat.com>
Cc: SeongJae Park <sj@kernel.org>
Cc: Sven Schnelle <svens@linux.ibm.com>
Cc: Will Deacon <will@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
2022-09-26 19:46:19 -07:00
Yu Zhao e1fd09e3d1 mm: x86, arm64: add arch_has_hw_pte_young()
Patch series "Multi-Gen LRU Framework", v14.

What's new
==========
1. OpenWrt, in addition to Android, Arch Linux Zen, Armbian, ChromeOS,
   Liquorix, post-factum and XanMod, is now shipping MGLRU on 5.15.
2. Fixed long-tailed direct reclaim latency seen on high-memory (TBs)
   machines. The old direct reclaim backoff, which tries to enforce a
   minimum fairness among all eligible memcgs, over-swapped by about
   (total_mem>>DEF_PRIORITY)-nr_to_reclaim. The new backoff, which
   pulls the plug on swapping once the target is met, trades some
   fairness for curtailed latency:
   https://lore.kernel.org/r/20220918080010.2920238-10-yuzhao@google.com/
3. Fixed minior build warnings and conflicts. More comments and nits.

TLDR
====
The current page reclaim is too expensive in terms of CPU usage and it
often makes poor choices about what to evict. This patchset offers an
alternative solution that is performant, versatile and
straightforward.

Patchset overview
=================
The design and implementation overview is in patch 14:
https://lore.kernel.org/r/20220918080010.2920238-15-yuzhao@google.com/

01. mm: x86, arm64: add arch_has_hw_pte_young()
02. mm: x86: add CONFIG_ARCH_HAS_NONLEAF_PMD_YOUNG
Take advantage of hardware features when trying to clear the accessed
bit in many PTEs.

03. mm/vmscan.c: refactor shrink_node()
04. Revert "include/linux/mm_inline.h: fold __update_lru_size() into
    its sole caller"
Minor refactors to improve readability for the following patches.

05. mm: multi-gen LRU: groundwork
Adds the basic data structure and the functions that insert pages to
and remove pages from the multi-gen LRU (MGLRU) lists.

06. mm: multi-gen LRU: minimal implementation
A minimal implementation without optimizations.

07. mm: multi-gen LRU: exploit locality in rmap
Exploits spatial locality to improve efficiency when using the rmap.

08. mm: multi-gen LRU: support page table walks
Further exploits spatial locality by optionally scanning page tables.

09. mm: multi-gen LRU: optimize multiple memcgs
Optimizes the overall performance for multiple memcgs running mixed
types of workloads.

10. mm: multi-gen LRU: kill switch
Adds a kill switch to enable or disable MGLRU at runtime.

11. mm: multi-gen LRU: thrashing prevention
12. mm: multi-gen LRU: debugfs interface
Provide userspace with features like thrashing prevention, working set
estimation and proactive reclaim.

13. mm: multi-gen LRU: admin guide
14. mm: multi-gen LRU: design doc
Add an admin guide and a design doc.

Benchmark results
=================
Independent lab results
-----------------------
Based on the popularity of searches [01] and the memory usage in
Google's public cloud, the most popular open-source memory-hungry
applications, in alphabetical order, are:
      Apache Cassandra      Memcached
      Apache Hadoop         MongoDB
      Apache Spark          PostgreSQL
      MariaDB (MySQL)       Redis

An independent lab evaluated MGLRU with the most widely used benchmark
suites for the above applications. They posted 960 data points along
with kernel metrics and perf profiles collected over more than 500
hours of total benchmark time. Their final reports show that, with 95%
confidence intervals (CIs), the above applications all performed
significantly better for at least part of their benchmark matrices.

On 5.14:
1. Apache Spark [02] took 95% CIs [9.28, 11.19]% and [12.20, 14.93]%
   less wall time to sort three billion random integers, respectively,
   under the medium- and the high-concurrency conditions, when
   overcommitting memory. There were no statistically significant
   changes in wall time for the rest of the benchmark matrix.
2. MariaDB [03] achieved 95% CIs [5.24, 10.71]% and [20.22, 25.97]%
   more transactions per minute (TPM), respectively, under the medium-
   and the high-concurrency conditions, when overcommitting memory.
   There were no statistically significant changes in TPM for the rest
   of the benchmark matrix.
3. Memcached [04] achieved 95% CIs [23.54, 32.25]%, [20.76, 41.61]%
   and [21.59, 30.02]% more operations per second (OPS), respectively,
   for sequential access, random access and Gaussian (distribution)
   access, when THP=always; 95% CIs [13.85, 15.97]% and
   [23.94, 29.92]% more OPS, respectively, for random access and
   Gaussian access, when THP=never. There were no statistically
   significant changes in OPS for the rest of the benchmark matrix.
4. MongoDB [05] achieved 95% CIs [2.23, 3.44]%, [6.97, 9.73]% and
   [2.16, 3.55]% more operations per second (OPS), respectively, for
   exponential (distribution) access, random access and Zipfian
   (distribution) access, when underutilizing memory; 95% CIs
   [8.83, 10.03]%, [21.12, 23.14]% and [5.53, 6.46]% more OPS,
   respectively, for exponential access, random access and Zipfian
   access, when overcommitting memory.

On 5.15:
5. Apache Cassandra [06] achieved 95% CIs [1.06, 4.10]%, [1.94, 5.43]%
   and [4.11, 7.50]% more operations per second (OPS), respectively,
   for exponential (distribution) access, random access and Zipfian
   (distribution) access, when swap was off; 95% CIs [0.50, 2.60]%,
   [6.51, 8.77]% and [3.29, 6.75]% more OPS, respectively, for
   exponential access, random access and Zipfian access, when swap was
   on.
6. Apache Hadoop [07] took 95% CIs [5.31, 9.69]% and [2.02, 7.86]%
   less average wall time to finish twelve parallel TeraSort jobs,
   respectively, under the medium- and the high-concurrency
   conditions, when swap was on. There were no statistically
   significant changes in average wall time for the rest of the
   benchmark matrix.
7. PostgreSQL [08] achieved 95% CI [1.75, 6.42]% more transactions per
   minute (TPM) under the high-concurrency condition, when swap was
   off; 95% CIs [12.82, 18.69]% and [22.70, 46.86]% more TPM,
   respectively, under the medium- and the high-concurrency
   conditions, when swap was on. There were no statistically
   significant changes in TPM for the rest of the benchmark matrix.
8. Redis [09] achieved 95% CIs [0.58, 5.94]%, [6.55, 14.58]% and
   [11.47, 19.36]% more total operations per second (OPS),
   respectively, for sequential access, random access and Gaussian
   (distribution) access, when THP=always; 95% CIs [1.27, 3.54]%,
   [10.11, 14.81]% and [8.75, 13.64]% more total OPS, respectively,
   for sequential access, random access and Gaussian access, when
   THP=never.

Our lab results
---------------
To supplement the above results, we ran the following benchmark suites
on 5.16-rc7 and found no regressions [10].
      fs_fio_bench_hdd_mq      pft
      fs_lmbench               pgsql-hammerdb
      fs_parallelio            redis
      fs_postmark              stream
      hackbench                sysbenchthread
      kernbench                tpcc_spark
      memcached                unixbench
      multichase               vm-scalability
      mutilate                 will-it-scale
      nginx

[01] https://trends.google.com
[02] https://lore.kernel.org/r/20211102002002.92051-1-bot@edi.works/
[03] https://lore.kernel.org/r/20211009054315.47073-1-bot@edi.works/
[04] https://lore.kernel.org/r/20211021194103.65648-1-bot@edi.works/
[05] https://lore.kernel.org/r/20211109021346.50266-1-bot@edi.works/
[06] https://lore.kernel.org/r/20211202062806.80365-1-bot@edi.works/
[07] https://lore.kernel.org/r/20211209072416.33606-1-bot@edi.works/
[08] https://lore.kernel.org/r/20211218071041.24077-1-bot@edi.works/
[09] https://lore.kernel.org/r/20211122053248.57311-1-bot@edi.works/
[10] https://lore.kernel.org/r/20220104202247.2903702-1-yuzhao@google.com/

Read-world applications
=======================
Third-party testimonials
------------------------
Konstantin reported [11]:
   I have Archlinux with 8G RAM + zswap + swap. While developing, I
   have lots of apps opened such as multiple LSP-servers for different
   langs, chats, two browsers, etc... Usually, my system gets quickly
   to a point of SWAP-storms, where I have to kill LSP-servers,
   restart browsers to free memory, etc, otherwise the system lags
   heavily and is barely usable.
   
   1.5 day ago I migrated from 5.11.15 kernel to 5.12 + the LRU
   patchset, and I started up by opening lots of apps to create memory
   pressure, and worked for a day like this. Till now I had not a
   single SWAP-storm, and mind you I got 3.4G in SWAP. I was never
   getting to the point of 3G in SWAP before without a single
   SWAP-storm.

Vaibhav from IBM reported [12]:
   In a synthetic MongoDB Benchmark, seeing an average of ~19%
   throughput improvement on POWER10(Radix MMU + 64K Page Size) with
   MGLRU patches on top of 5.16 kernel for MongoDB + YCSB across
   three different request distributions, namely, Exponential, Uniform
   and Zipfan.

Shuang from U of Rochester reported [13]:
   With the MGLRU, fio achieved 95% CIs [38.95, 40.26]%, [4.12, 6.64]%
   and [9.26, 10.36]% higher throughput, respectively, for random
   access, Zipfian (distribution) access and Gaussian (distribution)
   access, when the average number of jobs per CPU is 1; 95% CIs
   [42.32, 49.15]%, [9.44, 9.89]% and [20.99, 22.86]% higher
   throughput, respectively, for random access, Zipfian access and
   Gaussian access, when the average number of jobs per CPU is 2.

Daniel from Michigan Tech reported [14]:
   With Memcached allocating ~100GB of byte-addressable Optante,
   performance improvement in terms of throughput (measured as queries
   per second) was about 10% for a series of workloads.

Large-scale deployments
-----------------------
We've rolled out MGLRU to tens of millions of ChromeOS users and
about a million Android users. Google's fleetwide profiling [15] shows
an overall 40% decrease in kswapd CPU usage, in addition to
improvements in other UX metrics, e.g., an 85% decrease in the number
of low-memory kills at the 75th percentile and an 18% decrease in
app launch time at the 50th percentile.

The downstream kernels that have been using MGLRU include:
1. Android [16]
2. Arch Linux Zen [17]
3. Armbian [18]
4. ChromeOS [19]
5. Liquorix [20]
6. OpenWrt [21]
7. post-factum [22]
8. XanMod [23]

[11] https://lore.kernel.org/r/140226722f2032c86301fbd326d91baefe3d7d23.camel@yandex.ru/
[12] https://lore.kernel.org/r/87czj3mux0.fsf@vajain21.in.ibm.com/
[13] https://lore.kernel.org/r/20220105024423.26409-1-szhai2@cs.rochester.edu/
[14] https://lore.kernel.org/r/CA+4-3vksGvKd18FgRinxhqHetBS1hQekJE2gwco8Ja-bJWKtFw@mail.gmail.com/
[15] https://dl.acm.org/doi/10.1145/2749469.2750392
[16] https://android.com
[17] https://archlinux.org
[18] https://armbian.com
[19] https://chromium.org
[20] https://liquorix.net
[21] https://openwrt.org
[22] https://codeberg.org/pf-kernel
[23] https://xanmod.org

Summary
=======
The facts are:
1. The independent lab results and the real-world applications
   indicate substantial improvements; there are no known regressions.
2. Thrashing prevention, working set estimation and proactive reclaim
   work out of the box; there are no equivalent solutions.
3. There is a lot of new code; no smaller changes have been
   demonstrated similar effects.

Our options, accordingly, are:
1. Given the amount of evidence, the reported improvements will likely
   materialize for a wide range of workloads.
2. Gauging the interest from the past discussions, the new features
   will likely be put to use for both personal computers and data
   centers.
3. Based on Google's track record, the new code will likely be well
   maintained in the long term. It'd be more difficult if not
   impossible to achieve similar effects with other approaches.


This patch (of 14):

Some architectures automatically set the accessed bit in PTEs, e.g., x86
and arm64 v8.2.  On architectures that do not have this capability,
clearing the accessed bit in a PTE usually triggers a page fault following
the TLB miss of this PTE (to emulate the accessed bit).

Being aware of this capability can help make better decisions, e.g.,
whether to spread the work out over a period of time to reduce bursty page
faults when trying to clear the accessed bit in many PTEs.

Note that theoretically this capability can be unreliable, e.g.,
hotplugged CPUs might be different from builtin ones.  Therefore it should
not be used in architecture-independent code that involves correctness,
e.g., to determine whether TLB flushes are required (in combination with
the accessed bit).

Link: https://lkml.kernel.org/r/20220918080010.2920238-1-yuzhao@google.com
Link: https://lkml.kernel.org/r/20220918080010.2920238-2-yuzhao@google.com
Signed-off-by: Yu Zhao <yuzhao@google.com>
Reviewed-by: Barry Song <baohua@kernel.org>
Acked-by: Brian Geffon <bgeffon@google.com>
Acked-by: Jan Alexander Steffens (heftig) <heftig@archlinux.org>
Acked-by: Oleksandr Natalenko <oleksandr@natalenko.name>
Acked-by: Steven Barrett <steven@liquorix.net>
Acked-by: Suleiman Souhlal <suleiman@google.com>
Acked-by: Will Deacon <will@kernel.org>
Tested-by: Daniel Byrne <djbyrne@mtu.edu>
Tested-by: Donald Carr <d@chaos-reins.com>
Tested-by: Holger Hoffstätte <holger@applied-asynchrony.com>
Tested-by: Konstantin Kharlamov <Hi-Angel@yandex.ru>
Tested-by: Shuang Zhai <szhai2@cs.rochester.edu>
Tested-by: Sofia Trinh <sofia.trinh@edi.works>
Tested-by: Vaibhav Jain <vaibhav@linux.ibm.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: Aneesh Kumar K.V <aneesh.kumar@linux.ibm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Dave Hansen <dave.hansen@linux.intel.com>
Cc: Hillf Danton <hdanton@sina.com>
Cc: Jens Axboe <axboe@kernel.dk>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Cc: Jonathan Corbet <corbet@lwn.net>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: linux-arm-kernel@lists.infradead.org
Cc: Matthew Wilcox <willy@infradead.org>
Cc: Mel Gorman <mgorman@suse.de>
Cc: Michael Larabel <Michael@MichaelLarabel.com>
Cc: Michal Hocko <mhocko@kernel.org>
Cc: Mike Rapoport <rppt@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Tejun Heo <tj@kernel.org>
Cc: Vlastimil Babka <vbabka@suse.cz>
Cc: Miaohe Lin <linmiaohe@huawei.com>
Cc: Mike Rapoport <rppt@linux.ibm.com>
Cc: Qi Zheng <zhengqi.arch@bytedance.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
2022-09-26 19:46:08 -07:00
Peter Xu 0d206b5d2e mm/swap: add swp_offset_pfn() to fetch PFN from swap entry
We've got a bunch of special swap entries that stores PFN inside the swap
offset fields.  To fetch the PFN, normally the user just calls
swp_offset() assuming that'll be the PFN.

Add a helper swp_offset_pfn() to fetch the PFN instead, fetching only the
max possible length of a PFN on the host, meanwhile doing proper check
with MAX_PHYSMEM_BITS to make sure the swap offsets can actually store the
PFNs properly always using the BUILD_BUG_ON() in is_pfn_swap_entry().

One reason to do so is we never tried to sanitize whether swap offset can
really fit for storing PFN.  At the meantime, this patch also prepares us
with the future possibility to store more information inside the swp
offset field, so assuming "swp_offset(entry)" to be the PFN will not stand
any more very soon.

Replace many of the swp_offset() callers to use swp_offset_pfn() where
proper.  Note that many of the existing users are not candidates for the
replacement, e.g.:

  (1) When the swap entry is not a pfn swap entry at all, or,
  (2) when we wanna keep the whole swp_offset but only change the swp type.

For the latter, it can happen when fork() triggered on a write-migration
swap entry pte, we may want to only change the migration type from
write->read but keep the rest, so it's not "fetching PFN" but "changing
swap type only".  They're left aside so that when there're more
information within the swp offset they'll be carried over naturally in
those cases.

Since at it, dropping hwpoison_entry_to_pfn() because that's exactly what
the new swp_offset_pfn() is about.

Link: https://lkml.kernel.org/r/20220811161331.37055-4-peterx@redhat.com
Signed-off-by: Peter Xu <peterx@redhat.com>
Reviewed-by: "Huang, Ying" <ying.huang@intel.com>
Cc: Alistair Popple <apopple@nvidia.com>
Cc: Andi Kleen <andi.kleen@intel.com>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Cc: David Hildenbrand <david@redhat.com>
Cc: Hugh Dickins <hughd@google.com>
Cc: "Kirill A . Shutemov" <kirill@shutemov.name>
Cc: Minchan Kim <minchan@kernel.org>
Cc: Nadav Amit <nadav.amit@gmail.com>
Cc: Vlastimil Babka <vbabka@suse.cz>
Cc: Dave Hansen <dave.hansen@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
2022-09-26 19:46:05 -07:00
Sami Tolvanen 607289a7cd treewide: Drop function_nocfi
With -fsanitize=kcfi, we no longer need function_nocfi() as
the compiler won't change function references to point to a
jump table. Remove all implementations and uses of the macro.

Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
Reviewed-by: Kees Cook <keescook@chromium.org>
Tested-by: Kees Cook <keescook@chromium.org>
Tested-by: Nathan Chancellor <nathan@kernel.org>
Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Tested-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20220908215504.3686827-14-samitolvanen@google.com
2022-09-26 10:13:14 -07:00
Sami Tolvanen 5f20997c19 arm64: Drop unneeded __nocfi attributes
With -fsanitize=kcfi, CONFIG_CFI_CLANG no longer has issues
with address space confusion in functions that switch to linear
mapping. Now that the indirectly called assembly functions have
type annotations, drop the __nocfi attributes.

Suggested-by: Mark Rutland <mark.rutland@arm.com>
Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
Reviewed-by: Kees Cook <keescook@chromium.org>
Tested-by: Kees Cook <keescook@chromium.org>
Tested-by: Nathan Chancellor <nathan@kernel.org>
Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Tested-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20220908215504.3686827-12-samitolvanen@google.com
2022-09-26 10:13:14 -07:00
Sami Tolvanen b26e484b8b arm64: Add CFI error handling
With -fsanitize=kcfi, CFI always traps. Add arm64 support for handling CFI
failures. The registers containing the target address and the expected type
are encoded in the first ten bits of the ESR as follows:

 - 0-4: n, where the register Xn contains the target address
 - 5-9: m, where the register Wm contains the type hash

This produces the following oops on CFI failure (generated using lkdtm):

[   21.885179] CFI failure at lkdtm_indirect_call+0x2c/0x44 [lkdtm]
(target: lkdtm_increment_int+0x0/0x1c [lkdtm]; expected type: 0x7e0c52a)
[   21.886593] Internal error: Oops - CFI: 0 [#1] PREEMPT SMP
[   21.891060] Modules linked in: lkdtm
[   21.893363] CPU: 0 PID: 151 Comm: sh Not tainted
5.19.0-rc1-00021-g852f4e48dbab #1
[   21.895560] Hardware name: linux,dummy-virt (DT)
[   21.896543] pstate: 80400009 (Nzcv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
[   21.897583] pc : lkdtm_indirect_call+0x2c/0x44 [lkdtm]
[   21.898551] lr : lkdtm_CFI_FORWARD_PROTO+0x3c/0x6c [lkdtm]
[   21.899520] sp : ffff8000083a3c50
[   21.900191] x29: ffff8000083a3c50 x28: ffff0000027e0ec0 x27: 0000000000000000
[   21.902453] x26: 0000000000000000 x25: ffffc2aa3d07e7b0 x24: 0000000000000002
[   21.903736] x23: ffffc2aa3d079088 x22: ffffc2aa3d07e7b0 x21: ffff000003379000
[   21.905062] x20: ffff8000083a3dc0 x19: 0000000000000012 x18: 0000000000000000
[   21.906371] x17: 000000007e0c52a5 x16: 000000003ad55aca x15: ffffc2aa60d92138
[   21.907662] x14: ffffffffffffffff x13: 2e2e2e2065707974 x12: 0000000000000018
[   21.909775] x11: ffffc2aa62322b88 x10: ffffc2aa62322aa0 x9 : c7e305fb5195d200
[   21.911898] x8 : ffffc2aa3d077e20 x7 : 6d20676e696c6c61 x6 : 43203a6d74646b6c
[   21.913108] x5 : ffffc2aa6266c9df x4 : ffffc2aa6266c9e1 x3 : ffff8000083a3968
[   21.914358] x2 : 80000000fffff122 x1 : 00000000fffff122 x0 : ffffc2aa3d07e8f8
[   21.915827] Call trace:
[   21.916375]  lkdtm_indirect_call+0x2c/0x44 [lkdtm]
[   21.918060]  lkdtm_CFI_FORWARD_PROTO+0x3c/0x6c [lkdtm]
[   21.919030]  lkdtm_do_action+0x34/0x4c [lkdtm]
[   21.919920]  direct_entry+0x170/0x1ac [lkdtm]
[   21.920772]  full_proxy_write+0x84/0x104
[   21.921759]  vfs_write+0x188/0x3d8
[   21.922387]  ksys_write+0x78/0xe8
[   21.922986]  __arm64_sys_write+0x1c/0x2c
[   21.923696]  invoke_syscall+0x58/0x134
[   21.924554]  el0_svc_common+0xb4/0xf4
[   21.925603]  do_el0_svc+0x2c/0xb4
[   21.926563]  el0_svc+0x2c/0x7c
[   21.927147]  el0t_64_sync_handler+0x84/0xf0
[   21.927985]  el0t_64_sync+0x18c/0x190
[   21.929133] Code: 728a54b1 72afc191 6b11021f 54000040 (d4304500)
[   21.930690] ---[ end trace 0000000000000000 ]---
[   21.930971] Kernel panic - not syncing: Oops - CFI: Fatal exception

Suggested-by: Mark Rutland <mark.rutland@arm.com>
Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
Reviewed-by: Kees Cook <keescook@chromium.org>
Tested-by: Kees Cook <keescook@chromium.org>
Tested-by: Nathan Chancellor <nathan@kernel.org>
Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Tested-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20220908215504.3686827-11-samitolvanen@google.com
2022-09-26 10:13:14 -07:00
Sami Tolvanen c50d32859e arm64: Add types to indirect called assembly functions
With CONFIG_CFI_CLANG, assembly functions indirectly called from C
code must be annotated with type identifiers to pass CFI checking. Use
SYM_TYPED_FUNC_START for the indirectly called functions, and ensure
we emit `bti c` also with SYM_TYPED_FUNC_START.

Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
Reviewed-by: Kees Cook <keescook@chromium.org>
Tested-by: Kees Cook <keescook@chromium.org>
Tested-by: Nathan Chancellor <nathan@kernel.org>
Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Tested-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20220908215504.3686827-10-samitolvanen@google.com
2022-09-26 10:13:13 -07:00
Sami Tolvanen f143ff397a treewide: Filter out CC_FLAGS_CFI
In preparation for removing CC_FLAGS_CFI from CC_FLAGS_LTO, explicitly
filter out CC_FLAGS_CFI in all the makefiles where we currently filter
out CC_FLAGS_LTO.

Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
Reviewed-by: Kees Cook <keescook@chromium.org>
Tested-by: Kees Cook <keescook@chromium.org>
Tested-by: Nathan Chancellor <nathan@kernel.org>
Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Tested-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20220908215504.3686827-2-samitolvanen@google.com
2022-09-26 10:13:12 -07:00
Paolo Bonzini c59fb12758 KVM: remove KVM_REQ_UNHALT
KVM_REQ_UNHALT is now unnecessary because it is replaced by the return
value of kvm_vcpu_block/kvm_vcpu_halt.  Remove it.

No functional change intended.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Sean Christopherson <seanjc@google.com>
Acked-by: Marc Zyngier <maz@kernel.org>
Message-Id: <20220921003201.1441511-13-seanjc@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2022-09-26 12:37:21 -04:00
Joerg Roedel 38713c6028 Merge branches 'apple/dart', 'arm/mediatek', 'arm/omap', 'arm/smmu', 'virtio', 'x86/vt-d', 'x86/amd' and 'core' into next 2022-09-26 15:52:31 +02:00
Elliot Berman b2a4d007c3 KVM: arm64: Ignore kvm-arm.mode if !is_hyp_mode_available()
Ignore kvm-arm.mode if !is_hyp_mode_available(). Specifically, we want
to avoid switching kvm_mode to KVM_MODE_PROTECTED if hypervisor mode is
not available. This prevents "Protected KVM" cpu capability being
reported when Linux is booting in EL1 and would not have KVM enabled.
Reasonably though, we should warn if the command line is requesting a
KVM mode at all if KVM isn't actually available. Allow
"kvm-arm.mode=none" to skip the warning since this would disable KVM
anyway.

Signed-off-by: Elliot Berman <quic_eberman@quicinc.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20220920190658.2880184-1-quic_eberman@quicinc.com
2022-09-26 10:49:49 +01:00
Gavin Shan 096560dd13 KVM: arm64: vgic: Remove duplicate check in update_affinity_collection()
The 'coll' parameter to update_affinity_collection() is never NULL,
so comparing it with 'ite->collection' is enough to cover both
the NULL case and the "another collection" case.

Remove the duplicate check in update_affinity_collection().

Signed-off-by: Gavin Shan <gshan@redhat.com>
[maz: repainted commit message]
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20220923065447.323445-1-gshan@redhat.com
2022-09-26 10:46:37 +01:00
Greg Kroah-Hartman 67102bd31b Merge 6.0-rc7 into usb-next
We need the USB fixes in here for other follow-on changes to be able to
be applied successfully.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-09-26 10:38:21 +02:00
Rafał Miłecki 28fc7c986f nvmem: prefix all symbols with NVMEM_
This unifies all NVMEM symbols. They follow one style now.

Reviewed-by: Matthias Brugger <matthias.bgg@gmail.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Link: https://lore.kernel.org/r/20220916122100.170016-8-srinivas.kandagatla@linaro.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-09-24 14:54:38 +02:00
Lukas Bulwahn 611d451e40 crypto: arm64 - revert unintended config name change for CRYPTO_SHA1_ARM64_CE
Commit 3f342a2325 ("crypto: Kconfig - simplify hash entries") makes
various changes to the config descriptions as part of some consolidation
and clean-up, but among all those changes, it also accidently renames
CRYPTO_SHA1_ARM64_CE to CRYPTO_SHA1_ARM64.

Revert this unintended config name change.

See Link for the author's confirmation of this happening accidently.

Fixes: 3f342a2325 ("crypto: Kconfig - simplify hash entries")
Link: https://lore.kernel.org/all/MW5PR84MB18424AB8C095BFC041AE33FDAB479@MW5PR84MB1842.NAMPRD84.PROD.OUTLOOK.COM/
Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
2022-09-24 16:14:43 +08:00
Linus Torvalds a63f2e7cb1 arm64 fixes for -rc7
- Fix false positive "sleeping while atomic" warning resulting from
   the kPTI rework taking a mutex too early.
 
 - Fix possible overflow in AMU frequency calculation
 
 - Fix incorrect shift in CMN PMU driver which causes problems with
   newer versions of the IP
 
 - Reduce alignment of the CFI jump table to avoid huge kernel images
   and link errors with !4KiB page size configurations
 -----BEGIN PGP SIGNATURE-----
 
 iQFEBAABCgAuFiEEPxTL6PPUbjXGY88ct6xw3ITBYzQFAmMtrWwQHHdpbGxAa2Vy
 bmVsLm9yZwAKCRC3rHDchMFjNJ/QCACnRX9+S83mixt+EEbqDMkCDqlKqpwYAP0a
 Fq7Yb4/iOqBCHY0n9of5SalpLc/ExAWDJiXoA0Y5g1E2hZMJnSvMx8aC6r92Ofdx
 uwx9PlWP6GhB7s1+kCNEHcSGHLDv4HT0nu/xbFHl64R+JwONeiB7tH3Mf9vXE05g
 As07ij7aLckMx19+SnezPawD55A6xKJ1KtoAF9NjWOuj79jJ7uTm9wCjAM29GPMT
 wC8axTaeqgHcI6fLqNpQ5cSQNHwN51f0PnPmj/fAeaJ8riAEubP1+ys4NNczrO0H
 uHQOnD0kArtjro/dNYZZZGa1u9BS+qYENgSwAl09cZ3r6orRrda4
 =EiMW
 -----END PGP SIGNATURE-----

Merge tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux

Pull arm64 fixes from Will Deacon:
 "These are all very simple and self-contained, although the CFI
  jump-table fix touches the generic linker script as that's where the
  problematic macro lives.

   - Fix false positive "sleeping while atomic" warning resulting from
     the kPTI rework taking a mutex too early.

   - Fix possible overflow in AMU frequency calculation

   - Fix incorrect shift in CMN PMU driver which causes problems with
     newer versions of the IP

   - Reduce alignment of the CFI jump table to avoid huge kernel images
     and link errors with !4KiB page size configurations"

* tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux:
  vmlinux.lds.h: CFI: Reduce alignment of jump-table to function alignment
  perf/arm-cmn: Add more bits to child node address offset field
  arm64: topology: fix possible overflow in amu_fie_setup()
  arm64: mm: don't acquire mutex when rewriting swapper
2022-09-23 15:28:51 -07:00
Arnd Bergmann 1ee41d92f1 Renesas ARM SoC updates for v6.1
- Drop superfluous selects of SOC_BUS.
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQQ9qaHoIs/1I4cXmEiKwlD9ZEnxcAUCYyhVdAAKCRCKwlD9ZEnx
 cGMLAQCmqW2G/sOlBzR+9vHUqvvNVbLWAc+1DfW6yh1uDbLsGQD/bdZrbKyeLPuw
 j+xysaxRUB6Aom8h6vwgH9rSGLqnwAQ=
 =Cht9
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMt/HMACgkQmmx57+YA
 GNnMdQ/9GU8v4CtyrB/09kUV7q+mKowGa4PTzOab/CKXqSmiIx5mNETPEQPT4yrx
 m82GLj0op9UbtV3obNzwejEhEDgmdmSCaKHzgWZbGwg6GILeBWNaAoG1IwVJE8gl
 jymu58+LGinLh8Hp2JCok/9S/CCFHALwrp+EZXhjO6jDfCYGdJ6rAIrHNRay5loa
 OpX1lnEd+iZmAUE/tTzEX7Ih+3YWpHb4O1Vrg/BJeHCxqEXFloROMwWZR+9Z+Xty
 pGvrTJmdwZJA+hSkJ4Fgon7UN0SLqCPws6/vdV8QRAXQhQmIACyYELTzRhA3buVS
 Tpc2uHqGKswp6X2CFLG1o+UVfsRvmAZ0Nlt0+Ic2x8hIVAgeRbwK2Avk5+r+WT3e
 96PzOLkc4xgecaYEtwxkRv9HVU4Q0IhoVtyYGQKyNmCVs2Pyv2Iz93UWCb2CCCo+
 iHc5sEAVCwg+cNTPJObSUDf0ASVeeaT92M7M0CNXb/xVA1btEHYriuAhqUh2UQWx
 U+sYXKoOM+ctsImjhVbMsIKfGTNbTUs/39Jeb46DwZwWyrHPnNUJqvhy8WB10yU8
 uNg/a64bGZnVlBqzYyit/ZWJy5FrD0xRLHeddxpfuBJiM8HRPmtndESIRs56vFEc
 PNx41nMFVjSx3w7RyGEQlckkUh5gEJ4W6r6jhrzmRlBD9L99J1M=
 =/UxN
 -----END PGP SIGNATURE-----

Merge tag 'renesas-arm-soc-for-v6.1-tag1' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-devel into arm/soc

Renesas ARM SoC updates for v6.1

  - Drop superfluous selects of SOC_BUS.

* tag 'renesas-arm-soc-for-v6.1-tag1' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-devel:
  ARM: shmobile: Drop selecting SOC_BUS
  arm64: renesas: Drop selecting SOC_BUS

Link: https://lore.kernel.org/r/cover.1663588781.git.geert+renesas@glider.be
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 20:35:31 +02:00
Arnd Bergmann d1d48fd18a Qualcomm ARM64 defconfig updates for 6.1
This enables core providers needed to boot SC8180X, sound drivers for
 SC7180 and SC7280, the Qualcomm EDP PHY, last-level cache controller
 driver, on-chip memory driver and the SPM driver.
 -----BEGIN PGP SIGNATURE-----
 
 iQJJBAABCAAzFiEEBd4DzF816k8JZtUlCx85Pw2ZrcUFAmMrI6gVHGFuZGVyc3Nv
 bkBrZXJuZWwub3JnAAoJEAsfOT8Nma3Fo08QALw8PykktAsdOGjEkwuAbnhZsUH7
 s/bpR8Z3zZ+XGgJ25/vWI7HNqcLmUNJTpc72JMhVXcqEOAutXWxtML6fMN5sCmi5
 MGV+rwi9wm8hTmG7colGTykOwr2tpTcpPo8Xdf0Ii8/dfExUWxi63Ae0F8rYsEXD
 RVJFbvgM6gAaoUipvrP7L+GZpOmrHLBCjwGNFKiBsfkRAmg0YQdQf1wWgYQgSh8w
 OGgpJ60h/h9ReCeRrEWHpuzCTqq5y0qJuiz4pSBY0dHKB7wVUGRuraOf+FhTiJG8
 AMljNzXALd4cji/JUqRNw2ZqG7A1jQKucp7t0KaWQuXNmvYb7IqnmWR/kjuJ6QPp
 855Ryex1S8fOTNpboK0sMyTHzcqANIeZPl4WaWCSLcaNR4+b8AaNAbr+FMG7WYKX
 3mOUGAOQHN1pmXaCpeo/qK6YoJ49Bih0fb3q+d4sdLQTmjOyShoznlIoIv8liV4z
 S7ff+s8S75HTlc85eG5lsT7bIAKNZcpAzWewZgjLxYhCi4kJowIGceRkE5FXQKl6
 p0vleRY9YNpZrwgZOyGI+7Y+sLtRx1Fq3vFKL3XOrEfzsneFjCSWV/2+GZlBp0D8
 xIE3WF5JMtnbEQ7R26AHJB2paY/L347ymwSmw8ZVn98vJkvUsQFeLsMXNpv9uVPS
 CctipT8yhCFgsQpR
 =ada5
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMt15EACgkQmmx57+YA
 GNlPiBAAgY1WoP84lbv1NegVEJ3Y0FGnpyS/oSbXp6CY1QCYgaLVWvZW4nIf9KkM
 iSa+SEdCDAEf7resWstESl4JrYOoo7dM31wWXBXq9+tskCQy6t+uBao1WDb4PZP0
 tFlJurCiCcYOFe2bLLHmWzGiL/DLQ0uyDP5GE2S3NxxiPd4Qcs5HajuWlfFGsAfw
 UhsWokD+poH2cpIyjoY5EzUzdP4kfOrJJCePI+1auokuY7IEcSwYtZJyxY5ISQQ3
 Mhxaynt5SAh8FAQJNaocylmQrdC7gJ6VEGsLf65F8FwiWbz/4sDE4wRzhSdhrL3k
 J2Jgd5dnyBtn371TbiSZFKluZFqvAEhz7A80Ffzk8BMEz079Ngo5Hiefbz3ALQI/
 Uq8e2zPHN8eHxrBvLfKykCooed2oSoeq7T2Biy1aB6Y6WZ2Sl7AapS7FjFBDE6i6
 NU9PkhF4j9pAHOW4a+pt4cvi4vPQllj8FH1+B9w/WngErKpXLW/OjsBArkJgCL4W
 6WW5osa0iyjEWffjN1xgCd6HPusLeOawZDro3Joo4nIG6V717zqHof/qmDm/UVEo
 pgYDZHre27s+FO+2vVqZDV0IiuFo4uyZ5BtyiCdw0y2LsdJJ6RxLUhRWKguF7X90
 XQXX8CWUAQDny34iAYnnilYa6Y1N4+cT45gWOFYLrBU0DnGk1Ps=
 =uYuP
 -----END PGP SIGNATURE-----

Merge tag 'qcom-arm64-defconfig-for-6.1' of https://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux into arm/defconfig

Qualcomm ARM64 defconfig updates for 6.1

This enables core providers needed to boot SC8180X, sound drivers for
SC7180 and SC7280, the Qualcomm EDP PHY, last-level cache controller
driver, on-chip memory driver and the SPM driver.

* tag 'qcom-arm64-defconfig-for-6.1' of https://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux:
  arm64: defconfig: Enabled SC8180x configs
  arm64: defconfig: enable newer Qualcomm SoC sound drivers
  arm64: defconfig: enable more Qualcomm drivers

Link: https://lore.kernel.org/r/20220921150314.1312358-1-andersson@kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 17:58:09 +02:00
Mark Brown 075ed7b9e4
arm64: configs: Enable all PMUs provided by Arm
The selection of PMUs enabled in the defconfig is currently a bit random
and does not include a number of those provided by Arm and present in a
fairly wide range of SoCs. Improve coverage and defconfig utility by
enabling all the Arm provided PMUs by default.

Signed-off-by: Mark Brown <broonie@kernel.org>
Reviewed-by: James Clark <james.clark@arm.com>
Reviewed-by: Anshuman Khandual <anshuman.khandual@arm.com>
Link: https://lore.kernel.org/r/20220919162753.3079869-1-broonie@kernel.org'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 17:57:43 +02:00
Arnd Bergmann e1381b13ee Enable devfreq cooling device driver in arm64 defconfig
-----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQSPRixG1tysKC2PKM10Ba7+DO8kkwUCYyeKKQAKCRB0Ba7+DO8k
 k3twAP4iTzbS/CDTCc3pNGZIesdl8hUHskttciiH7MuZzWQ9zwEAsoE7bO8PznUB
 2TYoLzmvE8QEFfcdFwdXM4cpvlIkGgk=
 =yRxp
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMt1xgACgkQmmx57+YA
 GNn4Cw//Tb/XWYraXwSeiest52Qnj3BzYAUfUwOtbxuoP2Wt18JSfFmsCixqkq1+
 fg+Ld4vwEaUcuiYkK5bfV1p66HLW3hVUMd90QRCy//TOiOvBJh+GyFhsEcXPWZGr
 gv9odDhT+5LEcapTG4K6fmMJQxZRdA59IEc/EBf6wj9hRWJEsjcsAlvu21B3HI84
 PYZjvOzvMnGbMXpPD1lrlwB6NH2mTpJQxnCbkpv/v/gtXPtzG/UC4GFTlBTAG5X3
 SDvGujXrpzDQyR2PgqQZTNv26pvAqP8BNHB05E3VPvFxdiDiH23zXdY4ZFYfpw47
 7dh7DU9j2xh0DKhzinhzJzCIak04EQlmcvKHTarl4EMlaOR/idq9jKBeT0moVhRo
 cG0p9106qnv50qiJkSyuhN1JOZtqk39hhJ0pRiv7/71b5S9xbE+jLkgjev8Zq9RS
 NSof/tnDvik/nNQRm6cL2CtL5n6TgQ967OQBPV01edhcGLYH4jj+Du1/nGOC0icm
 kFcBSjZc1IxivbnhnP92aD3tyQDw1nEQsHvk53bCsKodl6rasbKsIpyyVrgoWrMw
 4bMpSpLGDXXzJpCSqJpIx60ZUQb4fTFjT7ZQ0AgA1h7NuDKwr26JzUhQUwWlC98o
 dnYArwxWu5kO5jJfdHpuCO1JxwlVV53fLBb/8LIT/gGgredLHgA=
 =90km
 -----END PGP SIGNATURE-----

Merge tag 'sunxi-config-for-6.1-1' of https://git.kernel.org/pub/scm/linux/kernel/git/sunxi/linux into arm/defconfig

Enable devfreq cooling device driver in arm64 defconfig

* tag 'sunxi-config-for-6.1-1' of https://git.kernel.org/pub/scm/linux/kernel/git/sunxi/linux:
  arm64: defconfig: Enable devfreq cooling device

Link: https://lore.kernel.org/r/YyePcA5YHOZjdOf7@kista.localdomain
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 17:56:08 +02:00
Arnd Bergmann 7b04ab8376 arm64: tegra: Default configuration changes for v6.1-rc1
Enables the new MGBE driver, as well as the existing SPI and QSPI
 drivers on 64-bit ARM. The GPC DMA driver is now also built into the
 kernel by default to avoid needless probe deferrals that would slow
 down the boot process significantly.
 -----BEGIN PGP SIGNATURE-----
 
 iQJHBAABCAAxFiEEiOrDCAFJzPfAjcif3SOs138+s6EFAmMkTFkTHHRyZWRpbmdA
 bnZpZGlhLmNvbQAKCRDdI6zXfz6zoeqcEACFjZGVkgAriqQLN+n/+ZUh/haV8pst
 9TB6ZJ8Gb1LPyfiM9bL/rM5aUxILXmu4xaoa4wyD/mFq3XqjAUeRGmQ9I82FvFSv
 sSI/yrz0+W1oEsdFOUNzRnoToapmHFpWkmPNc5aGA/J4UK47EywHhSC1rYex8+4C
 VKKMIEXA+rGHRFy7+D49JK2ERD5FZbYaP872f26qyYzMaeYqKx7mkRFIzzTQ2tNc
 cAje4Vkzp/G0MH3sldlo0AREH4gmiGB3/36dDgFgQIJXD5tpP1Rjtqnlu2thUp89
 Xfi6FNOYwnpRCVvVlCA1pzGW8TQ0sq6VMQ3DfoVCocdFh8VEfblAlFclFJRgy9mQ
 RotuleCMR0tLsLsazwBascQToSA6h6FxnF47wyiGvTV493aP8DkCrw7xof6D0gWQ
 wjBFBFtgWGOiqOf0iJg7I5lJXYLahU42mXnW91TKUXkFI2CFgq5/Drd5Ja332W4r
 52YC56na5c/8mXaLp+IDCB1fwybJOYE11HBe3yQqkarF61/xVjFQd5UCragSMKLY
 rj51+jgRsNfZj5NU6MRcxOCbn4cseewPgBatDEsevUwnd09nXFWlrkq1RM3iPzoB
 1vdfBd+GF8lC2nHrtNvM+G6w2KQDWVp4+Gyy9pvzNRvQrDILuYt08+BFmWWk2S7Q
 ffp2VpW4aBNFRA==
 =wtaF
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMt1t8ACgkQmmx57+YA
 GNmlWQ//XO1vdPjlWkKH1JxhZdK/keiuUBeugVnyrkiatqN3a6eG8FkKZFot+h3H
 Z7eMiy1wsPxnNxPPGVBIlmncoTEFmpfh5+Quk/Py+/1hmmvxERA2bOqVp1Ecw8fl
 dpNa5tXOW3XvFABuGEL/h+/yiFU/ztJeASGAJCIeEA82kYehumPcv87si/miE7wW
 jjlKs1rlW/1ZRZiYCdX2X4fPfephCcEOE6r3eBbQjGZRRot/uwhEQK+kt2odb9Bf
 ezmfObkoI9L/aMJnkZ37XKRSyTE1amNC9y/q2I9moUbwoODmLiryjAxtnjQb2pDi
 S8lzYtJfeVfuuLJ9HMDGZvLf7q3oyXpjaUfrdkNBGbXRATbnd+iNfYf6KPHfa7XU
 YpM+eWm+Znomg6UDpxhMgb6FFPJFJStp5J3SFXKjd8bo2ST0apORkBMje4mm+Zqz
 UYFypsUwnD9KPhqNpMnvJEm0fNberBOT+tqQ3Mkq9MfEAZLV1hrg43nm//SGp419
 hVPr3qyAe6ide5R2G/up6UfDZmCLZ2nvLBWOZQnbbhsxJSsaOp30tRNN5XWmg+dd
 ibGSNz07HwemAglw/kgkir1GLXgoL2ppAPktszciAEYdqlpmW2PAN7PBfWccek8V
 4xqCPjHdGWk+rFET+bR40llj48VAtsQycc1Gnx5fi0dmky85jwU=
 =Hr4N
 -----END PGP SIGNATURE-----

Merge tag 'tegra-for-6.1-arm64-defconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into arm/defconfig

arm64: tegra: Default configuration changes for v6.1-rc1

Enables the new MGBE driver, as well as the existing SPI and QSPI
drivers on 64-bit ARM. The GPC DMA driver is now also built into the
kernel by default to avoid needless probe deferrals that would slow
down the boot process significantly.

* tag 'tegra-for-6.1-arm64-defconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux:
  arm64: defconfig: Make TEGRA186_GPC_DMA built-in
  arm64: tegra: Enable Tegra SPI & QSPI in deconfig
  arm64: defconfig: Enable Tegra MGBE driver

Link: https://lore.kernel.org/r/20220916101957.1635854-6-thierry.reding@gmail.com
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 17:55:11 +02:00
Arnd Bergmann 141258d430 mvebu dt64 for 6.1 (part 1)
- Add UART1-3 for AC5/AC5X SoC
  - Improve uDPU support (Aramda 3720 based board)
  - Add new eDPU based on uDPU
 -----BEGIN PGP SIGNATURE-----
 
 iF0EABECAB0WIQQYqXDMF3cvSLY+g9cLBhiOFHI71QUCYy3RlwAKCRALBhiOFHI7
 1cGYAJwNGA4PrJaYZJEl5HA2yS2irIa5mwCeJgb2Ka+JMQJBAD1qazCOytwcyaM=
 =vQH9
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMt1PwACgkQmmx57+YA
 GNkQEg/+KzdyCWQPvc+8sGfzAZlHAVpm+UVo4WB2+kebfEqMKFCyIVr01H1Gze89
 HRHuJ/wfN+8+eoTu0E9GSUQjcCsbTNRLkA/iGybMBlSM2cpg0GzEPg9vrlf4ZMks
 24si2Tr2fEZqjsILWktIrGqeI26SQCTUfOkaxfC8axxz/xvtFZhPkJgz9aQ98yGS
 pyXtIAHcbjVbswfa/RC6TyFOQuOZxJV+BSgoDjNsp9RXL+Hr4uXgdySBEshazGVY
 y+4mocuiZCc98cn/TglnazDXJQhI1s0rWDZmWTVlaaZwjAM1wZ+vbCp+F6kDWYp9
 E4tobjRb5MmUxo+5s4/+2JcIwTvsYcxFmi65kzmPn6jRtHSZmpGii8orrHIK6bVp
 0QD0XHxAPCgJCZDJlpaM1VeS/mGtd9g5B2zRJB29XipzxF02km6w7wEL1yxSiayx
 jJzx2VLeH3rH5d+YldRX1om3BFcWTsrQIU66SsSUJ2rVWH9hdIHqeax2htNJ2xji
 NmD9LJGDrEAIsNxM2gx0toR6P8wlCXJGayhtKw9UGD66n49D0/K+Gd61fKj+Y+GO
 0AXrGV5Ca0TFFCvgUUnWNljQ6BDDhgJJODiN1O09G6qQYoPjW4sBiT4Jfv+FKAFg
 RhnqfNx7bijQnZ0hCrNjFMoltVgc53X3WP1AotqGjTO3ru8nl3Q=
 =Uuqf
 -----END PGP SIGNATURE-----

Merge tag 'mvebu-dt64-6.1-1' of git://git.kernel.org/pub/scm/linux/kernel/git/gclement/mvebu into arm/dt

mvebu dt64 for 6.1 (part 1)

 - Add UART1-3 for AC5/AC5X SoC
 - Improve uDPU support (Aramda 3720 based board)
 - Add new eDPU based on uDPU

* tag 'mvebu-dt64-6.1-1' of git://git.kernel.org/pub/scm/linux/kernel/git/gclement/mvebu:
  arm64: dts: marvell: 98dx25xx: use correct property for i2c gpios
  arm64: dts: marvell: add support for Methode eDPU
  dt-bindings: marvell: armada-37xx: add Methode eDPU compatible
  arm64: dts: marvell: split Methode uDPU DTS
  arm64: dts: marvell: rename temp sensor nodes
  arm64: dts: marvell: uDPU: remove LED node pinctrl-names
  arm64: dts: marvell: uDPU: align LED-s with bindings
  arm64: dts: marvell: uDPU: add missing SoC compatible
  arm64: dts: marvell: espressobin-ultra: add generic Espressobin compatible
  dt-bindings: marvell: convert Armada 37xx compatibles to YAML
  dt-bindings: vendor-prefixes: add Methode Electronics
  arm64: dts: marvell: Add UART1-3 for AC5/AC5X

Link: https://lore.kernel.org/r/87h70yxfmy.fsf@BL-laptop
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 17:47:08 +02:00
Linus Torvalds 317fab7ec5 ARM:
* Fix for kmemleak with pKVM
 
 s390:
 
 * Fixes for VFIO with zPCI
 
 * smatch fix
 
 x86:
 
 * Ensure XSAVE-capable hosts always allow  FP and SSE state to be saved
   and restored via KVM_{GET,SET}_XSAVE
 
 * Fix broken max_mmu_rmap_size stat
 
 * Fix compile error with old glibc that doesn't have gettid()
 -----BEGIN PGP SIGNATURE-----
 
 iQFIBAABCAAyFiEE8TM4V0tmI4mGbHaCv/vSX3jHroMFAmMtvg4UHHBib256aW5p
 QHJlZGhhdC5jb20ACgkQv/vSX3jHroNy2Af/VybWK2uAbaMkV6irQ1YTJIrRPco1
 C+JQdiQklYbjzThfPWNF/MiH+VTObloR1KqztOeQbfcrgwzygO68D3bs0wkAukLA
 mtdcMjdsqNx8r9u533i6S8Dpo0RkHKl+I8+3mHdPHTzlrbCuYJFFFxFNLhE+xbrK
 DP2Gl/xXIGYwOv2nfHA/xxI7TRICv4IxmzQazxlmC27n6BLNSr8qp6jI9lXJQfJ8
 XJh3SbmRux3/cs2oEqONg8DySJh631kI1jGGOmL3qk07ZR7A5KZ+lju0xM7vQIEq
 aR25YNYZux+BPIY/WxT1R0j6pwinBmFp8OoQYCs8DaQ65fdE5gegtJRpow==
 =VADm
 -----END PGP SIGNATURE-----

Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm

Pull kvm fixes from Paolo Bonzini:
 "As everyone back came back from conferences, here are the pending
  patches for Linux 6.0.

  ARM:

   - Fix for kmemleak with pKVM

  s390:

   - Fixes for VFIO with zPCI

   - smatch fix

  x86:

   - Ensure XSAVE-capable hosts always allow FP and SSE state to be
     saved and restored via KVM_{GET,SET}_XSAVE

   - Fix broken max_mmu_rmap_size stat

   - Fix compile error with old glibc that doesn't have gettid()"

* tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm:
  KVM: x86: Inject #UD on emulated XSETBV if XSAVES isn't enabled
  KVM: x86: Always enable legacy FP/SSE in allowed user XFEATURES
  KVM: x86: Reinstate kvm_vcpu_arch.guest_supported_xcr0
  KVM: x86/mmu: add missing update to max_mmu_rmap_size
  selftests: kvm: Fix a compile error in selftests/kvm/rseq_test.c
  KVM: s390: pci: register pci hooks without interpretation
  KVM: s390: pci: fix GAIT physical vs virtual pointers usage
  KVM: s390: Pass initialized arg even if unused
  KVM: s390: pci: fix plain integer as NULL pointer warnings
  KVM: arm64: Use kmemleak_free_part_phys() to unregister hyp_mem_base
2022-09-23 08:42:30 -07:00
Arnd Bergmann c69badd1d7 Qualcomm ARM64 DTS fixes for 6.0
This corrects invalid IOMMU streams for the SM8150 CDSP FastRPC, moves
 the wakeup-source of SC7280 USB nodes to the correct place, fixes the
 SM8350 UFS PHY serdes size to not overlap with the other subnodes and
 updates the firmware location for the Lenovo ThinkPad X13s to match the
 movement in linux-firmware.
 
 It also updates MAINTAINERS and .mailmap to reflect the changes in my
 email address.
 -----BEGIN PGP SIGNATURE-----
 
 iQJJBAABCAAzFiEEBd4DzF816k8JZtUlCx85Pw2ZrcUFAmMrHooVHGFuZGVyc3Nv
 bkBrZXJuZWwub3JnAAoJEAsfOT8Nma3FXQcP/i9Np/QVhTEcyeGyXcM9Et+gUCK+
 ne/4bz+hXJLqrFbd4eZSeHb+tAg0S6yFnEXGrYPHhoe5iRHZGXoIxCbgTwCWO/SN
 sVwfVa5/ekvCQK+yUaKa1POka2TjKKWfTXj/HZiCYRcezWyxkxFZh00cjD3NiC1u
 WaHCB0YbMnvEC1RabJoh+ZK+N2KXPVQpP9n/MZEMXtyPrCLe59feQyg7xcviJ/cY
 Xwc77YB9lKsLiWzbDOvhwdSrEpb7vFvPXFKj4Pg7xEZ1nINUPmdtjf1v/Z/1luAj
 gyxL92xZytSw5oireRf6Vwio80SPopafTeMvsjjvcO0mnmA1LhAD5srnUi8z8yXE
 XVk9CQ/v4HjXYGJJxuTNUo7J30ar3O8Whbd5i0jRuwUCqu1OsgamXJYtK2WUSVyr
 65idMgDfv01F7WMC59ZoLxvoZpncAO5nu+JozdZ4ryR9Iidl3L/D4ge+gjLLBFvR
 8CN1Y/ZV5qqa+VUbovLod4zrr6tGO27OJ7QNIxblMqEBOFF9OEW+fRezH4R37VsM
 Y9B7LWbPVVV/QNmGjXud4hl/ihz8AcgplXMOR5oMmpy8mp3gHFyi8umMcWpw/u6g
 6DeQ356dSP2wFAgE+xlhEYABxIYdN+3wSrxNElgHldP5QxoYufrqT/Tcg6Nd7iHq
 R4VNA9vp/irXtksF
 =0C1/
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMtxlUACgkQmmx57+YA
 GNkb4A/+M9UqBcaskORpCLzW9CF3NFvD9eUqK1c04vlZySnJAnhSv7FiemRM13Ru
 31k1MVORRH0i5KjReM9yB95nyasDhodmumZgZPoYL+iF236NzekeJ3xn+RvG2mpp
 EOVIIL0LlWVS1FQMr8kGaPJxydUxtocPfeaisEu1TIKS01cA4xQ9DlJrYUU/POkV
 BiRVaZlN2kdQPmEJW8ZaAruNsOo7KmGI0yuQ4IzBMFh20Zu/fOnyORNtrbKCfQqK
 9axTb9M/xtnkuoFxtLrVRF7rAumSr5tjvOqWw7gmSM/2kvK6/RuN5/BLkWh8dMyS
 yvQ3xztyI8IJX6YOZ7qcbcLPobxUHcuqUH/cUMRXqtSSW0jMuVItQ4DHm5qleFZ6
 +1XFsHsI8Y7c2jaxY3V5BV2jd98zwxD0FCSvLNi1Sc+eW1FJXdCiv+fqf8q8302O
 jjto6UW7/aiWOFiTErE+Hddcyq0D14BNVlwBMRmPK2Mk4h5NUmMPmur69uYniTcb
 3+Grt8lY13uO5smhFBUrQ/HjC6bGEeKjOpxTQ/LT0/aWlwBsZcP+/ihOK3EinNLJ
 ROSW63iv2iOhNYZ9A7W4D1CGOH62RAxxfaee568LwG8aCLt47FrQ/g5U+z5zkUHc
 M8loNtUpTKIfw4GxJgGHomVXppFx1JbhTrDY35MsmWEeJjIl5rQ=
 =WotM
 -----END PGP SIGNATURE-----

Merge tag 'qcom-arm64-fixes-for-6.0' of https://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux into arm/fixes

Qualcomm ARM64 DTS fixes for 6.0

This corrects invalid IOMMU streams for the SM8150 CDSP FastRPC, moves
the wakeup-source of SC7280 USB nodes to the correct place, fixes the
SM8350 UFS PHY serdes size to not overlap with the other subnodes and
updates the firmware location for the Lenovo ThinkPad X13s to match the
movement in linux-firmware.

It also updates MAINTAINERS and .mailmap to reflect the changes in my
email address.

* tag 'qcom-arm64-fixes-for-6.0' of https://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux:
  arm64: dts: qcom: sm8350: fix UFS PHY serdes size
  arm64: dts: qcom: sc8280xp-x13s: Update firmware location
  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

Link: https://lore.kernel.org/r/20220921142939.1310163-1-andersson@kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 16:44:37 +02:00
Arnd Bergmann 6972b275fe Qualcomm ARM64 DTS updates for 6.1
Support for Samsung Galaxy E5, E7 and Grand Max is added, with support
 for both 32-bit and 64-bit variants. The Samsung Galaxy S4 Mini Value
 Edition gains magnetometer support.
 
 MSM8996-based Xiaomi devices gains descriptions of the LPG-based LEDs.
 
 On SA8295P ADP problems arising from regulators being switched into
 low-power mode is worked around by removing this ability, for now.
 
 The onboard USB Hub on SC7180 Trogdor is finally described and a few ADC
 related updates are introduced.
 
 On SC7280 support for the CPU and LLC bwmon instances are introduced.
 Soundwire, audio codecs and sound introduced for a variety of boards.
 Using required-opps the USB controllers votes for a minimum corner on
 VDD_CX.
 The onboard USB Hub Herobrine is described. A new board, the Google
 Evoker is added, as is another revision of Herobrine Villager.
 
 On SC8280XP the USB controllers are marked as wakeup-sources, to keep
 them powered during suspend. The CRD has HID devices marked as
 wakeup-sources to enable resuming the system. In addition to these
 changes the alternative touchpad is introduced on the Lenovo ThinkPad
 X13s.
 
 SDM845 gains RPMh stats support and the LLCC BWMON is added. For SM6350
 interconnect providers and GPI DMA is introduced. A description of the
 PM7280b PMIC is added to Fairphone FP4 on SM7225.
 
 With the multi-MSI support added in the PCIe controller, SM8250 gets all
 its MSI interrupts added.
 
 UFS ICE and the second SDHCI controller is introduced on SM8450. Support
 for the Sony Xperia 1 IV is introduced.
 
 Throughout a variety of platforms the TCSR mutex syscon is replaced with
 the MMIO-based binding. TCSR nodes gained proper compatibles and halt
 syscon nodes are split out from the mutex ranges.
 
 A range of fixes to align with DT bindings are introduced. Among these
 are the changes to the follow the TLMM binding and suffix pinctrl states
 with -state and subnodes thereof with -pins, another is a number of
 changes transitioning to use -gpios and introduction of proper parent
 clock references in various clock providers.
 -----BEGIN PGP SIGNATURE-----
 
 iQJJBAABCAAzFiEEBd4DzF816k8JZtUlCx85Pw2ZrcUFAmMrosIVHGFuZGVyc3Nv
 bkBrZXJuZWwub3JnAAoJEAsfOT8Nma3FCkkP/iuTNOUwcpz03IijhJJILfUF1aSS
 o7UAadfYj4dKqvc9BGdq+A9OSDqaMmceXwbPWYZQONpHrSNVMIUxUevtrUAxOxYj
 fEf4VLRk2AJ2GqtRasqQL7WOESPS1bD7rRyNg5nFD3urTTqXjkgC9XoYQk9uufPx
 hLdFeEB672pi0HWiQIgk5iL36O6OEEeK6rl0/PF1y8N8GkYVln1XD7SKNs2tsDcM
 0unclymdckPbhxq1tuuRWXhCUZlOWRUP8+89L14M+HT3RrtudnJ8v2jtgygtziPS
 TZ+wJa2CMcIZCgQ7kBcORSiMquIHV4bGcq5UNAX0juU2CFIFIQu+VzStT80+6SsU
 ATkJSl4GKw/HuJS4W0JLk73mLIhtEhqIfR7qFfiDjhGphbgRkTEdMtqG5WIKzf7D
 3ourD0qs3IC+XmtkjnTykJZam9BYNFt99QBHdsjZq37rMvll7BKtEPdrKIKmzzzY
 hqOv27Bt4cp2xgZ6Hoot/oSfCOSQffcHPuDzkrfsinM0ZEeDLpMW7ynIQDvw08Fs
 2OMbhbP3c/onhoaEuLp9eLt+ghV58PkNvKPcWBma5oNCDvi84CRDU8HOGLbnmeDv
 4haXe/Ib3OoT4+raCLYrY5fI3lf2CG9cLQVHs02apilKUQ7HiMLeH3L6vNpH9v0g
 BXpu2rG+gbAgJzgH
 =XT9N
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMtxHsACgkQmmx57+YA
 GNnDbw/7BIQIOXFkx6xb5dJbfxAs9EGlPngcgUGWHMUZ166Q+e+nGCUMiDtekLrC
 E07g05dPO2oaS2XtcHYVQmaR+Sq9SQYb1nFE6P1kvHmz0SxueR8fDpUheFn4IunP
 OCcyPoKGar72HcFh/v2r9SdJgVAEQ6bYvNzwJN2qqMQRW5fMHUBlJtcMumGNyg/0
 MNzoSvmx/s2sL6yf6xVt7kqerl/7szFF13PnbWlUEnDhbZUHoOh5VYt2Xxpp9rjX
 M09iM/mOkyms7ngcU9m+izYAg+aVeDBSynoyhqQUlrDwbFu83TQ+jFSp0MkJrSiQ
 RHJSBNnXx9wmJuox/A2ZBUmMcjqaizz4ciXXVu5t7xP8wFKQZRfblCX1+B2G0qSu
 1rqxBqGrVEzRanoZjpMCSrObSjD/t1wIpTN5hqvpEoR3nXWRFzLOIQjXyIkKVZ4p
 ePc8Et1yYlQqv7S3GS12jLy8s/sKxOk0sTAzWuTavT+QrgJVDZScaSU9t9hhk4tC
 HRlwHBag0nallJcz+gnmbG56f0zcVsvOHnMV+OBFA4wHInlVS+A+Rt0TouqjEiAo
 IlVCXlO24jgsZi/x6ZwVboIBYzPLsaOmsr5Tg9Dua494/U+Im23qCFBvRGHiEoBe
 tAyCAsYSLNsOhgjxC/tFVOQJOmlw+moerBpZNcu2XMG/aXLHwMA=
 =ZHbe
 -----END PGP SIGNATURE-----

Merge tag 'qcom-arm64-for-6.1' of https://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux into arm/dt

Qualcomm ARM64 DTS updates for 6.1

Support for Samsung Galaxy E5, E7 and Grand Max is added, with support
for both 32-bit and 64-bit variants. The Samsung Galaxy S4 Mini Value
Edition gains magnetometer support.

MSM8996-based Xiaomi devices gains descriptions of the LPG-based LEDs.

On SA8295P ADP problems arising from regulators being switched into
low-power mode is worked around by removing this ability, for now.

The onboard USB Hub on SC7180 Trogdor is finally described and a few ADC
related updates are introduced.

On SC7280 support for the CPU and LLC bwmon instances are introduced.
Soundwire, audio codecs and sound introduced for a variety of boards.
Using required-opps the USB controllers votes for a minimum corner on
VDD_CX.
The onboard USB Hub Herobrine is described. A new board, the Google
Evoker is added, as is another revision of Herobrine Villager.

On SC8280XP the USB controllers are marked as wakeup-sources, to keep
them powered during suspend. The CRD has HID devices marked as
wakeup-sources to enable resuming the system. In addition to these
changes the alternative touchpad is introduced on the Lenovo ThinkPad
X13s.

SDM845 gains RPMh stats support and the LLCC BWMON is added. For SM6350
interconnect providers and GPI DMA is introduced. A description of the
PM7280b PMIC is added to Fairphone FP4 on SM7225.

With the multi-MSI support added in the PCIe controller, SM8250 gets all
its MSI interrupts added.

UFS ICE and the second SDHCI controller is introduced on SM8450. Support
for the Sony Xperia 1 IV is introduced.

Throughout a variety of platforms the TCSR mutex syscon is replaced with
the MMIO-based binding. TCSR nodes gained proper compatibles and halt
syscon nodes are split out from the mutex ranges.

A range of fixes to align with DT bindings are introduced. Among these
are the changes to the follow the TLMM binding and suffix pinctrl states
with -state and subnodes thereof with -pins, another is a number of
changes transitioning to use -gpios and introduction of proper parent
clock references in various clock providers.

* tag 'qcom-arm64-for-6.1' of https://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux: (136 commits)
  arm64: dts: qcom: sc7280: Add required-opps for USB
  arm64: dts: qcom: sm8450: fix UFS PHY serdes size
  arm64: dts: qcom: ipq8074: fix PCIe PHY serdes size
  arm64: dts: qcom: sa8295p-adp: add missing gpio-ranges in PMIC GPIOs
  arm64: dts: qcom: sa8295p-adp: add fallback compatible to PMIC GPIOs
  arm64: dts: qcom: msm8996-xiaomi: align PMIC GPIO pin configuration with DT schema
  arm64: dts: qcom: msm8994-msft-lumia-octagon: align resin node name with bindings
  arm64: dts: qcom: pmi8994: add missing MPP compatible fallback
  dt-bindings: pci: QCOM Add missing sc7280 aggre0, aggre1 clocks
  arm64: dts: qcom: sc7280: Add missing aggre0, aggre1 clocks
  arm64: dts: qcom: sc7280-villager: Adjust LTE SKUs
  dt-bindings: arm: qcom: Adjust LTE SKUs for sc7280-villager
  arm64: dts: qcom: sc7280-herobrine: Add nodes for onboard USB hub
  arm64: dts: qcom: sc7180-trogdor: Add nodes for onboard USB hub
  arm64: dts: qcom: align SDHCI reg-names with DT schema
  arm64: dts: qcom: sm8250: provide additional MSI interrupts
  arm64: dts: qcom: msm8996: add #clock-cells and XO clock to the HDMI PHY node
  arm64: dts: qcom: Use WCD9335 DT bindings
  arm64: dts: qcom: msm8994: switch TCSR mutex to MMIO
  arm64: dts: qcom: ipq6018: switch TCSR mutex to MMIO
  ...

Link: https://lore.kernel.org/r/20220921234854.1343238-1-andersson@kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 16:36:43 +02:00
Arnd Bergmann aa577af3de TI K3 device tree updates for v6.1
New Features:
 AM62A:
 * Basic support for AM62A SoC and SK Board
 AM62:
 * EPWM support
 AM64:
 * GPMC, LED, Crypto accelerator support
 
 Fixes:
 J7200 pinmux node update
 Fixes for Crypto and RNG accelerators on AM65, J721e, J7200
 
 Cleanups:
 Reorder SoC compatible and pinmux macros alphabetically
 -----BEGIN PGP SIGNATURE-----
 
 iQFEBAABCAAuFiEEyRC2zAhGcGjrhiNExEYeRXyRFuMFAmMq5n4QHHZpZ25lc2hy
 QHRpLmNvbQAKCRDERh5FfJEW44z/CACMrwIDvNby4wK1TGpv2jtjW2UD/6Bo23ZL
 HYRy2kkNBa5hMbhGZGh5+GznOXyoZJD07OmuYLq8wdxIvo19QHOjAK7YLuHGvpel
 u8o1IPXQEDylgbpcm06vCF/C73UGb8ozBcPP56v8wYhq/AeD7iAd9VtkxzBwdmpu
 hG/X5r1q0LJbxDLrNaI8jjsOjrc2ep5LIbnqzibKZR1+JX1E2LSezDVxjOEtG3aC
 Sl9kgA8mr96nB2WTcAV1oDuaiI9mlH6HEBaofTdFRU4gA9hu9Z7lWBBF3G+GKnTE
 bJIgSxQpzAr1TxqKqIRMzWa9/Xrg6O+M9MBs6RMb0oDMvmb4+wTg
 =fi01
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMtw0EACgkQmmx57+YA
 GNnDCw/8DcqGvp/NJjhmYgfmBL94OHCL6NseST0QRdqBxhQbfskc2rfMf+lxbNR8
 o/Ic5YRwo5z54z34dpw3bi+N0dUYE6V80RJBPOSTlX/Dk3thb1/MyxZqTALhduRU
 BPu/fwZFE34uOi6xy6e8cfZqXtnDX6dHvtw+XCPPJ8Tb34SAmAvkQ/LCLrfS6wjw
 xIGIIVwCiIAHK4FLSd5rvnyeVA0CfKEeDJ405Wob7cKz/aUAwUiwbRPszP9+62JC
 XHvvxZoeFgoG4UhN57RN7E4tkmBkKNYMzNGLd6bKD45YJk4MwzyW560nMcrJ25IJ
 3GimiaFXKG8NRX2Ai0cWyuAp4vOFkygQ2xpMVMjfr0gBkSbV8vuGNUK5yXhkT2V3
 JBz5CA3lo3Di3zTk8qXRRXBDeYIcTPxSYiCpnhuMhdCn282y0VL3h1padgR7W8eg
 F9ikkrkh6T5IAq5yzXHO+FRBaZRmecrHbbsS2H7vnzGLWHCG5ynle/5BeOTVXOeF
 2X7IcPFgzBGFLe02THIooFkeBQ3X0fIn/uJ4VxqwUshuc8BLv5ys6JLFMoHY99Z/
 PI4SJ5tdAo3pacsW5RfvMHZ3jFJwRo2i/kmy95vyeEGm0By1js8eziKi1ehsD195
 tNQSd+giXRBtDGAr/KrRWfwH+MxNNj+g6aWt80HSk2uG3Pr8Qek=
 =XhYf
 -----END PGP SIGNATURE-----

Merge tag 'ti-k3-dt-for-v6.1' of https://git.kernel.org/pub/scm/linux/kernel/git/ti/linux into arm/dt

TI K3 device tree updates for v6.1

New Features:
AM62A:
* Basic support for AM62A SoC and SK Board
AM62:
* EPWM support
AM64:
* GPMC, LED, Crypto accelerator support

Fixes:
J7200 pinmux node update
Fixes for Crypto and RNG accelerators on AM65, J721e, J7200

Cleanups:
Reorder SoC compatible and pinmux macros alphabetically

* tag 'ti-k3-dt-for-v6.1' of https://git.kernel.org/pub/scm/linux/kernel/git/ti/linux: (22 commits)
  arm64: dts: ti: k3-j7200: fix main pinmux range
  arm64: dts: ti: Add support for AM62A7-SK
  arm64: dts: ti: Introduce AM62A7 family of SoCs
  dt-bindings: pinctrl: k3: Introduce pinmux definitions for AM62A
  dt-bindings: arm: ti: Add bindings for AM62A7 SoC
  dt-bindings: arm: ti: Rearrange IOPAD macros alphabetically
  arm64: dts: ti: k3-am625-sk: Add epwm nodes
  arm64: dts: ti: k3-am62-main: Add epwm nodes
  arm64: dts: ti: k3-am642-sk: Add DT entry for onboard LEDs
  arm64: dts: ti: k3-j7200-mcu-wakeup: Add SA2UL node
  arm64: dts: ti: k3-am65-main: Do not exclusively claim SA2UL
  arm64: dts: ti: k3-am65-main: Move SA2UL to unused PSI-L thread ID
  arm64: dts: ti: k3-am65-main: Disable RNG node
  arm64: dts: ti: k3-j7200-main: Add main domain watchdog entries
  arm64: dts: ti: k3-am64-main: Add ELM (Error Location Module) node
  arm64: dts: ti: k3-am64-main: Add GPMC memory controller node
  arm64: dts: ti: k3-j721e-main: fix RNG node clock id
  arm64: dts: ti: k3-am64-main: Enable crypto accelerator
  arm64: dts: ti: k3-am64: Add SA2UL address space to Main CBASS ranges
  arm64: dts: ti: k3-am64-main: Add main_cpts label
  ...

Link: https://lore.kernel.org/r/44729b46-27f9-94a0-17ed-8868649a4a0a@ti.com
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 16:31:29 +02:00
Arnd Bergmann c328a66dfd Renesas ARM DT updates for v6.1 (take two)
- Merge Renesas ARM/ARM64 maintainers entries,
   - CAN support for the RZ/N1 SoC and the RZN1D-DB development board,
   - Watchdog, pin control, I2C (EEPROM), GPIO (LEDS/switches), and
     Ethernet support for the R-Car V4H SoC and the White Hawk
     development board,
   - Miscellaneous fixes and improvements.
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQQ9qaHoIs/1I4cXmEiKwlD9ZEnxcAUCYyhZSgAKCRCKwlD9ZEnx
 cOSeAQDY7CNJJ8S5iCGdfpYj0OF4E/SLjuY72FN9W/yriv+uiwD9H8YeF+E7cXCS
 /Q0bFjrWpuuminmlWrtwQ8jH30R89QM=
 =pwpK
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMtwigACgkQmmx57+YA
 GNmPPA//f9VL4tO8ms1mjgjAAjlq21JKGIkmpdJ/SzSVAZU39k0XBFORBaG04qRv
 aNDfJay1UHl5f+Ygq6j3v2KFHtNBkKv6NT1N+F+gzJ+I3Bf/sNdYBA7FVAmsLSuD
 zxoxJhUu0V+/d2EtjbUyMeyQSRLbYtArrq0f40e4CMDdPwcM35gGHOspk8lllEkS
 94hdIPhBDpejbbq8H1SYOEAA2OJNGKHO/ArcDf4dbXDupv0ELovFhktBlhUzf5en
 +Y2xABZ8aTHT3l+K649EhlgK6OHH81bHbyFoebZQo3UO6OvLS5qWbySYHirIwKy2
 oFwRexzjz3hskWFgm2vnr5C94J1xJhsTAFK7HAA0wnc5GNCxy521ECVsR6MgkHUi
 WoazCKXqAx+t+iAFQ++Yut6QBwBP5MCTzC9jU0HqSVWwuPYltKiGnkZ7Q4lAp0q1
 stBEO67puu/nuVG9Q8Yv+ZoeKKvcCg42dJbZjlL8FjNP9Th2Ygm5DKvSJp7L99bn
 pHPSQOVDFBj9kdcrwL1Tbxck6RGKIkHHfzYfpN7X0CczGr2b7/l+Od2aKEAetpUp
 iNs1150Dophd//ooJqrE4ksi9UoGcWbLyk0m4okUpUyXMBKAqnRfowgX/liZ1HhA
 /JefVEZjPwbJ9N8I7FzmXaP4iC7R0D38sa8mz2OSDNFVNdRLxvo=
 =uEBt
 -----END PGP SIGNATURE-----

Merge tag 'renesas-arm-dt-for-v6.1-tag2' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-devel into arm/dt

Renesas ARM DT updates for v6.1 (take two)

  - Merge Renesas ARM/ARM64 maintainers entries,
  - CAN support for the RZ/N1 SoC and the RZN1D-DB development board,
  - Watchdog, pin control, I2C (EEPROM), GPIO (LEDS/switches), and
    Ethernet support for the R-Car V4H SoC and the White Hawk
    development board,
  - Miscellaneous fixes and improvements.

* tag 'renesas-arm-dt-for-v6.1-tag2' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-devel: (26 commits)
  arm64: dts: renesas: Adjust whitespace around '{'
  arm64: dts: renesas: rzg2ul-smarc: Include SoM DTSI into board DTS
  arm64: dts: renesas: rzg2ul-smarc-som: Drop enabling wdt2
  ARM: dts: renesas: Fix USB PHY device and child node names
  arm64: dts: renesas: r8a779a0: Update to R-Car Gen4 compatible values
  arm64: dts: renesas: white-hawk-cpu: Add missing bootargs
  arm64: dts: renesas: spider-cpu: Add missing bootargs
  arm64: dts: renesas: spider: Move aliases and chosen
  arm64: dts: renesas: white-hawk-cpu: Add Ethernet support
  arm64: dts: renesas: white-hawk: Move aliases and chosen
  arm64: dts: renesas: r8a779g0: Add RAVB nodes
  arm64: dts: renesas: white-hawk-cpu: Add push switches
  arm64: dts: renesas: white-hawk-cpu: Add GP LEDs
  arm64: dts: renesas: r8a779g0: Add GPIO nodes
  arm64: dts: renesas: white-hawk: Add Ethernet sub-board
  arm64: dts: renesas: white-hawk: Add CSI/DSI sub-board
  arm64: dts: renesas: white-hawk: Add I2C0 and EEPROMs
  arm64: dts: renesas: r8a779g0: Add I2C nodes
  arm64: dts: renesas: white-hawk-cpu: Add serial port pin control
  arm64: dts: renesas: r8a779g0: Add pinctrl device node
  ...

Link: https://lore.kernel.org/r/cover.1663588776.git.geert+renesas@glider.be
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 16:26:48 +02:00
Arnd Bergmann 9cc2df424a mt6795:
- add add system timer node
 
 mt7986a:
 - add wifi support
 
 mt8183:
 - add MDP3 and keypad
 
 mt8186:
 - basic support for the Evaluation Board including, i2c, usb and uart.
 
 mt8192:
 - add nodes to support PWM, MIPI transciever, display with GCE and DSI.
 
 mt8195:
 - disable nodes not used on all boards
 - Add support for CPU freq, clocks, power domain controller, spmi, scp.
 - Enable audio decoder, DSP, IOMMU, mailbox.
 - Add display nodes for vdosys0.
 - On Cherry based chromebooks, enable the system companion processor,
   Cross EC, Google Security Chip, secondary MMC controller, trackpad and
   a few regulators.
 -----BEGIN PGP SIGNATURE-----
 
 iQJLBAABCAA1FiEEUdvKHhzqrUYPB/u8L21+TfbCqH4FAmMoR0AXHG1hdHRoaWFz
 LmJnZ0BnbWFpbC5jb20ACgkQL21+TfbCqH56sxAAlYaMbyDw5sSEV+CwwDRMYunP
 3SoRz53TFCoKD9+K0TH46ft1+Gci0J4e5jngckxR4KRA+dZ9QrnZspZwgkFANhQa
 qXYJdaQI9q6UAVXg9pXuTFi0YjDg9eevYgGLQZtI8EqDHrUfTidLTEKPgzWBwVCS
 qJBAHdzQp/1t9g1xNq2hqZOTK3Mk1j5G3RCdOH4479dzIb7flz29F6FDM2pz82xr
 8vnAShdzysahePR+kybuvpGjaUGHr4HbMp2WNkfwqVE34E4XcI+sl8My2TReCwVH
 Mv0viJWuqHvaEKUW6CAlmXwRgKTWNDZpj9b9KCBUsb407U8ICPrrn4aAg4mm3g9e
 5TkZ4K8nFcv/u39j3C9Lpg8HJYCfyJ6XC9DN+ljRW3K3InUsXXuIVxCXFZKFIs5x
 xMlXAjpMrZY2xeAvQeDGgZrG7t+DVsQZSflat+0iiX59sLjE6NA6DmFZl5dPWDtM
 pH+63WhQ8c2vEh9arP07zKbZK4Khgj8BxbTm/Fuo7OD5ConixfJTZ9e8jIP7Vdaq
 J9Q6gaFGnoPHMvgAzfxrvIr20cl7UJP+olOXYm4Eu5oi4O0Z0aroTGGZX+eDGiXi
 JZvEO3itmH7GFRxy8fZuHMBdTed0T4iqxlPXmjqRYe6H0B2rWDO88bMiuUEOS/Sk
 U9yp++jkaP1TXirGVxY=
 =9RIH
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMtwIwACgkQmmx57+YA
 GNmiPxAAqN2iYxT6IUaMRnOKRRFhPxjo79P/uPZkMEZOz30Z+Cpc+jc/n1FhMvid
 g6L+409cdkWp3PcgWNlar88MKq6NzelvKHz4zfTY1yOJW18meK5CJvp1cBQy2bXL
 gv3/j11eZ8RwUj/5bDoFgBq9WkJUdtCgrrntRiYrFV8Mre4xjNui6bHMRTYEfIQI
 lvcGfosPyMLPrfqpbO9tJXtaDHQEQqeuBwWewl2m/Z4552eZrKPH5H3a0X5nRPGo
 QTjJxmCAOFpQD29FHpmlKav1Jtg6SJyPmtdf3ukqibunkOA59MLOI3xpzydkrGPO
 UC1AdI5GVFhYYASQ+qzoUwMFU7XHXKTDKj8xgFoYFwjcmZK/2X//GsTXiqNX/LAa
 NuIuSCvlMljfP4xQ7RSTrQDAilQRBHeycnU4Nx6UDy5knGBeSGEXGPkALMLbMnx9
 v2ztJ9Uzt41XQCJGDjWHivcDApXjczzclNs7UQj8Vl7fvutDbw4pjiFaLIo7Svlm
 0gdwCD2ljgNr46zKDcuFvqJ1R3WBX0vV+8oaYrcIEpzYMNdhRvioqHD0nGv+keuy
 Q64hspNkpe6rn5bxQRNnunA3zjtqmPthf1MUfbymo+4D3j1HjNWT5igDDfWIJ2LU
 CGglghEupiAqHp7R95KtDYVvG3exdOQWyG2+qVg1I1bqB5ti26M=
 =j9bb
 -----END PGP SIGNATURE-----

Merge tag 'v6.0-next-dts64' of https://git.kernel.org/pub/scm/linux/kernel/git/matthias.bgg/linux into arm/dt

mt6795:
- add add system timer node

mt7986a:
- add wifi support

mt8183:
- add MDP3 and keypad

mt8186:
- basic support for the Evaluation Board including, i2c, usb and uart.

mt8192:
- add nodes to support PWM, MIPI transciever, display with GCE and DSI.

mt8195:
- disable nodes not used on all boards
- Add support for CPU freq, clocks, power domain controller, spmi, scp.
- Enable audio decoder, DSP, IOMMU, mailbox.
- Add display nodes for vdosys0.
- On Cherry based chromebooks, enable the system companion processor,
  Cross EC, Google Security Chip, secondary MMC controller, trackpad and
  a few regulators.

* tag 'v6.0-next-dts64' of https://git.kernel.org/pub/scm/linux/kernel/git/matthias.bgg/linux: (34 commits)
  arm64: dts: mediatek: mt6795: Add CPUX system timer node
  arm64: dts: mt7986: add built-in Wi-Fi device nodes
  arm64: dts: mediatek: cherry: Enable MT6315 regulators on SPMI bus
  arm64: dts: mediatek: cherry: Enable Elantech eKTH3000 i2c trackpad
  arm64: dts: mediatek: cherry: Enable secondary SD/MMC controller
  arm64: dts: mediatek: cherry: Add keyboard mapping for the top row
  arm64: dts: mediatek: cherry: Add Google Security Chip (GSC) TPM
  arm64: dts: mediatek: cherry: Wire up the ChromeOS Embedded Controller
  arm64: dts: mediatek: cherry: Enable the System Companion Processor
  arm64: dts: mediatek: Fix build warnings of mt8173 vcodec nodes
  arm64: dts: mediatek: Add missing xHCI clocks for mt8192 and mt8195
  arm64: dts: mt8192: Add dsi node
  arm64: dts: mt8192: Add display nodes
  arm64: dts: mediatek: Add mmsys #reset-cells property for mt8192
  arm64: dts: mt8192: Add mipi_tx node
  arm64: dts: mt8192: Add pwm node
  arm64: dts: Add MediaTek MT8186 dts and evaluation board and Makefile
  arm64: dts: mt8195: Add display node for vdosys0
  arm64: dts: mt8195: Add gce node
  arm64: dts: mt8195: Add iommu and smi nodes
  ...

Link: https://lore.kernel.org/r/3b915692-c8a9-c508-5a4a-0fdb49355e99@gmail.com
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 16:19:56 +02:00
Arnd Bergmann 9f1fe339ef - Allwinner A100 DMA node
- Allwinner H6 GPU devfreq scaling
 - sunxi sram bindings cleanup and D1 addition
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQSPRixG1tysKC2PKM10Ba7+DO8kkwUCYyeLcAAKCRB0Ba7+DO8k
 k29tAQDWg16eBX+DxH0QiTSvAOU8Baq1auW9+wHWjbP9KEaI+gD/XlYpHQcX2FME
 ck+BP47ZeWInvt0vv2/HlRVOOsHEIQM=
 =v2pD
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMtwCAACgkQmmx57+YA
 GNlLnA/8CbdEp1FGj5tHdt9vFu0Zof/2PIhWk4ACq8fIAq7zvb2uwVINU0ZuNlBy
 yEWU2nka9P00MySmI/yVuf1zuPV8pT3BgXjEby32+KKrz1lAGORgQpOwe8UuxHVg
 ieCR2UH0MTfpfAIuRr4XLN/M72QJS7STaSP62N2ZF1txosbE14Xf/Mv5lCHUiAuG
 YYZtcqdikpBsdy6nHaZMyqA7dTYcJhzmTuvnYKaa9QJXdgFzshmqlWVjCsTZ1x5l
 I06x2otj8S5DU9nIWi66nuEHduRFk6UrSvRD7O5DpPSK1RKtNQlofjldRQw+qf96
 qp9qcA0hQ7nOst6cUfFhgQW0IeTxJ0GXUpgHNPeNLxVhdpOcRkr9y3gEFlu/xyEk
 667zJ3E1tTpmExVVaE3uQ1va0md+cb0tJB/Kqw6abpcmdyTf4s9Nb2znV93GiyBe
 O1Um1ItLX8g1l5oInm52wklQhQD2v849oF9KXBkPl6IBVcw/sfKQ3amLOaVHfqLb
 Oti+7kWAOx71cLna1Ma7TWxhTCtROOBbM/NaRhht7A0ficnU8yDn1u0rW9kx1gKv
 kgtPCoftnozcIJUjRd0ArcCPkAd18XZvFespbPS3txgkfJFvECEQ2rZDFp6ZE1wz
 wCrfGGWngxsVEYNIkkvvjSGARevC9Ft+YJhkaDtWTkmE3ylL2+w=
 =DYkD
 -----END PGP SIGNATURE-----

Merge tag 'sunxi-dt-for-6.1-1' of https://git.kernel.org/pub/scm/linux/kernel/git/sunxi/linux into arm/dt

- Allwinner A100 DMA node
- Allwinner H6 GPU devfreq scaling
- sunxi sram bindings cleanup and D1 addition

* tag 'sunxi-dt-for-6.1-1' of https://git.kernel.org/pub/scm/linux/kernel/git/sunxi/linux:
  dt-bindings: sram: sunxi-sram: Add D1 compatible string
  dt-bindings: sram: sunxi-sram: Clean up the compatible lists
  arm64: dts: allwinner: beelink-gs1: Enable GPU OPP
  arm64: dts: allwinner: h6: Add GPU OPP table
  arm64: dts: allwinner: h6: Add cooling map for GPU
  arm64: dts: allwinner: a100: Add I2C DMA requests
  arm64: dts: allwinner: a100: Add device node for DMA controller

Link: https://lore.kernel.org/r/YyePKDnOeP8Tdt5n@kista.localdomain
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 16:18:07 +02:00
Arnd Bergmann b805cc89bd i.MX arm64 device tree change for 6.1:
- New board support: i.MX8DXL EVK, Kontron SL/BL i.MX8MM OSM-S, i.MX8MM
   Gateworks GW7904, MSC SM2S-IMX8PLUS SoM and carrier board, NXP
   LS2081ARDB.
 - Update i.MX8MQ device tree to use generic name 'dma-controller' for
   SDMA.
 - A number of i.MX8ULP device tree improvements and updates: correct
   parent clock of LPI2C & LPSPI, increase the clock speed of LPSPI, add
   PMU and mailbox device, drop undocumented CGC property, enable FEC, etc.
 - Add interconnect property for various i.MX8MP blk-ctrl devices.
 - Enable VPU PGC, blk-ctrl and PCIe support for i.MX8MP SoC.
 - A set of changes from Peng Fan to add various devices for i.MX93 SoC,
   including MU, blk-ctrl, PMU, LPI2C, LPSPI, SRC, etc.
 - Two set of changes to update LS1043A and LS1046A device trees on
   various aspects, including USB3, PCIe, DMA, mdio-mux, QSPI Flash, etc.
 - Board imx8mq-librem5 update: add USB role switching, add RGB PWM
   notification LEDs, add voice coil motor for focus control, fix MIPI_CSI
   description.
 - A series from Frieder Schrempf to improve imx8mm-kontron device trees
   for VSELECT switch, DDRC operating point, SPI NOR partition layout etc.
 - A set of display and PMIC related additions and improvements on
   imx8mm-verdin board.
 - A number of i.MX8M Plus DHCOM PDK2 device tree improvments from Marek
   Vasut.
 - A few imx8mp-venice device tree updates on USB, cpufreq and WiFi/BT.
 - A series from Vladimir Oltean to enable multiple switch CPU ports
   support.
 - Other small and random board specific updates.
 -----BEGIN PGP SIGNATURE-----
 
 iQFIBAABCgAyFiEEFmJXigPl4LoGSz08UFdYWoewfM4FAmMm4WcUHHNoYXduZ3Vv
 QGtlcm5lbC5vcmcACgkQUFdYWoewfM616ggApJ4zHHQQovmdWWYa6XH471LQGxZ4
 HNw1Pui4imStowaPvyiRFcjr8wrQMGQ59NAQV4vVqX3p+xoeb/3ICO1h2cx8kosE
 9YkBU0AqbgcFuiXRb4lOHqzy8D/ZGH1N/A8xASgUkTVSQDMCNyPucA7Xc5+EULDo
 RmnicFCeF85j/mXy/IBVkXJwV/aH9RqF1HUwjYRAR/GE7yLCWMSwRfDhECCkjfqw
 ypkTeYEkaubnZzFY1QWguOG9/x+TZ+VdMzOsRosfzFOowsC1SrurK5rm+DdVBoAJ
 p5z7GumhY5kfFLBbScvtvR/HGF3YNyekHmaGm6xExhzZuhcy3fVLhsGRhg==
 =sWBW
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMtvnIACgkQmmx57+YA
 GNnQBQ//YAs4teQnZkTNYe0bpsUbUSqHZmbXHldBWHXM1o+753RnVlYYpcDpq3xX
 D8jKnnZSGv/PApdjSiNsNZYvgA7loe9Xut6LgWtTGXL3MZHbtygK2a7r+GucPGy2
 Ku8rZ2XfGROo11SUlIE4AAz0Yb/kUdxYL7COim5pBcinWBVAVBF71Ls6nKD0vida
 bKhxc+ymrBofDtaZjiwLTBUA5I0a9NUdwFRI0GhY3tK1BmmlV453bTgY5DGBeRoC
 G0ApQ/0tIAHuXVVh2a+NwlAS77iq9psYwGkzNhLDmkEmwfXvw7Of+qkCQNaAaga8
 hTGfZKEZ2E45pGVI/P7rTh5POCIPcY3rwXIjqcRdaedm3RewLnQQuo8b7prsAJZW
 OsnmilkxjjhUdHbxEp8OlYHSWbgWiaJMgnxPyT1YTp8dsIuXCF28UbvMlmgfc0H0
 SiJsVYYRxm36TBr6L1weFKtatCextjgGDej236924VwzJCM5UAOSlFbaoO/wuVyl
 vcjVCaapzWJrtTNGgneFltsUXGjdky4VQxLzfBzNc1lSkWHY7fK6sjnQYogRP3Vt
 y+oztYJOSYMPOzS50NaliGl/daV3qZQXuIhAwtjXUwezuPvQJpb5XByaPeNJ6j1c
 sTjo5NXvLZzcVD+32m9Rrhdj1+KT7ULeIKN2rAPm6JNCDxTzGjQ=
 =S7Rl
 -----END PGP SIGNATURE-----

Merge tag 'imx-dt64-6.1' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into arm/dt

i.MX arm64 device tree change for 6.1:

- New board support: i.MX8DXL EVK, Kontron SL/BL i.MX8MM OSM-S, i.MX8MM
  Gateworks GW7904, MSC SM2S-IMX8PLUS SoM and carrier board, NXP
  LS2081ARDB.
- Update i.MX8MQ device tree to use generic name 'dma-controller' for
  SDMA.
- A number of i.MX8ULP device tree improvements and updates: correct
  parent clock of LPI2C & LPSPI, increase the clock speed of LPSPI, add
  PMU and mailbox device, drop undocumented CGC property, enable FEC, etc.
- Add interconnect property for various i.MX8MP blk-ctrl devices.
- Enable VPU PGC, blk-ctrl and PCIe support for i.MX8MP SoC.
- A set of changes from Peng Fan to add various devices for i.MX93 SoC,
  including MU, blk-ctrl, PMU, LPI2C, LPSPI, SRC, etc.
- Two set of changes to update LS1043A and LS1046A device trees on
  various aspects, including USB3, PCIe, DMA, mdio-mux, QSPI Flash, etc.
- Board imx8mq-librem5 update: add USB role switching, add RGB PWM
  notification LEDs, add voice coil motor for focus control, fix MIPI_CSI
  description.
- A series from Frieder Schrempf to improve imx8mm-kontron device trees
  for VSELECT switch, DDRC operating point, SPI NOR partition layout etc.
- A set of display and PMIC related additions and improvements on
  imx8mm-verdin board.
- A number of i.MX8M Plus DHCOM PDK2 device tree improvments from Marek
  Vasut.
- A few imx8mp-venice device tree updates on USB, cpufreq and WiFi/BT.
- A series from Vladimir Oltean to enable multiple switch CPU ports
  support.
- Other small and random board specific updates.

* tag 'imx-dt64-6.1' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux: (90 commits)
  arm64: dts: ls1046a-qds: Modify the qspi flash frequency
  arm64: dts: ls1046a-qds: add mmio based mdio-mux nodes for FPGA
  arm64: dts: ls1046a: add gpios based i2c recovery information
  arm64: dts: ls1046a: use a pseudo-bus to constrain usb and sata dma size
  arm64: dts: ls1046a: make dma-coherent global to the SoC
  arm64: dts: ls1046a: add missing dma ranges property
  arm64: dts: ls1046a: Add big-endian property for PCIe nodes
  arm64: dts: ls1046a: Add the PME interrupt and big-endian to PCIe EP nodes
  arm64: dts: ls1046a: Enable usb3-lpm-capable for usb3 node
  arm64: dts: ls1043a-rdb: add pcf85263 rtc node
  arm64: dts: ls1043a-qds: add mmio based mdio-mux support
  arm64: dts: ls1043a: use a pseudo-bus to constrain usb and sata dma size
  arm64: dts: ls1043a: add gpio based i2c recovery information
  arm64: dts: ls1043a: make dma-coherent global to the SoC
  arm64: dts: ls1043a: add missing dma ranges property
  arm64: dts: ls1043a: Add big-endian property for PCIe nodes
  arm64: dts: ls1043a: Add SCFG phandle for PCIe nodes
  arm64: dts: ls1043a: use pcie aer/pme interrupts
  arm64: dts: ls1043a: Enable usb3-lpm-capable for usb3 node
  arm64: dts: ls1043a: fix the wrong size of dcfg space
  ...

Link: https://lore.kernel.org/r/20220918092806.2152700-4-shawnguo@kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 16:10:58 +02:00
Paolo Bonzini 69604fe76e More pci fixes
Fix for a code analyser warning
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEwGNS88vfc9+v45Yq41TmuOI4ufgFAmMtmHcACgkQ41TmuOI4
 ufhapA/+OGjJtUKEa/LkCArUMUgJ+ZYy9cwx3Qrkvm7BtEguN35uxO5T7X8pdMDU
 /dYSDwtPT1ob/QmjhwwE0dpgUF8yfkBNLKBK37f6jTznI4mS6UEq/IB1BcCk3ss5
 45xG8rWiXS7oFm9bxtNsa5jkrSf7gIOuEa570tOVtOlBYvtFIH2SiHvcCUY1w48N
 A6docb+vOJnPIBHPR/1q+bBoghO5rplYaX0EiAt3EYThrhAjsXjIFzaQPwXUxgFh
 Nk/3ni1St72sbWDiC7YxjDghMVuW1GuQAlgkDWvy8bdA0IfsaqbyISuyIWZWkRfx
 V8+7OfGVsCB7qhT4C+65fQPqwZwERNwwvAFsx175/Mm9/AXn217+sN52O54olFcM
 dhKI7med1R/LqO2HH9kCGIUfJ3t+0JHpFDwcJyiAZsFbYffnwUQbIW4YcA3O+rje
 cV8/kRhD6ebzrScTOMVH+Rb4Q0N0kL34iHXbI8wcTBKmSFrdRm9YeLtQM2P/HtPA
 GVyg49bfXfA13goM9jaUW/IgT1aSHNRHfbfFKTUB7ph2Wi5ktMizpkn/CQ8L7bm1
 I0JoZfA7ALDufg2Ajyqsqmv3RX2k6ydenmX/AxzQlo34kSXY6X+N+yiPlqhumBqq
 Gs2pmvQoyvAmuShhj+eSZsQYBObgjzN7B/SAbbUBT71GerGyWeQ=
 =Z7gl
 -----END PGP SIGNATURE-----

Merge tag 'kvm-s390-master-6.0-2' of https://git.kernel.org/pub/scm/linux/kernel/git/kvms390/linux into HEAD

More pci fixes
Fix for a code analyser warning
2022-09-23 10:06:08 -04:00
Tommaso Merciai 19d4aaf640 arm64: dts: rockchip: use pin constant for reset-gpios on px30-evb
Use rk gpio naming convention into reset-gpios of ov5695 camera

Signed-off-by: Tommaso Merciai <tommaso.merciai@amarulasolutions.com>
Link: https://lore.kernel.org/r/20220620161321.1898840-4-tommaso.merciai@amarulasolutions.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2022-09-23 15:53:18 +02:00
Tommaso Merciai 921890cae2 arm64: dts: rockchip: add pinctrl for mipi-pdn pin on px30-evb
Add right mux for mipi-pdn. Mux this pad as gpio2 14

Signed-off-by: Tommaso Merciai <tommaso.merciai@amarulasolutions.com>
Link: https://lore.kernel.org/r/20220620161321.1898840-3-tommaso.merciai@amarulasolutions.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2022-09-23 15:53:18 +02:00
Tommaso Merciai 8cde966713 arm64: dts: rockchip: set max drive-strength for cif_clkout_m0 on px30-evb
Add max drive-strength for cif_clkout_m0. This fix the issue that
sometimes camera ov5695 is not probed correctly.
Tested on PX30_Mini_EVB_V11_20190507

Signed-off-by: Tommaso Merciai <tommaso.merciai@amarulasolutions.com>
Link: https://lore.kernel.org/r/20220620161321.1898840-2-tommaso.merciai@amarulasolutions.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2022-09-23 15:53:18 +02:00
FUKAUMI Naoki b6047ba2ca arm64: dts: rockchip: add avdd-0v9-supply and avdd-1v8-supply on rk3399 rock 4c and pi4
this patch adds avdd-0v9-supply and avdd-1v8-supply to hdmi node for
Radxa ROCK 4 series.

Signed-off-by: FUKAUMI Naoki <naoki@radxa.com>
Link: https://lore.kernel.org/r/20220909195006.127957-6-naoki@radxa.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2022-09-23 15:46:02 +02:00
FUKAUMI Naoki 06c5b5690a arm64: dts: rockchip: sort nodes/properties on rk3399-rock-4
sort nodes/properties alphabetically

Signed-off-by: FUKAUMI Naoki <naoki@radxa.com>
Link: https://lore.kernel.org/r/20220909195006.127957-5-naoki@radxa.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2022-09-23 15:46:02 +02:00
FUKAUMI Naoki 69448624b7 arm64: dts: rockchip: fix regulator name on rk3399-rock-4
fix regulator name

ref:
 https://dl.radxa.com/rockpi4/docs/hw/rockpi4/rockpi4_v13_sch_20181112.pdf

Signed-off-by: FUKAUMI Naoki <naoki@radxa.com>
Link: https://lore.kernel.org/r/20220909195006.127957-4-naoki@radxa.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2022-09-23 15:46:02 +02:00
FUKAUMI Naoki b153f26d2c arm64: dts: rockchip: sort nodes/properties on rk3399-rock-4c-plus
sort nodes/properties alphabetically

Signed-off-by: FUKAUMI Naoki <naoki@radxa.com>
Link: https://lore.kernel.org/r/20220909195006.127957-3-naoki@radxa.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2022-09-23 15:46:02 +02:00
FUKAUMI Naoki a088c855ac arm64: dts: rockchip: fix regulator structure on rk3399-rock-4c-plus
fix regulator name.
also, add vcc_3v3 and vdd_log.

ref:
 https://dl.radxa.com/rockpi4/docs/hw/rockpi4/rockpi4c_plus_v12_sch_220304.pdf

Signed-off-by: FUKAUMI Naoki <naoki@radxa.com>
Link: https://lore.kernel.org/r/20220909195006.127957-2-naoki@radxa.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2022-09-23 15:46:01 +02:00
FUKAUMI Naoki 110a1f0eea arm64: dts: rockchip: connect vcca_1v8 to APIO5_VDD on rk3399-rock-4c-plus
GPIO pins for LEDs on ROCK 4C+ are in APIO5

Signed-off-by: FUKAUMI Naoki <naoki@radxa.com>
Link: https://lore.kernel.org/r/20220909195006.127957-1-naoki@radxa.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2022-09-23 15:46:01 +02:00
Arnd Bergmann f58ec42950 arm64: tegra: Device tree changes for v6.1-rc1
These changes enable PCI, Ethernet and HDA support on Jetson AGX Orin.
 DMA support is enabled for I2C on a number of SoC generations and the
 Google Pixel C (a.k.a. Smaug) device receives Bluetooth and Wi-Fi
 support.
 
 Other than that this also contains some minor cleanups and fixes.
 -----BEGIN PGP SIGNATURE-----
 
 iQJHBAABCAAxFiEEiOrDCAFJzPfAjcif3SOs138+s6EFAmMkS+cTHHRyZWRpbmdA
 bnZpZGlhLmNvbQAKCRDdI6zXfz6zoSVxEACS52ng2EWzrY27C1nZkka1+1bt9BRs
 uKLBrA8BuwGNtyLHirN8TbEaSlg3/dv81lQDVBTYXtxdwudLL9lY2PGdgJaHM1FA
 bRKR2eZz6AQdvnQi348mbXRVEG7yWrZi9UCWCQwQ5Q/b1g0k4GJQU9U80acHtRsa
 XW6Wj9rlaUayxAMRYkbb+2GecoKk4zrHDqtHrhXJjHurGdzhvNdKZcIWzcXzxHal
 jWN81G8FNqf19S1BTkOsV3nwlqwVb9zA02ZAia/HYKIFR9Tsn0s6GlXaDo4F7bB/
 yrM6dfe+22ZUd+ivpjrHLnefAM//grvFEBdmuK/tIdnasYa70U6PnOoRhoob8orH
 yrJkxgzdWslD2BIDmXKiRvzjoLe8/0nTjMK1drNg6SRRYDXBx0b5atDSPcpTsmcu
 nVW+6w7ISHJvQ2FqvTwWXGyw8vjMIsba0vKO5z9E/Xnboy6qFTb7y7032MrHhk7i
 HIAHfHQTMEwPFJQnVXZquC0X7lKrY3hKlyjsGcdtqqU0UGyDwU++dtdugF2HP6Na
 D7EZkBf+ibXWmIwSAAJRjXf/hbYLIVZHEAX7hQlESHZBI9ckLwxMVCKgwDkU8zus
 ZHhUuBQ/dmrEh+hgkYmkIMcGTJSBYtnvMVEB0K/oIB9+nbbuZ4mQ8vu38wrsQa6+
 X92eUMCBRB3N7g==
 =hMuy
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMtuBAACgkQmmx57+YA
 GNmaRxAAhAx+cHVY0rOROQ1bEFhu1C4GYrrcqwkgqsCFLNSU2OMMdSaD700J5RbO
 j1ghhXR9jispWZIc6WyjscmClDHcwq/fMjqHfl2Cru243RXSO+LL3Ut/JiBLIBpd
 Kj0/14XQzZc43PW3Jnz2SLMSU3recRt8ZMYnl3OxHzJPrXWedYKI2J6uSsPb32fG
 n6svKejHaqiFFtsHQhjlqox370wSocArhqh238iUqncOTj23lycO3VZ1Rwk/h8G0
 YdAGeeih0NGM2eah1ntYcdclpbILI9Nsme/xD4yCyxByVB5WqwLOkSqyppdRd2UY
 KG1Z95UsaNGBZTc/1F7FUGNCUiv/zHys8KysnibhXQniAvoG/sz4E8bFpGSpa76o
 hISOFb82q1PPDxUXIWq8deyrGtCZyUkgSEh0tNsuNafec2iOl0/ERvZyTD+6PKlT
 xbmtZoT1Wf69s6hh08pzS5cO5FztHXudA754jIRZUFbRquDNoBNDZHa8APKpGxSI
 e0+SS1kRgBHgrMXNOJH0UDQtkt1fdbDJWCHvXx1ki/1BjedyQZdkU75D5epEyTLn
 F1XTcGbtF5WlgC0vQCL8SEhIA6nqotkZHRSfs0E0+9JadRsH9f9xWgLG+CqGsPzM
 /FWS4UnijuiIj5r1lcm0xuLO524tGdGuDdAIBkymehZkpDF1Bjc=
 =fOSZ
 -----END PGP SIGNATURE-----

Merge tag 'tegra-for-6.1-arm64-dt' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into arm/dt

arm64: tegra: Device tree changes for v6.1-rc1

These changes enable PCI, Ethernet and HDA support on Jetson AGX Orin.
DMA support is enabled for I2C on a number of SoC generations and the
Google Pixel C (a.k.a. Smaug) device receives Bluetooth and Wi-Fi
support.

Other than that this also contains some minor cleanups and fixes.

* tag 'tegra-for-6.1-arm64-dt' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux:
  arm64: tegra: Add GPCDMA support for Tegra I2C
  arm64: tegra: Add iommus for HDA on Tegra234
  arm64: tegra: Enable HDA node for Jetson AGX Orin
  arm64: tegra: Add context isolation domains on Tegra234
  arm64: tegra: Fixup iommu-map property formatting
  arm64: dts: tegra: smaug: Add Wi-Fi node
  arm64: dts: tegra: smaug: Add Bluetooth node
  arm64: tegra: Enable MGBE on Jetson AGX Orin Developer Kit
  arm64: tegra: Add MGBE nodes on Tegra234
  arm64: tegra: Fix up compatible for Tegra234 GPCDMA
  arm64: tegra: Enable PCIe slots in P3737-0000 board
  arm64: tegra: Add P2U and PCIe controller nodes to Tegra234 DT
  arm64: tegra: Add regulators required for PCIe

Link: https://lore.kernel.org/r/20220916101957.1635854-5-thierry.reding@gmail.com
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 15:43:44 +02:00
Mark Rutland 2305b809be arm64: uaccess: simplify uaccess_mask_ptr()
We introduced uaccess pointer masking for arm64 in commit:

  4d8efc2d5e ("arm64: Use pointer masking to limit uaccess speculation")

Which was intended to prevent speculative uaccesses to kernel memory on
CPUs where access permissions were not respected under speculation.

At the time, the uaccess primitives were occasionally used to access
kernel memory, with the maximum permitted address held in
thread_info::addr_limit. Consequently, the address masking needed to
take this dynamic limit into account.

Subsequently the uaccess primitives were reworked such that they are
only used for user memory, and as of commit:

  3d2403fd10 ("arm64: uaccess: remove set_fs()")

... the address limit was made a compile-time constant, but the logic
was otherwise unchanged.

Regardless of the configured VA size or whether TBI is in use, the
address space can be divided into three ranges:

* The TTBR0 VA range, for which any valid pointer has bit 55 *clear*,
  and any non-tag bits [63-56] must match bit 55 (i.e. must be clear).

* The TTBR1 VA range, for which any valid pointer has bit 55 *set*, and
  any non-tag bits [63-56] must match bit 55 (i.e. must be set).

* The gap between the TTBR0 and TTBR1 ranges, where bit 55 may be set or
  clear, but any access will result in a fault.

As the uaccess primitives are now only used for user memory in the TTBR0
VA range, we can prevent generation of TTBR1 addresses by clearing bit
55, which will either result in a TTBR0 address or a faulting address
between the TTBR VA ranges.

This is beneficial for code generation as:

* We no longer clobber the condition codes.

* We no longer burn a register on (TASK_SIZE_MAX - 1).

* We no longer need to consume the untagged pointer.

When building a defconfig v6.0-rc3 with GCC 12.1.0, this change makes
the resulting Image 64KiB smaller.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: James Morse <james.morse@arm.com>
Cc: Robin Murphy <robin.murphy@arm.com>
Cc: Will Deacon <will@kernel.org>
Reviewed-by: Robin Murphy <robin.murphy@arm.com>
Link: https://lore.kernel.org/r/20220922151053.3520750-1-mark.rutland@arm.com
[catalin.marinas@arm.com: remove csdb() as the bit clearing is unconditional]
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-23 14:39:20 +01:00
Chris Morgan e18d9b0930 arm64: dts: rockchip: Add DSI and DSI-DPHY nodes to rk356x
This adds the DSI controller nodes and DSI-DPHY controller nodes to the
rk356x device tree.

Signed-off-by: Chris Morgan <macromorgan@hotmail.com>
Acked-by: Michael Riesch <michael.riesch@wolfvision.net>
Link: https://lore.kernel.org/r/20220919164616.12492-4-macroalpha82@gmail.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2022-09-23 12:27:18 +02:00
Nicolas Frattaroli d99efdaba9 arm64: dts: rockchip: Enable HDMI and GPU on quartz64-b
This enables the GPU and HDMI output (including HDMI audio) on
the PINE64 Quartz64 Model B single board computer.

Signed-off-by: Nicolas Frattaroli <frattaroli.nicolas@gmail.com>
Link: https://lore.kernel.org/r/20220920143446.633956-1-frattaroli.nicolas@gmail.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2022-09-23 11:42:53 +02:00
Anand Moon 489dd8611b arm64: defconfig: Enable Synopsys DWC MSHC driver
Enable the driver SDHCI support for the Synopsys DWC MSHC
controller which can be found on Rockchip 356x SoCs.

Cc: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Anand Moon <linux.amoon@gmail.com>
Link: https://lore.kernel.org/r/20220922192050.2031-1-linux.amoon@gmail.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2022-09-23 11:23:38 +02:00
Will Deacon aa3e49b606 arm64: asm/perf_regs.h: Avoid C++-style comment in UAPI header
An arm64 'allmodconfig' build fails with GCC due to use of a C++-style
comment for the new SVE vector granule 'enum perf_event_arm_regs' entry:

  | /usr/include/asm/perf_regs.h:42:26: error: C++ style comments are not allowed in ISO C90

Use good ol' /* */ comment syntax to keep things rosey.

Link: https://lore.kernel.org/r/632cceb2.170a0220.599ec.0a3a@mx.google.com
Fixes: cbb0c02caf ("perf: arm64: Add SVE vector granule register to user regs")
Signed-off-by: Will Deacon <will@kernel.org>
2022-09-22 22:15:33 +01:00
Paolo Bonzini b4ac28a32f KVM/arm64 fixes for 6.0, take #2
- Fix kmemleak usage in Protected KVM (again)
 -----BEGIN PGP SIGNATURE-----
 
 iQJDBAABCgAtFiEEn9UcU+C1Yxj9lZw9I9DQutE9ekMFAmMoo2EPHG1hekBrZXJu
 ZWwub3JnAAoJECPQ0LrRPXpD308QAL5sZ7lzB6sS2Zw4zMxpi1nW0qPJKJuvwaF7
 PZKhZTJhbXUWlSFIBRtcfzR7Aw7fP5W/dcE66TcE8IA5zNd8/O+jrJtE3uul65SG
 3nKaVuU0cYvFiA7rLJsrg+KLqPHYGnKbRO3KQrfpPT8MDs0t/OgXdyiwBycU8Os0
 XWT5anjJRCPpUIUhOW19gBKSMyYrMRlhybrWbY0MAJgtpJTMJyqjosrHWFUeDog8
 0ecDg/FS7SZhRvm6Ruf27fydNkh4mJ2dNZqzpaWTttxOV8+LN2r9ClJP98a4VWYz
 ek55ihLU+XijNozOu3O9OxcC3VULf12R/0SMnXpGdi752H+3fH26iiDmxKiHGSSR
 LV/JVPLrw1OgxAK7Wb/0v29+Z7dD9l7gBGIgvZGT5PhgKGR4W//k1EGkIS0Yh7HI
 lT7URgwagP8qgdJBfmaROdx3V4XEDX17I862aEinstr8HaCvQzgKIXmdUHiW+21P
 4Xk7HcvgJuL/NOhVtZFT8ejAlgWNi4HRyPZ/YHVA2XPbmCZk2KS0Oe0WbX9iX7vT
 SYx/X9J/CJ1+BRiDk/hMQlNMxua/9eTG42iNdg/5zB/medZpb3GlDVmvO5vXIHut
 V2chjnt11rWtzskP4noaGYGd6QlURbSHYPWTG0+XCL9BG0CJ0+Pmu9lMRHwWGnlU
 NJoGm0ZC
 =UygE
 -----END PGP SIGNATURE-----

Merge tag 'kvmarm-fixes-6.0-2' of git://git.kernel.org/pub/scm/linux/kernel/git/kvmarm/kvmarm into HEAD

KVM/arm64 fixes for 6.0, take #2

- Fix kmemleak usage in Protected KVM (again)
2022-09-22 17:01:33 -04:00
Jakub Kicinski 0140a7168f Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
drivers/net/ethernet/freescale/fec.h
  7b15515fc1 ("Revert "fec: Restart PPS after link state change"")
  40c79ce13b ("net: fec: add stop mode support for imx8 platform")
https://lore.kernel.org/all/20220921105337.62b41047@canb.auug.org.au/

drivers/pinctrl/pinctrl-ocelot.c
  c297561bc9 ("pinctrl: ocelot: Fix interrupt controller")
  181f604b33 ("pinctrl: ocelot: add ability to be used in a non-mmio configuration")
https://lore.kernel.org/all/20220921110032.7cd28114@canb.auug.org.au/

tools/testing/selftests/drivers/net/bonding/Makefile
  bbb774d921 ("net: Add tests for bonding and team address list management")
  152e8ec776 ("selftests/bonding: add a test for bonding lladdr target")
https://lore.kernel.org/all/20220921110437.5b7dbd82@canb.auug.org.au/

drivers/net/can/usb/gs_usb.c
  5440428b3d ("can: gs_usb: gs_can_open(): fix race dev->can.state condition")
  45dfa45f52 ("can: gs_usb: add RX and TX hardware timestamp support")
https://lore.kernel.org/all/84f45a7d-92b6-4dc5-d7a1-072152fab6ff@tessares.net/

Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-09-22 13:02:10 -07:00
Linus Torvalds c69cf88cda ARM: SoC fixes for 6.0-rc6
Another set of fixes for fixes for the soc tree:
 
  - A fix for the interrupt number on at91/lan966 ethernet PHYs
 
  - A second round of fixes for NXP i.MX series, including a couple
    of build issues, and board specific DT corrections on
    TQMa8MPQL, imx8mp-venice-gw74xx and imx8mm-verdin for reliability
    and partially broken functionality.
 
  - Several fixes for Rockchip SoCs, addressing a USB issue on BPI-R2-Pro,
    wakeup on Gru-Bob and reliability of high-speed SD cards, among
    other minor issues.
 
  - A fix for a long-running naming mistake that prevented the moxart mmc
    driver from working at all.
 
  - Multiple Arm SCMI firmware fixes for hardening some corner cases.
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMsf8kACgkQmmx57+YA
 GNklew//T+pAuVwhR8OMp3DolbM/CwezgZgEXkuqDS0GvLkuoR71N7y1wEO77CDI
 9/luYQiFnMI8ooBMXLG545EJCZNommtDKWfSMjJnYeVQit3nupJSYaOLkzD949hg
 fg2BhA3mIKJY53m5SHRfZJOr+Q5E1DEmREX7m9e3nXTDY7izWpE2HtlKt26lKTq4
 w4sbchmrC4YRLqkBbSGLczClCakF0/L3QhGUIfBlTdLmhye0PJiQzfhVTKgdb7Jr
 l0T8vt5vg+5f5ib3PrnPQCaA3Azgu0QvImwKr7/vU/Sn6/e/xwV/hcuqQBZPFbbl
 RmSkHb3mBLXogk/EjLiw8y59D22SIbdtE+/tD+FRP+q0gjgPKobRZiqLFijvIWSB
 TtaTsKhotFKFs+pDysF0C/IfpK9MaYcX71WdqfvwlPiGGK7xCt3W+AKzgUmRVfew
 dVMeyBlVL9T3003MpLkiaIoDp8JfJsD3051CCH5tdOtF53PeKsgTUEXtnQezBof2
 80KgGXg2QGbwx+vYPGJqgQKzG7teq06G4BERK/yeFCrOsxrRXzH/icDA3F5xKY5f
 IqQiTqvZeCQvvr8G1iZb6YkhflQHaNktsRCajxERTgPfRzuQFHwF96C/+weGcZBp
 edBtweGCJ7AvV8vmvmvCdMDg9BDfgHOOwiNOKqmVvsIO01Ei8Oc=
 =fI2K
 -----END PGP SIGNATURE-----

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

Pull ARM SoC fixes from Arnd Bergmann:
 "Another set of fixes for fixes for the soc tree:

   - A fix for the interrupt number on at91/lan966 ethernet PHYs

   - A second round of fixes for NXP i.MX series, including a couple of
     build issues, and board specific DT corrections on TQMa8MPQL,
     imx8mp-venice-gw74xx and imx8mm-verdin for reliability and
     partially broken functionality

   - Several fixes for Rockchip SoCs, addressing a USB issue on
     BPI-R2-Pro, wakeup on Gru-Bob and reliability of high-speed SD
     cards, among other minor issues

   - A fix for a long-running naming mistake that prevented the moxart
     mmc driver from working at all

   - Multiple Arm SCMI firmware fixes for hardening some corner cases"

* tag 'soc-fixes-6.0-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc: (30 commits)
  arm64: dts: imx8mp-venice-gw74xx: fix port/phy validation
  ARM: dts: lan966x: Fix the interrupt number for internal PHYs
  arm64: dts: imx8mp-venice-gw74xx: fix ksz9477 cpu port
  arm64: dts: imx8mp-venice-gw74xx: fix CAN STBY polarity
  dt-bindings: memory-controllers: fsl,imx8m-ddrc: drop Leonard Crestez
  arm64: dts: tqma8mqml: Include phy-imx8-pcie.h header
  arm64: defconfig: enable ARCH_NXP
  arm64: dts: imx8mp-tqma8mpql-mba8mpxl: add missing pinctrl for RTC alarm
  ARM: dts: fix Moxa SDIO 'compatible', remove 'sdhci' misnomer
  arm64: dts: imx8mm-verdin: extend pmic voltages
  arm64: dts: rockchip: Remove 'enable-active-low' from rk3566-quartz64-a
  arm64: dts: rockchip: Remove 'enable-active-low' from rk3399-puma
  arm64: dts: rockchip: fix property for usb2 phy supply on rk3568-evb1-v10
  arm64: dts: rockchip: fix property for usb2 phy supply on rock-3a
  arm64: dts: imx8ulp: add #reset-cells for pcc
  arm64: dts: tqma8mpxl-ba8mpxl: Fix button GPIOs
  arm64: dts: imx8mn: remove GPU power domain reset
  arm64: dts: rockchip: Set RK3399-Gru PCLK_EDP to 24 MHz
  arm64: dts: imx8mm: Reverse CPLD_Dn GPIO label mapping on MX8Menlo
  arm64: dts: rockchip: fix upper usb port on BPI-R2-Pro
  ...
2022-09-22 11:10:11 -07:00
Peter Collingbourne 973b9e3733 arm64: mte: move register initialization to C
If FEAT_MTE2 is disabled via the arm64.nomte command line argument on a
CPU that claims to support FEAT_MTE2, the kernel will use Tagged Normal
in the MAIR. If we interpret arm64.nomte to mean that the CPU does not
in fact implement FEAT_MTE2, setting the system register like this may
lead to UNSPECIFIED behavior. Fix it by arranging for MAIR to be set
in the C function cpu_enable_mte which is called based on the sanitized
version of the system register.

There is no need for the rest of the MTE-related system register
initialization to happen from assembly, with the exception of TCR_EL1,
which must be set to include at least TBI1 because the secondary CPUs
access KASan-allocated data structures early. Therefore, make the TCR_EL1
initialization unconditional and move the rest of the initialization to
cpu_enable_mte so that we no longer have a dependency on the unsanitized
ID register value.

Co-developed-by: Evgenii Stepanov <eugenis@google.com>
Signed-off-by: Peter Collingbourne <pcc@google.com>
Signed-off-by: Evgenii Stepanov <eugenis@google.com>
Suggested-by: Catalin Marinas <catalin.marinas@arm.com>
Reported-by: kernel test robot <lkp@intel.com>
Fixes: 3b714d24ef ("arm64: mte: CPU feature detection and initial sysreg configuration")
Cc: <stable@vger.kernel.org> # 5.10.x
Link: https://lore.kernel.org/r/20220915222053.3484231-1-eugenis@google.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-22 18:02:50 +01:00
Kefeng Wang 739e49e0fc arm64: mm: handle ARM64_KERNEL_USES_PMD_MAPS in vmemmap_populate()
Directly check ARM64_SWAPPER_USES_SECTION_MAPS to choose base page
or PMD level huge page mapping in vmemmap_populate() to simplify
code a bit.

Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>
Link: https://lore.kernel.org/r/20220920014951.196191-1-wangkefeng.wang@huawei.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-22 16:25:51 +01:00
Will Deacon c44094eee3 arm64: dma: Drop cache invalidation from arch_dma_prep_coherent()
arch_dma_prep_coherent() is called when preparing a non-cacheable region
for a consistent DMA buffer allocation. Since the buffer pages may
previously have been written via a cacheable mapping and consequently
allocated as dirty cachelines, the purpose of this function is to remove
these dirty lines from the cache, writing them back so that the
non-coherent device is able to see them.

On arm64, this operation can be achieved with a clean to the point of
coherency; a subsequent invalidation is not required and serves little
purpose in the presence of a cacheable alias (e.g. the linear map),
since clean lines can be speculatively fetched back into the cache after
the invalidation operation has completed.

Relax the cache maintenance in arch_dma_prep_coherent() so that only a
clean, and not a clean-and-invalidate operation is performed.

Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Robin Murphy <robin.murphy@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Ard Biesheuvel <ardb@kernel.org>
Signed-off-by: Will Deacon <will@kernel.org>
Reviewed-by: Catalin Marinas <catalin.marinas@arm.com>
Link: https://lore.kernel.org/r/20220823122111.17439-1-will@kernel.org
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-22 15:09:31 +01:00
James Clark cbb0c02caf perf: arm64: Add SVE vector granule register to user regs
Dwarf based unwinding in a function that pushes SVE registers onto
the stack requires the unwinder to know the length of the SVE register
to calculate the stack offsets correctly. This was added to the Arm
specific Dwarf spec as the VG pseudo register[1].

Add the vector length at position 46 if it's requested by userspace and
SVE is supported. If it's not supported then fail to open the event.

The vector length must be on each sample because it can be changed
at runtime via a prctl or ptrace call. Also by adding it as a register
rather than a separate attribute, minimal changes will be required in an
unwinder that already indexes into the register list.

[1]: https://github.com/ARM-software/abi-aa/blob/main/aadwarf64/aadwarf64.rst

Reviewed-by: Mark Brown <broonie@kernel.org>
Signed-off-by: James Clark <james.clark@arm.com>
Link: https://lore.kernel.org/r/20220901132658.1024635-2-james.clark@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
2022-09-22 15:06:02 +01:00
Alexander Stein 5c3d5ecf48 arm64: dts: imx8mp: Add snps,gfladj-refclk-lpm-sel quirk to USB nodes
With this set the SOF/ITP counter is based on ref_clk when 2.0 ports are
suspended.
snps,dis-u2-freeclk-exists-quirk can be removed as
snps,gfladj-refclk-lpm-sel also clears the free running clock configuration
bit.

Signed-off-by: Alexander Stein <alexander.stein@ew.tq-group.com>
Link: https://lore.kernel.org/r/20220915062855.751881-4-alexander.stein@ew.tq-group.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-09-22 15:52:30 +02:00
Lorenzo Bianconi 00b9903996 arm64: dts: mediatek: mt7986: add support for Wireless Ethernet Dispatch
Introduce wed0 and wed1 nodes in order to enable offloading forwarding
between ethernet and wireless devices on the mt7986 chipset.

Co-developed-by: Bo Jiao <Bo.Jiao@mediatek.com>
Signed-off-by: Bo Jiao <Bo.Jiao@mediatek.com>
Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
2022-09-22 15:13:23 +02:00
Sergey Shtylyov d4955c0ad7 arm64: topology: fix possible overflow in amu_fie_setup()
cpufreq_get_hw_max_freq() returns max frequency in kHz as *unsigned int*,
while freq_inv_set_max_ratio() gets passed this frequency in Hz as 'u64'.
Multiplying max frequency by 1000 can potentially result in overflow --
multiplying by 1000ULL instead should avoid that...

Found by Linux Verification Center (linuxtesting.org) with the SVACE static
analysis tool.

Fixes: cd0ed03a89 ("arm64: use activity monitors for frequency invariance")
Signed-off-by: Sergey Shtylyov <s.shtylyov@omp.ru>
Link: https://lore.kernel.org/r/01493d64-2bce-d968-86dc-11a122a9c07d@omp.ru
Signed-off-by: Will Deacon <will@kernel.org>
2022-09-22 12:57:06 +01:00
Mark Rutland 61d2d1808b arm64: mm: don't acquire mutex when rewriting swapper
Since commit:

  47546a1912 ("arm64: mm: install KPTI nG mappings with MMU enabled)"

... when building with CONFIG_DEBUG_ATOMIC_SLEEP=y and booting under
QEMU TCG with '-cpu max', there's a boot-time splat:

| BUG: sleeping function called from invalid context at kernel/locking/mutex.c:580
| in_atomic(): 1, irqs_disabled(): 128, non_block: 0, pid: 15, name: migration/0
| preempt_count: 1, expected: 0
| RCU nest depth: 0, expected: 0
| no locks held by migration/0/15.
| irq event stamp: 28
| hardirqs last  enabled at (27): [<ffff8000091ed180>] _raw_spin_unlock_irq+0x3c/0x7c
| hardirqs last disabled at (28): [<ffff8000081b8d74>] multi_cpu_stop+0x150/0x18c
| softirqs last  enabled at (0): [<ffff80000809a314>] copy_process+0x594/0x1964
| softirqs last disabled at (0): [<0000000000000000>] 0x0
| CPU: 0 PID: 15 Comm: migration/0 Not tainted 6.0.0-rc3-00002-g419b42ff7eef #3
| Hardware name: linux,dummy-virt (DT)
| Stopper: multi_cpu_stop+0x0/0x18c <- stop_cpus.constprop.0+0xa0/0xfc
| Call trace:
|  dump_backtrace.part.0+0xd0/0xe0
|  show_stack+0x1c/0x5c
|  dump_stack_lvl+0x88/0xb4
|  dump_stack+0x1c/0x38
|  __might_resched+0x180/0x230
|  __might_sleep+0x4c/0xa0
|  __mutex_lock+0x5c/0x450
|  mutex_lock_nested+0x30/0x40
|  create_kpti_ng_temp_pgd+0x4fc/0x6d0
|  kpti_install_ng_mappings+0x2b8/0x3b0
|  cpu_enable_non_boot_scope_capabilities+0x7c/0xd0
|  multi_cpu_stop+0xa0/0x18c
|  cpu_stopper_thread+0x88/0x11c
|  smpboot_thread_fn+0x1ec/0x290
|  kthread+0x118/0x120
|  ret_from_fork+0x10/0x20

Since commit:

  ee017ee353 ("arm64/mm: avoid fixmap race condition when create pud mapping")

... once the kernel leave the SYSTEM_BOOTING state, the fixmap pagetable
entries are protected by the fixmap_lock mutex.

The new KPTI rewrite code uses __create_pgd_mapping() to create a
temporary pagetable. This happens in atomic context, after secondary
CPUs are brought up and the kernel has left the SYSTEM_BOOTING state.
Hence we try to acquire a mutex in atomic context, which is generally
unsound (though benign in this case as the mutex should be free and all
other CPUs are quiescent).

This patch avoids the issue by pulling the mutex out of alloc_init_pud()
and calling it at a higher level in the pagetable manipulation code.
This allows it to be used without locking where one CPU is known to be
in exclusive control of the machine, even after having left the
SYSTEM_BOOTING state.

Fixes: 47546a1912 ("arm64: mm: install KPTI nG mappings with MMU enabled")
Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Ard Biesheuvel <ardb@kernel.org>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Will Deacon <will@kernel.org>
Reviewed-by: Ard Biesheuvel <ardb@kernel.org>
Link: https://lore.kernel.org/r/20220920134731.1625740-1-mark.rutland@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
2022-09-22 12:55:39 +01:00
Mark Brown 0027d9c6c7 arm64/ptrace: Support access to TPIDR2_EL0
SME introduces an additional EL0 register, TPIDR2_EL0, intended for use
by userspace as part of the SME. Provide ptrace access to it through the
existing NT_ARM_TLS regset used for TPIDR_EL0 by expanding it to two
registers with TPIDR2_EL0 being the second one.

Existing programs that query the size of the register set will be able
to observe the increased size of the register set. Programs that assume
the register set is single register will see no change. On systems that
do not support SME TPIDR2_EL0 will read as 0 and writes will be ignored,
support for SME should be queried via hwcaps as normal.

Signed-off-by: Mark Brown <broonie@kernel.org>
Link: https://lore.kernel.org/r/20220829154921.837871-4-broonie@kernel.org
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-21 17:26:58 +01:00
Greg Kroah-Hartman 8be7dfc6a8 coresight: Changes for v6.1
Coresight trace subsystem updates for v6.1 includes:
   - Support for HiSilicon PTT trace
   - Coresight cleanup of sysfs accessor functions, reduced
     code size.
   - Expose coresight timestamp source for ETMv4+
   - DT binding updates to include missing properties
   - Minor documentation, Kconfig text fixes.
 
 Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEuFy0byloRoXZHaWBxcXRZPKyBqEFAmMpf/UACgkQxcXRZPKy
 BqE58g//cxM7TR4QNsI0IQxHxfDjFxWyiDVLfLxpZK8HHQYbpWZSMq/8Da+BJMNC
 UtxaDIPdpMJy1oPcNuLE6tyvhlpK+Mp1BII934LpqvQp14YIjaghWCikYyHy0Awi
 Fz1UG46bjcq3L8VA2kg3ShzUmW/SJH4/Lh5yGvnGmQPGP/Kc4Fr/PdY1NNcE+wC4
 HeIRCla5rt6LXvNMGWL747pYPwwrG6moIb9JfYiebeD/vmAG1tTubSZFkvEKYTzE
 zZRHWJVQaKEAvrP4Ra4/m3ZavvQ6lqrs8GiuwZNsiVvIL+CThIg7/uJDxrJt9X+9
 J0qoPP8UmSQYTbFOAfGerrTkRGjk+eb+CAtY3vIN99TMsCVsDCfUN0sOLLKNmHKD
 JAO7od8hgPMON4V/B3bKUKU1j66Ufw4v3G3T0QkjGfspMxOfUA7fbr7XXxQ6Dtxf
 608OgOG8T2Xww+k5XJMTBXJchM5/SH3gSQwmqoMe5oq6YYN2DNjzf+/M6+uSwQFi
 Yy7ONu6mm7OU6XrCvccYQgc33ZY6kUkELKqH3/zPqObx5xLl9zKjX4tFBcy1/CWe
 D7tk0+ofPRuistyMV6ECCaIAVj5pWv8hiW7FDfI4okbSM5ah5spONrcaM6lwddPF
 B1kVRcYCjZBmVhANsqtMmLxARX2qXgRnHJ6h5TH13C/hmEnoEls=
 =rg+8
 -----END PGP SIGNATURE-----

Merge tag 'coresight-next-v6.1' of git://git.kernel.org/pub/scm/linux/kernel/git/coresight/linux into char-misc-next

Suzuki writes:
  "coresight: Changes for v6.1

   Coresight trace subsystem updates for v6.1 includes:
     - Support for HiSilicon PTT trace
     - Coresight cleanup of sysfs accessor functions, reduced
       code size.
     - Expose coresight timestamp source for ETMv4+
     - DT binding updates to include missing properties
     - Minor documentation, Kconfig text fixes.

   Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>"

* tag 'coresight-next-v6.1' of git://git.kernel.org/pub/scm/linux/kernel/git/coresight/linux:
  hwtracing: hisi_ptt: Fix up for "iommu/dma: Make header private"
  MAINTAINERS: Add maintainer for HiSilicon PTT driver
  docs: trace: Add HiSilicon PTT device driver documentation
  hwtracing: hisi_ptt: Add tune function support for HiSilicon PCIe Tune and Trace device
  hwtracing: hisi_ptt: Add trace function support for HiSilicon PCIe Tune and Trace device
  iommu/arm-smmu-v3: Make default domain type of HiSilicon PTT device to identity
  coresight: cti-sysfs: Mark coresight_cti_reg_store() as __maybe_unused
  coresight: Make new csdev_access offsets unsigned
  coresight: cti-sysfs: Re-use same functions for similar sysfs register accessors
  coresight: Re-use same function for similar sysfs register accessors
  coresight: Simplify sysfs accessors by using csdev_access abstraction
  coresight: Remove unused function parameter
  coresight: etm4x: docs: Add documentation for 'ts_source' sysfs interface
  coresight: etm4x: Expose default timestamp source in sysfs
  dt-bindings: arm: coresight-tmc: Add 'iommu' property
  dt-bindings: arm: coresight: Add 'power-domains' property
  coresight: docs: Fix a broken reference
  coresight: trbe: fix Kconfig "its" grammar
2022-09-21 16:16:03 +02:00
Vincenzo Frascino e2c1254042 arm64: Enable docker support in defconfig
The arm64 defconfig does not support the docker usecase.

Enable the missing configuration options.

The resulting .config was validated with [1].

...

Generally Necessary:
- cgroup hierarchy: properly mounted [/sys/fs/cgroup]
- apparmor: enabled and tools installed
- CONFIG_NAMESPACES: enabled
- CONFIG_NET_NS: enabled
- CONFIG_PID_NS: enabled
- CONFIG_IPC_NS: enabled
- CONFIG_UTS_NS: enabled
- CONFIG_CGROUPS: enabled
- CONFIG_CGROUP_CPUACCT: enabled
- CONFIG_CGROUP_DEVICE: enabled
- CONFIG_CGROUP_FREEZER: enabled
- CONFIG_CGROUP_SCHED: enabled
- CONFIG_CPUSETS: enabled
- CONFIG_MEMCG: enabled
- CONFIG_KEYS: enabled
- CONFIG_VETH: enabled (as module)
- CONFIG_BRIDGE: enabled (as module)
- CONFIG_BRIDGE_NETFILTER: enabled (as module)
- CONFIG_IP_NF_FILTER: enabled (as module)
- CONFIG_IP_NF_TARGET_MASQUERADE: enabled (as module)
- CONFIG_NETFILTER_XT_MATCH_ADDRTYPE: enabled (as module)
- CONFIG_NETFILTER_XT_MATCH_CONNTRACK: enabled (as module)
- CONFIG_NETFILTER_XT_MATCH_IPVS: enabled (as module)
- CONFIG_NETFILTER_XT_MARK: enabled (as module)
- CONFIG_IP_NF_NAT: enabled (as module)
- CONFIG_NF_NAT: enabled (as module)
- CONFIG_POSIX_MQUEUE: enabled
- CONFIG_CGROUP_BPF: enabled

...

[1] https://github.com/moby/moby/blob/master/contrib/check-config.sh

Cc: Will Deacon <will@kernel.org>
Cc: Arnd Bergmann <arnd@kernel.org>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Vincenzo Frascino <vincenzo.frascino@arm.com>
Link: https://lore.kernel.org/r/20220907110235.14708-1-vincenzo.frascino@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-21 13:12:00 +01:00
Kefeng Wang 31dbadcc28 arm64: defconfig: Enable memory hotplug and hotremove config
Let's enable ACPI_HMAT, ACPI_HOTPLUG_MEMORY, MEMORY_HOTPLUG
and MEMORY_HOTREMOVE for more test coverage, also there are
useful for heterogeneous memory scene.

Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>
Reviewed-by: Catalin Marinas <catalin.marinas@arm.com>
Link: https://lore.kernel.org/r/20220629093524.34801-1-wangkefeng.wang@huawei.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-21 13:10:40 +01:00
Mark Brown 120072f48f arm64: configs: Enable all PMUs provided by Arm
The selection of PMUs enabled in the defconfig is currently a bit random
and does not include a number of those provided by Arm and present in a
fairly wide range of SoCs. Improve coverage and defconfig utility by
enabling all the Arm provided PMUs by default.

Signed-off-by: Mark Brown <broonie@kernel.org>
Reviewed-by: James Clark <james.clark@arm.com>
Reviewed-by: Anshuman Khandual <anshuman.khandual@arm.com>
Link: https://lore.kernel.org/r/20220919162753.3079869-1-broonie@kernel.org
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-21 13:07:53 +01:00
Mark Rutland 0072dc1b53 arm64: avoid BUILD_BUG_ON() in alternative-macros
Nathan reports that the build fails when using clang and LTO:

|  In file included from kernel/bounds.c:10:
|  In file included from ./include/linux/page-flags.h:10:
|  In file included from ./include/linux/bug.h:5:
|  In file included from ./arch/arm64/include/asm/bug.h:26:
|  In file included from ./include/asm-generic/bug.h:5:
|  In file included from ./include/linux/compiler.h:248:
|  In file included from ./arch/arm64/include/asm/rwonce.h:11:
|  ./arch/arm64/include/asm/alternative-macros.h:224:2: error: call to undeclared function 'BUILD_BUG_ON'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
|          BUILD_BUG_ON(feature >= ARM64_NCAPS);
|          ^
|  ./arch/arm64/include/asm/alternative-macros.h:241:2: error: call to undeclared function 'BUILD_BUG_ON'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
|          BUILD_BUG_ON(feature >= ARM64_NCAPS);
|          ^
|  2 errors generated.

... the problem being that when LTO is enabled, <asm/rwonce.h> includes
<asm/alternative-macros.h>, and causes a circular include dependency
through <linux/bug.h>. This manifests as BUILD_BUG_ON() not being
defined when used within <asm/alternative-macros.h>.

This patch avoids the problem and simplifies the include dependencies by
using compiletime_assert() instead of BUILD_BUG_ON().

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Fixes: 21fb26bfb0 ("arm64: alternatives: add alternative_has_feature_*()")
Reported-by: Nathan Chancellor <nathan@kernel.org>
Tested-by: Nathan Chancellor <nathan@kernel.org>
Link: http://lore.kernel.org/r/YyigTrxhE3IRPzjs@dev-arch.thelio-3990X
Cc: Ard Biesheuvel <ardb@kernel.org>
Cc: James Morse <james.morse@arm.com>
Cc: Joey Gouly <joey.gouly@arm.com>
Cc: Marc Zyngier <maz@kernel.org>
Cc: Will Deacon <will@kernel.org>
Reviewed-by: Ard Biesheuvel <ardb@kernel.org>
Acked-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20220920140044.1709073-1-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-21 12:41:50 +01:00
Matt Ranostay 0d0a0b4413 arm64: dts: ti: k3-j7200: fix main pinmux range
Range size of 0x2b4 was incorrect since there isn't 173 configurable
pins for muxing. Additionally there is a non-addressable region in the
mapping which requires splitting into two ranges.

main_pmx0 -> 67 pins
main_pmx1 -> 3 pins

Fixes: d361ed8845 ("arm64: dts: ti: Add support for J7200 SoC")
Signed-off-by: Matt Ranostay <mranostay@ti.com>
Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
Tested-by: Vaishnav Achath <vaishnav.a@ti.com>
Link: https://lore.kernel.org/r/20220919205723.8342-1-mranostay@ti.com
2022-09-21 15:24:37 +05:30
Ard Biesheuvel c37b830fef arm64: efi: enable generic EFI compressed boot
Wire up the generic EFI zboot support for arm64.

Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Tested-by: Jeremy Linton <jeremy.linton@arm.com>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
2022-09-20 12:01:27 +02:00
Zenghui Yu 522c9a64c7 KVM: arm64: Use kmemleak_free_part_phys() to unregister hyp_mem_base
With commit 0c24e06119 ("mm: kmemleak: add rbtree and store physical
address for objects allocated with PA"), kmemleak started to put the
objects allocated with physical address onto object_phys_tree_root tree.
The kmemleak_free_part() therefore no longer worked as expected on
physically allocated objects (hyp_mem_base in this case) as it attempted to
search and remove things in object_tree_root tree.

Fix it by using kmemleak_free_part_phys() to unregister hyp_mem_base. This
fixes an immediate crash when booting a KVM host in protected mode with
kmemleak enabled.

Signed-off-by: Zenghui Yu <yuzenghui@huawei.com>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Reviewed-by: Oliver Upton <oliver.upton@linux.dev>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20220908130659.2021-1-yuzenghui@huawei.com
2022-09-19 17:59:48 +01:00
Lad Prabhakar 4ebf297b93 arm64: dts: renesas: Adjust whitespace around '{'
Drop extra space around the '{' sign. No functional changes (same DTB).

Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
Link: https://lore.kernel.org/r/20220916100251.20329-1-prabhakar.mahadev-lad.rj@bp.renesas.com
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
2022-09-19 13:53:47 +02:00
Lad Prabhakar 53072ba67e arm64: dts: renesas: rzg2ul-smarc: Include SoM DTSI into board DTS
Move including the rzg2ul-smarc-som.dtsi from the carrier board
rzg2ul-smarc.dtsi to the actual RZ/G2UL SMARC EVK board dts
r9a07g043u11-smarc.dts. Also move the SW_SW0_DEV_SEL and
SW_ET0_EN_N macros to board dts as they are used by SoM and carrier
board DTS/I.

This is in preparation of re-using the SoM and carrier board DTSIs
for RZ/Five SMARC EVK.

Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
Link: https://lore.kernel.org/r/20220915165256.352843-2-prabhakar.mahadev-lad.rj@bp.renesas.com
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
2022-09-19 13:53:47 +02:00
Lad Prabhakar 1ca318459c arm64: dts: renesas: rzg2ul-smarc-som: Drop enabling wdt2
WDT CH2 is specifically to check the operation of Cortex-M33 CPU so
don't enable WDT2 by default.

Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
Link: https://lore.kernel.org/r/20220914134211.199631-1-prabhakar.mahadev-lad.rj@bp.renesas.com
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
2022-09-19 13:53:47 +02:00
Geert Uytterhoeven 167720e4bc arm64: dts: renesas: r8a779a0: Update to R-Car Gen4 compatible values
Despite the name, R-Car V3U is the first member of the R-Car Gen4
family.  Hence update the compatible properties in various device nodes
to include family-specific compatible values for R-Car Gen4 instead of
R-Car Gen3:
  - CMT,
  - SDHI.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Link: https://lore.kernel.org/r/f14fde21270bf8269a61a75fc6e50af2765f2a42.1663164707.git.geert+renesas@glider.be
2022-09-19 13:53:46 +02:00
Kuninori Morimoto f4b7dffdc8 arm64: dts: renesas: white-hawk-cpu: Add missing bootargs
This patch adds missing bootargs for R-Car V4H White Hawk board.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87k06858oe.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
2022-09-19 13:53:46 +02:00
Kuninori Morimoto 567934a8c3 arm64: dts: renesas: spider-cpu: Add missing bootargs
This patch adds missing bootargs for R-Car S4 Spider board.

One note is that current Spider board doesn't have Ethernet
support yet, but this patch adds standard settings for it, too.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87leqo58ox.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
2022-09-19 13:53:46 +02:00
Geert Uytterhoeven 5c2b5a2849 arm64: dts: renesas: spider: Move aliases and chosen
The serial console and serial debug ports on Spider are located on the
CPU board.  Hence move the aliases and chosen nodes containing serial
port configuration from the main Spider DTS file to the DTS file that
describes the CPU board.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Link: https://lore.kernel.org/r/c03500bb10eae10caeb3f4f97bc979eeee6cce75.1663167551.git.geert+renesas@glider.be
2022-09-19 13:53:46 +02:00
Geert Uytterhoeven 96f7071d2b arm64: dts: renesas: white-hawk-cpu: Add Ethernet support
Describe the wiring of the first Ethernet AVB instance to the Micrel
KSZ9031RNXVB PHY.

Based on a larger patch in the BSP by Takeshi Kihara.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/50a31bc8267ab4c90bff27ef3aca1169f8ebc7ae.1662715538.git.geert+renesas@glider.be
2022-09-19 13:53:46 +02:00
Geert Uytterhoeven 7bb9e42435 arm64: dts: renesas: white-hawk: Move aliases and chosen
The serial console port on White Hawk is located on the CPU board.
Hence move the aliases and chosen nodes containing serial console
configuration from the main White Hawk DTS file to the DTS file that
describes the CPU board.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/b03b74f4b5ee3c3e828e753beb334ec43162c132.1662715538.git.geert+renesas@glider.be
2022-09-19 13:53:46 +02:00
Geert Uytterhoeven 848c82db56 arm64: dts: renesas: r8a779g0: Add RAVB nodes
Add device nodes for the Renesas Ethernet AVB (EtherAVB-IF) blocks on
the Renesas R-Car V4H (R8A779G0) SoC.

Based on a larger patch in the BSP by Takeshi Kihara.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/980e7a62d8dc3a1e2387a2d93a6296625b105506.1662715538.git.geert+renesas@glider.be
2022-09-19 13:53:46 +02:00
Geert Uytterhoeven 6672f84001 arm64: dts: renesas: white-hawk-cpu: Add push switches
Describe the three Push Switches on the White Hawk CPU board, so
they can be used for user input.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/e18d0d5087a514db611295f5d1e13c950cf7dae7.1662715538.git.geert+renesas@glider.be
2022-09-19 13:53:46 +02:00
Geert Uytterhoeven 60dc0e87fb arm64: dts: renesas: white-hawk-cpu: Add GP LEDs
Describe the three General Purpose LEDs on the White Hawk CPU board, so
they can be used as indicator LEDs.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/007acd941ef925057f1f9b925ed4e339dbd29a74.1662715538.git.geert+renesas@glider.be
2022-09-19 13:53:46 +02:00
Geert Uytterhoeven 120c7a5838 arm64: dts: renesas: r8a779g0: Add GPIO nodes
Add device nodes for the General Purpose Input/Output (GPIO) blocks on
the Renesas R-Car V4H (R8A779G0) SoC.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/81176a5e12a5828cdcdd4b107d0b2e5970232c31.1662715538.git.geert+renesas@glider.be
2022-09-19 13:53:42 +02:00
Hector Martin 4302b3fba1 arm64: dts: apple: Add WiFi module and antenna properties
Add the new module-instance/antenna-sku properties required to select
WiFi firmwares properly to all board device trees.

Signed-off-by: Hector Martin <marcan@marcan.st>
Reviewed-by: Mark Kettenis <kettenis@openbsd.org>
Acked-by: Hector Martin <marcan@marcan.st>
Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/E1oZDoI-0077b3-Dd@rmk-PC.armlinux.org.uk
2022-09-19 12:59:35 +03:00
Marc Zyngier bb0cca240a Merge branch kvm-arm64/single-step-async-exception into kvmarm-master/next
* kvm-arm64/single-step-async-exception:
  : .
  : Single-step fixes from Reiji Watanabe:
  :
  : "This series fixes two bugs of single-step execution enabled by
  : userspace, and add a test case for KVM_GUESTDBG_SINGLESTEP to
  : the debug-exception test to verify the single-step behavior."
  : .
  KVM: arm64: selftests: Add a test case for KVM_GUESTDBG_SINGLESTEP
  KVM: arm64: selftests: Refactor debug-exceptions to make it amenable to new test cases
  KVM: arm64: Clear PSTATE.SS when the Software Step state was Active-pending
  KVM: arm64: Preserve PSTATE.SS for the guest while single-step is enabled

Signed-off-by: Marc Zyngier <maz@kernel.org>
2022-09-19 10:59:29 +01:00
Reiji Watanabe 370531d1e9 KVM: arm64: Clear PSTATE.SS when the Software Step state was Active-pending
While userspace enables single-step, if the Software Step state at the
last guest exit was "Active-pending", clear PSTATE.SS on guest entry
to restore the state.

Currently, KVM sets PSTATE.SS to 1 on every guest entry while userspace
enables single-step for the vCPU (with KVM_GUESTDBG_SINGLESTEP).
It means KVM always makes the vCPU's Software Step state
"Active-not-pending" on the guest entry, which lets the VCPU perform
single-step (then Software Step exception is taken). This could cause
extra single-step (without returning to userspace) if the Software Step
state at the last guest exit was "Active-pending" (i.e. the last
exit was triggered by an asynchronous exception after the single-step
is performed, but before the Software Step exception is taken.
See "Figure D2-3 Software step state machine" and "D2.12.7 Behavior
in the active-pending state" in ARM DDI 0487I.a for more info about
this behavior).

Fix this by clearing PSTATE.SS on guest entry if the Software Step state
at the last exit was "Active-pending" so that KVM restore the state (and
the exception is taken before further single-step is performed).

Fixes: 337b99bf7e ("KVM: arm64: guest debug, add support for single-step")
Signed-off-by: Reiji Watanabe <reijiw@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20220917010600.532642-3-reijiw@google.com
2022-09-19 10:48:53 +01:00
Reiji Watanabe 34fbdee086 KVM: arm64: Preserve PSTATE.SS for the guest while single-step is enabled
Preserve the PSTATE.SS value for the guest while userspace enables
single-step (i.e. while KVM manipulates the PSTATE.SS) for the vCPU.

Currently, while userspace enables single-step for the vCPU
(with KVM_GUESTDBG_SINGLESTEP), KVM sets PSTATE.SS to 1 on every
guest entry, not saving its original value.
When userspace disables single-step, KVM doesn't restore the original
value for the subsequent guest entry (use the current value instead).
Exception return instructions copy PSTATE.SS from SPSR_ELx.SS
only in certain cases when single-step is enabled (and set it to 0
in other cases). So, the value matters only when the guest enables
single-step (and when the guest's Software step state isn't affected
by single-step enabled by userspace, practically), though.

Fix this by preserving the original PSTATE.SS value while userspace
enables single-step, and restoring the value once it is disabled.

This fix modifies the behavior of GET_ONE_REG/SET_ONE_REG for the
PSTATE.SS while single-step is enabled by userspace.
Presently, GET_ONE_REG/SET_ONE_REG gets/sets the current PSTATE.SS
value, which KVM will override on the next guest entry (i.e. the
value userspace gets/sets is not used for the next guest entry).
With this patch, GET_ONE_REG/SET_ONE_REG will get/set the guest's
preserved value, which KVM will preserve and try to restore after
single-step is disabled.

Fixes: 337b99bf7e ("KVM: arm64: guest debug, add support for single-step")
Signed-off-by: Reiji Watanabe <reijiw@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20220917010600.532642-2-reijiw@google.com
2022-09-19 10:48:53 +01:00
Marc Zyngier b04b331502 Merge remote-tracking branch 'arm64/for-next/sysreg' into kvmarm-master/next
Merge arm64/for-next/sysreg in order to avoid upstream conflicts
due to the never ending sysreg repainting...

Signed-off-by: Marc Zyngier <maz@kernel.org>
2022-09-19 09:45:00 +01:00
Geert Uytterhoeven 9c1277a25f arm64: dts: renesas: white-hawk: Add Ethernet sub-board
Add a DTS file for the R-Car V4H White Hawk RAVB/Ethernet(1000Base-T1)
sub-board (RTP8A779G0ASKB0SE0SA000), and include it from the main
r8a779g0-white-hawk.dts.

For now its contents are limited to the Board ID EEPROM.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/991600919513dd05a9a7d9c170c6924baf14d1a2.1662715538.git.geert+renesas@glider.be
2022-09-18 14:53:35 +02:00
Geert Uytterhoeven 78c84f4680 arm64: dts: renesas: white-hawk: Add CSI/DSI sub-board
Add a DTS file for the R-Car V4H White Hawk CSI/DSI sub-board
(RTP8A779G0ASKB0SC0SA000), and include it from the main
r8a779g0-white-hawk.dts.

For now its contents are limited to the Board ID EEPROM.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/265f7782743c539c57906e8207785f8b0d80d5d0.1662715538.git.geert+renesas@glider.be
2022-09-18 14:53:35 +02:00
Geert Uytterhoeven 77643815b0 arm64: dts: renesas: white-hawk: Add I2C0 and EEPROMs
Enable the I2C0 bus on the White Hawk CPU board, and describe the I2C
EEPROMs present on the White Hawk CPU and BreakOut boards.

Based on a larger patch in the BSP by Takeshi Kihara.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/d01cada6f2d3e44dd6cb26cfa8e4ce6382f1fbff.1662715538.git.geert+renesas@glider.be
2022-09-18 14:53:34 +02:00
Geert Uytterhoeven ff77ba0514 arm64: dts: renesas: r8a779g0: Add I2C nodes
Add device nodes for the I2C Bus Interfaces on the Renesas R-Car V4H
(R8A779G0) SoC.

Extracted from a larger patch in the BSP by Takeshi Kihara.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/272fd18fed2d7addfbdb7945ae2134988a7c3a7e.1662715538.git.geert+renesas@glider.be
2022-09-18 14:53:34 +02:00
Geert Uytterhoeven 7a8d590de8 arm64: dts: renesas: white-hawk-cpu: Add serial port pin control
Complete the description of the serial console and the external serial
clock by adding pin control.

Based on larger patch in the BSP by Takeshi Kihara.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/74c862ef6e46b4af398d9b371ff38fae17b3db05.1662715538.git.geert+renesas@glider.be
2022-09-18 14:53:34 +02:00
Geert Uytterhoeven 4cebce2577 arm64: dts: renesas: r8a779g0: Add pinctrl device node
Add a device node for the Pin Function Controller on the Renesas R-Car
V4H (R8A779G0) SoC.

Based on a larger patch in the BSP by Takeshi Kihara.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/ecddcadd2fad46b1cf4c9be3ec750f360b9730e4.1662715538.git.geert+renesas@glider.be
2022-09-18 14:53:34 +02:00
Geert Uytterhoeven 495e36c3a3 arm64: dts: renesas: white-hawk-cpu: Enable watchdog timer
Enable the watchdog timer on the White Hawk CPU board.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/77a0e29d965032115de1f07ceecb2d5d07db74eb.1662715538.git.geert+renesas@glider.be
2022-09-18 14:53:34 +02:00
Geert Uytterhoeven a43306faee arm64: dts: renesas: r8a779g0: Add RWDT node
Add a device node for the RCLK Watchdog Timer (RWDT) on the Renesas
R-Car V4H (R8A779G0) SoC.

Based on a patch in the BSP by Thanh Quan.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/187904c279be6654ea3deb11b7250b64dd18c3b5.1662715538.git.geert+renesas@glider.be
2022-09-18 14:53:34 +02:00
Lad Prabhakar bb81684d2d arm64: renesas: Drop selecting SOC_BUS
Don't automatically select the SOC_BUS config option as we already have
automatically selected it as part of the SOC_RENESAS config option [0]
as renesas-soc.c [1] uses the APIs provided by SOC_BUS config option.

[0] drivers/soc/renesas/Kconfig
[1] drivers/soc/renesas/renesas-soc.c

Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
Link: https://lore.kernel.org/r/20220915233640.415305-1-prabhakar.mahadev-lad.rj@bp.renesas.com
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
2022-09-18 14:51:10 +02:00
Ard Biesheuvel c82ceb440b efi/libstub: use EFI provided memcpy/memset routines
The stub is used in different execution environments, but on arm64,
RISC-V and LoongArch, we still use the core kernel's implementation of
memcpy and memset, as they are just a branch instruction away, and can
generally be reused even from code such as the EFI stub that runs in a
completely different address space.

KAsan complicates this slightly, resulting in the need for some hacks to
expose the uninstrumented, __ prefixed versions as the normal ones, as
the latter are instrumented to include the KAsan checks, which only work
in the core kernel.

Unfortunately, #define'ing memcpy to __memcpy when building C code does
not guarantee that no explicit memcpy() calls will be emitted. And with
the upcoming zboot support, which consists of a separate binary which
therefore needs its own implementation of memcpy/memset anyway, it's
better to provide one explicitly instead of linking to the existing one.

Given that EFI exposes implementations of memmove() and memset() via the
boot services table, let's wire those up in the appropriate way, and
drop the references to the core kernel ones.

Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
2022-09-17 15:13:21 +02:00
Pankaj Bansal d4e87e4e84 arm64: dts: ls1046a-qds: Modify the qspi flash frequency
The qspi flash in ls1046a QDS board can operate at 50MHz frequency.
Therefore, update the maximum supported freq in dts file.

Signed-off-by: Pankaj Bansal <pankaj.bansal@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:25 +08:00
Li Yang 63c396414b arm64: dts: ls1046a-qds: add mmio based mdio-mux nodes for FPGA
There is mmio based mdio mux function in the FPGA device on ls1046a-qds
board.  Add the mmio based mdio-mux nodes to ls1043a-qds boards and
add simple-mfd as a compatbile for the FPGA node to reflect the
multi-function nature of it.

Signed-off-by: Camelia Groza <camelia.groza@nxp.com>
Signed-off-by: Pankaj Bansal <pankaj.bansal@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:25 +08:00
Li Yang 0f62994a55 arm64: dts: ls1046a: add gpios based i2c recovery information
Add scl-gpios property for i2c recovery and add SoC specific
compatible string for SoC specific fixup.

Signed-off-by: Zhang Ying <ying.zhang22455@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:24 +08:00
Laurentiu Tudor f8179c89d7 arm64: dts: ls1046a: use a pseudo-bus to constrain usb and sata dma size
Wrap the usb and sata controllers in an intermediate simple-bus and use
it to constrain the dma address size of these usb controllers to the 40
bits that they generate toward the interconnect.  This is required
because the SoC uses 48 bits address sizes and this mismatch would lead
to smmu context faults because the usb generates 40-bit addresses while
the smmu page tables are populated with 48-bit wide addresses.

Suggested-by: Robin Murphy <robin.murphy@arm.com>
Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:24 +08:00
Li Yang 136975c338 arm64: dts: ls1046a: make dma-coherent global to the SoC
These SoCs are really completely dma coherent in their entirety so add
the dma-coherent property at the soc level in the device tree and drop
the instances where it's specifically added to a few select devices.

Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:24 +08:00
Laurentiu Tudor 0d3990796f arm64: dts: ls1046a: add missing dma ranges property
These chips have a 48-bit address size so make sure that the dma-ranges
reflects this. Otherwise the linux kernel's dma sub-system will set
the default dma masks to full 64-bit, badly breaking dmas.

Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:24 +08:00
Hou Zhiqiang b236df8982 arm64: dts: ls1046a: Add big-endian property for PCIe nodes
Add the big-endian property for LS1046A PCIe RC nodes.

Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:24 +08:00
Xiaowei Bao 163608619b arm64: dts: ls1046a: Add the PME interrupt and big-endian to PCIe EP nodes
Add the PME interrupt porperty and big-endian property in PCIe EP nodes.

Signed-off-by: Xiaowei Bao <xiaowei.bao@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:24 +08:00
Li Yang 6f3e8922e5 arm64: dts: ls1046a: Enable usb3-lpm-capable for usb3 node
Enable USB3 HW LPM feature for ls1046a.

Signed-off-by: Ran Wang <ran.wang_1@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:24 +08:00
Li Yang a81e12d2ac arm64: dts: ls1043a-rdb: add pcf85263 rtc node
Add the missing node for rtc device under i2c and fix style problems at
the same time.

Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:23 +08:00
Li Yang ab9d8032db arm64: dts: ls1043a-qds: add mmio based mdio-mux support
There is mmio based mdio mux function in the FPGA device on ls1043a-qds
board.  Add the mmio based mdio-mux nodes to ls1043a-qds boards and
add simple-mfd as a compatbile for the FPGA node to reflect the
multi-function nature of it.  Also connect the ethernet interfaces to
these phy interfaces.

Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:23 +08:00
Laurentiu Tudor 2a2ab4d520 arm64: dts: ls1043a: use a pseudo-bus to constrain usb and sata dma size
Wrap the usb and sata controllers in an intermediate simple-bus and use
it to constrain the dma address size of these usb controllers to the 40
bits that they generate toward the interconnect.  This is required
because the SoC uses 48 bits address sizes and this mismatch would lead
to smmu context faults because the usb generates 40-bit addresses while
the smmu page tables are populated with 48-bit wide addresses.

Suggested-by: Robin Murphy <robin.murphy@arm.com>
Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:23 +08:00
Li Yang 4b211ebb88 arm64: dts: ls1043a: add gpio based i2c recovery information
Add scl-gpios property for i2c recovery and add SoC specific compatible
string for SoC specific fixup.

Signed-off-by: Zhang Ying <ying.zhang22455@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:23 +08:00
Li Yang f0560158da arm64: dts: ls1043a: make dma-coherent global to the SoC
ls1043a is really completely dma coherent in their entirety so add the
dma-coherent property at the soc level in the device tree and drop the
instances where it's specifically added to a few select devices.

Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:23 +08:00
Laurentiu Tudor 21d5096f84 arm64: dts: ls1043a: add missing dma ranges property
ls1043a has a 48-bit address size so make sure that the dma-ranges
reflects this. Otherwise the linux kernel's dma sub-system will set the
default dma masks to full 64-bit, badly breaking dmas.

Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:23 +08:00
Hou Zhiqiang 5c4820af65 arm64: dts: ls1043a: Add big-endian property for PCIe nodes
Add the big-endian property for LS1043A PCIe nodes for accessing PEX_LUT
and PF register block.

Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:22 +08:00
Hou Zhiqiang 8580b6aa02 arm64: dts: ls1043a: Add SCFG phandle for PCIe nodes
The LS1043A PCIe controller has some control registers
in SCFG block, so add the SCFG phandle for each PCIe
controller node.

Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:22 +08:00
Li Yang ee00c1a631 arm64: dts: ls1043a: use pcie aer/pme interrupts
After the binding has been updated to include more specific interrupt
definition, update the dts to use the more specific interrupt names.

Signed-off-by: Po Liu <po.liu@nxp.com>
Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:22 +08:00
Li Yang d7b01cca02 arm64: dts: ls1043a: Enable usb3-lpm-capable for usb3 node
Enable USB3 HW LPM feature for ls1043a.

Signed-off-by: Ran Wang <ran.wang_1@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:22 +08:00
Li Yang 9b6408f027 arm64: dts: ls1043a: fix the wrong size of dcfg space
The size of the block should be 0x1000 instead of 0x10000.

Signed-off-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2022-09-17 16:35:22 +08:00