Commit Graph

15802 Commits

Author SHA1 Message Date
Lars Povlsen
5ef399aa5c arm64: dts: sparx5: Add reset support
This adds reset support to the Sparx5 SoC DT.

Signed-off-by: Lars Povlsen <lars.povlsen@microchip.com>
Link: https://lore.kernel.org/r/20201006200316.2261245-4-lars.povlsen@microchip.com
2020-12-10 11:50:43 +01:00
Catalin Marinas
d889797530 Merge remote-tracking branch 'arm64/for-next/fixes' into for-next/core
* arm64/for-next/fixes: (26 commits)
  arm64: mte: fix prctl(PR_GET_TAGGED_ADDR_CTRL) if TCF0=NONE
  arm64: mte: Fix typo in macro definition
  arm64: entry: fix EL1 debug transitions
  arm64: entry: fix NMI {user, kernel}->kernel transitions
  arm64: entry: fix non-NMI kernel<->kernel transitions
  arm64: ptrace: prepare for EL1 irq/rcu tracking
  arm64: entry: fix non-NMI user<->kernel transitions
  arm64: entry: move el1 irq/nmi logic to C
  arm64: entry: prepare ret_to_user for function call
  arm64: entry: move enter_from_user_mode to entry-common.c
  arm64: entry: mark entry code as noinstr
  arm64: mark idle code as noinstr
  arm64: syscall: exit userspace before unmasking exceptions
  arm64: pgtable: Ensure dirty bit is preserved across pte_wrprotect()
  arm64: pgtable: Fix pte_accessible()
  ACPI/IORT: Fix doc warnings in iort.c
  arm64/fpsimd: add <asm/insn.h> to <asm/kprobes.h> to fix fpsimd build
  arm64: cpu_errata: Apply Erratum 845719 to KRYO2XX Silver
  arm64: proton-pack: Add KRYO2XX silver CPUs to spectre-v2 safe-list
  arm64: kpti: Add KRYO2XX gold/silver CPU cores to kpti safelist
  ...

# Conflicts:
#	arch/arm64/include/asm/exception.h
#	arch/arm64/kernel/sdei.c
2020-12-09 18:04:55 +00:00
Catalin Marinas
d45056ad73 Merge remote-tracking branch 'arm64/for-next/scs' into for-next/core
* arm64/for-next/scs:
  arm64: sdei: Push IS_ENABLED() checks down to callee functions
  arm64: scs: use vmapped IRQ and SDEI shadow stacks
  scs: switch to vmapped shadow stacks
2020-12-09 18:04:48 +00:00
Catalin Marinas
d8602f8bf3 Merge remote-tracking branch 'arm64/for-next/perf' into for-next/core
* arm64/for-next/perf:
  perf/imx_ddr: Add system PMU identifier for userspace
  bindings: perf: imx-ddr: add compatible string
  arm64: Fix build failure when HARDLOCKUP_DETECTOR_PERF is enabled
  arm64: Enable perf events based hard lockup detector
  perf/imx_ddr: Add stop event counters support for i.MX8MP
  perf/smmuv3: Support sysfs identifier file
  drivers/perf: hisi: Add identifier sysfs file
  perf: remove duplicate check on fwnode
  driver/perf: Add PMU driver for the ARM DMC-620 memory controller
2020-12-09 18:04:48 +00:00
Catalin Marinas
ba4259a6f8 Merge branch 'for-next/misc' into for-next/core
* for-next/misc:
  : Miscellaneous patches
  arm64: vmlinux.lds.S: Drop redundant *.init.rodata.*
  kasan: arm64: set TCR_EL1.TBID1 when enabled
  arm64: mte: optimize asynchronous tag check fault flag check
  arm64/mm: add fallback option to allocate virtually contiguous memory
  arm64/smp: Drop the macro S(x,s)
  arm64: consistently use reserved_pg_dir
  arm64: kprobes: Remove redundant kprobe_step_ctx

# Conflicts:
#	arch/arm64/kernel/vmlinux.lds.S
2020-12-09 18:04:48 +00:00
Catalin Marinas
e0f7a8d5e8 Merge branch 'for-next/uaccess' into for-next/core
* for-next/uaccess:
  : uaccess routines clean-up and set_fs() removal
  arm64: mark __system_matches_cap as __maybe_unused
  arm64: uaccess: remove vestigal UAO support
  arm64: uaccess: remove redundant PAN toggling
  arm64: uaccess: remove addr_limit_user_check()
  arm64: uaccess: remove set_fs()
  arm64: uaccess cleanup macro naming
  arm64: uaccess: split user/kernel routines
  arm64: uaccess: refactor __{get,put}_user
  arm64: uaccess: simplify __copy_user_flushcache()
  arm64: uaccess: rename privileged uaccess routines
  arm64: sdei: explicitly simulate PAN/UAO entry
  arm64: sdei: move uaccess logic to arch/arm64/
  arm64: head.S: always initialize PSTATE
  arm64: head.S: cleanup SCTLR_ELx initialization
  arm64: head.S: rename el2_setup -> init_kernel_el
  arm64: add C wrappers for SET_PSTATE_*()
  arm64: ensure ERET from kthread is illegal
2020-12-09 18:04:42 +00:00
Catalin Marinas
3c09ec59cd Merge branches 'for-next/kvm-build-fix', 'for-next/va-refactor', 'for-next/lto', 'for-next/mem-hotplug', 'for-next/cppc-ffh', 'for-next/pad-image-header', 'for-next/zone-dma-default-32-bit', 'for-next/signal-tag-bits' and 'for-next/cmdline-extended' into for-next/core
* for-next/kvm-build-fix:
  : Fix KVM build issues with 64K pages
  KVM: arm64: Fix build error in user_mem_abort()

* for-next/va-refactor:
  : VA layout changes
  arm64: mm: don't assume struct page is always 64 bytes
  Documentation/arm64: fix RST layout of memory.rst
  arm64: mm: tidy up top of kernel VA space
  arm64: mm: make vmemmap region a projection of the linear region
  arm64: mm: extend linear region for 52-bit VA configurations

* for-next/lto:
  : Upgrade READ_ONCE() to RCpc acquire on arm64 with LTO
  arm64: lto: Strengthen READ_ONCE() to acquire when CONFIG_LTO=y
  arm64: alternatives: Remove READ_ONCE() usage during patch operation
  arm64: cpufeatures: Add capability for LDAPR instruction
  arm64: alternatives: Split up alternative.h
  arm64: uaccess: move uao_* alternatives to asm-uaccess.h

* for-next/mem-hotplug:
  : Memory hotplug improvements
  arm64/mm/hotplug: Ensure early memory sections are all online
  arm64/mm/hotplug: Enable MEM_OFFLINE event handling
  arm64/mm/hotplug: Register boot memory hot remove notifier earlier
  arm64: mm: account for hotplug memory when randomizing the linear region

* for-next/cppc-ffh:
  : Add CPPC FFH support using arm64 AMU counters
  arm64: abort counter_read_on_cpu() when irqs_disabled()
  arm64: implement CPPC FFH support using AMUs
  arm64: split counter validation function
  arm64: wrap and generalise counter read functions

* for-next/pad-image-header:
  : Pad Image header to 64KB and unmap it
  arm64: head: tidy up the Image header definition
  arm64/head: avoid symbol names pointing into first 64 KB of kernel image
  arm64: omit [_text, _stext) from permanent kernel mapping

* for-next/zone-dma-default-32-bit:
  : Default to 32-bit wide ZONE_DMA (previously reduced to 1GB for RPi4)
  of: unittest: Fix build on architectures without CONFIG_OF_ADDRESS
  mm: Remove examples from enum zone_type comment
  arm64: mm: Set ZONE_DMA size based on early IORT scan
  arm64: mm: Set ZONE_DMA size based on devicetree's dma-ranges
  of: unittest: Add test for of_dma_get_max_cpu_address()
  of/address: Introduce of_dma_get_max_cpu_address()
  arm64: mm: Move zone_dma_bits initialization into zone_sizes_init()
  arm64: mm: Move reserve_crashkernel() into mem_init()
  arm64: Force NO_BLOCK_MAPPINGS if crashkernel reservation is required
  arm64: Ignore any DMA offsets in the max_zone_phys() calculation

* for-next/signal-tag-bits:
  : Expose the FAR_EL1 tag bits in siginfo
  arm64: expose FAR_EL1 tag bits in siginfo
  signal: define the SA_EXPOSE_TAGBITS bit in sa_flags
  signal: define the SA_UNSUPPORTED bit in sa_flags
  arch: provide better documentation for the arch-specific SA_* flags
  signal: clear non-uapi flag bits when passing/returning sa_flags
  arch: move SA_* definitions to generic headers
  parisc: start using signal-defs.h
  parisc: Drop parisc special case for __sighandler_t

* for-next/cmdline-extended:
  : Add support for CONFIG_CMDLINE_EXTENDED
  arm64: Extend the kernel command line from the bootloader
  arm64: kaslr: Refactor early init command line parsing
2020-12-09 18:04:35 +00:00
Arnd Bergmann
c87b013f23 arm64: dts: ZynqMP DT changes for v5.11
- Wiring IPI communication channel with firmware driver
 - Taking GIC to main bus to have only one
 - Small fix in zynqmp.dtsi reported by dt_binding_check
 -----BEGIN PGP SIGNATURE-----
 
 iF0EABECAB0WIQQbPNTMvXmYlBPRwx7KSWXLKUoMIQUCX9DlAwAKCRDKSWXLKUoM
 ITJiAJ90LYMCutcZExL1FKJoPiJYsdYZqwCZAQ/q5gWgBny8HC5t5jxt84wN84Q=
 =wxe9
 -----END PGP SIGNATURE-----

Merge tag 'zynqmp-dt-for-v5.11' of https://github.com/Xilinx/linux-xlnx into arm/dt

arm64: dts: ZynqMP DT changes for v5.11

- Wiring IPI communication channel with firmware driver
- Taking GIC to main bus to have only one
- Small fix in zynqmp.dtsi reported by dt_binding_check

* tag 'zynqmp-dt-for-v5.11' of https://github.com/Xilinx/linux-xlnx:
  arm64: dts: zynqmp: Wire mailbox with zynqmp-power driver
  arm64: dts: zynqmp: Fix pcie ranges description
  arm64: zynqmp: Move gic node to axi bus

Link: https://lore.kernel.org/r/f460f6ac-d235-a33b-3d0f-ca904a43e687@monstr.eu
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-09 17:51:45 +01:00
Kevin Hilman
dcb11100cd arm64: Kconfig: meson: drop pinctrl
Don't automatically select pinctrl drivers, leave it up to defaults in
drivers/pinctrl/meson, which default to built-in, but are also now
optionally configurable as modules as of
commit 9c65441ec8 ("pinctrl/meson: enable building as modules")

Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Reviewed-by: Jerome Brunet <jbrunet@baylibre.com>
Link: https://lore.kernel.org/r/20201207230156.10198-1-khilman@baylibre.com'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-09 17:36:46 +01:00
Arnd Bergmann
b760bfbcbf arm64: Kconfig.platform: amlogic updates for v5.11
- ship only the necessary clock controllers
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEe4dGDhaSf6n1v/EMWTcYmtP7xmUFAl/GwtUACgkQWTcYmtP7
 xmV0Iw//f53+9bGT9suyUIaE7vTkUD3N7BpOZ2hhc+wjoDcWz3cg+R4R6LF7pdZ6
 AEbJYQUTepBZvtgS35TEMOL+w+kpL++IG2Jj3bgTUCrWfUNEK52ZnaJobMehdhdL
 dRny5BYLDWwj+G1VIIQu3lCyxr7qonA4AEsVr+5jFhpJdxvkLyYkRGEDWG1lybUa
 p0xRE21OfH4BKx4nrXZU64MFUv501iHLtUdhtkddeFaG7UvcwaNdQz3llh7SvxX6
 gC2pR6aaU7bjsCZOBk/Gig12PxlSMzt8/PkAAAOiyzFsWoC4qzXShUeJkIPTUZ8i
 pecuV8dY1XDj35EMROiIHoNMfEDYmwjr+yww3PP8NAyhMBrff/GX4cPeV5pPRWsK
 UiL3WBqFMQNhAm+guDXW4aUlHEw0EzhhkA4ZhEnRTGkwrPWeqyP6lvi2vk14itpG
 NXLHosoJaiZLb/i8/6UJYj4vhPaRMo44Sja+8NtzUm1R/nVza69pNvCmH+bNg4ct
 1v7NKUoExaGT69bWrxcW1T6ZQNDhXNude1+ZUpsTRjcFH410ouy3pF0oPr57K2M5
 S7HsHiRlkomewWEsfq/O7qzAY1lk5jTNan1SA1MgYpPaQ+sIYJpQTvdSxtJ8m63A
 XR7bhxxYuq+J+6gJecxyP5EBp2sMrj/uqJ2TIPrDshwG2/Y5X1o=
 =vf5y
 -----END PGP SIGNATURE-----

Merge tag 'amlogic-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-amlogic into arm/soc

arm64: Kconfig.platform: amlogic updates for v5.11
- ship only the necessary clock controllers

* tag 'amlogic-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-amlogic:
  arm64: meson: ship only the necessary clock controllers

Link: https://lore.kernel.org/r/7hlfehjgv8.fsf@baylibre.com
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-09 17:26:34 +01:00
Marc Zyngier
3a514592b6 Merge remote-tracking branch 'origin/kvm-arm64/psci-relay' into kvmarm-master/next
Signed-off-by: Marc Zyngier <maz@kernel.org>
2020-12-09 10:00:24 +00:00
Ard Biesheuvel
54649911f3 efi: stub: get rid of efi_get_max_fdt_addr()
Now that ARM started following the example of arm64 and RISC-V, and
no longer imposes any restrictions on the placement of the FDT in
memory at boot, we no longer need per-arch implementations of
efi_get_max_fdt_addr() to factor out the differences. So get rid of
it.

Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Reviewed-by: Atish Patra <atish.patra@wdc.com>
Link: https://lore.kernel.org/r/20201029134901.9773-1-ardb@kernel.org
2020-12-09 08:37:27 +01:00
Ard Biesheuvel
4dbe44fb53 efi: capsule: clean scatter-gather entries from the D-cache
Scatter-gather lists passed to UpdateCapsule() should be cleaned
from the D-cache to ensure that they are visible to the CPU after a
warm reboot before the MMU is enabled. On ARM and arm64 systems, this
implies a D-cache clean by virtual address to the point of coherency.

However, due to the fact that the firmware itself is not able to map
physical addresses back to virtual addresses when running under the OS,
this must be done by the caller.

Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
2020-12-09 08:37:27 +01:00
Arnd Bergmann
d23e629717 A few more RGMII-ID fixes
-----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCX8+ocQAKCRDj7w1vZxhR
 xYTCAQDuwJCQDbBh5+UFsWUBPnphCTo53H9kxY/GO/g6fw4gNAD+NhV1F8l53n+e
 jCmnANqbNP1T/blps9RJgMsw57NvRAY=
 =xWDk
 -----END PGP SIGNATURE-----

Merge tag 'sunxi-fixes-for-5.10-3' of git://git.kernel.org/pub/scm/linux/kernel/git/sunxi/linux into arm/fixes

A few more RGMII-ID fixes

* tag 'sunxi-fixes-for-5.10-3' of git://git.kernel.org/pub/scm/linux/kernel/git/sunxi/linux:
  arm64: dts: allwinner: H5: NanoPi Neo Plus2: phy-mode rgmii-id
  arm64: dts: allwinner: A64 Sopine: phy-mode rgmii-id

Link: https://lore.kernel.org/r/2a351c9c-470f-4c5e-ba37-80065ae0586d.lettre@localhost
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-09 00:13:38 +01:00
Arnd Bergmann
4f9f1415bb arm64: dts: amlogic updates for v5.11, round 2
- audio support for several more boards
 - PHY timing fixes
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEe4dGDhaSf6n1v/EMWTcYmtP7xmUFAl/P0pIACgkQWTcYmtP7
 xmUYRQ//R7B1Qh94p79Lj8swFQxzjJJutIaw5weI/xeZ2V9kGp21+IXtj7btM2PF
 JyCYhnP4iuvsehRXd5FzK2Q2YQR3wsKMx7yzO9mD7I6pFkvhEOwDIDwzz+NV76SU
 yU2eNHjE07TyKwGfbbo2Gt4UkXIB0Hv6cHsHzRo9HswsR3bZ1lznytvnBf8ZQUeR
 QQxXvZeA/BHAgsvCqHsOcXnnzcRR8PUQ9rtPVeIL6RB0yzQaZ590jWsLXW2LTPHr
 l13KkJ+/+izkTua3QI3CSMv85RydTN6RTWkc+1/WxA5uGgl6Sj3fj8B8117tIVR5
 3WAMDtp7qYYBfXSfV+xWg3ov1EQOPYri6pOHaco8YZgA0jxHolHJIF0dUXQLWzGg
 HByQIwpZ5ZGw2179dVg/UwPeKUKHxWOudxsFA5SIAMAlpbsHeXShkfjB5Pd1tS42
 COHjyrX47h8zoD0Il0nNDNU//+GYP52RmDpsSakxNIP/dXYt/OzDeCgo1gipPOdd
 W1FBb1VKQKJbxlLGrSWdeB4A13uY2XKeQcjac1Dd0sQ48A0lvseK1MLe8Q92KmPh
 vBFpq1qqjJUl8hbywC99xqTiXwUE2QxzmXS3uLmu6+VpHJiMx0eVIilOkTLdbveZ
 Mu1lQFEvucd7w6cYVDICUg37O8zuP3ZA0pZXllpFFc0xZCe5Fmc=
 =0cIr
 -----END PGP SIGNATURE-----

Merge tag 'amlogic-dt64-2' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-amlogic into arm/dt

arm64: dts: amlogic updates for v5.11, round 2
- audio support for several more boards
- PHY timing fixes

* tag 'amlogic-dt64-2' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-amlogic:
  arm64: dts: meson: add i2c3/rtc nodes and vrtc alias to GT-King/GT-King-Pro
  arm64: dts: meson: g12b: w400: fix PHY deassert timing requirements
  arm64: dts: meson: g12a: x96-max: fix PHY deassert timing requirements
  ARM: dts: meson: fix PHY deassert timing requirements
  arm64: dts: meson: fix PHY deassert timing requirements
  arm64: dts: meson: g12b: odroid-n2: fix PHY deassert timing requirements
  arm64: dts: meson: minor fixups for Khadas VIM/VIM2 dts
  arm64: dts: meson: add audio playback to wetek-play2
  arm64: dts: meson: add audio playback to wetek-hub
  arm64: dts: meson: add audio playback to odroid-c2
  arm64: dts: meson: add audio playback to nanopi-k2
  arm64: dts: meson: add audio playback to khadas-vim2
  arm64: dts: meson: add audio playback to khadas-vim
  arm64: dts: meson: add audio playback to a95x
  arm64: dts: meson-axg: add GE2D node

Link: https://lore.kernel.org/r/7ho8j4gkxo.fsf@baylibre.com
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-09 00:06:33 +01:00
Arnd Bergmann
4569830224 Veyron backlight fix, another fix for dtbs-check and some additions
to the rk3288-based VMARC boards.
 -----BEGIN PGP SIGNATURE-----
 
 iQFEBAABCAAuFiEE7v+35S2Q1vLNA3Lx86Z5yZzRHYEFAl/NHWkQHGhlaWtvQHNu
 dGVjaC5kZQAKCRDzpnnJnNEdgVlcB/wIdj41vGWslMZcShijb+QeW5W6bYus3WkX
 Zvl+RDGccGbjDH6UEKP+XETXR2tgKfXSooiO8YKjEV9L/fnfMZQWQh3rPg8SA39b
 f2N7JTnB7YCasZU4XXeQtqB6TKRubAZixUxEWibY1l1mwb+izPeij73PptjEMgsm
 jkVOjwX4lWhfISbVf2Nl5d6KWfbJgPgqu0yA7kIDlRDOvmsxh8vQyByHaTltoa/+
 slLEGn0B+7kMEdGSdL6TgGQ1jwF1WPGoBokl7CnTsNzBkzQIm2wVnbvzZNY/5oI4
 2HCR8ihpqjDxy84Dx3mmlVCl6uGCG8ipHSpLubg3rvqRhA2w1fes
 =oBVw
 -----END PGP SIGNATURE-----

Merge tag 'v5.11-rockchip-dts32-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into arm/dt

Veyron backlight fix, another fix for dtbs-check and some additions
to the rk3288-based VMARC boards.

* tag 'v5.11-rockchip-dts32-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip:
  ARM: dts: rockchip: Add SDIO0 node for VMARC SOM
  ARM: dts: rockchip: Add rtc node for VMARC SOM
  ARM: dts: rockchip: rename wdt nodename to watchdog on rv1108
  ARM: dts: rockchip: Remove 0 point from brightness-levels on rk3288-veyron

Link: https://lore.kernel.org/r/4582475.GXAFRqVoOG@phil
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-09 00:04:35 +01:00
Arnd Bergmann
261078ab90 Newly added boards are the PX30 SOM system from Engicam and Kobol Helios64.
The Scarlet tablet finally gets support for its cameras, now that the
 the rk3399-isp moved out of staging.
 The Odroid-Go-Advance got its joystick support now that the adc-joystick
 driver was merged and misc omprovements to the RockPi4, rk3328-roc-cc
 and orange-pi.
 -----BEGIN PGP SIGNATURE-----
 
 iQFEBAABCAAuFiEE7v+35S2Q1vLNA3Lx86Z5yZzRHYEFAl/NIB8QHGhlaWtvQHNu
 dGVjaC5kZQAKCRDzpnnJnNEdgSkWB/9XzLgxka9y6ntWV6+dlhHJQ/KnlvFwIH0m
 o/thgqAd6ns0ey0pYEpQ8Hj6piMHuNWuqIq0S6u19ssv/CPK38lpbrcx+rPnXyd5
 Vvu5KiXtMILPBTz4M0wSNuUfjGtvYvud86OcFKEc8AgWHKs7S8OoxaoRWr2CE+bH
 L4wMUQIsafT0iZEe/PoNl8HwfaNWbf1/5qjhW6oD+DVc0ssbWEdOwDTzwb0rgsK0
 LSgxX+j/qlP57mS5b2CRot18C7meep4EvHcQII2JtHnbY7dgzuqENTI5utTj/q9c
 MtwUNWOlSFUpuu4tMiPf9C29hOoQfWsaW+r9yrsO84Yl+U04TYT9
 =84Fb
 -----END PGP SIGNATURE-----

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

Newly added boards are the PX30 SOM system from Engicam and Kobol Helios64.
The Scarlet tablet finally gets support for its cameras, now that the
the rk3399-isp moved out of staging.
The Odroid-Go-Advance got its joystick support now that the adc-joystick
driver was merged and misc omprovements to the RockPi4, rk3328-roc-cc
and orange-pi.

* tag 'v5.11-rockchip-dts64-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip: (28 commits)
  arm64: dts: rockchip: use USB host by default on rk3399-rock-pi-4
  arm64: dts: rockchip: fix I2S conflict on rk3399-rock-pi-4
  arm64: dts: rockchip: fix supplies on rk3399-rock-pi-4
  arm64: dts: rockchip: Fix UART pull-ups on rk3328
  arm64: dts: rockchip: add isp and sensors for Scarlet
  arm64: dts: rockchip: add isp0 node for rk3399
  arm64: dts: rockchip: Properly define the type C connector on rk3399-orangepi
  arm64: dts: rockchip: Add BT support on px30-engicam
  arm64: dts: rockchip: Add WiFi support on px30-engicam
  arm64: dts: rockchip: Add Engicam PX30.Core C.TOUCH 2.0 10.1" OF
  dt-bindings: arm: rockchip: Add Engicam PX30.Core C.TOUCH 2.0 10.1" OF
  arm64: dts: rockchip: Enable LVDS panel on px30-engicam-edimm2.2
  arm64: dts: rockchip: Enable USB Host, OTG on px30-enagicam
  arm64: dts: rockchip: rename sdhci nodename to mmc on rk3399
  arm64: dts: rockchip: Enable analog audio on rk3328-roc-cc
  arm64: dts: rockchip: Enable HDMI audio on rk3328-roc-cc
  arm64: dts: rockchip: Set dr_mode to "host" for OTG on rk3328-roc-cc
  arm64: dts: rockchip: Add Engicam PX30.Core C.TOUCH 2.0
  arm64: dts: rockchip: Add Engicam C.TOUCH 2.0
  dt-bindings: arm: rockchip: Add Engicam PX30.Core C.TOUCH 2.0
  ...

Link: https://lore.kernel.org/r/4278011.LvFx2qVVIh@phil
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-09 00:03:14 +01:00
Arnd Bergmann
49d47bf9f5 i.MX arm64 device tree changes for 5.11:
- New board support: LX2162A QDS, Kontron i.MX8M Mini SoMs and
   baseboards.
 - A number of patches from Adam Ford to add various audio devices for
   i.MX8MM/MN and update imx8mm-beacon-som board on QSPI NOR and RTC.
 - Correct WDOG_B pin configuration for i.MX8MM/MN/MP.
 - A series from Ioana Ciornei complete the MAC/PCS/PHY representation
   on DPAA2 devices.
 - Add PMU device for i.MX8MP/MN.
 - Add IR and CAN support for i.MX8MP/MN/MM EVK board.
 - Adjust GIC CPU mask to match number of CPUs for i.MX8MP/MN/MM.
 - A series of patch from Michael Walle to update LS1028A support with
   addition of CAN and OPTEE, also ENETC PTP and FlexSPI clock input
   correction.
 - Add SPDIF sound card support on imx8mq-evk board.
 - Misc random updates and device additions.
 -----BEGIN PGP SIGNATURE-----
 
 iQFIBAABCgAyFiEEFmJXigPl4LoGSz08UFdYWoewfM4FAl/HoBgUHHNoYXduZ3Vv
 QGtlcm5lbC5vcmcACgkQUFdYWoewfM5KUQf8Dby60Z9z0QtFSzjGNr9MaHMerP7/
 9qtngN9PTUTjdAviCCg8tORU9+knjnRe/gOTjIbeWWHUTsG6sKNFBrEtqoCCT7Sz
 RUm+cdYcg2FEiIV5p4xwCbrvKt3ISLud6qyTk3HkTkknUNDZfhuv3QPPSrH8Zc0l
 526D6gkHJW9DqHt8XFHT4l3OJNHN7QAw/z16dVueseons+Uhz3eUxG9keUpQhH6F
 mBoqfTkMx2JtHnsdG/8V1BFbc2Kry7HhZkK+96wb+LoZ0TtK7h7SR6iFoVFu3dnB
 ugDmkzG8TPzjAt9oSGy9+vgNXqIZwpRa+DiXvjWuaAoaI9/c3QDsWmS44g==
 =asj6
 -----END PGP SIGNATURE-----

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

i.MX arm64 device tree changes for 5.11:

- New board support: LX2162A QDS, Kontron i.MX8M Mini SoMs and
  baseboards.
- A number of patches from Adam Ford to add various audio devices for
  i.MX8MM/MN and update imx8mm-beacon-som board on QSPI NOR and RTC.
- Correct WDOG_B pin configuration for i.MX8MM/MN/MP.
- A series from Ioana Ciornei complete the MAC/PCS/PHY representation
  on DPAA2 devices.
- Add PMU device for i.MX8MP/MN.
- Add IR and CAN support for i.MX8MP/MN/MM EVK board.
- Adjust GIC CPU mask to match number of CPUs for i.MX8MP/MN/MM.
- A series of patch from Michael Walle to update LS1028A support with
  addition of CAN and OPTEE, also ENETC PTP and FlexSPI clock input
  correction.
- Add SPDIF sound card support on imx8mq-evk board.
- Misc random updates and device additions.

* tag 'imx-dt64-5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux: (50 commits)
  arm64: dts: imx8mm-beacon-som: Assign PMIC clock
  arm64: dts: imx8mm-beacon-som: Configure RTC aliases
  arm64: dts: imx8mn: Add node for SPDIF
  arm64: dts: imx8mn: Add support for micfil
  arm64: dts: imx8mn: Add SAI nodes
  arm64: dts: imx8mn: Enable Asynchronous Sample Rate Converter
  arm64: dts: ls1028a: make the eMMC and SD card controllers use fixed indices
  arm64: dts: freescale: update calibration table for TMU module
  arm64: dts: freescale: sl28: combine SPI MTD partitions
  arm64: dts: ls1028a: add optee node
  arm64: dts: ls1028a: fix FlexSPI clock input
  arm64: dts: ls1028a: fix ENETC PTP clock input
  arm64: dts: imx: Fix imx8mm-kontron-n801x-s.dtb target
  arm64: dts: imx8mn-evk: add IR support
  arm64: dts: imx8mm-evk: add IR support
  arm64: dts: imx8mq-evk: add linux,autosuspend-period property for IR
  arm64: dts: imx8mp-evk: add CAN support
  arm64: dts: imx8mq-evk: Add spdif sound card support
  arm64: dts: imx8mq: Configure clock rate for audio plls
  arm64: dts: layerscape: Add PCIe EP node for ls1088a
  ...

Link: https://lore.kernel.org/r/20201202142717.9262-5-shawnguo@kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-09 00:00:23 +01:00
Arnd Bergmann
1e3e7ca547 arm64: dts: amlogic updates for v5.11
- AXG SoCs: add/enable PCIe & USB OTG support
 - AXG SoCs: add MIPI DSI support
 - Khadas VIM: add RTC
 - several cleanups & fixups
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEe4dGDhaSf6n1v/EMWTcYmtP7xmUFAl/GxC4ACgkQWTcYmtP7
 xmUbdA/+IA2JJZg9q2u0xJmePsft6QTwLqIiDRp970jfooVSLqSPz7xYhdlWiXR5
 Gxzyv6Kyd0Nw/G16Ffl6sPs30/lMI8OYsR/imOqc8SYTRvUE/4gy0xXEd8aLWSU4
 2g4B8k985WIEeRNz/788SoGvtpA+zXMmS7EHNczoyQaihfywE56fYaM/TjT+pi+a
 prrCxdiRCX8DGOjB6ynR8efQyguUxRhOKx5sJZnaymY5NhaYl0ZUjRNR8iqhkFj0
 SLSGghTal5PcweVSDWMuZbtxaCtf6v3dnZ9ohzS0w25U7xnNoVVQX/OMjA19ZLDt
 SX2QcS5fCr1BcTfSxsw8zXrbPAqGlrb1PlWdf9uneHf02ze38P7FZSQFhyjzM+1v
 L9aZgSbvg4jJ/H/p8HFyxuf3ynQMzadRkhcfGo5sUfGWDgwG6189tNjpTPD3BSub
 CguzUOSuIfml/8KnS0S5aI0NCXyESprHfNwZQyvz6FdgXxdtF38twwKgpmUHUoxA
 uw5bzpJgrpF7PM9OpmP/yCfETj4EQ++hQyosJNeAweIrt+VIkQ/OW4SZ5dBrwB3k
 R0rCU80E5gpNBrmmY7AvbjCv91DH2xzxz7/w2FZmt5vs5KBxRCPnCkeRwor0n+sT
 asQ0YMUoMnJqCbay8ditaARhCvNQCfNe8w+KDrr2MqnCi/PLYLw=
 =XtmV
 -----END PGP SIGNATURE-----

Merge tag 'amlogic-dt64' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-amlogic into arm/dt

arm64: dts: amlogic updates for v5.11
- AXG SoCs: add/enable PCIe & USB OTG support
- AXG SoCs: add MIPI DSI support
- Khadas VIM: add RTC
- several cleanups & fixups

* tag 'amlogic-dt64' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-amlogic:
  arm64: dts: meson-sm1: fix typo in opp table
  arm64: dts: meson: add KHAMSIN IR remote node to SML5442TW
  arm64: dts: meson: update the Khadas VIM3/3L LED bindings
  arm64: dts: meson: fix spi-max-frequency on Khadas VIM2
  arm64: dts: meson: add rtc aliases to meson-khadas-vim3.dtsi
  arm64: dts: meson: Add capacity-dmips-mhz attributes to GXM
  arm64: dts: meson-axg-s400: enable PCIe M.2 Key E slots
  arm64: dts: meson-axg: add PCIe nodes
  arm64: dts: meson-axg: add MIPI DSI PHY nodes
  arm64: dts: meson-axg: add PWRC node
  arm64: dts: meson: enable rtc node on Khadas VIM1/VIM2 boards
  dt-bindings: clk: axg-clkc: add MIPI DSI Host clock binding
  dt-bindings: clk: axg-clkc: add Video Clocks
  arm64: dts: meson: add watchdog to g12-common dtsi
  arm64: dts: meson: remove empty lines from aml-s905x-cc v2 dts

Link: https://lore.kernel.org/r/7heek9jgox.fsf@baylibre.com
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 23:56:07 +01:00
Arnd Bergmann
96631a0d11 Samsung DTS ARM64 changes for v5.11
1. Several cleanups, including aligning node names with dtschema.
 2. Add WiFi/PCIe to TM2 boards (Exynos5433).
 3. Correct restart and shutdown of Exynos7 boards, as part of Paweł
    Chmiel Exynos7420 mainlining effort.
 -----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCgAuFiEE3dJiKD0RGyM7briowTdm5oaLg9cFAl/GqikQHGtyemtAa2Vy
 bmVsLm9yZwAKCRDBN2bmhouD14LnD/9YevUbxVHz0k9Whgb/uWNuai4uH8nbbm3i
 Iw97MTQA/QoVlbblm8hTo83UOL5zWy0zfQhslNFJ46BrxXi79oNS5CCVWvS9mYtv
 9BPjT93CAsdc8iVwd8DAampW/eghvd7KpApg8pgmvon8kXFwpqcXjN11SQ/jDpwv
 7/87RF8bvaIRW8NZBoxD/qWkqgYKK+Gb8UhZMDtpI2UWt+mW9O6efuBqgL9nDvQh
 9+5nQM3BBOWKee1Xnsmka6iuRQZpO2I+JqRk1iAVQdFx6QJ2mnfwQJK7nLlnR6Ff
 h4t0TbmEn4jqDtH7ZiQa7B4fYWK4BtnBi1aAwvlJewwaxDrjJdmDHHQgTXd5zeUx
 L4FeOM5u0stGb+610omuFvPzPAE+1B5upoEoga2qMhI8pnWkpEidGXe+LhU4//wE
 vS5wRqBzC6Mv+qUf5qV3iUOmzZhvMaWqMvQ1PaKSPOhDuE1yBrkcda0dd2kYcaK7
 nfLOTXaqRhBTdEt0NRevzeq1+xKMr3gTN7neg1rPNXNGzqyPRyAPlVU8mm9nYnHA
 sKaIlZJ7PaUizN5MMQZFJVZ3nSEU+VXYRaP4GGK5JSfDpgw5MwTXY2SlKGBBokG8
 AIQFJycH4sJx6/udueC2IRIdZEslJxTGvSnimL2rHuxgKxbnHtYIugvZvgOF17Iw
 tsFR2mG4rQ==
 =sxn6
 -----END PGP SIGNATURE-----

Merge tag 'samsung-dt64-5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux into arm/dt

Samsung DTS ARM64 changes for v5.11

1. Several cleanups, including aligning node names with dtschema.
2. Add WiFi/PCIe to TM2 boards (Exynos5433).
3. Correct restart and shutdown of Exynos7 boards, as part of Paweł
   Chmiel Exynos7420 mainlining effort.

* tag 'samsung-dt64-5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux:
  arm64: dts: exynos: Drop incorrect use of io-channel-ranges property
  arm64: dts: exynos: use hyphens in Exynos5433 node names
  arm64: dts: exynos: Correct psci compatible used on Exynos7
  arm64: dts: exynos: Include common syscon restart/poweroff for Exynos7
  arm64: dts: exynos: add the WiFi/PCIe support to TM2(e) boards
  arm64: dts: exynos: remove redundant status=okay in Exynos5433 TM2
  arm64: dts: exynos: adjust node names to DT spec in Exynos7 Espresso
  arm64: dts: exynos: adjust node names to DT spec in Exynos5433 TM2
  arm64: dts: exynos: Harmonize DWC USB3 DT nodes name

Link: https://lore.kernel.org/r/20201201204404.22675-3-krzk@kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 23:55:32 +01:00
Arnd Bergmann
6ce23595b5 Qualcomm DT updates for 5.11
This adds support for SD card, WiFi, LED, touchscreeni, touchkey and
 fuel gauge to the Samsung Galaxy S5. Nexus 5 also gains fuel gauge
 support.
 
 Finally IPQ6016 gains support for the QPIC NAND controller.
 -----BEGIN PGP SIGNATURE-----
 
 iQJPBAABCAA5FiEEBd4DzF816k8JZtUlCx85Pw2ZrcUFAl/FP/0bHGJqb3JuLmFu
 ZGVyc3NvbkBsaW5hcm8ub3JnAAoJEAsfOT8Nma3FGD0P/izpx+KKodHihjPWuKXk
 cPWMwkbARIB2XfkrsATT02jFBy579k4G2XETWlZwk4697gXXIf26TmJMOmlivWk4
 7ESdmOh4oplJyKcIr0TED/lpRkEx5it5jOhVQMTqOaQOJ5R95x2aoXq3CZnwfZI2
 EPSq+sfpws72PhlalDZIKPpwSbfu4XtSBErecsbJOShQJ1nvZgYC/++PLR7LFNM6
 t701MlWljlY7twYIlfeeyrcTZ8oI/j8s1Zt8AkINAwIbxv2x1m1Grf8k05a8Kez2
 oRZQEdC03lvck17YOAXw3GxWAnzFqSQ8OSyldg3eJZA2Ze3wLfG0Agq5zq55fT1X
 1wHeE9+ygD7gxXgo6HVCaTGttuP47rDWFT/6Lj9Qf+qZnYKDhThrFALxmxgZyFZV
 Y3QFrk021RyfOTaWIyVZ4PmJTQu/PoTY7IAKUM7GXf2obgxx5stjSC++r3Hue1uX
 EDAb+5hhV7weVu9XaOakXt6YufPrChZl9G8NcK27bnvUIy2LQsB8n7ah33AlMsh7
 cPI/JyDcwkKDtf+JXSZ5W0oX5y0zDC8MWrF0D0TFEfykYyvwsVYX2u0U0ntqMBnz
 ZpFVE9gPaY61+AVOsJf2TV25wuLa5GfNCibnKHqeWyYJaR4jJX3Sux8gkYK9GF3c
 vOqRnWSM1apriVDN+JVFS+WF
 =J3Nk
 -----END PGP SIGNATURE-----

Merge tag 'qcom-dts-for-5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux into arm/dt

Qualcomm DT updates for 5.11

This adds support for SD card, WiFi, LED, touchscreeni, touchkey and
fuel gauge to the Samsung Galaxy S5. Nexus 5 also gains fuel gauge
support.

Finally IPQ6016 gains support for the QPIC NAND controller.

* tag 'qcom-dts-for-5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux:
  arm64: dts: ipq6018: Add the QPIC peripheral nodes
  ARM: dts: qcom-pma8084: Drop incorrect use of io-channel-ranges
  ARM: dts: qcom: msm8974-lge-nexus5: Add fuel gauge
  ARM: dts: qcom: msm8974-klte: Add fuel gauge
  ARM: dts: qcom: msm8974-klte: Add support for SD card
  ARM: dts: qcom: msm8974-klte: Add support for wifi
  ARM: dts: qcom: msm8974-klte: Add gpio expander chip
  ARM: dts: qcom: msm8974-klte: Add support for led
  ARM: dts: qcom: msm8974-klte: Add support for touchscreen
  ARM: dts: qcom: msm8974-klte: Add support for touchkey
  ARM: dts: qcom: msm8974-klte: Merge pinctrl nodes

Link: https://lore.kernel.org/r/20201130190148.345302-1-bjorn.andersson@linaro.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 23:51:52 +01:00
Arnd Bergmann
a39d2ef78d Qualcomm ARM64 DT updates for 5.11
For SM8250 the recently introduced support for handling boot-loader
 stream mappings in the ARM SMMU allow us to enable this, and thereby USB
 controller and PHY, SDHCI controller and FastRPC, as well as support for
 the SM8250 HDK board has been added. Additionally PRNG and RTC is
 enabled.
 
 Similarly for SM8150, the ARM SMMU could be added which allows the
 secondary USB controller and PHYs, as well as WiFi to be added and
 support for the SM8150 HDK board to be introduced. Additionally
 Coresight and support for the last-level cache controller was added.
 
 MSM8916 finally has VDDCX and VDDMX removed as regulators and are now
 handled by the rpmpd driver for the devices controlling them. The
 Longsheer L8150 gains touchscreen, sensors, vibrator and LED support.
 
 MSM8992 gains USB and SDHCI support as well as an I2C controller and the
 associated RMI4 based touchscreen for the Lumia 950.
 
 MSM8994 also gains USB and SDHCI support, as well as VADC and temp-alarm
 support. Then support for the Lumia 950 XL is added.
 
 SDM845 gains interconnect properties for a number of devices and the
 GENI wrappers gains iommu stream configuration, which means DMA
 operations on e.g. I2C now works. The Lenovo Yoga C630 finally has the
 SMMU enabled, a few fixes and the description of the eDP bridge and
 panel means that the laptop can now boot mainline with working display,
 GPU, WiFi and audio.
 
 SC7180 gains a slew of smaller improvements and fixes.
 -----BEGIN PGP SIGNATURE-----
 
 iQJPBAABCAA5FiEEBd4DzF816k8JZtUlCx85Pw2ZrcUFAl/FP0cbHGJqb3JuLmFu
 ZGVyc3NvbkBsaW5hcm8ub3JnAAoJEAsfOT8Nma3FINAP/11hbDNRXJ+3oqLk53aD
 /8G0Xbyzy9gekpYURZwJJrjaGY7l1psM39Kbo+flUPusFfxRBNmbWrw57PPbzjyS
 d3RnPXuc/XDkOvCHtQstowtdKBl5EIXU6ec9xg4RY5bZUiD5Fpk8OLBAitvruEqy
 6YCgMhy5yRspb8iBXA5N4ERU0EsQBOMIIoP6DRuGkeMkUhk/QllO+xwAr6ugI3Ot
 s3gua4tjWfi5kxT0bXklU4fk7Xeiuy6VL+giddd4dWVUm2GdO7jRlU6ae6CLoi2k
 PStZJcca8uOpTMpF4ZqMLNX51UAk+VZsCvjMm5pYIQAWCp15sWyMA20wi8vM+cjx
 HHhsXU7WAqQfLzMntgUd36CJaTuGw8J+QzQyNpQeHjbL6tAA15BfnIIQ+RUZWgsx
 XoPWdSvmUBhyo9g2cR7yXRXQGxvMRy/w7uHgv6Szb9KkDxeBnpYMjBMrbaZAsyMA
 YoYvhdIO9HkL2IbUxQgiszQsD58aDvauEY+KpOZclVW5ODPhJmsSTZK2aH/L6kj9
 6hn0rOBrXy8rZE5Vs08C5D2WvqZ0Ib45vXNpb9uucvyXXNZMywGw+94B3YMNbkCz
 /C9C1DJcRX1NZjJnQco3Cn0Ni7AmRzD5aAHi3n2BhxbsxOxZ6v0SjEDbce+lXwYJ
 5l4AcPSLDjGXFJsbUPQrHvJF
 =lkn4
 -----END PGP SIGNATURE-----

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

Qualcomm ARM64 DT updates for 5.11

For SM8250 the recently introduced support for handling boot-loader
stream mappings in the ARM SMMU allow us to enable this, and thereby USB
controller and PHY, SDHCI controller and FastRPC, as well as support for
the SM8250 HDK board has been added. Additionally PRNG and RTC is
enabled.

Similarly for SM8150, the ARM SMMU could be added which allows the
secondary USB controller and PHYs, as well as WiFi to be added and
support for the SM8150 HDK board to be introduced. Additionally
Coresight and support for the last-level cache controller was added.

MSM8916 finally has VDDCX and VDDMX removed as regulators and are now
handled by the rpmpd driver for the devices controlling them. The
Longsheer L8150 gains touchscreen, sensors, vibrator and LED support.

MSM8992 gains USB and SDHCI support as well as an I2C controller and the
associated RMI4 based touchscreen for the Lumia 950.

MSM8994 also gains USB and SDHCI support, as well as VADC and temp-alarm
support. Then support for the Lumia 950 XL is added.

SDM845 gains interconnect properties for a number of devices and the
GENI wrappers gains iommu stream configuration, which means DMA
operations on e.g. I2C now works. The Lenovo Yoga C630 finally has the
SMMU enabled, a few fixes and the description of the eDP bridge and
panel means that the laptop can now boot mainline with working display,
GPU, WiFi and audio.

SC7180 gains a slew of smaller improvements and fixes.

* tag 'qcom-arm64-for-5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux: (93 commits)
  arm64: dts: qcom: c630: Define eDP bridge and panel
  arm64: dts: qcom: c630: Fix pinctrl pins properties
  arm64: dts: qcom: c630: Polish i2c-hid devices
  arm64: dts: qcom: sc7180: Add lpass cpu node for I2S driver
  arm64: dts: sdm845: Add interconnect properties for QUP
  interconnect: qcom: sdm845: Add the missing nodes for QUP
  dt-bindings: interconnect: sdm845: Add IDs for the QUP ports
  arm64: dts: qcom: c630: Expose LID events
  arm64: dts: qcom: c630: Re-enable apps_smmu
  dts: qcom: sdm845: Add dt entries to support crypto engine.
  arm64: dts: qcom: qrb5165-rb5: Add support for MCP2518FD
  arm64: dts: qcom: sdm845: use GIC_SPI for IPA interrupts
  arm64: dts: qcom: sc7180: use GIC_SPI for IPA interrupts
  arm64: dts: qcom: sc7180: limit IPA iommu streams
  arm64: dts: qcom: sm8150: Add Coresight support
  arm64: dts: qcom: sc7180-trogdor: Make pp3300_a the default supply for pp3300_hub
  arm64: dts: qcom: sc7180: Add DDR/L3 votes for the pro variant
  arm64: dts: qcom: sc7180-lite: Tweak DDR/L3 scaling on SC7180-lite
  arm64: dts: qcom: sc7180-trogdor: add "pen-insert" label for trogdor
  arm64: qcom: sc7180: trogdor: Add ADC nodes and thermal zone for charger thermistor
  ...

Link: https://lore.kernel.org/r/20201130190131.345187-1-bjorn.andersson@linaro.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 23:50:08 +01:00
Arnd Bergmann
e40917e466 Devicetree changes for TI K3 platforms for v5.11 merge window:
- Standardized usage of "disabled" only in board.dts files, #interrupt-cells warning fixups, node format error fixes
 
 - J721E: R5F support, MMC/SD UHS mode added
 
 - AM654: R5F support, dss marked coherent, drop unused dma-ring-reset-quirk property
 
 - J7200: ADC support, Mailbox, hwspinlock
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEE+KKGk1TrgjIXoxo03bWEnRc2JJ0FAl/FKtUACgkQ3bWEnRc2
 JJ2SaBAArDEu+ulsXnB9jsTW6OUP2f184AM2LPQYcv0SZRF6e51NXbpY2slbkAgm
 2Vn29bz5EnDMoO0J9ONOhrC52PJ1KVmGJnJukK7fGdqQujXjbuCignziRsuSlMXX
 hDRL52oY0BPI9MQN7ueQAOe2RKPPsL5OHRi5SssFwMZ2P9RArQ4/eP9hQ4gfcsAh
 XmW8Z8OIEEV0QQujQjhPTYJWy7ujU/FSiOHF7GtDcGx0scuvv7NkGzqHIpsKqx8+
 Jfd3hc7qxTvfrHppYNyoUXnc6axzEWPDDpHqZ2umpffxXh46sBQ+fjMDBg+d7R1d
 79J+WbnPFZucIbpOuy92/8fVlnZfHv4s1ymAi3bC4RriRfo8aHhhtFqR+VSSWlH1
 UCYIn7ddiqo854jys4eclUaKRRRDUqH/BPQyKZQN6KmDjhA+mctz3Ih5hUtpm7Xd
 cV5MS8ltNatSU98Yfne3ubKbUdw3NAIOdwp2lwattAc1TIx3RCB79Lv1X2rRU4Oy
 4qUOlhLDuewioFo1m9vwfZi5qqw7kImfyXXix4gmLxsnIp3Og7IpvdbIGZK+ctej
 Lp9Qa6XZx+2ddhB28RnTmguhNFAfsi9W7c/ZrXd0TeZdClB0FwV+tX/APssEWpQv
 19fMF1/Ps/WznQsimS4JVB1MNzh1y6z5nvWGEjdoLQBsvQa3Xqo=
 =Alsn
 -----END PGP SIGNATURE-----

Merge tag 'ti-k3-dt-for-v5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/nmenon/linux into arm/dt

Devicetree changes for TI K3 platforms for v5.11 merge window:

- Standardized usage of "disabled" only in board.dts files, #interrupt-cells warning fixups, node format error fixes

- J721E: R5F support, MMC/SD UHS mode added

- AM654: R5F support, dss marked coherent, drop unused dma-ring-reset-quirk property

- J7200: ADC support, Mailbox, hwspinlock

* tag 'ti-k3-dt-for-v5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/nmenon/linux: (25 commits)
  arm64: dts: ti: k3-j721e-common-proc-board: Add support for SD card UHS modes
  arm64: dts: ti: k3-j721e-main: Add output tap delay values
  arm64: dts: ti: k3: squelch warning about lack of #interrupt-cells
  arm64: dts: ti: k3-j7200-common-proc-board: Correct the name of io expander on main_i2c1
  arm64: dts: ti: k3-j7200-som-p0: main_i2c0 have an ioexpander on the SOM
  arm64: dts: ti: k3-j7200-som-p0: Add IPC sub-mailbox nodes
  arm64: dts: ti: k3-j7200-main: Add mailbox cluster nodes
  arm64: dts: ti: k3-j7200-main: Add hwspinlock node
  arm64: dts: ti: am65/j721e/j7200: Mark firmware used uart as "reserved"
  arm64: dts: ti: k3-am654-base-board: Fix up un-necessary status set to "okay" for USB
  arm64: dts: ti: am65/j721e: Fix up un-necessary status set to "okay" for crypto
  arm64: dts: ti: k3-j721e*: Cleanup disabled nodes at SoC dtsi level
  arm64: dts: ti: k3-am65*: Cleanup disabled nodes at SoC dtsi level
  arm64: dts: ti: k3-j7200-mcu-wakeup: Enable ADC support
  arm64: dts: ti: k3-am65*/j721e*: Fix unit address format error for dss node
  arm64: dts: ti: k3-j721e-som-p0: Add DDR carveout memory nodes for R5Fs
  arm64: dts: ti: k3-j721e-som-p0: Add mailboxes to R5Fs
  arm64: dts: ti: k3-j721e-main: Add MAIN domain R5F cluster nodes
  arm64: dts: ti: k3-j721e-mcu: Add MCU domain R5F cluster node
  arm64: dts: ti: k3-am654-base-board: Reserve memory for IPC between R5F cores
  ...

Link: https://lore.kernel.org/r/20201130174258.ljsiokkyr7x7tsbd@covenant
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 23:47:05 +01:00
Arnd Bergmann
a2f9886a9e mvebu dt64 for 5.11 (part 1)
- Add support for IEI Puzzle-M801 board (Armada 8040 based)
  - Add support ESPRESSObin-Ultra (Armada 3720 based)
  - Clean-up and improve espressobin device tree
  - Switch to per-port SATA interrupts on CP110 based SoC
  - Use compliant node name for USB3  on CP110 based SoC
  - Add heartbeat LED on mcbin singleshot
  - Disable SMMU by default for Armada 7040 and 8040 to continued
    supporting custom bot firmware
  - Turris mox:
    - add 3W power capability to SFP cage
    - update ethernet-phy handle name
 -----BEGIN PGP SIGNATURE-----
 
 iF0EABECAB0WIQQYqXDMF3cvSLY+g9cLBhiOFHI71QUCX8UWegAKCRALBhiOFHI7
 1c5BAJ4ilmwKGPP5eFE+fCfEjzxvskL3mQCdFKOIraWngVbX+GCAZ2UhZfYT6cA=
 =G+GT
 -----END PGP SIGNATURE-----

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

mvebu dt64 for 5.11 (part 1)

 - Add support for IEI Puzzle-M801 board (Armada 8040 based)
 - Add support ESPRESSObin-Ultra (Armada 3720 based)
 - Clean-up and improve espressobin device tree
 - Switch to per-port SATA interrupts on CP110 based SoC
 - Use compliant node name for USB3  on CP110 based SoC
 - Add heartbeat LED on mcbin singleshot
 - Disable SMMU by default for Armada 7040 and 8040 to continued
   supporting custom bot firmware
 - Turris mox:
   - add 3W power capability to SFP cage
   - update ethernet-phy handle name

* tag 'mvebu-dt64-5.11-1' of git://git.kernel.org/pub/scm/linux/kernel/git/gclement/mvebu:
  arm64: dts: armada-3720-turris-mox: add 3W power capability to SFP cage
  arm64: dts: marvell: keep SMMU disabled by default for Armada 7040 and 8040
  arm64: dts: mcbin-singleshot: add heartbeat LED
  arm64: dts: marvell: cp11x: Harmonize xHCI DT nodes name
  arm64: dts: marvell: espressobin: Update link to V7 schematic
  arm64: dts: armada-3720-turris-mox: update ethernet-phy handle name
  arm64: dts: marvell: armada-cp110: Switch to per-port SATA interrupts
  arm64: dts: marvell: add DT for ESPRESSObin-Ultra
  arm64: dts: marvell: espressobin: Add support for LED2
  arm64: dts: marvell: Add a device tree for the IEI Puzzle-M801 board
  arm64: dts: marvell: espressobin: De-duplicate eMMC definitions
  arm64: dts: marvell: espressobin: Get rid of duplicate serial aliases
  arm64: dts: marvell: espressobin: Simplify v7 ethernet port labeling

Link: https://lore.kernel.org/r/87eekaj0i4.fsf@BL-laptop
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 23:45:59 +01:00
Arnd Bergmann
5161540797 mt8173:
- add new power domain controller node
 
 mt8183:
 - add new power domain controller
 - add display, iommu and dsi nodes
 
 mt8192:
 - add basic support, pinctrl, uart, spi, i2c and timer
 
 mt8516:
 - add auxadc, efuse and usb nodes
 
 mt8167:
 - add basic support for the SoC
 - add support for the pumkin board
 
 mt6779:
 - add initial support, interrupt controller, clocks, uart
 
 mt7622:
 -  PWM node for all available PWM channels
 -----BEGIN PGP SIGNATURE-----
 
 iQJLBAABCAA1FiEEUdvKHhzqrUYPB/u8L21+TfbCqH4FAl/EC2oXHG1hdHRoaWFz
 LmJnZ0BnbWFpbC5jb20ACgkQL21+TfbCqH6e9BAAkG3psWVaYuiHUnlEbIvIWFPx
 pCS7KV0J5kXe3F/oEAlQWDHiipAEVMyr9ABXnALfwjoqy7hAV6g775COLfZMR/ia
 oxBtYWKbKE3/6LSLr6F9l4bJKvox/qpd7hWCkDW3/2xZ2zzZLZo7BPU0o6kHXQAr
 ZdgtFx9Fxy1q2BIo/GP7wXmSt6dl+O9XTGAt/Hx3U2jQ5PMrQDblICbiEYFLSotR
 I58Nw7vKDrQ6bFQfXSOza5FjNoGswzB8wEzi3etEcSsYvinwhuTkqhVAs7kYgxqJ
 mp93ydrM2hsTy71p4kEA7uNaGKIrBPkzLVmwt3tWZ7nh/BE6IXt6hIWIUgHX4igL
 e31BG7u3IkYAwFMV9XJ5KZL37oQwF5UytrrwLIxN+dmozcfF1nd/r0VxJQkmfQ00
 DUQvqhPUKAGJDgFNK5f+Kh3A+8JIkZpxN6GxqUdKitlgA1hUTbafaVXKG0fcADsu
 8wRO6+JA0/pL36QU+3zPrLC6FinZGoPa9lWCdP0YmXOLTw3BGoa9nwkvwIMvcw2X
 3aKIOBWglxds3XYVMP+bWrWV3sat1vFIh03lK/gbhci2h2WFdpDfZ+wFu7Y2WNAf
 DQP45UkGI/sN+1MpDWfpK/oxVWMwxCNoEtOhHCDXBMh/6ysjmrRTbm1vqLLaNYQP
 WYzIYR/BaYpJQUz+xUM=
 =DU+G
 -----END PGP SIGNATURE-----

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

mt8173:
- add new power domain controller node

mt8183:
- add new power domain controller
- add display, iommu and dsi nodes

mt8192:
- add basic support, pinctrl, uart, spi, i2c and timer

mt8516:
- add auxadc, efuse and usb nodes

mt8167:
- add basic support for the SoC
- add support for the pumkin board

mt6779:
- add initial support, interrupt controller, clocks, uart

mt7622:
-  PWM node for all available PWM channels

* tag 'v5.10-next-dts64' of git://git.kernel.org/pub/scm/linux/kernel/git/matthias.bgg/linux: (25 commits)
  dts64: mt7622: disable spi1 and uart2 because pins are used by pwm
  dts64: mt7622: enable all pwm for bananapi r64
  arm64: dts: mt8183: Add display nodes for MT8183
  arm64: dts: mt8183: Add iommu and larb nodes
  arm64: dts: mt8183: Add dsi node
  arm64: dts: mt8183: Add pwm and backlight node
  arm64: dts: mediatek: Add mt8183 power domains controller
  arm64: dts: mediatek: Add smi_common node for MT8183
  arm64: dts: mediatek: Add mt8173 power domain controller
  dt-bindings: power: Add MT8192 power domains
  dt-bindings: power: Add MT8183 power domains
  dt-bindings: power: Add bindings for the Mediatek SCPSYS power domains controller
  arm64: dts: Add Mediatek SoC MT8192 and evaluation board dts and Makefile
  arm64: dts: mediatek: add MT8167 pumpkin board dts
  arm64: dts: mediatek: add dtsi for MT8167
  dt-bindings: arm64: dts: mediatek: Add mt8167-pumpkin board
  arm64: dts: mediatek: mt8516: add efuse node
  arm64: dts: mediatek: align GPIO hog names with dtschema
  arm64: dts: mediatek: mt8516: add usb1 node
  arm64: dts: mediatek: mt8516: rename usb phy
  ...

Link: https://lore.kernel.org/r/72fe1c4f-f27c-c455-dfd9-66bde90bb295@gmail.com
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 23:38:36 +01:00
Arnd Bergmann
1c202d0c5a This pull request contains Broadcom ARM64-based SoCs Device Tree changes
for 5.11, please pull the following:
 
 - Rafal adds initial support for the Broadcom 4908 which are SoCs used
   in home routers and are based on the DSL architecture and using
   Broadcom Brahma-B53 CPUs.
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEm+Rq3+YGJdiR9yuFh9CWnEQHBwQFAl/Ce8YACgkQh9CWnEQH
 BwQnhw/9GQHgXy+ZSI5a8mak8eUzK/dwrtdMvtCuERLK6sMvTBJSmuejYoWwzF27
 e+t0rm40Ly2JhxfBdrx6Y/uWxAvXUgFE5Wd//ukY8+G9rHDDvY2KtYxb9V0wjM7L
 4ye0ghYtK1snZRWa5DBNyn4b8UPOCETGqysOQ3hUlSzIL4zzY2OjAXarKAfv4lHJ
 Qj5zRYj0I+KMHBNLa0nryz2fLy3HGVevAMapJ6Sm/sL4feLTX7FkhT9GLpTQXGk6
 9ou3g5ywOZ2P8ic1wldxuPCMGsTYu53MVpRmnuDec68PzGYTfYrd3zyDcTQEh8am
 UtGV/Wo7HwTdGR1KDUEgIbEbf5bSm+vaohEwc/XLziQMf9cCJ+cIushaWb2r/IY4
 EDWD9nYN9z+kJe+05wtWZ4JeXQjL0lajVSpTTSn4oAVcoEl7ixLepqY2uDRl7jFl
 iJhyzvuJOinxJ8Ggs6S0eYgAVrIEZNUrsT6J9MrumXrcAJQPoBMppEPdWeIPkWMn
 hlfWDn7MyWil1+PeCnB9VCgtTq1XlAHzcXXHzdZqJhdHQwi200NmJioEC/M2dJ2Q
 EG/jAmytRJ5N9KFwqTnuVwn581FUdgxDxmTyXw2pr6hafqOou4APqDwmJw8QcBcf
 QLsIJ+3iPyPT52P4zymTKEN22YD768JrRWa1pItAGObzGitlUBE=
 =oz5b
 -----END PGP SIGNATURE-----

Merge tag 'arm-soc/for-5.11/devicetree-arm64' of https://github.com/Broadcom/stblinux into arm/dt

This pull request contains Broadcom ARM64-based SoCs Device Tree changes
for 5.11, please pull the following:

- Rafal adds initial support for the Broadcom 4908 which are SoCs used
  in home routers and are based on the DSL architecture and using
  Broadcom Brahma-B53 CPUs.

* tag 'arm-soc/for-5.11/devicetree-arm64' of https://github.com/Broadcom/stblinux:
  arm64: add config for Broadcom BCM4908 SoCs
  arm64: dts: broadcom: add BCM4908 and Asus GT-AC5300 early DTS files
  dt-bindings: arm: bcm: document BCM4908 bindings

Link: https://lore.kernel.org/r/20201128163410.1691529-4-f.fainelli@gmail.com
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 23:37:24 +01:00
Arnd Bergmann
915a391915 Our usual bunch of patches to support the Allwinner SoCs, this time
adding:
   - Some nice pinephone additions
   - I2S support for the A64, H3, H5 and H6
   - New boards: Elimo Impetus, Elimo Initium, FriendlyArm ZeroPi, NanoPi R1
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCX8I0KAAKCRDj7w1vZxhR
 xS3/AQDlamXDfa+nsu9C/ZKbeHkN82m/iqRgSK9WonJHgddCiAEAuuvwBytJVhAg
 E4qZ8vQjuKa2tisQv5b2hPZy/VCEUQk=
 =O2Xu
 -----END PGP SIGNATURE-----

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

Our usual bunch of patches to support the Allwinner SoCs, this time
adding:
  - Some nice pinephone additions
  - I2S support for the A64, H3, H5 and H6
  - New boards: Elimo Impetus, Elimo Initium, FriendlyArm ZeroPi, NanoPi R1

* tag 'sunxi-dt-for-5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/sunxi/linux: (21 commits)
  ARM: dts: sun8i-h2-plus-bananapi-m2-zero: add gpio-line-names
  ARM: dts: sun8i: h3: Add initial NanoPi R1 support
  arm64: dts: allwinner: pinephone: Use generic sensor node names
  ARM: dts: sun8i: s3: Add dts for the Elimo Initium SBC
  dt-bindings: arm: sunxi: add Elimo bindings
  ARM: dts: sun8i: s3: Add dtsi for the Elimo Impetus SoM
  arm64: dts: allwinner: pinephone: Add Bluetooth support
  arm64: dts: allwinner: pinephone: Add WiFi support
  arm64: dts: allwinner: pinephone: Add light/proximity sensor
  arm64: dts: allwinner: pinephone: Add LED flash
  arm64: dts: allwinner: pinephone: Set ALDO3 to exactly 3v0
  arm64: dts: allwinner: pinephone: Remove AC power supply
  arm: dts: sunxi: h3/h5: Add I2S2 node
  arm64: dts: allwinner: a64: Add I2S2 node
  arm64: dts: allwinner: h6: Add I2S1 node
  arm64: dts: allwinner: h6: PineH64 model B: Add wifi
  ARM: dts: sun8i-v3s: Add I2C1 PB pins description
  ARM: dts: sun8i: V3/S3: Add UART1 pin definitions to the V3/S3 dtsi
  dt-bindings: vendors: add Elimo Engineering vendor prefix
  ARM: dts: sun8i: add FriendlyArm ZeroPi support
  ...

Link: https://lore.kernel.org/r/551fdf4f-8a0b-4a22-ba49-b4f61520a9ab.lettre@localhost
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 23:34:53 +01:00
Marc Zyngier
0cc519f85a KVM: arm64: Fix nVHE boot on VHE systems
Conflict resolution gone astray results in the kernel not booting
on VHE-capable HW when VHE support is disabled. Thankfully spotted
by David.

Reported-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
2020-12-08 19:51:49 +00:00
Christian Hewitt
7704b10071 arm64: dts: meson: add i2c3/rtc nodes and vrtc alias to GT-King/GT-King-Pro
The GT-King and GT-King-Pro boxes have an RTC chip and power cell, so enable it.

GTKING:~ # dmesg | grep rtc
[    5.237245] meson-vrtc ff8000a8.rtc: registered as rtc1
[    5.261869] rtc-hym8563 0-0051: registered as rtc0
[    5.265016] rtc-hym8563 0-0051: setting system clock to 2020-11-30T09:16:54 UTC (1606727814)

Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201201062135.18241-1-christianshewitt@gmail.com
2020-12-08 09:48:45 -08:00
Andrey Zhizhikin
717c4c8336 arm64: defconfig: drop unused BACKLIGHT_GENERIC option
Commit 7ecdea4a02 ("backlight: generic_bl: Remove this driver as it is
unused") removed geenric_bl driver from the tree, together with
corresponding config option.

Remove BACKLIGHT_GENERIC config item from arm64 configuration.

Fixes: 7ecdea4a02 ("backlight: generic_bl: Remove this driver as it is unused")
Signed-off-by: Andrey Zhizhikin <andrey.zhizhikin@leica-geosystems.com>
Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org>
Acked-by: Daniel Thompson <daniel.thompson@linaro.org>
Acked-by: Sam Ravnborg <sam@ravnborg.org>
Cc: Sam Ravnborg <sam@ravnborg.org>
Link: https://lore.kernel.org/r/20201201222922.3183-3-andrey.zhizhikin@leica-geosystems.com'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 17:30:24 +01:00
Arnd Bergmann
ba2f9a5fbc Some additional modules needed by Rockchip-based boards.
-----BEGIN PGP SIGNATURE-----
 
 iQFEBAABCAAuFiEE7v+35S2Q1vLNA3Lx86Z5yZzRHYEFAl/NHNgQHGhlaWtvQHNu
 dGVjaC5kZQAKCRDzpnnJnNEdgSnBB/9R9Ur2yr2coGE8Q/J76+xg9f0jFsXFG74e
 r+yxavk+cy7I/+6xVAu0Vs4YsEgwM1/3lCc2Lt2yBpCebCi2idbu4a5PCZXe8XUs
 Af5uP6GvTqV39SUPaYB/nvd4A//cPB4ZiZErhQ4R1qghaKGO+1WHD5naoySDpRXe
 snEJftlWX+TJyWnmf1kuto03FVGqND60IgXlbrIJe1gpKAI2deon6JNbl0xmYg1g
 6TnRqi//8H7cHKTJtB+phFoYq93PcCLBsgvVh7c5Rw8UYytmQJdYUEX07p25xYp7
 /bGcfotOr0jMQNvQymG7jWyNN3NL3ZQFl71GUI2pJf6fjZexiCMb
 =0eqb
 -----END PGP SIGNATURE-----

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

Some additional modules needed by Rockchip-based boards.

* tag 'v5.11-rockchip-defconfig64-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip:
  arm64: defconfig: Enable RTC_DRV_HYM8563
  arm64: defconfig: Enable USB_SERIAL_CP210X
  arm64: defconfig: Enable PHY_ROCKCHIP_INNO_DSIDPHY
  arm64: defconfig: Enable ROCKCHIP_LVDS

Link: https://lore.kernel.org/r/2750818.e9J7NaK4W3@phil
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 17:25:39 +01:00
Arnd Bergmann
249293397e i.MX defconfig update for 5.11:
- A couple of patches that enable various i.MX audio drivers for i.MX8M.
 - Enable more drivers that are useful on Librem 5 hardware.
 -----BEGIN PGP SIGNATURE-----
 
 iQFIBAABCgAyFiEEFmJXigPl4LoGSz08UFdYWoewfM4FAl/HokMUHHNoYXduZ3Vv
 QGtlcm5lbC5vcmcACgkQUFdYWoewfM6oCggAs8waHnriWnEi6pBv/vuX1GFNPsoj
 EmPk505RL6akL+QiGwFl9L4/k+khuZRgUbUfgsrx1qTcpu3XyKrIfABmez1vJIXT
 staufuHoOsgjJUzP+aeuyoc/PVhq1EtV/xPAjQrhIHnET5NxIJPiOg+caHnLyD71
 Z9hJYy72o1S4p+FMVjB5icc9P/yZh7fZNBj3eH7x8YF0jRnePoDomykIPua+xt19
 Qtz1mSg9YZF1NXXrY+TX5BP7J0byeCgicFRrV9VLIMnv2qq3oKKwqpTFjw52G4IL
 dinAlOtKhuVmMprveDXVUHyzpifTaCOF7vjwA9By8sJCkJTKgz9x02KcjQ==
 =LJQK
 -----END PGP SIGNATURE-----

Merge tag 'imx-defconfig-5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into arm/defconfig

i.MX defconfig update for 5.11:

- A couple of patches that enable various i.MX audio drivers for i.MX8M.
- Enable more drivers that are useful on Librem 5 hardware.

* tag 'imx-defconfig-5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux:
  arm64: defconfig: Enable more Librem 5 hardware
  arm64: defconfig: Enable ASRC and EASRC
  arm64: defconfig: Enable additional sound drivers on i.MX8M Mini

Link: https://lore.kernel.org/r/20201202142717.9262-6-shawnguo@kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 17:24:30 +01:00
Arnd Bergmann
786e484016 Qualcomm defconfig updates for 5.11
This enables the Qualcomm PON and OSM L3 drivers. It then ensures that
 the QCOM_SCM and Command DB drivers are built-in, now that they have
 been made user selectable and tristate.
 -----BEGIN PGP SIGNATURE-----
 
 iQJPBAABCAA5FiEEBd4DzF816k8JZtUlCx85Pw2ZrcUFAl/FL88bHGJqb3JuLmFu
 ZGVyc3NvbkBsaW5hcm8ub3JnAAoJEAsfOT8Nma3FSgMP/3UlXphDNwFXV3i52vmm
 IEbJl+jXt/sibR9g9yMZubSu0zZKIEZZL6QVPRcU+HOjW9auZz3t/jQBGC4jWVjc
 QICEHtQIsWW6lpaUVd7yMANHqE9uGkqXjK1NsKyIuGjAogv1/MpN3sElLZFZ/fWT
 xMZ7/YF0ENWHCbLNILODmXsaBob++pexj5r6dO/VDXi6OkNvGLsshCtU8kDOUF0p
 Jyt+Iog1Xe7joyTalvLc1RTJtZrDy09aGnPJ8naC9DFz28hMuX1ka4R2XJUPziRX
 3WpoEntkwNqR7Eqre6hJ8DQMcgEQswP45kd/LnlklQpehQFvKzchpElBL68cR5jC
 UqGvBqqVU6bTZqpgU5vQ4d0JpBU/wWCeVuMzLgP9XOqDh5eepCBw95lLynKl1vmM
 wRlEEsb42lzVj6UZp0KZEwx9m0pD1g6kVjTcqgkn744a17Quf2c3cwnnLpVYoDV7
 AQaUcxfp+UxsvG5HD9sKoigZyTh+O36pUfgEAmiNYnKvuJVQCnxwo6MxKQyxz9WB
 qjrqOYBQ80/sSQUXH+A+xigI10cCUtznG/icN6PO4RAF6hw2i9LIB99QbgiWg3XA
 T5HWvs8v7e/R2Bj6s1u8r0PbRpxio7Cj4WY6DDMfatMAWJgHyIMff4vmBTZJGzUO
 LwTb6ps/f6AtJCHpp9HUgeJ5
 =slxb
 -----END PGP SIGNATURE-----

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

Qualcomm defconfig updates for 5.11

This enables the Qualcomm PON and OSM L3 drivers. It then ensures that
the QCOM_SCM and Command DB drivers are built-in, now that they have
been made user selectable and tristate.

* tag 'qcom-arm64-defconfig-for-5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux:
  arm64: defconfig: Enable Qualcomm PON driver
  arm64: defconfig: Enable QCOM_SCM as builtin
  arm64: defconfig: Enable Qualcomm OSM L3 driver
  arm64: defconfig: Enable Qualcomm Command DB driver

Link: https://lore.kernel.org/r/20201130190124.345127-1-bjorn.andersson@linaro.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 17:19:19 +01:00
Arnd Bergmann
2ede693874 ARM64 defconfig changes for TI K3 platforms for v5.11 merge window:
- GPIO and I2C for J721E SD card support to be functional
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEE+KKGk1TrgjIXoxo03bWEnRc2JJ0FAl/FLQcACgkQ3bWEnRc2
 JJ1pDBAAparXFEaiieQ6veeQLl8CLEHE6rUwbnm15ufdBg97y6urDPE1sZbyupsj
 syBy6vwVtaPiciXFdC0OHj9IR5SzncUByLaYMRDi7pPa779IgpSLeVCv8cauRq5w
 RHrHuRBH+cqlPJepVdxlot9A9k1It1c/RrG4e4IyoGB1yV7iQVQPqrndA/0YnpD2
 gv0YmHH+x06pqNG3Ra8+kc/LiqXJDX0M8jxePR3UXe9EH/xNIlpn1VdVcXMPgGUO
 FK04YuT+DgsrZBENfY3VGmIrRqQLd36zJsgp97g7sVUNmIsrRScdLu07KL/5vCee
 lLAX/4hnmeDcWu61Cs4QmoxRZwFOn0e8rguVp9KYRqB/jSf2xvtqp/rzqNVuKweI
 dH1m4uP2St/wwq+cNQizfykvZOnzuCTpk79yWpk70BfXSigUpswhTyYeaTCSscu6
 M3rqP2rS0WfnXlK6vDRKVPZge/jPi5aMt0tzRMEdRF7R6Y+fVfoEmmz7dZ8UuLDR
 0ODoO1Wl5KP6UKcPCzGiZs2qKxbkSZN1LmHilyEnl/SDhEJXUsNe0aKbM9X7wDbG
 CTiH5Mzx9sc1eVKMG6BoABVN30+UOZ/xH38jMUe71JPScZAYm4TYPTtON2ifyw46
 WRRpAmtGAb0yb+u8pGXF5FYGUPBta1vZ0F9ffqCYP3hraTXR14A=
 =+rdo
 -----END PGP SIGNATURE-----

Merge tag 'ti-k3-config-for-v5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/nmenon/linux into arm/defconfig

ARM64 defconfig changes for TI K3 platforms for v5.11 merge window:

- GPIO and I2C for J721E SD card support to be functional

* tag 'ti-k3-config-for-v5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/nmenon/linux:
  arm64: defconfig: Enable GPIO and I2C configs for TI's J721e platform

Link: https://lore.kernel.org/r/20201130174850.ni4sdyz3qp67j3sz@upstart
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 17:18:27 +01:00
Arnd Bergmann
0f4b0b479b This pull request contains ARM64 defconfig changes for 5.11, please pull
the following:
 
 - Florian enables the ARM SCMI protocol, and the common clock, HWMON and
   CPU frequency scaling drivers since those are used by ARCH_BRCMSTB
   platforms
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEm+Rq3+YGJdiR9yuFh9CWnEQHBwQFAl/Cez0ACgkQh9CWnEQH
 BwSwXxAAzRgh952TV4detmqzdbdRsSSaMpeBYyNsP512b/H6ZTofKjek//aoLguG
 B6i1gLPrMAIOjuzhdtZ1YJAABJ6fy3It4KHRJWthwZU2hUJv6R5/3bH28t0EhS3u
 0f8w84iiPeQTnu/+WkoFf5qK7P8dxXWMFrelZKyGEHYdL7nvwbXEZxt5Qwn2qMHW
 HRUlxqef7qZLj1meFeffxZplWg64C7LMUD1OOq6VPBjNPQTmcSb72Z9jkbwVHcPx
 WN9+cMzWmrbiqBcPoRPaOxrP5L3FNdbVPXMy2g5NvvKPopk8twQ61Wv1mBRh97Tb
 wSi7HItUDq8SdK3kHA7MKe6LMCZ9Rv+QphZ2PYUedANpAjh1Y18q6HlpwcjKN2+N
 FT2/iouy6v15fQDSqjNwvWdNIwIXxM5Bj1ARih964+5ali1K3HfFVEFCXV4tPgui
 9V9oEcK6Ipx3hDA9iDEUoGuyv6PBO/HmGeoZf8SKeSwgUIjiUAI97VRC8+weS0Zs
 uOhkdj18nvbEnE8u5XQAk+wT1mTpT8flJoPeViIdAUaY8sbqmgsw+eqDpfijFjSd
 y8LNwc2MQeRFKiWpIoweTGRMHmlrFbTrzWMuucz2BGO2gWCyiB00BaO850LrhdgP
 v2UjtRaSBL4+Y1uaj3n9u/OeZQLioF7EF7EpuFJB/+eZFJhgW9o=
 =8JN3
 -----END PGP SIGNATURE-----

Merge tag 'arm-soc/for-5.11/defconfig-arm64' of https://github.com/Broadcom/stblinux into arm/defconfig

This pull request contains ARM64 defconfig changes for 5.11, please pull
the following:

- Florian enables the ARM SCMI protocol, and the common clock, HWMON and
  CPU frequency scaling drivers since those are used by ARCH_BRCMSTB
  platforms

* tag 'arm-soc/for-5.11/defconfig-arm64' of https://github.com/Broadcom/stblinux:
  arm64: defconfig: Enable ARM SCMI protocol and drivers

Link: https://lore.kernel.org/r/20201128163410.1691529-2-f.fainelli@gmail.com
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 17:16:47 +01:00
Arnd Bergmann
69f7aeee06 One patch to enable the Allwinner I2S controller on arm64's defconfig
-----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCX8IzNQAKCRDj7w1vZxhR
 xRGVAQCz65FoHboWxCwXPuduSZ6sCkyRjdSzw84U7qJzrWHgVgD+MR93mv7aYM4A
 x+S/Pa1sxH3awHUw8JDmT51Qt0JijgU=
 =rDZm
 -----END PGP SIGNATURE-----

Merge tag 'sunxi-config64-for-5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/sunxi/linux into arm/defconfig

One patch to enable the Allwinner I2S controller on arm64's defconfig

* tag 'sunxi-config64-for-5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/sunxi/linux:
  arm64: defconfig: Enable Allwinner i2s driver

Link: https://lore.kernel.org/r/5ddf5486-a20c-467a-bc67-d5e8fbc38856.lettre@localhost
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-08 17:14:58 +01:00
Stefan Agner
9e454e37dc arm64: dts: meson: g12b: w400: fix PHY deassert timing requirements
According to the datasheet (Rev. 1.9) the RTL8211F requires at least
72ms "for internal circuits settling time" before accessing the PHY
egisters. On similar boards with the same PHY this fixes an issue where
Ethernet link would not come up when using ip link set down/up.

Fixes: 2cd2310fca ("arm64: dts: meson-g12b-ugoos-am6: add initial device-tree")
Reviewed-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Signed-off-by: Stefan Agner <stefan@agner.ch>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/46298e66572784c44f873f1b71cc4ab3d8fc5aa6.1607363522.git.stefan@agner.ch
2020-12-07 11:12:50 -08:00
Stefan Agner
3d07c3b3a8 arm64: dts: meson: g12a: x96-max: fix PHY deassert timing requirements
According to the datasheet (Rev. 1.9) the RTL8211F requires at least
72ms "for internal circuits settling time" before accessing the PHY
registers. On similar boards with the same PHY this fixes an issue where
Ethernet link would not come up when using ip link set down/up.

Fixes: ed5e8f6891 ("arm64: dts: meson: g12a: x96-max: fix the Ethernet PHY reset line")
Reviewed-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Signed-off-by: Stefan Agner <stefan@agner.ch>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/12506964ca5d5f936579a280ad0a7e7f9a0a2d4c.1607363522.git.stefan@agner.ch
2020-12-07 11:12:49 -08:00
Stefan Agner
c183c406c4 arm64: dts: meson: fix PHY deassert timing requirements
According to the datasheet (Rev. 1.9) the RTL8211F requires at least
72ms "for internal circuits settling time" before accessing the PHY
registers. This fixes an issue seen on ODROID-C2 where the Ethernet
link doesn't come up when using ip link set down/up:
  [ 6630.714855] meson8b-dwmac c9410000.ethernet eth0: Link is Down
  [ 6630.785775] meson8b-dwmac c9410000.ethernet eth0: PHY [stmmac-0:00] driver [RTL8211F Gigabit Ethernet] (irq=36)
  [ 6630.893071] meson8b-dwmac c9410000.ethernet: Failed to reset the dma
  [ 6630.893800] meson8b-dwmac c9410000.ethernet eth0: stmmac_hw_setup: DMA engine initialization failed
  [ 6630.902835] meson8b-dwmac c9410000.ethernet eth0: stmmac_open: Hw setup failed

Fixes: f29cabf240 ("arm64: dts: meson: use the generic Ethernet PHY reset GPIO bindings")
Reviewed-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Signed-off-by: Stefan Agner <stefan@agner.ch>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/4a322c198b86e4c8b3dda015560a683babea4d63.1607363522.git.stefan@agner.ch
2020-12-07 11:12:49 -08:00
Stefan Agner
1c7412530d arm64: dts: meson: g12b: odroid-n2: fix PHY deassert timing requirements
According to the datasheet (Rev. 1.9) the RTL8211F requires at least
72ms "for internal circuits settling time" before accessing the PHY
registers. This fixes an issue where the Ethernet link doesn't come up
when using ip link set down/up:
  [   29.360965] meson8b-dwmac ff3f0000.ethernet eth0: Link is Down
  [   34.569012] meson8b-dwmac ff3f0000.ethernet eth0: PHY [0.0:00] driver [RTL8211F Gigabit Ethernet] (irq=31)
  [   34.676732] meson8b-dwmac ff3f0000.ethernet: Failed to reset the dma
  [   34.678874] meson8b-dwmac ff3f0000.ethernet eth0: stmmac_hw_setup: DMA engine initialization failed
  [   34.687850] meson8b-dwmac ff3f0000.ethernet eth0: stmmac_open: Hw setup failed

Fixes: 658e4129bb ("arm64: dts: meson: g12b: odroid-n2: add the Ethernet PHY reset line")
Reviewed-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Signed-off-by: Stefan Agner <stefan@agner.ch>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/df3f5c4fc6e43c55429fd3662a636036a21eed49.1607363522.git.stefan@agner.ch
2020-12-07 11:12:48 -08:00
Christian Hewitt
c993c4e843 arm64: dts: meson: minor fixups for Khadas VIM/VIM2 dts
Reorder the VIM/VIM2 includes/bindings to follow the format of other dts
in the Amlogic tree and remove a stray empty line in the VIM2 dts.

Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
Reviewed-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201203061605.9603-1-christianshewitt@gmail.com
2020-12-07 11:06:33 -08:00
Christian Hewitt
5e3ee48ea0 arm64: dts: meson: add audio playback to wetek-play2
Add initial support limited to HDMI i2s and SPDIF (LPCM).

Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
Acked-by: Jerome Brunet <jbrunet@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201203060023.9454-8-christianshewitt@gmail.com
2020-12-07 11:05:56 -08:00
Christian Hewitt
e0d9e6eead arm64: dts: meson: add audio playback to wetek-hub
Add initial audio support limited to HDMI i2s.

Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
Acked-by: Jerome Brunet <jbrunet@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201203060023.9454-7-christianshewitt@gmail.com
2020-12-07 11:05:56 -08:00
Christian Hewitt
ba414bc548 arm64: dts: meson: add audio playback to odroid-c2
Add initial audio support limited to HDMI i2s.

Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
Acked-by: Jerome Brunet <jbrunet@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201203060023.9454-6-christianshewitt@gmail.com
2020-12-07 11:05:56 -08:00
Christian Hewitt
6a74f78c34 arm64: dts: meson: add audio playback to nanopi-k2
Add initial audio support limited to HDMI i2s.

Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
Acked-by: Jerome Brunet <jbrunet@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201203060023.9454-5-christianshewitt@gmail.com
2020-12-07 11:05:56 -08:00
Christian Hewitt
0157e1a63c arm64: dts: meson: add audio playback to khadas-vim2
Add initial audio support limited to HDMI i2s.

Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
Acked-by: Jerome Brunet <jbrunet@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201203060023.9454-4-christianshewitt@gmail.com
2020-12-07 11:05:55 -08:00
Christian Hewitt
4e0649f495 arm64: dts: meson: add audio playback to khadas-vim
Add initial audio support limited to HDMI i2s.

Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
Acked-by: Jerome Brunet <jbrunet@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201203060023.9454-3-christianshewitt@gmail.com
2020-12-07 11:05:55 -08:00
Christian Hewitt
ec78dc8964 arm64: dts: meson: add audio playback to a95x
Add initial audio support limited to HDMI i2s.

Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
Acked-by: Jerome Brunet <jbrunet@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201203060023.9454-2-christianshewitt@gmail.com
2020-12-07 11:05:55 -08:00
Neil Armstrong
b03455ae3c arm64: dts: meson-axg: add GE2D node
This adds the node for the GE2D accelerator unit.

Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201202174417.3778306-5-narmstrong@baylibre.com
2020-12-07 10:58:26 -08:00
Arnd Bergmann
b11ddaac89 A few more RGMII-ID fixes, and a bunch of other more random fixes
-----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCX8Is4AAKCRDj7w1vZxhR
 xbAjAP4ohHei2PZ3mHF6wU9kBv4lM2aV60mqvKDFirMdfQBNoAD/Y5fMBAVp6yJn
 lRECtoJdPWI4x97ZNZMR4xX1XVSXoQk=
 =aO5k
 -----END PGP SIGNATURE-----

Merge tag 'sunxi-fixes-for-5.10-2' of git://git.kernel.org/pub/scm/linux/kernel/git/sunxi/linux into arm/fixes

A few more RGMII-ID fixes, and a bunch of other more random fixes

* tag 'sunxi-fixes-for-5.10-2' of git://git.kernel.org/pub/scm/linux/kernel/git/sunxi/linux:
  ARM: dts: sun7i: pcduino3-nano: enable RGMII RX/TX delay on PHY
  ARM: dts: sun8i: v3s: fix GIC node memory range
  ARM: dts: sun8i: v40: bananapi-m2-berry: Fix ethernet node
  ARM: dts: sun8i: r40: bananapi-m2-berry: Fix dcdc1 regulator
  ARM: dts: sun7i: bananapi: Enable RGMII RX/TX delay on Ethernet PHY
  ARM: dts: s3: pinecube: align compatible property to other S3 boards
  ARM: sunxi: Add machine match for the Allwinner V3 SoC
  arm64: dts: allwinner: h6: orangepi-one-plus: Fix ethernet

Link: https://lore.kernel.org/r/1280f1de-1b6d-4cc2-8448-e5a9096a41e8.lettre@localhost
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2020-12-07 15:28:28 +01:00
Linus Torvalds
e6585a4939 Kbuild fixes for v5.10 (2nd)
- Move -Wcast-align to W=3, which tends to be false-positive and there
    is no tree-wide solution.
 
  - Pass -fmacro-prefix-map to KBUILD_CPPFLAGS because it is a preprocessor
    option and makes sense for .S files as well.
 
  - Disable -gdwarf-2 for Clang's integrated assembler to avoid warnings.
 
  - Disable --orphan-handling=warn for LLD 10.0.1 to avoid warnings.
 
  - Fix undesirable line breaks in *.mod files.
 -----BEGIN PGP SIGNATURE-----
 
 iQJJBAABCgAzFiEEbmPs18K1szRHjPqEPYsBB53g2wYFAl/MzyMVHG1hc2FoaXJv
 eUBrZXJuZWwub3JnAAoJED2LAQed4NsGKJ8P/2kLq296XAPjqC90/LWMja8dsXO/
 Wgaq8zC819x0JFuGdBKlwlFe3AvFYRtts9V5+mzjxvsOjH/6+xzyrXjRPCwZYqlj
 XKC3ZwuS2SGDPFCriI1edwTUp5tyDnG/VBjqbf3ybQnz0LAShidXBD9IlM/XX9Rz
 BlWqd7Uib50Pq8AfM2JVokrSmkkvhqxocIsmjTa0wvRjRAw7+aVkGNCWXqnTho7y
 YuHmTWbmUQIROF3Bzs1fkGp+qaQofPRfA1tTwaTVvgmt8rEqyzXi11y6kj56INfg
 /pq4O1KrplKtJFdrcjj4/eptqHG3I+Jq56qCHVescF6+bH6cc6BUL8qDdAzFZQai
 e/pWCzREqFDKchEmT2d0Uzik8Zfxi5Cw68Otpzb4LqTUUxXSoRx1R9Of/Ei5QZum
 6b6s9Q41UwH983UQCOOSGjXGZYP6fZG1a0XejbduYo7TL4KEECAO/FlLBWGttYH3
 0i3aKz3aDKb/fo7hDbbqg+o6F0mShEraqxMmWgIvgGt+k76j0O0wS2KryqpTd7Vv
 xg72suGM7f9QBA50lZ0r32fm86XnlqwQAm9ZMaSXR1Ii7j4F9UNRmR/FUYq7dPwa
 COkuHr+9LqzV/tkluWi2rjLIGPaCuEVeSCcQ/wIDdp2iOyb54CbozwK0Yi2dxxus
 jVFKwSaMUDHrkSj6
 =/ysh
 -----END PGP SIGNATURE-----

Merge tag 'kbuild-fixes-v5.10-2' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild

Pull Kbuild fixes from Masahiro Yamada:

 - Move -Wcast-align to W=3, which tends to be false-positive and there
   is no tree-wide solution.

 - Pass -fmacro-prefix-map to KBUILD_CPPFLAGS because it is a
   preprocessor option and makes sense for .S files as well.

 - Disable -gdwarf-2 for Clang's integrated assembler to avoid warnings.

 - Disable --orphan-handling=warn for LLD 10.0.1 to avoid warnings.

 - Fix undesirable line breaks in *.mod files.

* tag 'kbuild-fixes-v5.10-2' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild:
  kbuild: avoid split lines in .mod files
  kbuild: Disable CONFIG_LD_ORPHAN_WARN for ld.lld 10.0.1
  kbuild: Hoist '--orphan-handling' into Kconfig
  Kbuild: do not emit debug info for assembly with LLVM_IAS=1
  kbuild: use -fmacro-prefix-map for .S sources
  Makefile.extrawarn: move -Wcast-align to W=3
2020-12-06 10:31:39 -08:00
Vicente Bergas
e12f67fe83 arm64: dts: rockchip: use USB host by default on rk3399-rock-pi-4
Based on the board schematics at
https://dl.radxa.com/rockpi4/docs/hw/rockpi4/rockpi_4c_v12_sch_20200620.pdf
on page 19 there is an USB Type-A receptacle being used as an USB-OTG port.

But the Type-A connector is not valid for OTG operation, for this reason
there is a switch to select host or device role.
This is non-compliant and error prone because switching is manual.
So, use host mode as it corresponds for a Type-A receptacle.

Signed-off-by: Vicente Bergas <vicencb@gmail.com>
Link: https://lore.kernel.org/r/20201201154132.1286-4-vicencb@gmail.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-12-04 11:23:52 +01:00
Vicente Bergas
eff57d38b5 arm64: dts: rockchip: fix I2S conflict on rk3399-rock-pi-4
Based on the board schematics at
https://dl.radxa.com/rockpi4/docs/hw/rockpi4/rockpi_4c_v12_sch_20200620.pdf
on page 14:
Only two channels of I2S are connected and the extra
I2S pins are in conflict with other functions like USB power.

Signed-off-by: Vicente Bergas <vicencb@gmail.com>
Link: https://lore.kernel.org/r/20201201154132.1286-3-vicencb@gmail.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-12-04 11:23:52 +01:00
Vicente Bergas
328c611278 arm64: dts: rockchip: fix supplies on rk3399-rock-pi-4
Based on the board schematics at
https://dl.radxa.com/rockpi4/docs/hw/rockpi4/rockpi_4c_v12_sch_20200620.pdf
on page 18:
vcc_lan is not controllable by software, it is just an analog LC filter.
Because of this, it can not be turned off-in-suspend.

and on page 17:
vcc_cam and vcc_mipi are not voltage regulators, they are just switches.
So, the voltage range is not applicable.
This silences an error message about not being able to adjust the voltage.

Signed-off-by: Vicente Bergas <vicencb@gmail.com>
Link: https://lore.kernel.org/r/20201201154132.1286-2-vicencb@gmail.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-12-04 11:23:52 +01:00
Chen-Yu Tsai
94dad6bed3 arm64: dts: rockchip: Fix UART pull-ups on rk3328
For UARTs, the local pull-ups should be on the RX pin, not the TX pin.
UARTs transmit active-low, so a disconnected RX pin should be pulled
high instead of left floating to prevent noise being interpreted as
transmissions.

This gets rid of bogus sysrq events when the UART console is not
connected.

Fixes: 52e02d377a ("arm64: dts: rockchip: add core dtsi file for RK3328 SoCs")
Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Link: https://lore.kernel.org/r/20201204064805.6480-1-wens@kernel.org
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-12-04 11:22:07 +01:00
Marc Zyngier
17f84520cb Merge remote-tracking branch 'origin/kvm-arm64/misc-5.11' into kvmarm-master/queue
Signed-off-by: Marc Zyngier <maz@kernel.org>
2020-12-04 10:12:55 +00:00
David Brazdil
f19f6644a5 KVM: arm64: Fix EL2 mode availability checks
With protected nVHE hyp code interception host's PSCI SMCs, the host
starts seeing new CPUs boot in EL1 instead of EL2. The kernel logic
that keeps track of the boot mode needs to be adjusted.

Add a static key enabled if KVM protected mode initialization is
successful.

When the key is enabled, is_hyp_mode_available continues to report
`true` because its users either treat it as a check whether KVM will be
/ was initialized, or whether stub HVCs can be made (eg. hibernate).

is_hyp_mode_mismatched is changed to report `false` when the key is
enabled. That's because all cores' modes matched at the point of KVM
init and KVM will not allow cores not present at init to boot. That
said, the function is never used after KVM is initialized.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-27-dbrazdil@google.com
2020-12-04 10:08:36 +00:00
David Brazdil
b93c17c418 KVM: arm64: Trap host SMCs in protected mode
While protected KVM is installed, start trapping all host SMCs.
For now these are simply forwarded to EL3, except PSCI
CPU_ON/CPU_SUSPEND/SYSTEM_SUSPEND which are intercepted and the
hypervisor installed on newly booted cores.

Create new constant HCR_HOST_NVHE_PROTECTED_FLAGS with the new set of HCR
flags to use while the nVHE vector is installed when the kernel was
booted with the protected flag enabled. Switch back to the default HCR
flags when switching back to the stub vector.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-26-dbrazdil@google.com
2020-12-04 10:08:36 +00:00
David Brazdil
fa8c3d6553 KVM: arm64: Keep nVHE EL2 vector installed
KVM by default keeps the stub vector installed and installs the nVHE
vector only briefly for init and later on demand. Change this policy
to install the vector at init and then never uninstall it if the kernel
was given the protected KVM command line parameter.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-25-dbrazdil@google.com
2020-12-04 10:08:36 +00:00
David Brazdil
d945f8d9ec KVM: arm64: Intercept host's SYSTEM_SUSPEND PSCI SMCs
Add a handler of SYSTEM_SUSPEND host PSCI SMCs. The semantics are
equivalent to CPU_SUSPEND, typically called on the last online CPU.
Reuse the same entry point and boot args struct as CPU_SUSPEND.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-24-dbrazdil@google.com
2020-12-04 10:08:35 +00:00
David Brazdil
abf16336dd KVM: arm64: Intercept host's CPU_SUSPEND PSCI SMCs
Add a handler of CPU_SUSPEND host PSCI SMCs. The SMC can either enter
a sleep state indistinguishable from a WFI or a deeper sleep state that
behaves like a CPU_OFF+CPU_ON except that the core is still considered
online while asleep.

The handler saves r0,pc of the host and makes the same call to EL3 with
the hyp CPU entry point. It either returns back to the handler and then
back to the host, or wakes up into the entry point and initializes EL2
state before dropping back to EL1. No EL2 state needs to be
saved/restored for this purpose.

CPU_ON and CPU_SUSPEND are both implemented using struct psci_boot_args
to store the state upon powerup, with each CPU having separate structs
for CPU_ON and CPU_SUSPEND so that CPU_SUSPEND can operate locklessly
and so that a CPU_ON call targeting a CPU cannot interfere with
a concurrent CPU_SUSPEND call on that CPU.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-23-dbrazdil@google.com
2020-12-04 10:08:35 +00:00
David Brazdil
cdf3671927 KVM: arm64: Intercept host's CPU_ON SMCs
Add a handler of the CPU_ON PSCI call from host. When invoked, it looks
up the logical CPU ID corresponding to the provided MPIDR and populates
the state struct of the target CPU with the provided x0, pc. It then
calls CPU_ON itself, with an entry point in hyp that initializes EL2
state before returning ERET to the provided PC in EL1.

There is a simple atomic lock around the boot args struct. If it is
already locked, CPU_ON will return PENDING_ON error code.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-22-dbrazdil@google.com
2020-12-04 10:08:35 +00:00
David Brazdil
04e05f057a KVM: arm64: Add function to enter host from KVM nVHE hyp code
All nVHE hyp code is currently executed as handlers of host's HVCs. This
will change as nVHE starts intercepting host's PSCI CPU_ON SMCs. The
newly booted CPU will need to initialize EL2 state and then enter the
host. Add __host_enter function that branches into the existing
host state-restoring code after the trap handler would have returned.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-21-dbrazdil@google.com
2020-12-04 10:08:35 +00:00
David Brazdil
f74e1e2128 KVM: arm64: Extract __do_hyp_init into a helper function
In preparation for adding a CPU entry point in nVHE hyp code, extract
most of __do_hyp_init hypervisor initialization code into a common
helper function. This will be invoked by the entry point to install KVM
on the newly booted CPU.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-20-dbrazdil@google.com
2020-12-04 10:08:35 +00:00
David Brazdil
1fd12b7e4d KVM: arm64: Forward safe PSCI SMCs coming from host
Forward the following PSCI SMCs issued by host to EL3 as they do not
require the hypervisor's intervention. This assumes that EL3 correctly
implements the PSCI specification.

Only function IDs implemented in Linux are included.

Where both 32-bit and 64-bit variants exist, it is assumed that the host
will always use the 64-bit variant.

 * SMCs that only return information about the system
   * PSCI_VERSION        - PSCI version implemented by EL3
   * PSCI_FEATURES       - optional features supported by EL3
   * AFFINITY_INFO       - power state of core/cluster
   * MIGRATE_INFO_TYPE   - whether Trusted OS can be migrated
   * MIGRATE_INFO_UP_CPU - resident core of Trusted OS
 * operations which do not affect the hypervisor
   * MIGRATE             - migrate Trusted OS to a different core
   * SET_SUSPEND_MODE    - toggle OS-initiated mode
 * system shutdown/reset
   * SYSTEM_OFF
   * SYSTEM_RESET
   * SYSTEM_RESET2

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-19-dbrazdil@google.com
2020-12-04 10:08:35 +00:00
David Brazdil
d084ecc5c7 KVM: arm64: Add offset for hyp VA <-> PA conversion
Add a host-initialized constant to KVM nVHE hyp code for converting
between EL2 linear map virtual addresses and physical addresses.
Also add `__hyp_pa` macro that performs the conversion.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-18-dbrazdil@google.com
2020-12-04 10:08:34 +00:00
David Brazdil
eeeee7193d KVM: arm64: Bootstrap PSCI SMC handler in nVHE EL2
Add a handler of PSCI SMCs in nVHE hyp code. The handler is initialized
with the version used by the host's PSCI driver and the function IDs it
was configured with. If the SMC function ID matches one of the
configured PSCI calls (for v0.1) or falls into the PSCI function ID
range (for v0.2+), the SMC is handled by the PSCI handler. For now, all
SMCs return PSCI_RET_NOT_SUPPORTED.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-17-dbrazdil@google.com
2020-12-04 10:08:34 +00:00
David Brazdil
a805e1fb30 KVM: arm64: Add SMC handler in nVHE EL2
Add handler of host SMCs in KVM nVHE trap handler. Forward all SMCs to
EL3 and propagate the result back to EL1. This is done in preparation
for validating host SMCs in KVM protected mode.

The implementation assumes that firmware uses SMCCC v1.2 or older. That
means x0-x17 can be used both for arguments and results, other GPRs are
preserved.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-16-dbrazdil@google.com
2020-12-04 10:08:34 +00:00
David Brazdil
94f5e8a464 KVM: arm64: Create nVHE copy of cpu_logical_map
When KVM starts validating host's PSCI requests, it will need to map
MPIDR back to the CPU ID. To this end, copy cpu_logical_map into nVHE
hyp memory when KVM is initialized.

Only copy the information for CPUs that are online at the point of KVM
initialization so that KVM rejects CPUs whose features were not checked
against the finalized capabilities.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-15-dbrazdil@google.com
2020-12-04 10:08:34 +00:00
David Brazdil
687413d34d KVM: arm64: Support per_cpu_ptr in nVHE hyp code
When compiling with __KVM_NVHE_HYPERVISOR__, redefine per_cpu_offset()
to __hyp_per_cpu_offset() which looks up the base of the nVHE per-CPU
region of the given cpu and computes its offset from the
.hyp.data..percpu section.

This enables use of per_cpu_ptr() helpers in nVHE hyp code. Until now
only this_cpu_ptr() was supported by setting TPIDR_EL2.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-14-dbrazdil@google.com
2020-12-04 10:08:34 +00:00
David Brazdil
2d7bf218ca KVM: arm64: Add .hyp.data..ro_after_init ELF section
Add rules for renaming the .data..ro_after_init ELF section in KVM nVHE
object files to .hyp.data..ro_after_init, linking it into the kernel
and mapping it in hyp at runtime.

The section is RW to the host, then mapped RO in hyp. The expectation is
that the host populates the variables in the section and they are never
changed by hyp afterwards.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-13-dbrazdil@google.com
2020-12-04 10:08:33 +00:00
David Brazdil
d3e1086c64 KVM: arm64: Init MAIR/TCR_EL2 from params struct
MAIR_EL2 and TCR_EL2 are currently initialized from their _EL1 values.
This will not work once KVM starts intercepting PSCI ON/SUSPEND SMCs
and initializing EL2 state before EL1 state.

Obtain the EL1 values during KVM init and store them in the init params
struct. The struct will stay in memory and can be used when booting new
cores.

Take the opportunity to move copying the T0SZ value from idmap_t0sz in
KVM init rather than in .hyp.idmap.text. This avoids the need for the
idmap_t0sz symbol alias.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-12-dbrazdil@google.com
2020-12-04 10:08:33 +00:00
David Brazdil
63fec24351 KVM: arm64: Move hyp-init params to a per-CPU struct
Once we start initializing KVM on newly booted cores before the rest of
the kernel, parameters to __do_hyp_init will need to be provided by EL2
rather than EL1. At that point it will not be possible to pass its three
arguments directly because PSCI_CPU_ON only supports one context
argument.

Refactor __do_hyp_init to accept its parameters in a struct. This
prepares the code for KVM booting cores as well as removes any limits on
the number of __do_hyp_init arguments.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-11-dbrazdil@google.com
2020-12-04 10:08:32 +00:00
David Brazdil
5be1d6226d KVM: arm64: Remove vector_ptr param of hyp-init
KVM precomputes the hyp VA of __kvm_hyp_host_vector, essentially a
constant (minus ASLR), before passing it to __kvm_hyp_init.
Now that we have alternatives for converting kimg VA to hyp VA, replace
this with computing the constant inside __kvm_hyp_init, thus removing
the need for an argument.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-10-dbrazdil@google.com
2020-12-04 10:08:32 +00:00
David Brazdil
78869f0f05 arm64: Extract parts of el2_setup into a macro
When a CPU is booted in EL2, the kernel checks for VHE support and
initializes the CPU core accordingly. For nVHE it also installs the stub
vectors and drops down to EL1.

Once KVM gains the ability to boot cores without going through the
kernel entry point, it will need to initialize the CPU the same way.
Extract the relevant bits of el2_setup into an init_el2_state macro
with an argument specifying whether to initialize for VHE or nVHE.

The following ifdefs are removed:
 * CONFIG_ARM_GIC_V3 - always selected on arm64
 * CONFIG_COMPAT - hstr_el2 can be set even without 32-bit support

No functional change intended. Size of el2_setup increased by
148 bytes due to duplication.

Signed-off-by: David Brazdil <dbrazdil@google.com>
[maz: reworked to fit the new PSTATE initial setup code]
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-9-dbrazdil@google.com
2020-12-04 10:07:12 +00:00
Will Deacon
ce4b2c0178 arm64: Fix build failure when HARDLOCKUP_DETECTOR_PERF is enabled
If HARDLOCKUP_DETECTOR_PERF is selected but HW_PERF_EVENTS is not, then
the associated watchdog driver will fail to link:

  |    aarch64-linux-ld: Unexpected GOT/PLT entries detected!
  |    aarch64-linux-ld: Unexpected run-time procedure linkages detected!
  |    aarch64-linux-ld: kernel/watchdog_hld.o: in function `hardlockup_detector_event_create':
  | >> watchdog_hld.c:(.text+0x68): undefined reference to `hw_nmi_get_sample_period

Change the Kconfig dependencies so that HAVE_PERF_EVENTS_NMI requires
the hardware PMU driver to be enabled, ensuring that the required
symbols are present.

Cc: Sumit Garg <sumit.garg@linaro.org>
Reported-by: kernel test robot <lkp@intel.com>
Link: https://lore.kernel.org/r/202012031509.4O5ZoWNI-lkp@intel.com
Fixes: 367c820ef0 ("arm64: Enable perf events based hard lockup detector")
Signed-off-by: Will Deacon <will@kernel.org>
2020-12-04 09:26:37 +00:00
David Brazdil
c1f45f4eb6 arm64: Make cpu_logical_map() take unsigned int
CPU index should never be negative. Change the signature of
(set_)cpu_logical_map to take an unsigned int.

This still works even if the users treat the CPU index as an int,
and will allow the hypervisor's implementation to check that the index
is valid with a single upper-bound check.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-8-dbrazdil@google.com
2020-12-04 08:44:24 +00:00
David Brazdil
3eb681fba2 KVM: arm64: Add ARM64_KVM_PROTECTED_MODE CPU capability
Expose the boolean value whether the system is running with KVM in
protected mode (nVHE + kernel param). CPU capability was selected over
a global variable to allow use in alternatives.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-3-dbrazdil@google.com
2020-12-04 08:44:19 +00:00
David Brazdil
d8b369c4e3 KVM: arm64: Add kvm-arm.mode early kernel parameter
Add an early parameter that allows users to select the mode of operation
for KVM/arm64.

For now, the only supported value is "protected". By passing this flag
users opt into the hypervisor placing additional restrictions on the
host kernel. These allow the hypervisor to spawn guests whose state is
kept private from the host. Restrictions will include stage-2 address
translation to prevent host from accessing guest memory, filtering its
SMC calls, etc.

Without this parameter, the default behaviour remains selecting VHE/nVHE
based on hardware support and CONFIG_ARM64_VHE.

Signed-off-by: David Brazdil <dbrazdil@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201202184122.26046-2-dbrazdil@google.com
2020-12-04 08:43:43 +00:00
Marc Zyngier
64dad8e49d Merge remote-tracking branch 'arm64/for-next/uaccess' into HEAD
Signed-off-by: Marc Zyngier <maz@kernel.org>
2020-12-04 08:43:37 +00:00
Marc Zyngier
f86e54653e Merge remote-tracking branch 'origin/kvm-arm64/csv3' into kvmarm-master/queue
Signed-off-by: Marc Zyngier <maz@kernel.org>
2020-12-03 19:12:24 +00:00
Keqian Zhu
652d0b701d KVM: arm64: Use kvm_write_guest_lock when init stolen time
There is a lock version kvm_write_guest. Use it to simplify code.

Signed-off-by: Keqian Zhu <zhukeqian1@huawei.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Reviewed-by: Andrew Jones <drjones@redhat.com>
Reviewed-by: Steven Price <steven.price@arm.com>
Link: https://lore.kernel.org/r/20200817110728.12196-3-zhukeqian1@huawei.com
2020-12-03 19:02:18 +00:00
Peter Collingbourne
929c1f3384 arm64: mte: fix prctl(PR_GET_TAGGED_ADDR_CTRL) if TCF0=NONE
Previously we were always returning a tag inclusion mask of zero via
PR_GET_TAGGED_ADDR_CTRL if TCF0 was set to NONE. Fix it by making
the code for the NONE case match the others.

Signed-off-by: Peter Collingbourne <pcc@google.com>
Link: https://linux-review.googlesource.com/id/Iefbea66cf7d2b4c80b82f9639b9ea7f33f7fac53
Fixes: af5ce95282 ("arm64: mte: Allow user control of the generated random tags via prctl()")
Reviewed-by: Catalin Marinas <catalin.marinas@arm.com>
Link: https://lore.kernel.org/r/20201203075110.2781021-1-pcc@google.com
Signed-off-by: Will Deacon <will@kernel.org>
2020-12-03 18:17:35 +00:00
Mark Rutland
701f49065e arm64: mark __system_matches_cap as __maybe_unused
Now that the PAN toggling has been removed, the only user of
__system_matches_cap() is has_generic_auth(), which is only built when
CONFIG_ARM64_PTR_AUTH is selected, and Qian reports that this results in
a build-time warning when CONFIG_ARM64_PTR_AUTH is not selected:

| arch/arm64/kernel/cpufeature.c:2649:13: warning: '__system_matches_cap' defined but not used [-Wunused-function]
|  static bool __system_matches_cap(unsigned int n)
|              ^~~~~~~~~~~~~~~~~~~~

It's tricky to restructure things to prevent this, so let's mark
__system_matches_cap() as __maybe_unused, as we used to do for the other
user of __system_matches_cap() which we just removed.

Reported-by: Qian Cai <qcai@redhat.com>
Suggested-by: Qian Cai <qcai@redhat.com>
Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Link: https://lore.kernel.org/r/20201203152403.26100-1-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-03 16:54:57 +00:00
Peter Zijlstra
d55863db1d arm64/mm: Implement pXX_leaf_size() support
ARM64 has non-pagetable aligned large page support with PTE_CONT, when
this bit is set the page is part of a super-page. Match the hugetlb
code and support these super pages for PTE and PMD levels.

This enables PERF_SAMPLE_{DATA,CODE}_PAGE_SIZE to report accurate
pagetable leaf sizes.

Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Acked-by: Will Deacon <will@kernel.org>
Link: https://lkml.kernel.org/r/20201126125747.GG2414@hirez.programming.kicks-ass.net
2020-12-03 10:14:51 +01:00
Linus Torvalds
3bb61aa618 arm64 fixes for -rc7
- Fix numerous issues with instrumentation and exception entry
 
 - Fix hideous typo in unused register field definition
 -----BEGIN PGP SIGNATURE-----
 
 iQFEBAABCgAuFiEEPxTL6PPUbjXGY88ct6xw3ITBYzQFAl/HvbwQHHdpbGxAa2Vy
 bmVsLm9yZwAKCRC3rHDchMFjNFTMB/oD0ucfP6CH65w+7Sbsv2L8FABfYzSrA9gP
 f1cmeh1+MyRN4Nbx2ves5wcRGoX1CgZ8KFAmLXG6yyn7UDA/q27CTELknwobhOft
 tQIPB2hFDW9qq3VBXFReL3aoXLnWUiRL3nBxQFt7LG1Xor/ivEb1ZFht351UklDh
 u1P6NVptpjXFuGPvdqxkHo2WzT0QHI57MRuc1l7I1FRo4dV1nKSlwohu0Ydii4q9
 8oLhx77Ga1SWK80IztNmpo7CSMP/FLGDwbUE3vAaftUJx5CBt+lYR1CeWNACSEvy
 22y7CkJWKGQccG62oHI7zQaZm1+fum70ndP5dDlfQW/BcCaz8vRH
 =KSDc
 -----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:
 "I'm sad to say that we've got an unusually large arm64 fixes pull for
  rc7 which addresses numerous significant instrumentation issues with
  our entry code.

  Without these patches, lockdep is hopelessly unreliable in some
  configurations [1,2] and syzkaller is therefore not a lot of use
  because it's so noisy.

  Although much of this has always been broken, it appears to have been
  exposed more readily by other changes such as 044d0d6de9 ("lockdep:
  Only trace IRQ edges") and general lockdep improvements around IRQ
  tracing and NMIs.

  Fixing this properly required moving much of the instrumentation hooks
  from our entry assembly into C, which Mark has been working on for the
  last few weeks. We're not quite ready to move to the recently added
  generic functions yet, but the code here has been deliberately written
  to mimic that closely so we can look at cleaning things up once we
  have a bit more breathing room.

  Having said all that, the second version of these patches was posted
  last week and I pushed it into our CI (kernelci and cki) along with a
  commit which forced on PROVE_LOCKING, NOHZ_FULL and
  CONTEXT_TRACKING_FORCE. The result? We found a real bug in the
  md/raid10 code [3].

  Oh, and there's also a really silly typo patch that's unrelated.

  Summary:

   - Fix numerous issues with instrumentation and exception entry

   - Fix hideous typo in unused register field definition"

[1] https://lore.kernel.org/r/CACT4Y+aAzoJ48Mh1wNYD17pJqyEcDnrxGfApir=-j171TnQXhw@mail.gmail.com
[2] https://lore.kernel.org/r/20201119193819.GA2601289@elver.google.com
[3] https://lore.kernel.org/r/94c76d5e-466a-bc5f-e6c2-a11b65c39f83@redhat.com

* tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux:
  arm64: mte: Fix typo in macro definition
  arm64: entry: fix EL1 debug transitions
  arm64: entry: fix NMI {user, kernel}->kernel transitions
  arm64: entry: fix non-NMI kernel<->kernel transitions
  arm64: ptrace: prepare for EL1 irq/rcu tracking
  arm64: entry: fix non-NMI user<->kernel transitions
  arm64: entry: move el1 irq/nmi logic to C
  arm64: entry: prepare ret_to_user for function call
  arm64: entry: move enter_from_user_mode to entry-common.c
  arm64: entry: mark entry code as noinstr
  arm64: mark idle code as noinstr
  arm64: syscall: exit userspace before unmasking exceptions
2020-12-02 12:27:37 -08:00
Mark Rutland
1517c4facf arm64: uaccess: remove vestigal UAO support
Now that arm64 no longer uses UAO, remove the vestigal feature detection
code and Kconfig text.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201202131558.39270-13-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:49:11 +00:00
Mark Rutland
7cf283c7bd arm64: uaccess: remove redundant PAN toggling
Some code (e.g. futex) needs to make privileged accesses to userspace
memory, and uses uaccess_{enable,disable}_privileged() in order to
permit this. All other uaccess primitives use LDTR/STTR, and never need
to toggle PAN.

Remove the redundant PAN toggling.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201202131558.39270-12-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:49:11 +00:00
Mark Rutland
b5a5a01d8e arm64: uaccess: remove addr_limit_user_check()
Now that set_fs() is gone, addr_limit_user_check() is redundant. Remove
the checks and associated thread flag.

To ensure that _TIF_WORK_MASK can be used as an immediate value in an
AND instruction (as it is in `ret_to_user`), TIF_MTE_ASYNC_FAULT is
renumbered to keep the constituent bits of _TIF_WORK_MASK contiguous.

There should be no functional change as a result of this patch.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201202131558.39270-11-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:49:11 +00:00
Mark Rutland
3d2403fd10 arm64: uaccess: remove set_fs()
Now that the uaccess primitives dont take addr_limit into account, we
have no need to manipulate this via set_fs() and get_fs(). Remove
support for these, along with some infrastructure this renders
redundant.

We no longer need to flip UAO to access kernel memory under KERNEL_DS,
and head.S unconditionally clears UAO for all kernel configurations via
an ERET in init_kernel_el. Thus, we don't need to dynamically flip UAO,
nor do we need to context-switch it. However, we still need to adjust
PAN during SDEI entry.

Masking of __user pointers no longer needs to use the dynamic value of
addr_limit, and can use a constant derived from the maximum possible
userspace task size. A new TASK_SIZE_MAX constant is introduced for
this, which is also used by core code. In configurations supporting
52-bit VAs, this may include a region of unusable VA space above a
48-bit TTBR0 limit, but never includes any portion of TTBR1.

Note that TASK_SIZE_MAX is an exclusive limit, while USER_DS and
KERNEL_DS were inclusive limits, and is converted to a mask by
subtracting one.

As the SDEI entry code repurposes the otherwise unnecessary
pt_regs::orig_addr_limit field to store the TTBR1 of the interrupted
context, for now we rename that to pt_regs::sdei_ttbr1. In future we can
consider factoring that out.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Acked-by: James Morse <james.morse@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201202131558.39270-10-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:49:11 +00:00
Mark Rutland
7b90dc40e3 arm64: uaccess cleanup macro naming
Now the uaccess primitives use LDTR/STTR unconditionally, the
uao_{ldp,stp,user_alternative} asm macros are misnamed, and have a
redundant argument. Let's remove the redundant argument and rename these
to user_{ldp,stp,ldst} respectively to clean this up.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Reviewed-by: Robin Murohy <robin.murphy@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201202131558.39270-9-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:49:11 +00:00
Mark Rutland
fc703d8013 arm64: uaccess: split user/kernel routines
This patch separates arm64's user and kernel memory access primitives
into distinct routines, adding new __{get,put}_kernel_nofault() helpers
to access kernel memory, upon which core code builds larger copy
routines.

The kernel access routines (using LDR/STR) are not affected by PAN (when
legitimately accessing kernel memory), nor are they affected by UAO.
Switching to KERNEL_DS may set UAO, but this does not adversely affect
the kernel access routines.

The user access routines (using LDTR/STTR) are not affected by PAN (when
legitimately accessing user memory), but are affected by UAO. As these
are only legitimate to use under USER_DS with UAO clear, this should not
be problematic.

Routines performing atomics to user memory (futex and deprecated
instruction emulation) still need to transiently clear PAN, and these
are left as-is. These are never used on kernel memory.

Subsequent patches will refactor the uaccess helpers to remove redundant
code, and will also remove the redundant PAN/UAO manipulation.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201202131558.39270-8-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:49:11 +00:00
Mark Rutland
f253d827f3 arm64: uaccess: refactor __{get,put}_user
As a step towards implementing __{get,put}_kernel_nofault(), this patch
splits most user-memory specific logic out of __{get,put}_user(), with
the memory access and fault handling in new __{raw_get,put}_mem()
helpers.

For now the LDR/LDTR patching is left within the *get_mem() helpers, and
will be removed in a subsequent patch.

There should be no functional change as a result of this patch.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201202131558.39270-7-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:49:11 +00:00
Mark Rutland
9e94fdade4 arm64: uaccess: simplify __copy_user_flushcache()
Currently __copy_user_flushcache() open-codes raw_copy_from_user(), and
doesn't use uaccess_mask_ptr() on the user address. Let's have it call
raw_copy_from_user(), which is both a simplification and ensures that
user pointers are masked under speculation.

There should be no functional change as a result of this patch.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Reviewed-by: Robin Murphy <robin.murphy@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201202131558.39270-6-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:49:10 +00:00
Mark Rutland
923e1e7d82 arm64: uaccess: rename privileged uaccess routines
We currently have many uaccess_*{enable,disable}*() variants, which
subsequent patches will cut down as part of removing set_fs() and
friends. Once this simplification is made, most uaccess routines will
only need to ensure that the user page tables are mapped in TTBR0, as is
currently dealt with by uaccess_ttbr0_{enable,disable}().

The existing uaccess_{enable,disable}() routines ensure that user page
tables are mapped in TTBR0, and also disable PAN protections, which is
necessary to be able to use atomics on user memory, but also permit
unrelated privileged accesses to access user memory.

As preparatory step, let's rename uaccess_{enable,disable}() to
uaccess_{enable,disable}_privileged(), highlighting this caveat and
discouraging wider misuse. Subsequent patches can reuse the
uaccess_{enable,disable}() naming for the common case of ensuring the
user page tables are mapped in TTBR0.

There should be no functional change as a result of this patch.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201202131558.39270-5-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:49:10 +00:00
Mark Rutland
2376e75cc7 arm64: sdei: explicitly simulate PAN/UAO entry
In preparation for removing addr_limit and set_fs() we must decouple the
SDEI PAN/UAO manipulation from the uaccess code, and explicitly
reinitialize these as required.

SDEI enters the kernel with a non-architectural exception, and prior to
the most recent revision of the specification (ARM DEN 0054B), PSTATE
bits (e.g. PAN, UAO) are not manipulated in the same way as for
architectural exceptions. Notably, older versions of the spec can be
read ambiguously as to whether PSTATE bits are inherited unchanged from
the interrupted context or whether they are generated from scratch, with
TF-A doing the latter.

We have three cases to consider:

1) The existing TF-A implementation of SDEI will clear PAN and clear UAO
   (along with other bits in PSTATE) when delivering an SDEI exception.

2) In theory, implementations of SDEI prior to revision B could inherit
   PAN and UAO (along with other bits in PSTATE) unchanged from the
   interrupted context. However, in practice such implementations do not
   exist.

3) Going forward, new implementations of SDEI must clear UAO, and
   depending on SCTLR_ELx.SPAN must either inherit or set PAN.

As we can ignore (2) we can assume that upon SDEI entry, UAO is always
clear, though PAN may be clear, inherited, or set per SCTLR_ELx.SPAN.
Therefore, we must explicitly initialize PAN, but do not need to do
anything for UAO.

Considering what we need to do:

* When set_fs() is removed, force_uaccess_begin() will have no HW
  side-effects. As this only clears UAO, which we can assume has already
  been cleared upon entry, this is not a problem. We do not need to add
  code to manipulate UAO explicitly.

* PAN may be cleared upon entry (in case 1 above), so where a kernel is
  built to use PAN and this is supported by all CPUs, the kernel must
  set PAN upon entry to ensure expected behaviour.

* PAN may be inherited from the interrupted context (in case 3 above),
  and so where a kernel is not built to use PAN or where PAN support is
  not uniform across CPUs, the kernel must clear PAN to ensure expected
  behaviour.

This patch reworks the SDEI code accordingly, explicitly setting PAN to
the expected state in all cases. To cater for the cases where the kernel
does not use PAN or this is not uniformly supported by hardware we add a
new cpu_has_pan() helper which can be used regardless of whether the
kernel is built to use PAN.

The existing system_uses_ttbr0_pan() is redefined in terms of
system_uses_hw_pan() both for clarity and as a minor optimization when
HW PAN is not selected.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Reviewed-by: James Morse <james.morse@arm.com>
Cc: James Morse <james.morse@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201202131558.39270-3-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:48:57 +00:00
Mark Rutland
a0ccf2ba68 arm64: sdei: move uaccess logic to arch/arm64/
The SDEI support code is split across arch/arm64/ and drivers/firmware/,
largley this is split so that the arch-specific portions are under
arch/arm64, and the management logic is under drivers/firmware/.
However, exception entry fixups are currently under drivers/firmware.

Let's move the exception entry fixups under arch/arm64/. This
de-clutters the management logic, and puts all the arch-specific
portions in one place. Doing this also allows the fixups to be applied
earlier, so things like PAN and UAO will be in a known good state before
we run other logic. This will also make subsequent refactoring easier.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Reviewed-by: James Morse <james.morse@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201202131558.39270-2-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:46:14 +00:00
Mark Rutland
d87a8e65b5 arm64: head.S: always initialize PSTATE
As with SCTLR_ELx and other control registers, some PSTATE bits are
UNKNOWN out-of-reset, and we may not be able to rely on hardware or
firmware to initialize them to our liking prior to entry to the kernel,
e.g. in the primary/secondary boot paths and return from idle/suspend.

It would be more robust (and easier to reason about) if we consistently
initialized PSTATE to a default value, as we do with control registers.
This will ensure that the kernel is not adversely affected by bits it is
not aware of, e.g. when support for a feature such as PAN/UAO is
disabled.

This patch ensures that PSTATE is consistently initialized at boot time
via an ERET. This is not intended to relax the existing requirements
(e.g. DAIF bits must still be set prior to entering the kernel). For
features detected dynamically (which may require system-wide support),
it is still necessary to subsequently modify PSTATE.

As ERET is not always a Context Synchronization Event, an ISB is placed
before each exception return to ensure updates to control registers have
taken effect. This handles the kernel being entered with SCTLR_ELx.EOS
clear (or any future control bits being in an UNKNOWN state).

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201113124937.20574-6-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:44:03 +00:00
Mark Rutland
2ffac9e3fd arm64: head.S: cleanup SCTLR_ELx initialization
Let's make SCTLR_ELx initialization a bit clearer by using meaningful
names for the initialization values, following the same scheme for
SCTLR_EL1 and SCTLR_EL2.

These definitions will be used more widely in subsequent patches.

There should be no functional change as a result of this patch.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201113124937.20574-5-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:44:03 +00:00
Mark Rutland
ecbb11ab3e arm64: head.S: rename el2_setup -> init_kernel_el
For a while now el2_setup has performed some basic initialization of EL1
even when the kernel is booted at EL1, so the name is a little
misleading. Further, some comments are stale as with VHE it doesn't drop
the CPU to EL1.

To clarify things, rename el2_setup to init_kernel_el, and update
comments to be clearer as to the function's purpose.

There should be no functional change as a result of this patch.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201113124937.20574-4-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:44:03 +00:00
Mark Rutland
515d5c8a13 arm64: add C wrappers for SET_PSTATE_*()
To make callsites easier to read, add trivial C wrappers for the
SET_PSTATE_*() helpers, and convert trivial uses over to these. The new
wrappers will be used further in subsequent patches.

There should be no functional change as a result of this patch.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201113124937.20574-3-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:44:02 +00:00
Mark Rutland
f80d034086 arm64: ensure ERET from kthread is illegal
For consistency, all tasks have a pt_regs reserved at the highest
portion of their task stack. Among other things, this ensures that a
task's SP is always pointing within its stack rather than pointing
immediately past the end.

While it is never legitimate to ERET from a kthread, we take pains to
initialize pt_regs for kthreads as if this were legitimate. As this is
never legitimate, the effects of an erroneous return are rarely tested.

Let's simplify things by initializing a kthread's pt_regs such that an
ERET is caught as an illegal exception return, and removing the explicit
initialization of other exception context. Note that as
spectre_v4_enable_task_mitigation() only manipulates the PSTATE within
the unused regs this is safe to remove.

As user tasks will have their exception context initialized via
start_thread() or start_compat_thread(), this should only impact cases
where something has gone very wrong and we'd like that to be clearly
indicated.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201113124937.20574-2-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2020-12-02 19:44:02 +00:00
Yanan Wang
7d894834a3 KVM: arm64: Add usage of stage 2 fault lookup level in user_mem_abort()
If we get a FSC_PERM fault, just using (logging_active && writable) to
determine calling kvm_pgtable_stage2_map(). There will be two more cases
we should consider.

(1) After logging_active is configged back to false from true. When we
get a FSC_PERM fault with write_fault and adjustment of hugepage is needed,
we should merge tables back to a block entry. This case is ignored by still
calling kvm_pgtable_stage2_relax_perms(), which will lead to an endless
loop and guest panic due to soft lockup.

(2) We use (FSC_PERM && logging_active && writable) to determine
collapsing a block entry into a table by calling kvm_pgtable_stage2_map().
But sometimes we may only need to relax permissions when trying to write
to a page other than a block.
In this condition,using kvm_pgtable_stage2_relax_perms() will be fine.

The ISS filed bit[1:0] in ESR_EL2 regesiter indicates the stage2 lookup
level at which a D-abort or I-abort occurred. By comparing granule of
the fault lookup level with vma_pagesize, we can strictly distinguish
conditions of calling kvm_pgtable_stage2_relax_perms() or
kvm_pgtable_stage2_map(), and the above two cases will be well considered.

Suggested-by: Keqian Zhu <zhukeqian1@huawei.com>
Signed-off-by: Yanan Wang <wangyanan55@huawei.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Acked-by: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201201201034.116760-4-wangyanan55@huawei.com
2020-12-02 09:53:29 +00:00
Yanan Wang
3a0b870e34 KVM: arm64: Fix handling of merging tables into a block entry
When dirty logging is enabled, we collapse block entries into tables
as necessary. If dirty logging gets canceled, we can end-up merging
tables back into block entries.

When this happens, we must not only free the non-huge page-table
pages but also invalidate all the TLB entries that can potentially
cover the block. Otherwise, we end-up with multiple possible translations
for the same physical page, which can legitimately result in a TLB
conflict.

To address this, replease the bogus invalidation by IPA with a full
VM invalidation. Although this is pretty heavy handed, it happens
very infrequently and saves a bunch of invalidations by IPA.

Signed-off-by: Yanan Wang <wangyanan55@huawei.com>
[maz: fixup commit message]
Signed-off-by: Marc Zyngier <maz@kernel.org>
Acked-by: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201201201034.116760-3-wangyanan55@huawei.com
2020-12-02 09:42:36 +00:00
Yanan Wang
5c646b7e1d KVM: arm64: Fix memory leak on stage2 update of a valid PTE
When installing a new leaf PTE onto an invalid ptep, we need to
get_page(ptep) to account for the new mapping.

However, simply updating a valid PTE shouldn't result in any
additional refcounting, as there is new mapping. This otherwise
results in a page being forever wasted.

Address this by fixing-up the refcount in stage2_map_walker_try_leaf()
if the PTE was already valid, balancing out the later get_page()
in stage2_map_walk_leaf().

Signed-off-by: Yanan Wang <wangyanan55@huawei.com>
[maz: update commit message, add comment in the code]
Signed-off-by: Marc Zyngier <maz@kernel.org>
Acked-by: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201201201034.116760-2-wangyanan55@huawei.com
2020-12-02 09:42:24 +00:00
Nathan Chancellor
59612b24f7 kbuild: Hoist '--orphan-handling' into Kconfig
Currently, '--orphan-handling=warn' is spread out across four different
architectures in their respective Makefiles, which makes it a little
unruly to deal with in case it needs to be disabled for a specific
linker version (in this case, ld.lld 10.0.1).

To make it easier to control this, hoist this warning into Kconfig and
the main Makefile so that disabling it is simpler, as the warning will
only be enabled in a couple places (main Makefile and a couple of
compressed boot folders that blow away LDFLAGS_vmlinx) and making it
conditional is easier due to Kconfig syntax. One small additional
benefit of this is saving a call to ld-option on incremental builds
because we will have already evaluated it for CONFIG_LD_ORPHAN_WARN.

To keep the list of supported architectures the same, introduce
CONFIG_ARCH_WANT_LD_ORPHAN_WARN, which an architecture can select to
gain this automatically after all of the sections are specified and size
asserted. A special thanks to Kees Cook for the help text on this
config.

Link: https://github.com/ClangBuiltLinux/linux/issues/1187
Acked-by: Kees Cook <keescook@chromium.org>
Acked-by: Michael Ellerman <mpe@ellerman.id.au> (powerpc)
Reviewed-by: Nick Desaulniers <ndesaulniers@google.com>
Tested-by: Nick Desaulniers <ndesaulniers@google.com>
Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
2020-12-01 22:45:36 +09:00
Will Deacon
eec3bf6861 arm64: sdei: Push IS_ENABLED() checks down to callee functions
Handling all combinations of the VMAP_STACK and SHADOW_CALL_STACK options
in sdei_arch_get_entry_point() makes the code difficult to read,
particularly when considering the error and cleanup paths.

Move the checking of these options into the callee functions, so that
they return early if the relevant option is not enabled.

Signed-off-by: Will Deacon <will@kernel.org>
2020-12-01 11:24:16 +00:00
Sami Tolvanen
ac20ffbb02 arm64: scs: use vmapped IRQ and SDEI shadow stacks
Use scs_alloc() to allocate also IRQ and SDEI shadow stacks instead of
using statically allocated stacks.

Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
Acked-by: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201130233442.2562064-3-samitolvanen@google.com
[will: Move CONFIG_SHADOW_CALL_STACK check into init_irq_scs()]
Signed-off-by: Will Deacon <will@kernel.org>
2020-12-01 11:23:34 +00:00
Heinrich Schuchardt
d0c6707ca4
arm64: dts: allwinner: H5: NanoPi Neo Plus2: phy-mode rgmii-id
Since commit bbc4d71d63 ("net: phy: realtek: fix rtl8211e rx/tx
delay config") network is broken on the NanoPi Neo Plus2.

This patch changes the phy-mode to use internal delays both for RX and TX
as has been done for other boards affected by the same commit.

Fixes: bbc4d71d63 ("net: phy: realtek: fix rtl8211e rx/tx delay config")
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Link: https://lore.kernel.org/r/20201129194512.1475586-1-xypron.glpk@gmx.de
2020-12-01 11:33:33 +01:00
Heinrich Schuchardt
c2b111e59a
arm64: dts: allwinner: A64 Sopine: phy-mode rgmii-id
Since commit bbc4d71d63 ("net: phy: realtek: fix rtl8211e rx/tx
delay config") iSCSI booting fails on the Pine A64 LTS.

This patch changes the phy-mode to use internal delays both for RX and TX
as has been done for other boards affected by the same commit.

Fixes: bbc4d71d63 ("net: phy: realtek: fix rtl8211e rx/tx delay config")
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Link: https://lore.kernel.org/r/20201129162627.1244808-1-xypron.glpk@gmx.de
2020-12-01 11:33:29 +01:00
Adam Ford
0b84862688 arm64: dts: imx8mm-beacon-som: Assign PMIC clock
The PMIC throws an errors because the clock isn't assigned to it.
Fix this by assigning the clocks info.

Signed-off-by: Adam Ford <aford173@gmail.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-12-01 09:49:49 +08:00
Adam Ford
6b5cd77371 arm64: dts: imx8mm-beacon-som: Configure RTC aliases
On the i.MX8MM Beacon SOM, there is an RTC chip which is fed power
from the baseboard during power off.  The SNVS RTC integrated into
the SoC is not fed power.  Depending on the order the modules are
loaded, this can be a problem if the external RTC isn't rtc0.

Make the alias for rtc0 point to the external RTC all the time and
rtc1 point to the SVNS in order to correctly hold date/time over
a power-cycle.

Signed-off-by: Adam Ford <aford173@gmail.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-12-01 09:49:39 +08:00
Adam Ford
b9cf7d3b65 arm64: dts: imx8mn: Add node for SPDIF
The i.MX8M Nano can support SPDIF which is compatible to the
IP used on the i.MX35.

Add the node.

Signed-off-by: Adam Ford <aford173@gmail.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-12-01 09:35:27 +08:00
Adam Ford
cca69ef6eb arm64: dts: imx8mn: Add support for micfil
The i.MX8M Nano has supports the MICFIL digital interface.
It's a 16-bit audio signal from a PDM microphone bitstream.
The driver is already in the kernel, but the node is missing.

Add the micfil node.

Signed-off-by: Adam Ford <aford173@gmail.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-12-01 09:35:27 +08:00
Adam Ford
9e98600697 arm64: dts: imx8mn: Add SAI nodes
The i.MX8M Nano has several SAI nodes available to it.
Enable them.

Signed-off-by: Adam Ford <aford173@gmail.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-12-01 09:35:27 +08:00
Adam Ford
970406eaef arm64: dts: imx8mn: Enable Asynchronous Sample Rate Converter
The driver exists for the Enhanced Asynchronous Sample Rate Converter
(EASRC) Controller, but there isn't a device tree entry for it.

On the vendor kernel, they put this on a spba-bus for SDMA support.

Add the node for the spba-bus with the easrc node inside.

Signed-off-by: Adam Ford <aford173@gmail.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-12-01 09:35:27 +08:00
Vladimir Oltean
2e6cde9687 arm64: dts: ls1028a: make the eMMC and SD card controllers use fixed indices
As the boot order in the kernel continues to change, sometimes it may
happen that the eSDHC controller mmc@2150000 (the one for eMMC) gets
probed before the one at mmc@2140000 (for external SD cards). The effect
is that the eMMC controller gets the /dev/mmcblk0 name, and the SD card
gets /dev/mmcblk1.

Since the introduction of this SoC, that has never happened in practice,
even though it was never guaranteed in theory. Setting
"root=/dev/mmcblk0p2" in /proc/cmdline has always caused the kernel to
use the second partition from the SD card as the rootfs.

The NXP development boards are typically shipped with either
- LSDK, which uses "root=UUID=", or
- OpenIL, which uses "root=/dev/mmcblkNp2"

So for OpenIL, let's preserve that old behavior by adding some aliases
which create naming consistency (for LSDK it doesn't matter):
- the SD card controller uses /dev/mmcblk0
- the eMMC controller uses /dev/mmcblk1

For the Kontron SL28 boards, Michael Walle says that they are shipped
with "root=UUID=" already, so the probing order doesn't matter, but it
is more natural to him for /dev/mmcblk0 to be the eMMC, so let's do it
the other way around there.

The aliases are parsed by mmc_alloc_host() in drivers/mmc/core/host.c.

Cc: Ashish Kumar <Ashish.Kumar@nxp.com>
Cc: Yangbo Lu <yangbo.lu@nxp.com>
Cc: Michael Walle <michael@walle.cc>
Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Acked-by: Michael Walle <michael@walle.cc>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-12-01 09:35:27 +08:00
Guido Günther
eecc662ff3 arm64: defconfig: Enable more Librem 5 hardware
This enables

- CONFIG_BATTERY_MAX17042: battery chip
- CONFIG_CHARGER_BQ25980: charge controller
- CONFIG_DRM_PANEL_MANTIX_MLAF057WE5: LCD panel
- CONFIG_GNSS/CONFIG_GNSS_MTK_SERIAL: GNSS receiver
- CONFIG_IIO_ST_LSM6DSX: IMU
- CONFIG_IMX_DCSS: 2nd display controller
- CONFIG_LEDS_LM3692X: LCD backlight
- CONFIG_REGULATOR_TPS65132: regulator for the LCD panel
- CONFIG_TOUCHSCREEN_EDT_FT5X06: touch controller
- CONFIG_TYPEC_TPS6598X: USB PD controller
- CONFIG_VCNL4000: ambient light and proximity sensor

as modules.

Signed-off-by: Guido Günther <agx@sigxcpu.org>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-12-01 09:13:39 +08:00
Dongjin Kim
b6a1c8a1ea arm64: dts: meson-sm1: fix typo in opp table
The freqency 1512000000 should be 1500000000.

Signed-off-by: Dongjin Kim <tobetter@gmail.com>
Fixes: 3d9e764830 ("arm64: dts: meson-sm1-sei610: enable DVFS")
Reviewed-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201130060320.GA30098@anyang-linuxfactory-or-kr
2020-11-30 16:12:46 -08:00
Christian Hewitt
2493a9a515 arm64: dts: meson: add KHAMSIN IR remote node to SML5442TW
Set the IR keymap to the KHAMSIN remote shipped with the SML5442TW.

Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201126050440.6273-1-christianshewitt@gmail.com
2020-11-30 16:11:05 -08:00
Christian Hewitt
6714f28178 arm64: dts: meson: update the Khadas VIM3/3L LED bindings
Update the VIM3/3L common dtsi to use the new function/color bindings.

Suggested-by: Artem Lapkin <art@khadas.com>
Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
Reviewed-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201125052914.4092-1-christianshewitt@gmail.com
2020-11-30 16:10:35 -08:00
Artem Lapkin
b6c605e00c arm64: dts: meson: fix spi-max-frequency on Khadas VIM2
The max frequency for the w25q32 (VIM v1.2) and w25q128 (VIM v1.4) spifc
chip should be 104Mhz not 30MHz.

Fixes: b8b74dda39 ("ARM64: dts: meson-gxm: Add support for Khadas VIM2")
Signed-off-by: Artem Lapkin <art@khadas.com>
Reviewed-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201125024001.19036-1-christianshewitt@gmail.com
2020-11-30 16:10:00 -08:00
Christian Hewitt
a6077652cb arm64: dts: meson: add rtc aliases to meson-khadas-vim3.dtsi
Tweak the node name to make it aliasable, then add aliases for the
on-board RTC chip and meson-vrtc timer so they probe as rtc0 and
rtc1 respectively.

before:

VIM3:~ # dmesg | grep rtc
[    3.622530] meson-vrtc ff8000a8.rtc: registered as rtc0
[    3.622574] meson-vrtc ff8000a8.rtc: setting system clock to 1970-01-01T00:00:03 UTC (3)
[    3.646936] rtc-hym8563 0-0051: no valid clock/calendar values available
[    3.647125] rtc-hym8563 0-0051: registered as rtc1
[    3.852382] rtc-hym8563 0-0051: no valid clock/calendar values available

after:

VIM3:~ # dmesg | grep rtc
[    3.583735] meson-vrtc ff8000a8.rtc: registered as rtc1
[    3.633888] rtc-hym8563 0-0051: no valid clock/calendar values available
[    3.634120] rtc-hym8563 0-0051: registered as rtc0
[    3.635250] rtc-hym8563 0-0051: no valid clock/calendar values available
[    3.635267] rtc-hym8563 0-0051: hctosys: unable to read the hardware clock
[    3.852632] rtc-hym8563 0-0051: no valid clock/calendar values available

Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201124145338.17137-1-christianshewitt@gmail.com
2020-11-30 16:09:05 -08:00
Christian Hewitt
4592bfe9d9 arm64: dts: meson: Add capacity-dmips-mhz attributes to GXM
GXM (S912) is a big-little design with CPUs 0-3 clocked at 1.5GHz
and CPUs 4-7 at 1.0GHz. Adding capacity-dmips-mhz attributes allows
the scheduler to factor the different clock speeds into capacity
calculations and prefer the higher-clocked cluster to improve
overall performance.

This was inspired by the similar change for G12B [0] boards. The
diference here is that all cores are A53's so the same dmips-mhz
value is used.

VIM2:~ # cat /sys/devices/system/cpu/cpu*/cpufreq/scaling_cur_freq
1512000
1512000
1512000
1512000
1000000
1000000
1000000
1000000

before:

VIM2:~ # cat /sys/devices/system/cpu/cpu*/cpu_capacity
1024
1024
1024
1024
1024
1024
1024
1024

after:

VIM2:~ # cat /sys/devices/system/cpu/cpu*/cpu_capacity
1024
1024
1024
1024
677
677
677
677

The after value matches my table-napkin calculation:

(1000000 / 1512000 = 0.661) * 1024 = 677

[0] 6eeaf4d245

Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
Reviewed-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201124121740.25704-1-christianshewitt@gmail.com
2020-11-30 16:07:33 -08:00
Neil Armstrong
9715b01da6 arm64: dts: meson-axg-s400: enable PCIe M.2 Key E slots
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201120153229.3920123-5-narmstrong@baylibre.com
2020-11-30 15:54:25 -08:00
Neil Armstrong
5b3a9c2092 arm64: dts: meson-axg: add PCIe nodes
This adds the nodes for the :
- AXG PCIe PHY, using the shared analog PCIe/MIPI DSI PHY
- 2x AXG PCIe controllers

Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201120153229.3920123-4-narmstrong@baylibre.com
2020-11-30 15:54:25 -08:00
Neil Armstrong
3d3f1dfa08 arm64: dts: meson-axg: add MIPI DSI PHY nodes
This adds the nodes for :
- MIPI DSI+PCIe analog phy
- MIPI D-PHY

Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201120152131.3918814-3-narmstrong@baylibre.com
2020-11-30 15:54:25 -08:00
Neil Armstrong
78a6dcb527 arm64: dts: meson-axg: add PWRC node
This adds the power controller PWRC node and the corresponding ethernet power domain.

Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201120152131.3918814-2-narmstrong@baylibre.com
2020-11-30 15:54:24 -08:00
Christian Hewitt
287eb2be40 arm64: dts: meson: enable rtc node on Khadas VIM1/VIM2 boards
Enable the rtc node on VIM1/VIM2 boards so users can simply attach a power
cell and use the on-board RTC without modifying the device-tree.

Cold boot with no cell attached is gracefully handled:

VIM2:~ # dmesg | grep rtc
[    7.716150] rtc-hym8563 1-0051: no valid clock/calendar values available
[    7.716957] rtc-hym8563 1-0051: registered as rtc0
[    7.729850] rtc-hym8563 1-0051: no valid clock/calendar values available
[    7.729877] rtc-hym8563 1-0051: hctosys: unable to read the hardware clock
[    8.126768] rtc-hym8563 1-0051: no valid clock/calendar values available

Warm boot (and any boot with cell attached) recalls stored values resulting
in consistently faster (re)boot times:

VIM2:~ # dmesg | grep rtc
[    7.441671] rtc-hym8563 1-0051: registered as rtc0
[    7.442663] rtc-hym8563 1-0051: setting system clock to 2020-11-16T05:49:59 UTC (1605505799)

Suggested-by: Artem Lapkin <art@khadas.com>
Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
Reviewed-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Link: https://lore.kernel.org/r/20201116064147.12062-1-christianshewitt@gmail.com
2020-11-30 15:54:24 -08:00
Jagan Teki
eeffc0fbd0 arm64: defconfig: Enable RTC_DRV_HYM8563
RTC HYM8563 used in the ARM64 Rockchip SoC's SDIO power
sequence enablement.

Enable it as module.

Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Link: https://lore.kernel.org/r/20201023181814.220974-1-jagan@amarulasolutions.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 22:23:58 +01:00
Vincenzo Frascino
9e5344e0ff arm64: mte: Fix typo in macro definition
UL in the definition of SYS_TFSR_EL1_TF1 was misspelled causing
compilation issues when trying to implement in kernel MTE async
mode.

Fix the macro correcting the typo.

Note: MTE async mode will be introduced with a future series.

Fixes: c058b1c4a5 ("arm64: mte: system register definitions")
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Will Deacon <will@kernel.org>
Signed-off-by: Vincenzo Frascino <vincenzo.frascino@arm.com>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Link: https://lore.kernel.org/r/20201130170709.22309-1-vincenzo.frascino@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
2020-11-30 17:36:52 +00:00
Bjorn Andersson
956e9c85f4 arm64: dts: qcom: c630: Define eDP bridge and panel
The Lenovo Yoga C630 drives the Boe NV133FHM-N61 eDP display from DSI
using a TI SN65DSI86 bridge chip on I2C 10. Define the bridge and eDP
panel and enable the display blocks.

Tested-by: Steev Klimaszewski <steev@kali.org>
Acked-by: Shawn Guo <shawn.guo@linaro.org>
Link: https://lore.kernel.org/r/20201128034231.89750-1-bjorn.andersson@linaro.org
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
2020-11-30 11:30:30 -06:00
Bjorn Andersson
f55d373f79 arm64: dts: qcom: c630: Fix pinctrl pins properties
The "pins" property takes an array of pin _names_, not pin numbers. Fix
this.

Tested-by: Steev Klimaszewski <steev@kali.org>
Fixes: 44acee2078 ("arm64: dts: qcom: Add Lenovo Yoga C630")
Link: https://lore.kernel.org/r/20201130170028.319798-1-bjorn.andersson@linaro.org
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
2020-11-30 11:29:42 -06:00
Bjorn Andersson
11d0e4f281 arm64: dts: qcom: c630: Polish i2c-hid devices
The numbering of the i2c busses differs from ACPI and a number of typos
was made in the original patch. Further more the irq flags for the
various resources was not correct and i2c3 only has one of the two
client devices active in any one device.

Also label the various devices, for easier comparison with the ACPI
tables.

Tested-by: Steev Klimaszewski <steev@kali.org>
Fixes: 44acee2078 ("arm64: dts: qcom: Add Lenovo Yoga C630")
Link: https://lore.kernel.org/r/20201130165924.319708-1-bjorn.andersson@linaro.org
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
2020-11-30 11:29:27 -06:00
Ajit Pandey
96ddfbf46a arm64: dts: qcom: sc7180: Add lpass cpu node for I2S driver
Add the I2S controller node to sc7180 dtsi.
Add pinmux for primary and secondary I2S.

Reviewed-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Ajit Pandey <ajitp@codeaurora.org>
Signed-off-by: Cheng-Yi Chiang <cychiang@chromium.org>
Signed-off-by: V Sujith Kumar Reddy <vsujithk@codeaurora.org>
Signed-off-by: Srinivasa Rao Mandadapu <srivasam@codeaurora.org>
Link: https://lore.kernel.org/r/1600450426-14063-1-git-send-email-srivasam@codeaurora.org
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
2020-11-30 10:46:59 -06:00
Kathiravan T
74ab8ccfb8 arm64: dts: ipq6018: Add the QPIC peripheral nodes
Add the QPIC BAM and QPIC NAND controller support and
enable the same in board DTS file.

Co-developed-by: Anusha Canchi Ramachandra Rao <anusharao@codeaurora.org>
Signed-off-by: Anusha Canchi Ramachandra Rao <anusharao@codeaurora.org>
Signed-off-by: Kathiravan T <kathirav@codeaurora.org>
Link: https://lore.kernel.org/r/1606734105-12414-2-git-send-email-kathirav@codeaurora.org
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
2020-11-30 10:46:28 -06:00
Georgi Djakov
05b801afb7 arm64: dts: sdm845: Add interconnect properties for QUP
Add the interconnects DT property to describe the ports for GENI QUPs
on the sdm845 platform.

Signed-off-by: Georgi Djakov <georgi.djakov@linaro.org>
Link: https://lore.kernel.org/r/20201105135211.7160-3-georgi.djakov@linaro.org
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
2020-11-30 10:42:47 -06:00
Bjorn Andersson
71b83b74cc arm64: dts: qcom: c630: Expose LID events
The LID state can be read from GPIO 124 and the "tablet mode" from GPIO
95, expose these to the system using gpio-keys and mark the falling edge
of the LID state as a wakeup-source - to wake the system from suspend.

Tested-by: Steev Klimaszewski <steev@kali.org>
Acked-by: Shawn Guo <shawn.guo@linaro.org>
Link: https://lore.kernel.org/r/20201125060838.165576-1-bjorn.andersson@linaro.org
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
2020-11-30 10:42:44 -06:00
Bjorn Andersson
683227e5a3 arm64: dts: qcom: c630: Re-enable apps_smmu
Re-enable the apps_smmu now that the arm-smmu driver supports stream
mapping handoff from firmware.

Tested-by: Steev Klimaszewski <steev@kali.org>
Acked-by: Shawn Guo <shawn.guo@linaro.org>
Link: https://lore.kernel.org/r/20201124184414.380796-1-bjorn.andersson@linaro.org
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
2020-11-30 10:42:39 -06:00
Thara Gopinath
3e482859f1 dts: qcom: sdm845: Add dt entries to support crypto engine.
Add crypto engine (CE) and CE BAM related nodes and definitions to
"sdm845.dtsi".

Signed-off-by: Thara Gopinath <thara.gopinath@linaro.org>
Link: https://lore.kernel.org/r/20201119155233.3974286-6-thara.gopinath@linaro.org
[bjorn: Replaced RPMH_CE_CLK constant, for now]
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
2020-11-30 10:22:12 -06:00
Eddie Cai
ef098edc9c arm64: dts: rockchip: add isp and sensors for Scarlet
Enable ISP and camera sensor ov2685 and ov5695 for Scarlet Chromebook

Verified with:
    make ARCH=arm64 dtbs_check

Signed-off-by: Shunqian Zheng <zhengsq@rock-chips.com>
Signed-off-by: Eddie Cai <eddie.cai.linux@gmail.com>
Signed-off-by: Tomasz Figa <tfiga@chromium.org>
Signed-off-by: Helen Koike <helen.koike@collabora.com>
Reviewed-by: Tomasz Figa <tfiga@chromium.org>
Link: https://lore.kernel.org/r/20201020193850.1460644-10-helen.koike@collabora.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 17:03:38 +01:00
Shunqian Zheng
97a0115cd9 arm64: dts: rockchip: add isp0 node for rk3399
RK3399 has two ISPs, but only isp0 was tested.
Add isp0 node in rk3399 dtsi

Verified with:
make ARCH=arm64 dtbs_check DT_SCHEMA_FILES=Documentation/devicetree/bindings/media/rockchip-isp1.yaml

Signed-off-by: Shunqian Zheng <zhengsq@rock-chips.com>
Signed-off-by: Jacob Chen <jacob2.chen@rock-chips.com>
Signed-off-by: Helen Koike <helen.koike@collabora.com>
Link: https://lore.kernel.org/r/20201020193850.1460644-9-helen.koike@collabora.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 17:03:38 +01:00
Marc Zyngier
4f1df628d4 KVM: arm64: Advertise ID_AA64PFR0_EL1.CSV3=1 if the CPUs are Meltdown-safe
Cores that predate the introduction of ID_AA64PFR0_EL1.CSV3 to
the ARMv8 architecture have this field set to 0, even of some of
them are not affected by the vulnerability.

The kernel maintains a list of unaffected cores (A53, A55 and a few
others) so that it doesn't impose an expensive mitigation uncessarily.

As we do for CSV2, let's expose the CSV3 property to guests that run
on HW that is effectively not vulnerable. This can be reset to zero
by writing to the ID register from userspace, ensuring that VMs can
be migrated despite the new property being set.

Reported-by: Will Deacon <will@kernel.org>
Signed-off-by: Marc Zyngier <maz@kernel.org>
2020-11-30 16:02:53 +00:00
Marek Behún
a2081c09d7 arm64: dts: armada-3720-turris-mox: add 3W power capability to SFP cage
Add maximum-power-milliwatt = 3000 to SFP node of Turris MOX.

Signed-off-by: Marek Behún <kabel@kernel.org>
Fixes: 7109d817db ("arm64: dts: marvell: add DTS for Turris Mox")
Cc: Gregory CLEMENT <gregory.clement@bootlin.com>
Cc: Andrew Lunn <andrew@lunn.ch>
Cc: Rob Herring <robh+dt@kernel.org>
Cc: devicetree@vger.kernel.org
Cc: linux-arm-kernel@lists.infradead.org
Signed-off-by: Gregory CLEMENT <gregory.clement@bootlin.com>
2020-11-30 16:46:30 +01:00
Tomasz Nowicki
f43cadef2d arm64: dts: marvell: keep SMMU disabled by default for Armada 7040 and 8040
FW has to configure devices' StreamIDs so that SMMU is able to lookup
context and do proper translation later on. For Armada 7040 & 8040 and
publicly available FW, most of the devices are configured properly,
but some like ap_sdhci0, PCIe, NIC still remain unassigned which
results in SMMU faults about unmatched StreamID (assuming
ARM_SMMU_DISABLE_BYPASS_BY_DEFAUL=y).

Since there is dependency on custom FW let SMMU be disabled by default.
People who still willing to use SMMU need to enable manually and
use ARM_SMMU_DISABLE_BYPASS_BY_DEFAUL=n (or via kernel command line)
with extra caution.

Fixes: 83a3545d9c ("arm64: dts: marvell: add SMMU support")
Cc: <stable@vger.kernel.org> # 5.9+
Signed-off-by: Tomasz Nowicki <tn@semihalf.com>
Signed-off-by: Gregory CLEMENT <gregory.clement@bootlin.com>
2020-11-30 16:46:29 +01:00
Tomasz Maciej Nowak
da57203dc7 arm64: dts: mcbin-singleshot: add heartbeat LED
With board revision 1.3, SolidRun moved the power LED to the middle of
the board. In old place of power LED a GPIO controllable heartbeat LED
was added. This commit only touches Single Shot variant, since only this
variant is all revision 1.3.

Reported-by: Alexandra Alth <alexandra@alth.de>
Signed-off-by: Tomasz Maciej Nowak <tmn505@gmail.com>
Signed-off-by: Gregory CLEMENT <gregory.clement@bootlin.com>
2020-11-30 16:46:29 +01:00
Serge Semin
83afd0b3e0 arm64: dts: marvell: cp11x: Harmonize xHCI DT nodes name
In accordance with the Generic xHCI bindings the corresponding node
name is suppose to comply with the Generic USB HCD DT schema, which
requires the USB nodes to have the name acceptable by the regexp:
"^usb(@.*)?" . Make sure the "generic-xhci"-compatible nodes are
correctly named.

Signed-off-by: Serge Semin <Sergey.Semin@baikalelectronics.ru>
Acked-by: Krzysztof Kozlowski <krzk@kernel.org>
Signed-off-by: Gregory CLEMENT <gregory.clement@bootlin.com>
2020-11-30 16:46:29 +01:00
Yuantian Tang
64d8111393 arm64: dts: freescale: update calibration table for TMU module
Update the calibration table to make the temperature more accurate.
Three platforms have been updated: ls1012a, ls1043a and ls1046a.

Signed-off-by: Yuantian Tang <andy.tang@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Michael Walle
91ab1c1228 arm64: dts: freescale: sl28: combine SPI MTD partitions
The upstream port, doesn't really follow the vendor partitioning. The
bootloader partition has one U-Boot FIT image containing all needed
bits and pieces. Even today the bootloader is already larger than the
current "bootloader" partition. Thus, fold all the partitions into one
and keep the environment one. The latter is still valid.
We keep the failsafe partitions because the first half of the SPI flash
is preinstalled by the vendor and immutable.

Fixes: 815364d042 ("arm64: dts: freescale: add Kontron sl28 support")
Signed-off-by: Michael Walle <michael@walle.cc>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Michael Walle
f90931aeef arm64: dts: ls1028a: add optee node
Add the optee node which can either be enabled by a specific board or by
the bootloader.

Signed-off-by: Michael Walle <michael@walle.cc>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Michael Walle
588b17eda1 arm64: dts: ls1028a: fix FlexSPI clock input
On the LS1028A the FlexSPI clock is connected to the first HWA output,
see Figure 7 "Clock subsystem block diagram".

Fixes: c77fae5ba0 ("arm64: dts: ls1028a: Add FlexSPI support")
Signed-off-by: Michael Walle <michael@walle.cc>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Michael Walle
d0570a575a arm64: dts: ls1028a: fix ENETC PTP clock input
On the LS1028A the ENETC reference clock is connected to 4th HWA output,
see Figure 7 "Clock subsystem block diagram".

The PHC may run with a wrong frequency. ptp_qoriq_auto_config() will read
the clock speed of the clock given in the device tree. It is likely that,
on the reference board this wasn't noticed because both clocks have the
same frequency. But this must not be always the case. Fix it.

Fixes: 49401003e2 ("arm64: dts: fsl: ls1028a: add ENETC 1588 timer node")
Signed-off-by: Michael Walle <michael@walle.cc>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Nathan Chancellor
bd5840df91 arm64: dts: imx: Fix imx8mm-kontron-n801x-s.dtb target
While running 'make dtbs_install', the following error occurs:

make[3]: *** No rule to make target 'rootfs/freescale/imx8mm-kontron-n801x-s.dts', needed by '__dtbs_install'.

It should be .dtb, not .dts.

Fixes: 8668d8b2e6 ("arm64: dts: Add the Kontron i.MX8M Mini SoMs and baseboards")
Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org>
Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
Reviewed-by: Frieder Schrempf <frieder.schrempf@kontron.de>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Joakim Zhang
29939851a6 arm64: dts: imx8mn-evk: add IR support
Add IR support on i.MX8MN EVK board.

Signed-off-by: Joakim Zhang <qiangqing.zhang@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Joakim Zhang
56e08dc3a6 arm64: dts: imx8mm-evk: add IR support
Add IR support on i.MX8MM EVK board.

Signed-off-by: Joakim Zhang <qiangqing.zhang@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Joakim Zhang
4d583263f4 arm64: dts: imx8mq-evk: add linux,autosuspend-period property for IR
Add linux,autosuspend-period property for IR, details please refer to:

commit ff1c9223b7 ("media: rc: gpio-ir-recv: add QoS support for cpuidle system")

Signed-off-by: Joakim Zhang <qiangqing.zhang@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Joakim Zhang
3a7d56b3cd arm64: dts: imx8mp-evk: add CAN support
Add CAN device node and pinctrl on i.MX8MP evk board.

Signed-off-by: Joakim Zhang <qiangqing.zhang@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Shengjiu Wang
08a1a2e205 arm64: dts: imx8mq-evk: Add spdif sound card support
There are two spdif IP on imx8mq, spdif1 is for normal
spdif device, spdif2 is for HDMI ARC interface.

Enable these spdif sound card in this patch.

Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com>
Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Shengjiu Wang
71fa01d3a9 arm64: dts: imx8mq: Configure clock rate for audio plls
Configure clock rate for audio plls. audio pll1 is used
as parent clock for clocks that is multiple of 8kHz.
audio pll2 is used as parent clock for clocks that is
multiple of 11kHz.

Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Xiaowei Bao
b6abb31375 arm64: dts: layerscape: Add PCIe EP node for ls1088a
Add PCIe EP node for ls1088a to support EP mode.

Signed-off-by: Xiaowei Bao <xiaowei.bao@nxp.com>
Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
Reviewed-by: Andrew Murray <andrew.murray@arm.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Ioana Ciornei
f0f3531f3a arm64: dts: lx2160ardb: add nodes for the AQR107 PHYs
Annotate the EMDIO1 node and describe the 2 AQR107 PHYs found on the
LX2160ARDB board. Also, add the necessary phy-handles for DPMACs 3 and 4
to their associated PHY.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Ioana Ciornei
f94cfe322f arm64: dts: lx2160a: add PCS MDIO and PCS PHY nodes
Add PCS MDIO nodes for the internal MDIO buses on the LX2160A, along
with their internal PCS PHYs, which will be used when the DPMAC is
in TYPE_PHY mode.
Also, rename the dpmac@x nodes to ethernet@x in order to be compliant
with the naming convention used by ethernet controllers.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Ioana Ciornei
2e7c4c3c2f arm64: dts: ls208xa: add PCS MDIO and PCS PHY nodes
Add PCS MDIO nodes for the internal MDIO buses on the LS208x SoCs, along
with their internal PCS PHYs which will be used when the DPMAC object is
in TYPE_PHY mode.
Also, rename the dpmac@x nodes to ethernet@x in order to be compliant
with the naming convention used by ethernet controllers.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Ioana Ciornei
dd2ab5c8b8 arm64: dts: ls2088ardb: add PHY nodes for the AQR405 PHYs
Annotate the EMDIO2 node and describe the other 4 10GBASER PHYs found on
the LS2088ARDB board. Also, add phy-handles for DPMACs 5-8 to their
associated PHY.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Ioana Ciornei
173fb0a3f9 arm64: dts: ls2088ardb: add PHY nodes for the CS4340 PHYs
Annotate the EMDIO1 node and describe the 4 10GBASER PHYs found on the
LS2088ARDB board. Also, add phy-handles for DPMACs 1-4 to their
associated PHY.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Ioana Ciornei
0420dde30a arm64: dts: ls208xa: add the external MDIO nodes
Add the external MDIO device nodes found in the WRIOP global memory
region. This is needed for management of external PHYs.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Ioana Ciornei
379b4f7645 arm64: dts: ls1088ardb: add necessary DTS nodes for DPMAC2
Annotate the external MDIO2 node and describe the 10GBASER PHY found on
the LS1088ARDB board and add a phy-handle for DPMAC2 to link it.
Also, add the internal PCS MDIO node for the internal MDIO buses found
on the LS1088A SoC along with its internal PCS PHY and link the
corresponding DPMAC to the PCS through the pcs-handle.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Ioana Ciornei
73f034cc45 arm64: dts: ls1088ardb: add QSGMII PHY nodes
Annotate the external MDIO1 node and describe the 8 QSGMII PHYs found on
the LS1088ARDB board and add phy-handles for DPMACs 3-10 to its
associated PHY.  Also, add the internal PCS MDIO nodes for the internal
MDIO buses found on the LS1088A SoC along with their internal PCS PHY
and link the corresponding DPMAC to the PCS through the pcs-handle.
Also, rename the dpmac@x nodes to ethernet@x in order to be compliant
with the naming convention used by ethernet controllers.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Ioana Ciornei
bbe75af7b0 arm64: dts: ls1088a: add external MDIO device nodes
Add the external MDIO device nodes found in the WRIOP global memory
region. This is needed for management of external PHYs.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Meenakshi Aggarwal
87f7ba1651 arm64: dts: lx2160a: add device tree for lx2162aqds board
Add device tree support for LX2162AQDS board.
LX2162A has same die as of LX2160A with different packaging.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Signed-off-by: Kuldeep Singh <kuldeep.singh@nxp.com>
Signed-off-by: Meenakshi Aggarwal <meenakshi.aggarwal@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Adam Ford
60a9d6ab2f arm64: dts: imx8mm-beacon-som: Fix whitespace issue
The pinmux subnodes are indented too much.  This patch does nothing
more than remove an extra tab.  There are no functional changes.

Signed-off-by: Adam Ford <aford173@gmail.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
2020-11-30 22:30:29 +08:00
Alexis Ballier
e56ed188c8 arm64: dts: rockchip: Properly define the type C connector on rk3399-orangepi
Tested:
- USB3 Gigabit adapter
- USB2 mass storage

The wiring is the same as the pinebook pro according to the schematics,
thus this patch is heavily based on its dts.

Signed-off-by: Alexis Ballier <aballier@gentoo.org>
Cc: devicetree@vger.kernel.org
Cc: Heiko Stuebner <heiko@sntech.de>
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-rockchip@lists.infradead.org
Cc: linux-kernel@vger.kernel.org
Link: https://lore.kernel.org/r/20201022113532.18470-1-aballier@gentoo.org
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 14:34:01 +01:00
Jagan Teki
29952fea5e ARM: dts: rockchip: Add SDIO0 node for VMARC SOM
Rockchip RK3288 and RK3399Pro based VMARC SOM has sdio0 for
connecting WiFi/BT devices as a pluggable card via M.2 E-Key.

Add associated sdio0 nodes, properties.

Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Link: https://lore.kernel.org/r/20201023181814.220974-2-jagan@amarulasolutions.com
[moved the unrelated rtc addition to a separate patch]
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 14:30:56 +01:00
Faiz Abbas
cd48ce86a4 arm64: dts: ti: k3-j721e-common-proc-board: Add support for SD card UHS modes
Add support for UHS modes for the SD card connected at sdhci1. This
involves adding regulators for voltage switching and power cycling the
SD card and removing the no-1-8-v property.

Signed-off-by: Faiz Abbas <faiz_abbas@ti.com>
Signed-off-by: Sekhar Nori <nsekhar@ti.com>
Signed-off-by: Nishanth Menon <nm@ti.com>
Link: https://lore.kernel.org/r/20201129175223.21751-3-nsekhar@ti.com
2020-11-30 07:12:54 -06:00
Faiz Abbas
09ff4e90e0 arm64: dts: ti: k3-j721e-main: Add output tap delay values
Add output tap delay values as given in the latest Data Manual[1],
SPRSP36E, revised December 2019.

[1] https://www.ti.com/lit/gpn/tda4vm

Signed-off-by: Faiz Abbas <faiz_abbas@ti.com>
Signed-off-by: Sekhar Nori <nsekhar@ti.com>
Signed-off-by: Nishanth Menon <nm@ti.com>
Link: https://lore.kernel.org/r/20201129175223.21751-2-nsekhar@ti.com
2020-11-30 07:12:54 -06:00
Mark Rutland
2a9b3e6ac6 arm64: entry: fix EL1 debug transitions
In debug_exception_enter() and debug_exception_exit() we trace hardirqs
on/off while RCU isn't guaranteed to be watching, and we don't save and
restore the hardirq state, and so may return with this having changed.

Handle this appropriately with new entry/exit helpers which do the bare
minimum to ensure this is appropriately maintained, without marking
debug exceptions as NMIs. These are placed in entry-common.c with the
other entry/exit helpers.

In future we'll want to reconsider whether some debug exceptions should
be NMIs, but this will require a significant refactoring, and for now
this should prevent issues with lockdep and RCU.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marins <catalin.marinas@arm.com>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201130115950.22492-12-mark.rutland@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
2020-11-30 12:11:38 +00:00
Mark Rutland
f0cd5ac1e4 arm64: entry: fix NMI {user, kernel}->kernel transitions
Exceptions which can be taken at (almost) any time are consdiered to be
NMIs. On arm64 that includes:

* SDEI events
* GICv3 Pseudo-NMIs
* Kernel stack overflows
* Unexpected/unhandled exceptions

... but currently debug exceptions (BRKs, breakpoints, watchpoints,
single-step) are not considered NMIs.

As these can be taken at any time, kernel features (lockdep, RCU,
ftrace) may not be in a consistent kernel state. For example, we may
take an NMI from the idle code or partway through an entry/exit path.

While nmi_enter() and nmi_exit() handle most of this state, notably they
don't save/restore the lockdep state across an NMI being taken and
handled. When interrupts are enabled and an NMI is taken, lockdep may
see interrupts become disabled within the NMI code, but not see
interrupts become enabled when returning from the NMI, leaving lockdep
believing interrupts are disabled when they are actually disabled.

The x86 code handles this in idtentry_{enter,exit}_nmi(), which will
shortly be moved to the generic entry code. As we can't use either yet,
we copy the x86 approach in arm64-specific helpers. All the NMI
entrypoints are marked as noinstr to prevent any instrumentation
handling code being invoked before the state has been corrected.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201130115950.22492-11-mark.rutland@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
2020-11-30 12:11:38 +00:00
Mark Rutland
7cd1ea1010 arm64: entry: fix non-NMI kernel<->kernel transitions
There are periods in kernel mode when RCU is not watching and/or the
scheduler tick is disabled, but we can still take exceptions such as
interrupts. The arm64 exception handlers do not account for this, and
it's possible that RCU is not watching while an exception handler runs.

The x86/generic entry code handles this by ensuring that all (non-NMI)
kernel exception handlers call irqentry_enter() and irqentry_exit(),
which handle RCU, lockdep, and IRQ flag tracing. We can't yet move to
the generic entry code, and already hadnle the user<->kernel transitions
elsewhere, so we add new kernel<->kernel transition helpers alog the
lines of the generic entry code.

Since we now track interrupts becoming masked when an exception is
taken, local_daif_inherit() is modified to track interrupts becoming
re-enabled when the original context is inherited. To balance the
entry/exit paths, each handler masks all DAIF exceptions before
exit_to_kernel_mode().

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201130115950.22492-10-mark.rutland@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
2020-11-30 12:11:38 +00:00
Mark Rutland
1ec2f2c05b arm64: ptrace: prepare for EL1 irq/rcu tracking
Exceptions from EL1 may be taken when RCU isn't watching (e.g. in idle
sequences), or when the lockdep hardirqs transiently out-of-sync with
the hardware state (e.g. in the middle of local_irq_enable()). To
correctly handle these cases, we'll need to save/restore this state
across some exceptions taken from EL1.

A series of subsequent patches will update EL1 exception handlers to
handle this. In preparation for this, and to avoid dependencies between
those patches, this patch adds two new fields to struct pt_regs so that
exception handlers can track this state.

Note that this is placed in pt_regs as some entry/exit sequences such as
el1_irq are invoked from assembly, which makes it very difficult to add
a separate structure as with the irqentry_state used by x86. We can
separate this once more of the exception logic is moved to C. While the
fields only need to be bool, they are both made u64 to keep pt_regs
16-byte aligned.

There should be no functional change as a result of this patch.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201130115950.22492-9-mark.rutland@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
2020-11-30 12:11:38 +00:00
Mark Rutland
23529049c6 arm64: entry: fix non-NMI user<->kernel transitions
When built with PROVE_LOCKING, NO_HZ_FULL, and CONTEXT_TRACKING_FORCE
will WARN() at boot time that interrupts are enabled when we call
context_tracking_user_enter(), despite the DAIF flags indicating that
IRQs are masked.

The problem is that we're not tracking IRQ flag changes accurately, and
so lockdep believes interrupts are enabled when they are not (and
vice-versa). We can shuffle things so to make this more accurate. For
kernel->user transitions there are a number of constraints we need to
consider:

1) When we call __context_tracking_user_enter() HW IRQs must be disabled
   and lockdep must be up-to-date with this.

2) Userspace should be treated as having IRQs enabled from the PoV of
   both lockdep and tracing.

3) As context_tracking_user_enter() stops RCU from watching, we cannot
   use RCU after calling it.

4) IRQ flag tracing and lockdep have state that must be manipulated
   before RCU is disabled.

... with similar constraints applying for user->kernel transitions, with
the ordering reversed.

The generic entry code has enter_from_user_mode() and
exit_to_user_mode() helpers to handle this. We can't use those directly,
so we add arm64 copies for now (without the instrumentation markers
which aren't used on arm64). These replace the existing user_exit() and
user_exit_irqoff() calls spread throughout handlers, and the exception
unmasking is left as-is.

Note that:

* The accounting for debug exceptions from userspace now happens in
  el0_dbg() and ret_to_user(), so this is removed from
  debug_exception_enter() and debug_exception_exit(). As
  user_exit_irqoff() wakes RCU, the userspace-specific check is removed.

* The accounting for syscalls now happens in el0_svc(),
  el0_svc_compat(), and ret_to_user(), so this is removed from
  el0_svc_common(). This does not adversely affect the workaround for
  erratum 1463225, as this does not depend on any of the state tracking.

* In ret_to_user() we mask interrupts with local_daif_mask(), and so we
  need to inform lockdep and tracing. Here a trace_hardirqs_off() is
  sufficient and safe as we have not yet exited kernel context and RCU
  is usable.

* As PROVE_LOCKING selects TRACE_IRQFLAGS, the ifdeferry in entry.S only
  needs to check for the latter.

* EL0 SError handling will be dealt with in a subsequent patch, as this
  needs to be treated as an NMI.

Prior to this patch, booting an appropriately-configured kernel would
result in spats as below:

| DEBUG_LOCKS_WARN_ON(lockdep_hardirqs_enabled())
| WARNING: CPU: 2 PID: 1 at kernel/locking/lockdep.c:5280 check_flags.part.54+0x1dc/0x1f0
| Modules linked in:
| CPU: 2 PID: 1 Comm: init Not tainted 5.10.0-rc3 #3
| Hardware name: linux,dummy-virt (DT)
| pstate: 804003c5 (Nzcv DAIF +PAN -UAO -TCO BTYPE=--)
| pc : check_flags.part.54+0x1dc/0x1f0
| lr : check_flags.part.54+0x1dc/0x1f0
| sp : ffff80001003bd80
| x29: ffff80001003bd80 x28: ffff66ce801e0000
| x27: 00000000ffffffff x26: 00000000000003c0
| x25: 0000000000000000 x24: ffffc31842527258
| x23: ffffc31842491368 x22: ffffc3184282d000
| x21: 0000000000000000 x20: 0000000000000001
| x19: ffffc318432ce000 x18: 0080000000000000
| x17: 0000000000000000 x16: ffffc31840f18a78
| x15: 0000000000000001 x14: ffffc3184285c810
| x13: 0000000000000001 x12: 0000000000000000
| x11: ffffc318415857a0 x10: ffffc318406614c0
| x9 : ffffc318415857a0 x8 : ffffc31841f1d000
| x7 : 647261685f706564 x6 : ffffc3183ff7c66c
| x5 : ffff66ce801e0000 x4 : 0000000000000000
| x3 : ffffc3183fe00000 x2 : ffffc31841500000
| x1 : e956dc24146b3500 x0 : 0000000000000000
| Call trace:
|  check_flags.part.54+0x1dc/0x1f0
|  lock_is_held_type+0x10c/0x188
|  rcu_read_lock_sched_held+0x70/0x98
|  __context_tracking_enter+0x310/0x350
|  context_tracking_enter.part.3+0x5c/0xc8
|  context_tracking_user_enter+0x6c/0x80
|  finish_ret_to_user+0x2c/0x13cr

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201130115950.22492-8-mark.rutland@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
2020-11-30 12:11:38 +00:00
Mark Rutland
105fc33520 arm64: entry: move el1 irq/nmi logic to C
In preparation for reworking the EL1 irq/nmi entry code, move the
existing logic to C. We no longer need the asm_nmi_enter() and
asm_nmi_exit() wrappers, so these are removed. The new C functions are
marked noinstr, which prevents compiler instrumentation and runtime
probing.

In subsequent patches we'll want the new C helpers to be called in all
cases, so we don't bother wrapping the calls with ifdeferry. Even when
the new C functions are stubs the trivial calls are unlikely to have a
measurable impact on the IRQ or NMI paths anyway.

Prototypes are added to <asm/exception.h> as otherwise (in some
configurations) GCC will complain about the lack of a forward
declaration. We already do this for existing function, e.g.
enter_from_user_mode().

The new helpers are marked as noinstr (which prevents all
instrumentation, tracing, and kprobes). Otherwise, there should be no
functional change as a result of this patch.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201130115950.22492-7-mark.rutland@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
2020-11-30 12:11:38 +00:00
Mark Rutland
3cb5ed4d76 arm64: entry: prepare ret_to_user for function call
In a subsequent patch ret_to_user will need to make a C function call
(in some configurations) which may clobber x0-x18 at the start of the
finish_ret_to_user block, before enable_step_tsk consumes the flags
loaded into x1.

In preparation for this, let's load the flags into x19, which is
preserved across C function calls. This avoids a redundant reload of the
flags and ensures we operate on a consistent shapshot regardless.

There should be no functional change as a result of this patch. At this
point of the entry/exit paths we only need to preserve x28 (tsk) and the
sp, and x19 is free for this use.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201130115950.22492-6-mark.rutland@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
2020-11-30 12:11:37 +00:00
Mark Rutland
2f911d494f arm64: entry: move enter_from_user_mode to entry-common.c
In later patches we'll want to extend enter_from_user_mode() and add a
corresponding exit_to_user_mode(). As these will be common for all
entries/exits from userspace, it'd be better for these to live in
entry-common.c with the rest of the entry logic.

This patch moves enter_from_user_mode() into entry-common.c. As with
other functions in entry-common.c it is marked as noinstr (which
prevents all instrumentation, tracing, and kprobes) but there are no
other functional changes.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201130115950.22492-5-mark.rutland@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
2020-11-30 12:11:37 +00:00
Mark Rutland
da19267648 arm64: entry: mark entry code as noinstr
Functions in entry-common.c are marked as notrace and NOKPROBE_SYMBOL(),
but they're still subject to other instrumentation which may rely on
lockdep/rcu/context-tracking being up-to-date, and may cause nested
exceptions (e.g. for WARN/BUG or KASAN's use of BRK) which will corrupt
exceptions registers which have not yet been read.

Prevent this by marking all functions in entry-common.c as noinstr to
prevent compiler instrumentation. This also blacklists the functions for
tracing and kprobes, so we don't need to handle that separately.
Functions elsewhere will be dealt with in subsequent patches.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201130115950.22492-4-mark.rutland@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
2020-11-30 12:11:37 +00:00
Mark Rutland
114e0a6847 arm64: mark idle code as noinstr
Core code disables RCU when calling arch_cpu_idle(), so it's not safe
for arch_cpu_idle() or its calees to be instrumented, as the
instrumentation callbacks may attempt to use RCU or other features which
are unsafe to use in this context.

Mark them noinstr to prevent issues.

The use of local_irq_enable() in arch_cpu_idle() is similarly
problematic, and the "sched/idle: Fix arch_cpu_idle() vs tracing" patch
queued in the tip tree addresses that case.

Reported-by: Marco Elver <elver@google.com>
Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201130115950.22492-3-mark.rutland@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
2020-11-30 12:11:37 +00:00
Mark Rutland
ca1314d73e arm64: syscall: exit userspace before unmasking exceptions
In el0_svc_common() we unmask exceptions before we call user_exit(), and
so there's a window where an IRQ or debug exception can be taken while
RCU is not watching. In do_debug_exception() we account for this in via
debug_exception_{enter,exit}(), but in the el1_irq asm we do not and we
call trace functions which rely on RCU before we have a guarantee that
RCU is watching.

Let's avoid this by having el0_svc_common() exit userspace before
unmasking exceptions, matching what we do for all other EL0 entry paths.
We can use user_exit_irqoff() to avoid the pointless save/restore of IRQ
flags while we're sure exceptions are masked in DAIF.

The workaround for Cortex-A76 erratum 1463225 may trigger a debug
exception before this point, but the debug code invoked in this case is
safe even when RCU is not watching.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20201130115950.22492-2-mark.rutland@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
2020-11-30 12:11:37 +00:00
Shenming Lu
57e3cebd02 KVM: arm64: Delay the polling of the GICR_VPENDBASER.Dirty bit
In order to reduce the impact of the VPT parsing happening on the GIC,
we can split the vcpu reseidency in two phases:

- programming GICR_VPENDBASER: this still happens in vcpu_load()
- checking for the VPT parsing to be complete: this can happen
  on vcpu entry (in kvm_vgic_flush_hwstate())

This allows the GIC and the CPU to work in parallel, rewmoving some
of the entry overhead.

Suggested-by: Marc Zyngier <maz@kernel.org>
Signed-off-by: Shenming Lu <lushenming@huawei.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20201128141857.983-3-lushenming@huawei.com
2020-11-30 11:18:29 +00:00
Pali Rohár
cbc4a395dc arm64: dts: marvell: espressobin: Update link to V7 schematic
Up-to-date version of V7 schematic is on new URL linked from official
tech-spec webpage http://espressobin.net/tech-spec/

Signed-off-by: Pali Rohár <pali@kernel.org>
Signed-off-by: Gregory CLEMENT <gregory.clement@bootlin.com>
2020-11-30 11:16:57 +01:00
Jagan Teki
cf35bff64f arm64: defconfig: Enable USB_SERIAL_CP210X
Some hardware platforms required CP20x USB to Serial converter
in order to work onboard functionalities like Bluetooth.

An example of such a platform is from Engicam's PX30 (ARM64).

Mark it as module in defconfig.

Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Link: https://lore.kernel.org/r/20201109181017.206834-10-jagan@amarulasolutions.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 02:38:05 +01:00
Jagan Teki
ec68a66395 arm64: defconfig: Enable PHY_ROCKCHIP_INNO_DSIDPHY
In order to work LDVS, DSI in mainline tree for Rockchip based
hardware platforms, the associated PHY driver has to enable
in default defconfig.

Enable rockchip DSI phy driver.

Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Link: https://lore.kernel.org/r/20201109181017.206834-9-jagan@amarulasolutions.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 02:38:05 +01:00
Jagan Teki
dbb378a59c arm64: defconfig: Enable ROCKCHIP_LVDS
Now, some of the rockchip hardware platforms do enable
lvds in mainline tree.

So, enable Rockchip LVDS driver via default defconfig.

Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Link: https://lore.kernel.org/r/20201109181017.206834-8-jagan@amarulasolutions.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 02:38:05 +01:00
Suniel Mahesh
1cc1e851d1 arm64: dts: rockchip: Add BT support on px30-engicam
Engicam PX30 carrier boards like EDIMM2.2 and C.TOUCH2.0 have
an onboard Sterling-LWD Wifi/BT chip based on BCM43430 connected
on the UART bus.

UART bus on the design routed via USB to UART CP20x bridge. This
bridge powered from 3V3 regualtor gpio.

This patch adds BT enablement nodes for these respective boards.

Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com>
Signed-off-by: Suniel Mahesh <sunil@amarulasolutions.com>
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Link: https://lore.kernel.org/r/20201109181017.206834-7-jagan@amarulasolutions.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 02:37:13 +01:00
Suniel Mahesh
93a4e7d124 arm64: dts: rockchip: Add WiFi support on px30-engicam
Engicam PX30 carrier boards like EDIMM2.2 and C.TOUCH2.0 have
an onboard Sterling-LWD Wifi/BT chip based on BCM43430 connected
on the SDIO bus.

The SDIO power sequnce is connacted with exteernal 32KHz oscillator
and it require 3V3 regulator input.

This patch adds WiFi enablement nodes for these respective boards.

Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com>
Signed-off-by: Suniel Mahesh <sunil@amarulasolutions.com>
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Link: https://lore.kernel.org/r/20201109181017.206834-6-jagan@amarulasolutions.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 02:37:13 +01:00
Jagan Teki
0e418423be arm64: dts: rockchip: Add Engicam PX30.Core C.TOUCH 2.0 10.1" OF
PX30.Core is an EDIMM SOM based on Rockchip PX30 from Engicam.

C.TOUCH 2.0 is a general purpose carrier board with capacitive
touch interface support.

10.1" OF is a capacitive touch 10.1" Open Frame panel solutions.

PX30.Core needs to mount on top of C.TOUCH 2.0 carrier with pluged
10.1" OF for creating complete PX30.Core C.TOUCH 2.0 10.1" Open Frame.

Add support for it.

Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Link: https://lore.kernel.org/r/20201109181017.206834-5-jagan@amarulasolutions.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 02:37:13 +01:00
Jagan Teki
87761edeb2 arm64: dts: rockchip: Enable LVDS panel on px30-engicam-edimm2.2
Engicam PX30.Core EDIMM2.2 developement Kit has on board 10" LVDS
panel from yes-optoelectronics.

This patch adds panel enablement nodes on respective dts(i) files.

Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Link: https://lore.kernel.org/r/20201109181017.206834-3-jagan@amarulasolutions.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 02:37:13 +01:00
Jagan Teki
4548ea027c arm64: dts: rockchip: Enable USB Host, OTG on px30-enagicam
Engicam EDIMM2.2 and C.Touch 2.0 Kits support USB Host
and OTG ports.

Add support to enable USB on these kits while mounting
px30-core SOM.

Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Link: https://lore.kernel.org/r/20201109181017.206834-2-jagan@amarulasolutions.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 02:37:12 +01:00
Johan Jonker
9a9f642784 arm64: dts: rockchip: rename sdhci nodename to mmc on rk3399
A test with the command below gives for example this error:

/arch/arm64/boot/dts/rockchip/rk3399-evb.dt.yaml:
sdhci@fe330000: $nodename:0: 'sdhci@fe330000'
does not match '^mmc(@.*)?$'

Fix it by renaming sdhci to mmc.

make ARCH=arm64 dtbs_check
DT_SCHEMA_FILES=Documentation/devicetree/bindings/
mmc/arasan,sdhci.yaml

Signed-off-by: Johan Jonker <jbx6244@gmail.com>
Link: https://lore.kernel.org/r/20201116132311.8318-1-jbx6244@gmail.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 01:08:57 +01:00
Chen-Yu Tsai
5df4d4d16c arm64: dts: rockchip: Enable analog audio on rk3328-roc-cc
Now that driver support for the RK3328's audio codec, and the plumbing
is defined at the SoC level, we can enable analog audio at the board
level.

Enable analog audio by enabling the codec and the I2S interface
connected and the simple-audio-card that binds them together.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Link: https://lore.kernel.org/r/20201126073336.30794-4-wens@kernel.org
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 01:07:38 +01:00
Chen-Yu Tsai
65f0b420de arm64: dts: rockchip: Enable HDMI audio on rk3328-roc-cc
The RK3328-ROC-CC already has HDMI display output enabled. Now that
audio for the HDMI controller is supported, it can be enabled as well.

Enable the simple-audio-card, and the I2S interface the audio is fed
from.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Link: https://lore.kernel.org/r/20201126073336.30794-3-wens@kernel.org
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 01:07:38 +01:00
Chen-Yu Tsai
4076a007bd arm64: dts: rockchip: Set dr_mode to "host" for OTG on rk3328-roc-cc
The board has a standard USB A female port connected to the USB OTG
controller's data pins. Set dr_mode in the OTG controller node to
indicate this usage, instead of having the implementation guess.

Fixes: 2171f4fdac ("arm64: dts: rockchip: add roc-rk3328-cc board")
Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Link: https://lore.kernel.org/r/20201126073336.30794-2-wens@kernel.org
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2020-11-30 01:07:38 +01:00