Skip to content

Commit 57b8b1b

Browse files
committed
Merge branches 'for-next/acpi', 'for-next/boot', 'for-next/bpf', 'for-next/cpuinfo', 'for-next/fpsimd', 'for-next/misc', 'for-next/mm', 'for-next/pci', 'for-next/perf', 'for-next/ptrauth', 'for-next/sdei', 'for-next/selftests', 'for-next/stacktrace', 'for-next/svm', 'for-next/topology', 'for-next/tpyos' and 'for-next/vdso' into for-next/core
Remove unused functions and parameters from ACPI IORT code. (Zenghui Yu via Lorenzo Pieralisi) * for-next/acpi: ACPI/IORT: Remove the unused inline functions ACPI/IORT: Drop the unused @ops of iort_add_device_replay() Remove redundant code and fix documentation of caching behaviour for the HVC_SOFT_RESTART hypercall. (Pingfan Liu) * for-next/boot: Documentation/kvm/arm: improve description of HVC_SOFT_RESTART arm64/relocate_kernel: remove redundant code Improve reporting of unexpected kernel traps due to BPF JIT failure. (Will Deacon) * for-next/bpf: arm64: Improve diagnostics when trapping BRK with FAULT_BRK_IMM Improve robustness of user-visible HWCAP strings and their corresponding numerical constants. (Anshuman Khandual) * for-next/cpuinfo: arm64/cpuinfo: Define HWCAP name arrays per their actual bit definitions Cleanups to handling of SVE and FPSIMD register state in preparation for potential future optimisation of handling across syscalls. (Julien Grall) * for-next/fpsimd: arm64/sve: Implement a helper to load SVE registers from FPSIMD state arm64/sve: Implement a helper to flush SVE registers arm64/fpsimdmacros: Allow the macro "for" to be used in more cases arm64/fpsimdmacros: Introduce a macro to update ZCR_EL1.LEN arm64/signal: Update the comment in preserve_sve_context arm64/fpsimd: Update documentation of do_sve_acc Miscellaneous changes. (Tian Tao and others) * for-next/misc: arm64/mm: return cpu_all_mask when node is NUMA_NO_NODE arm64: mm: Fix missing-prototypes in pageattr.c arm64/fpsimd: Fix missing-prototypes in fpsimd.c arm64: hibernate: Remove unused including <linux/version.h> arm64/mm: Refactor {pgd, pud, pmd, pte}_ERROR() arm64: Remove the unused include statements arm64: get rid of TEXT_OFFSET arm64: traps: Add str of description to panic() in die() Memory management updates and cleanups. (Anshuman Khandual and others) * for-next/mm: arm64: dbm: Invalidate local TLB when setting TCR_EL1.HD arm64: mm: Make flush_tlb_fix_spurious_fault() a no-op arm64/mm: Unify CONT_PMD_SHIFT arm64/mm: Unify CONT_PTE_SHIFT arm64/mm: Remove CONT_RANGE_OFFSET arm64/mm: Enable THP migration arm64/mm: Change THP helpers to comply with generic MM semantics arm64/mm/ptdump: Add address markers for BPF regions Allow prefetchable PCI BARs to be exposed to userspace using normal non-cacheable mappings. (Clint Sbisa) * for-next/pci: arm64: Enable PCI write-combine resources under sysfs Perf/PMU driver updates. (Julien Thierry and others) * for-next/perf: perf: arm-cmn: Fix conversion specifiers for node type perf: arm-cmn: Fix unsigned comparison to less than zero arm_pmu: arm64: Use NMIs for PMU arm_pmu: Introduce pmu_irq_ops KVM: arm64: pmu: Make overflow handler NMI safe arm64: perf: Defer irq_work to IPI_IRQ_WORK arm64: perf: Remove PMU locking arm64: perf: Avoid PMXEV* indirection arm64: perf: Add missing ISB in armv8pmu_enable_counter() perf: Add Arm CMN-600 PMU driver perf: Add Arm CMN-600 DT binding arm64: perf: Add support caps under sysfs drivers/perf: thunderx2_pmu: Fix memory resource error handling drivers/perf: xgene_pmu: Fix uninitialized resource struct perf: arm_dsu: Support DSU ACPI devices arm64: perf: Remove unnecessary event_idx check drivers/perf: hisi: Add missing include of linux/module.h arm64: perf: Add general hardware LLC events for PMUv3 Support for the Armv8.3 Pointer Authentication enhancements. (By Amit Daniel Kachhap) * for-next/ptrauth: arm64: kprobe: clarify the comment of steppable hint instructions arm64: kprobe: disable probe of fault prone ptrauth instruction arm64: cpufeature: Modify address authentication cpufeature to exact arm64: ptrauth: Introduce Armv8.3 pointer authentication enhancements arm64: traps: Allow force_signal_inject to pass esr error code arm64: kprobe: add checks for ARMv8.3-PAuth combined instructions Tonnes of cleanup to the SDEI driver. (Gavin Shan) * for-next/sdei: firmware: arm_sdei: Remove _sdei_event_unregister() firmware: arm_sdei: Remove _sdei_event_register() firmware: arm_sdei: Introduce sdei_do_local_call() firmware: arm_sdei: Cleanup on cross call function firmware: arm_sdei: Remove while loop in sdei_event_unregister() firmware: arm_sdei: Remove while loop in sdei_event_register() firmware: arm_sdei: Remove redundant error message in sdei_probe() firmware: arm_sdei: Remove duplicate check in sdei_get_conduit() firmware: arm_sdei: Unregister driver on error in sdei_init() firmware: arm_sdei: Avoid nested statements in sdei_init() firmware: arm_sdei: Retrieve event number from event instance firmware: arm_sdei: Common block for failing path in sdei_event_create() firmware: arm_sdei: Remove sdei_is_err() Selftests for Pointer Authentication and FPSIMD/SVE context-switching. (Mark Brown and Boyan Karatotev) * for-next/selftests: selftests: arm64: Add build and documentation for FP tests selftests: arm64: Add wrapper scripts for stress tests selftests: arm64: Add utility to set SVE vector lengths selftests: arm64: Add stress tests for FPSMID and SVE context switching selftests: arm64: Add test for the SVE ptrace interface selftests: arm64: Test case for enumeration of SVE vector lengths kselftests/arm64: add PAuth tests for single threaded consistency and differently initialized keys kselftests/arm64: add PAuth test for whether exec() changes keys kselftests/arm64: add nop checks for PAuth tests kselftests/arm64: add a basic Pointer Authentication test Implementation of ARCH_STACKWALK for unwinding. (Mark Brown) * for-next/stacktrace: arm64: Move console stack display code to stacktrace.c arm64: stacktrace: Convert to ARCH_STACKWALK arm64: stacktrace: Make stack walk callback consistent with generic code stacktrace: Remove reliable argument from arch_stack_walk() callback Support for ASID pinning, which is required when sharing page-tables with the SMMU. (Jean-Philippe Brucker) * for-next/svm: arm64: cpufeature: Export symbol read_sanitised_ftr_reg() arm64: mm: Pin down ASIDs for sharing mm with devices Rely on firmware tables for establishing CPU topology. (Valentin Schneider) * for-next/topology: arm64: topology: Stop using MPIDR for topology information Spelling fixes. (Xiaoming Ni and Yanfei Xu) * for-next/tpyos: arm64/numa: Fix a typo in comment of arm64_numa_init arm64: fix some spelling mistakes in the comments by codespell vDSO cleanups. (Will Deacon) * for-next/vdso: arm64: vdso: Fix unusual formatting in *setup_additional_pages() arm64: vdso32: Remove a bunch of #ifdef CONFIG_COMPAT_VDSO guards
18 parents f75aef3 + c2bea7a + 3a17930 + 0fdb64c + 4e56de8 + 9c4b4c7 + a194c5f + 80d6b46 + 5fd39dc + 887e2cf + 03c9c8f + 4b2b76c + e093256 + 9e0f085 + 6f3c4af + 3102bc0 + 9a747c9 + 2a30aca commit 57b8b1b

105 files changed

Lines changed: 5565 additions & 777 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
=============================
2+
Arm Coherent Mesh Network PMU
3+
=============================
4+
5+
CMN-600 is a configurable mesh interconnect consisting of a rectangular
6+
grid of crosspoints (XPs), with each crosspoint supporting up to two
7+
device ports to which various AMBA CHI agents are attached.
8+
9+
CMN implements a distributed PMU design as part of its debug and trace
10+
functionality. This consists of a local monitor (DTM) at every XP, which
11+
counts up to 4 event signals from the connected device nodes and/or the
12+
XP itself. Overflow from these local counters is accumulated in up to 8
13+
global counters implemented by the main controller (DTC), which provides
14+
overall PMU control and interrupts for global counter overflow.
15+
16+
PMU events
17+
----------
18+
19+
The PMU driver registers a single PMU device for the whole interconnect,
20+
see /sys/bus/event_source/devices/arm_cmn. Multi-chip systems may link
21+
more than one CMN together via external CCIX links - in this situation,
22+
each mesh counts its own events entirely independently, and additional
23+
PMU devices will be named arm_cmn_{1..n}.
24+
25+
Most events are specified in a format based directly on the TRM
26+
definitions - "type" selects the respective node type, and "eventid" the
27+
event number. Some events require an additional occupancy ID, which is
28+
specified by "occupid".
29+
30+
* Since RN-D nodes do not have any distinct events from RN-I nodes, they
31+
are treated as the same type (0xa), and the common event templates are
32+
named "rnid_*".
33+
34+
* The cycle counter is treated as a synthetic event belonging to the DTC
35+
node ("type" == 0x3, "eventid" is ignored).
36+
37+
* XP events also encode the port and channel in the "eventid" field, to
38+
match the underlying pmu_event0_id encoding for the pmu_event_sel
39+
register. The event templates are named with prefixes to cover all
40+
permutations.
41+
42+
By default each event provides an aggregate count over all nodes of the
43+
given type. To target a specific node, "bynodeid" must be set to 1 and
44+
"nodeid" to the appropriate value derived from the CMN configuration
45+
(as defined in the "Node ID Mapping" section of the TRM).
46+
47+
Watchpoints
48+
-----------
49+
50+
The PMU can also count watchpoint events to monitor specific flit
51+
traffic. Watchpoints are treated as a synthetic event type, and like PMU
52+
events can be global or targeted with a particular XP's "nodeid" value.
53+
Since the watchpoint direction is otherwise implicit in the underlying
54+
register selection, separate events are provided for flit uploads and
55+
downloads.
56+
57+
The flit match value and mask are passed in config1 and config2 ("val"
58+
and "mask" respectively). "wp_dev_sel", "wp_chn_sel", "wp_grp" and
59+
"wp_exclusive" are specified per the TRM definitions for dtm_wp_config0.
60+
Where a watchpoint needs to match fields from both match groups on the
61+
REQ or SNP channel, it can be specified as two events - one for each
62+
group - with the same nonzero "combine" value. The count for such a
63+
pair of combined events will be attributed to the primary match.
64+
Watchpoint events with a "combine" value of 0 are considered independent
65+
and will count individually.

Documentation/admin-guide/perf/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ Performance monitor support
1212
qcom_l2_pmu
1313
qcom_l3_pmu
1414
arm-ccn
15+
arm-cmn
1516
xgene-pmu
1617
arm_dsu_pmu
1718
thunderx2-pmu
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2+
# Copyright 2020 Arm Ltd.
3+
%YAML 1.2
4+
---
5+
$id: http://devicetree.org/schemas/perf/arm,cmn.yaml#
6+
$schema: http://devicetree.org/meta-schemas/core.yaml#
7+
8+
title: Arm CMN (Coherent Mesh Network) Performance Monitors
9+
10+
maintainers:
11+
- Robin Murphy <robin.murphy@arm.com>
12+
13+
properties:
14+
compatible:
15+
const: arm,cmn-600
16+
17+
reg:
18+
items:
19+
- description: Physical address of the base (PERIPHBASE) and
20+
size (up to 64MB) of the configuration address space.
21+
22+
interrupts:
23+
minItems: 1
24+
maxItems: 4
25+
items:
26+
- description: Overflow interrupt for DTC0
27+
- description: Overflow interrupt for DTC1
28+
- description: Overflow interrupt for DTC2
29+
- description: Overflow interrupt for DTC3
30+
description: One interrupt for each DTC domain implemented must
31+
be specified, in order. DTC0 is always present.
32+
33+
arm,root-node:
34+
$ref: /schemas/types.yaml#/definitions/uint32
35+
description: Offset from PERIPHBASE of the configuration
36+
discovery node (see TRM definition of ROOTNODEBASE).
37+
38+
required:
39+
- compatible
40+
- reg
41+
- interrupts
42+
- arm,root-node
43+
44+
additionalProperties: false
45+
46+
examples:
47+
- |
48+
#include <dt-bindings/interrupt-controller/arm-gic.h>
49+
#include <dt-bindings/interrupt-controller/irq.h>
50+
pmu@50000000 {
51+
compatible = "arm,cmn-600";
52+
reg = <0x50000000 0x4000000>;
53+
/* 4x2 mesh with one DTC, and CFG node at 0,1,1,0 */
54+
interrupts = <GIC_SPI 46 IRQ_TYPE_LEVEL_HIGH>;
55+
arm,root-node = <0x104000>;
56+
};
57+
...

Documentation/virt/kvm/arm/hyp-abi.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,9 +54,9 @@ these functions (see arch/arm{,64}/include/asm/virt.h):
5454
x3 = x1's value when entering the next payload (arm64)
5555
x4 = x2's value when entering the next payload (arm64)
5656

57-
Mask all exceptions, disable the MMU, move the arguments into place
58-
(arm64 only), and jump to the restart address while at HYP/EL2. This
59-
hypercall is not expected to return to its caller.
57+
Mask all exceptions, disable the MMU, clear I+D bits, move the arguments
58+
into place (arm64 only), and jump to the restart address while at HYP/EL2.
59+
This hypercall is not expected to return to its caller.
6060

6161
Any other value of r0/x0 triggers a hypervisor-specific handling,
6262
which is not documented here.

arch/arm64/Kconfig

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ config ARM64
2929
select ARCH_HAS_SETUP_DMA_OPS
3030
select ARCH_HAS_SET_DIRECT_MAP
3131
select ARCH_HAS_SET_MEMORY
32+
select ARCH_STACKWALK
3233
select ARCH_HAS_STRICT_KERNEL_RWX
3334
select ARCH_HAS_STRICT_MODULE_RWX
3435
select ARCH_HAS_SYNC_DMA_FOR_DEVICE
@@ -211,12 +212,18 @@ config ARM64_PAGE_SHIFT
211212
default 14 if ARM64_16K_PAGES
212213
default 12
213214

214-
config ARM64_CONT_SHIFT
215+
config ARM64_CONT_PTE_SHIFT
215216
int
216217
default 5 if ARM64_64K_PAGES
217218
default 7 if ARM64_16K_PAGES
218219
default 4
219220

221+
config ARM64_CONT_PMD_SHIFT
222+
int
223+
default 5 if ARM64_64K_PAGES
224+
default 5 if ARM64_16K_PAGES
225+
default 4
226+
220227
config ARCH_MMAP_RND_BITS_MIN
221228
default 14 if ARM64_64K_PAGES
222229
default 16 if ARM64_16K_PAGES
@@ -1876,6 +1883,10 @@ config ARCH_ENABLE_HUGEPAGE_MIGRATION
18761883
def_bool y
18771884
depends on HUGETLB_PAGE && MIGRATION
18781885

1886+
config ARCH_ENABLE_THP_MIGRATION
1887+
def_bool y
1888+
depends on TRANSPARENT_HUGEPAGE
1889+
18791890
menu "Power management options"
18801891

18811892
source "kernel/power/Kconfig"

arch/arm64/Makefile

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
# Copyright (C) 1995-2001 by Russell King
1212

1313
LDFLAGS_vmlinux :=--no-undefined -X
14-
CPPFLAGS_vmlinux.lds = -DTEXT_OFFSET=$(TEXT_OFFSET)
1514

1615
ifeq ($(CONFIG_RELOCATABLE), y)
1716
# Pass --no-apply-dynamic-relocs to restore pre-binutils-2.27 behaviour
@@ -132,9 +131,6 @@ endif
132131
# Default value
133132
head-y := arch/arm64/kernel/head.o
134133

135-
# The byte offset of the kernel image in RAM from the start of RAM.
136-
TEXT_OFFSET := 0x0
137-
138134
ifeq ($(CONFIG_KASAN_SW_TAGS), y)
139135
KASAN_SHADOW_SCALE_SHIFT := 4
140136
else
@@ -145,8 +141,6 @@ KBUILD_CFLAGS += -DKASAN_SHADOW_SCALE_SHIFT=$(KASAN_SHADOW_SCALE_SHIFT)
145141
KBUILD_CPPFLAGS += -DKASAN_SHADOW_SCALE_SHIFT=$(KASAN_SHADOW_SCALE_SHIFT)
146142
KBUILD_AFLAGS += -DKASAN_SHADOW_SCALE_SHIFT=$(KASAN_SHADOW_SCALE_SHIFT)
147143

148-
export TEXT_OFFSET
149-
150144
core-y += arch/arm64/
151145
libs-y := arch/arm64/lib/ $(libs-y)
152146
libs-$(CONFIG_EFI_STUB) += $(objtree)/drivers/firmware/efi/libstub/lib.a

arch/arm64/include/asm/boot.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,7 @@
1313
#define MAX_FDT_SIZE SZ_2M
1414

1515
/*
16-
* arm64 requires the kernel image to placed
17-
* TEXT_OFFSET bytes beyond a 2 MB aligned base
16+
* arm64 requires the kernel image to placed at a 2 MB aligned base address
1817
*/
1918
#define MIN_KIMG_ALIGN SZ_2M
2019

arch/arm64/include/asm/cpu_ops.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
* mechanism for doing so, tests whether it is possible to boot
2222
* the given CPU.
2323
* @cpu_boot: Boots a cpu into the kernel.
24-
* @cpu_postboot: Optionally, perform any post-boot cleanup or necesary
24+
* @cpu_postboot: Optionally, perform any post-boot cleanup or necessary
2525
* synchronisation. Called from the cpu being booted.
2626
* @cpu_can_disable: Determines whether a CPU can be disabled based on
2727
* mechanism-specific information.

arch/arm64/include/asm/cpufeature.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -358,7 +358,7 @@ static inline int cpucap_default_scope(const struct arm64_cpu_capabilities *cap)
358358
}
359359

360360
/*
361-
* Generic helper for handling capabilties with multiple (match,enable) pairs
361+
* Generic helper for handling capabilities with multiple (match,enable) pairs
362362
* of call backs, sharing the same capability bit.
363363
* Iterate over each entry to see if at least one matches.
364364
*/

arch/arm64/include/asm/esr.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,9 @@
3535
#define ESR_ELx_EC_SYS64 (0x18)
3636
#define ESR_ELx_EC_SVE (0x19)
3737
#define ESR_ELx_EC_ERET (0x1a) /* EL2 only */
38-
/* Unallocated EC: 0x1b - 0x1E */
38+
/* Unallocated EC: 0x1B */
39+
#define ESR_ELx_EC_FPAC (0x1C) /* EL1 and above */
40+
/* Unallocated EC: 0x1D - 0x1E */
3941
#define ESR_ELx_EC_IMP_DEF (0x1f) /* EL3 only */
4042
#define ESR_ELx_EC_IABT_LOW (0x20)
4143
#define ESR_ELx_EC_IABT_CUR (0x21)

0 commit comments

Comments
 (0)