Skip to content

Commit

Permalink
Automatic merge of 'master' into merge (2023-11-12 11:39)
Browse files Browse the repository at this point in the history
  • Loading branch information
mpe committed Nov 12, 2023
2 parents fea4df5 + 3ca112b commit 275f511
Show file tree
Hide file tree
Showing 370 changed files with 7,085 additions and 7,489 deletions.
6 changes: 3 additions & 3 deletions Documentation/arch/arm64/elf_hwcaps.rst
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ HWCAP2_DCPODP
Functionality implied by ID_AA64ISAR1_EL1.DPB == 0b0010.

HWCAP2_SVE2
Functionality implied by ID_AA64ZFR0_EL1.SVEVer == 0b0001.
Functionality implied by ID_AA64ZFR0_EL1.SVEver == 0b0001.

HWCAP2_SVEAES
Functionality implied by ID_AA64ZFR0_EL1.AES == 0b0001.
Expand Down Expand Up @@ -222,7 +222,7 @@ HWCAP2_RNG
Functionality implied by ID_AA64ISAR0_EL1.RNDR == 0b0001.

HWCAP2_BTI
Functionality implied by ID_AA64PFR0_EL1.BT == 0b0001.
Functionality implied by ID_AA64PFR1_EL1.BT == 0b0001.

HWCAP2_MTE
Functionality implied by ID_AA64PFR1_EL1.MTE == 0b0010, as described
Expand All @@ -232,7 +232,7 @@ HWCAP2_ECV
Functionality implied by ID_AA64MMFR0_EL1.ECV == 0b0001.

HWCAP2_AFP
Functionality implied by ID_AA64MFR1_EL1.AFP == 0b0001.
Functionality implied by ID_AA64MMFR1_EL1.AFP == 0b0001.

HWCAP2_RPRES
Functionality implied by ID_AA64ISAR2_EL1.RPRES == 0b0001.
Expand Down
20 changes: 20 additions & 0 deletions Documentation/arch/riscv/uabi.rst
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,26 @@ An example string following the order is::

rv64imadc_zifoo_zigoo_zafoo_sbar_scar_zxmbaz_xqux_xrux

"isa" and "hart isa" lines in /proc/cpuinfo
-------------------------------------------

The "isa" line in /proc/cpuinfo describes the lowest common denominator of
RISC-V ISA extensions recognized by the kernel and implemented on all harts. The
"hart isa" line, in contrast, describes the set of extensions recognized by the
kernel on the particular hart being described, even if those extensions may not
be present on all harts in the system.

In both lines, the presence of an extension guarantees only that the hardware
has the described capability. Additional kernel support or policy changes may be
required before an extension's capability is fully usable by userspace programs.
Similarly, for S-mode extensions, presence in one of these lines does not
guarantee that the kernel is taking advantage of the extension, or that the
feature will be visible in guest VMs managed by this kernel.

Inversely, the absence of an extension in these lines does not necessarily mean
the hardware does not support that feature. The running kernel may not recognize
the extension, or may have deliberately removed it from the listing.

Misaligned accesses
-------------------

Expand Down
8 changes: 6 additions & 2 deletions Documentation/trace/fprobetrace.rst
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,12 @@ Synopsis of fprobe-events
and bitfield are supported.

(\*1) This is available only when BTF is enabled.
(\*2) only for the probe on function entry (offs == 0).
(\*3) only for return probe.
(\*2) only for the probe on function entry (offs == 0). Note, this argument access
is best effort, because depending on the argument type, it may be passed on
the stack. But this only support the arguments via registers.
(\*3) only for return probe. Note that this is also best effort. Depending on the
return value type, it might be passed via a pair of registers. But this only
accesses one register.
(\*4) this is useful for fetching a field of data structures.
(\*5) "u" means user-space dereference.

Expand Down
8 changes: 6 additions & 2 deletions Documentation/trace/kprobetrace.rst
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,12 @@ Synopsis of kprobe_events
(x8/x16/x32/x64), "char", "string", "ustring", "symbol", "symstr"
and bitfield are supported.

(\*1) only for the probe on function entry (offs == 0).
(\*2) only for return probe.
(\*1) only for the probe on function entry (offs == 0). Note, this argument access
is best effort, because depending on the argument type, it may be passed on
the stack. But this only support the arguments via registers.
(\*2) only for return probe. Note that this is also best effort. Depending on the
return value type, it might be passed via a pair of registers. But this only
accesses one register.
(\*3) this is useful for fetching a field of data structures.
(\*4) "u" means user-space dereference. See :ref:`user_mem_access`.

Expand Down
7 changes: 0 additions & 7 deletions MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -23198,13 +23198,6 @@ W: https://linuxtv.org
T: git git://linuxtv.org/media_tree.git
F: drivers/media/test-drivers/vivid/*

VLYNQ BUS
M: Florian Fainelli <[email protected]>
L: [email protected] (subscribers-only)
S: Maintained
F: drivers/vlynq/vlynq.c
F: include/linux/vlynq.h

VM SOCKETS (AF_VSOCK)
M: Stefano Garzarella <[email protected]>
L: [email protected]
Expand Down
3 changes: 0 additions & 3 deletions arch/arc/include/asm/kprobes.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,6 @@ struct kprobe;

void arch_remove_kprobe(struct kprobe *p);

int kprobe_exceptions_notify(struct notifier_block *self,
unsigned long val, void *data);

struct prev_kprobe {
struct kprobe *kp;
unsigned long status;
Expand Down
1 change: 0 additions & 1 deletion arch/arm/configs/pxa_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,6 @@ CONFIG_DEVTMPFS=y
CONFIG_DEVTMPFS_MOUNT=y
CONFIG_CONNECTOR=y
CONFIG_MTD=y
CONFIG_MTD_AR7_PARTS=m
CONFIG_MTD_CMDLINE_PARTS=m
CONFIG_MTD_OF_PARTS=m
CONFIG_MTD_AFS_PARTS=m
Expand Down
48 changes: 23 additions & 25 deletions arch/arm/include/asm/arm_pmuv3.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
#define PMUSERENR __ACCESS_CP15(c9, 0, c14, 0)
#define PMINTENSET __ACCESS_CP15(c9, 0, c14, 1)
#define PMINTENCLR __ACCESS_CP15(c9, 0, c14, 2)
#define PMCEID2 __ACCESS_CP15(c9, 0, c14, 4)
#define PMCEID3 __ACCESS_CP15(c9, 0, c14, 5)
#define PMMIR __ACCESS_CP15(c9, 0, c14, 6)
#define PMCCFILTR __ACCESS_CP15(c14, 0, c15, 7)

Expand Down Expand Up @@ -150,21 +152,6 @@ static inline u64 read_pmccntr(void)
return read_sysreg(PMCCNTR);
}

static inline void write_pmxevcntr(u32 val)
{
write_sysreg(val, PMXEVCNTR);
}

static inline u32 read_pmxevcntr(void)
{
return read_sysreg(PMXEVCNTR);
}

static inline void write_pmxevtyper(u32 val)
{
write_sysreg(val, PMXEVTYPER);
}

static inline void write_pmcntenset(u32 val)
{
write_sysreg(val, PMCNTENSET);
Expand Down Expand Up @@ -205,16 +192,6 @@ static inline void write_pmuserenr(u32 val)
write_sysreg(val, PMUSERENR);
}

static inline u32 read_pmceid0(void)
{
return read_sysreg(PMCEID0);
}

static inline u32 read_pmceid1(void)
{
return read_sysreg(PMCEID1);
}

static inline void kvm_set_pmu_events(u32 set, struct perf_event_attr *attr) {}
static inline void kvm_clr_pmu_events(u32 clr) {}
static inline bool kvm_pmu_counter_deferred(struct perf_event_attr *attr)
Expand All @@ -231,6 +208,7 @@ static inline void kvm_vcpu_pmu_resync_el0(void) {}

/* PMU Version in DFR Register */
#define ARMV8_PMU_DFR_VER_NI 0
#define ARMV8_PMU_DFR_VER_V3P1 0x4
#define ARMV8_PMU_DFR_VER_V3P4 0x5
#define ARMV8_PMU_DFR_VER_V3P5 0x6
#define ARMV8_PMU_DFR_VER_IMP_DEF 0xF
Expand All @@ -251,4 +229,24 @@ static inline bool is_pmuv3p5(int pmuver)
return pmuver >= ARMV8_PMU_DFR_VER_V3P5;
}

static inline u64 read_pmceid0(void)
{
u64 val = read_sysreg(PMCEID0);

if (read_pmuver() >= ARMV8_PMU_DFR_VER_V3P1)
val |= (u64)read_sysreg(PMCEID2) << 32;

return val;
}

static inline u64 read_pmceid1(void)
{
u64 val = read_sysreg(PMCEID1);

if (read_pmuver() >= ARMV8_PMU_DFR_VER_V3P1)
val |= (u64)read_sysreg(PMCEID3) << 32;

return val;
}

#endif
2 changes: 0 additions & 2 deletions arch/arm/include/asm/kprobes.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,6 @@ struct kprobe_ctlblk {

void arch_remove_kprobe(struct kprobe *);
int kprobe_fault_handler(struct pt_regs *regs, unsigned int fsr);
int kprobe_exceptions_notify(struct notifier_block *self,
unsigned long val, void *data);

/* optinsn template addresses */
extern __visible kprobe_opcode_t optprobe_template_entry[];
Expand Down
25 changes: 5 additions & 20 deletions arch/arm64/include/asm/arm_pmuv3.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,12 @@ static inline u32 read_pmuver(void)
ID_AA64DFR0_EL1_PMUVer_SHIFT);
}

static inline void write_pmcr(u32 val)
static inline void write_pmcr(u64 val)
{
write_sysreg(val, pmcr_el0);
}

static inline u32 read_pmcr(void)
static inline u64 read_pmcr(void)
{
return read_sysreg(pmcr_el0);
}
Expand All @@ -71,21 +71,6 @@ static inline u64 read_pmccntr(void)
return read_sysreg(pmccntr_el0);
}

static inline void write_pmxevcntr(u32 val)
{
write_sysreg(val, pmxevcntr_el0);
}

static inline u32 read_pmxevcntr(void)
{
return read_sysreg(pmxevcntr_el0);
}

static inline void write_pmxevtyper(u32 val)
{
write_sysreg(val, pmxevtyper_el0);
}

static inline void write_pmcntenset(u32 val)
{
write_sysreg(val, pmcntenset_el0);
Expand All @@ -106,7 +91,7 @@ static inline void write_pmintenclr(u32 val)
write_sysreg(val, pmintenclr_el1);
}

static inline void write_pmccfiltr(u32 val)
static inline void write_pmccfiltr(u64 val)
{
write_sysreg(val, pmccfiltr_el0);
}
Expand All @@ -126,12 +111,12 @@ static inline void write_pmuserenr(u32 val)
write_sysreg(val, pmuserenr_el0);
}

static inline u32 read_pmceid0(void)
static inline u64 read_pmceid0(void)
{
return read_sysreg(pmceid0_el0);
}

static inline u32 read_pmceid1(void)
static inline u64 read_pmceid1(void)
{
return read_sysreg(pmceid1_el0);
}
Expand Down
2 changes: 0 additions & 2 deletions arch/arm64/include/asm/kprobes.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ struct kprobe_ctlblk {

void arch_remove_kprobe(struct kprobe *);
int kprobe_fault_handler(struct pt_regs *regs, unsigned int fsr);
int kprobe_exceptions_notify(struct notifier_block *self,
unsigned long val, void *data);
void __kretprobe_trampoline(void);
void __kprobes *trampoline_probe_handler(struct pt_regs *regs);

Expand Down
1 change: 0 additions & 1 deletion arch/arm64/include/asm/syscall_wrapper.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@
ALLOW_ERROR_INJECTION(__arm64_sys##name, ERRNO); \
static long __se_sys##name(__MAP(x,__SC_LONG,__VA_ARGS__)); \
static inline long __do_sys##name(__MAP(x,__SC_DECL,__VA_ARGS__)); \
asmlinkage long __arm64_sys##name(const struct pt_regs *regs); \
asmlinkage long __arm64_sys##name(const struct pt_regs *regs) \
{ \
return __se_sys##name(SC_ARM64_REGS_TO_ARGS(x,__VA_ARGS__)); \
Expand Down
46 changes: 38 additions & 8 deletions arch/arm64/kernel/cpufeature.c
Original file line number Diff line number Diff line change
Expand Up @@ -999,6 +999,37 @@ static void init_32bit_cpu_features(struct cpuinfo_32bit *info)
init_cpu_ftr_reg(SYS_MVFR2_EL1, info->reg_mvfr2);
}

#ifdef CONFIG_ARM64_PSEUDO_NMI
static bool enable_pseudo_nmi;

static int __init early_enable_pseudo_nmi(char *p)
{
return kstrtobool(p, &enable_pseudo_nmi);
}
early_param("irqchip.gicv3_pseudo_nmi", early_enable_pseudo_nmi);

static __init void detect_system_supports_pseudo_nmi(void)
{
struct device_node *np;

if (!enable_pseudo_nmi)
return;

/*
* Detect broken MediaTek firmware that doesn't properly save and
* restore GIC priorities.
*/
np = of_find_compatible_node(NULL, NULL, "arm,gic-v3");
if (np && of_property_read_bool(np, "mediatek,broken-save-restore-fw")) {
pr_info("Pseudo-NMI disabled due to MediaTek Chromebook GICR save problem\n");
enable_pseudo_nmi = false;
}
of_node_put(np);
}
#else /* CONFIG_ARM64_PSEUDO_NMI */
static inline void detect_system_supports_pseudo_nmi(void) { }
#endif

void __init init_cpu_features(struct cpuinfo_arm64 *info)
{
/* Before we start using the tables, make sure it is sorted */
Expand Down Expand Up @@ -1057,6 +1088,13 @@ void __init init_cpu_features(struct cpuinfo_arm64 *info)
*/
init_cpucap_indirect_list();

/*
* Detect broken pseudo-NMI. Must be called _before_ the call to
* setup_boot_cpu_capabilities() since it interacts with
* can_use_gic_priorities().
*/
detect_system_supports_pseudo_nmi();

/*
* Detect and enable early CPU capabilities based on the boot CPU,
* after we have initialised the CPU feature infrastructure.
Expand Down Expand Up @@ -2085,14 +2123,6 @@ static void cpu_enable_e0pd(struct arm64_cpu_capabilities const *cap)
#endif /* CONFIG_ARM64_E0PD */

#ifdef CONFIG_ARM64_PSEUDO_NMI
static bool enable_pseudo_nmi;

static int __init early_enable_pseudo_nmi(char *p)
{
return kstrtobool(p, &enable_pseudo_nmi);
}
early_param("irqchip.gicv3_pseudo_nmi", early_enable_pseudo_nmi);

static bool can_use_gic_priorities(const struct arm64_cpu_capabilities *entry,
int scope)
{
Expand Down
5 changes: 1 addition & 4 deletions arch/arm64/kernel/smp.c
Original file line number Diff line number Diff line change
Expand Up @@ -965,10 +965,7 @@ static void smp_cross_call(const struct cpumask *target, unsigned int ipinr)

static bool ipi_should_be_nmi(enum ipi_msg_type ipi)
{
DECLARE_STATIC_KEY_FALSE(supports_pseudo_nmis);

if (!system_uses_irq_prio_masking() ||
!static_branch_likely(&supports_pseudo_nmis))
if (!system_uses_irq_prio_masking())
return false;

switch (ipi) {
Expand Down
1 change: 0 additions & 1 deletion arch/mips/Kbuild.platforms
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
# All platforms listed in alphabetic order

platform-$(CONFIG_MIPS_ALCHEMY) += alchemy/
platform-$(CONFIG_AR7) += ar7/
platform-$(CONFIG_ATH25) += ath25/
platform-$(CONFIG_ATH79) += ath79/
platform-$(CONFIG_BCM47XX) += bcm47xx/
Expand Down
22 changes: 0 additions & 22 deletions arch/mips/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -202,28 +202,6 @@ config MIPS_ALCHEMY
select SYS_SUPPORTS_ZBOOT
select COMMON_CLK

config AR7
bool "Texas Instruments AR7"
select BOOT_ELF32
select COMMON_CLK
select DMA_NONCOHERENT
select CEVT_R4K
select CSRC_R4K
select IRQ_MIPS_CPU
select NO_EXCEPT_FILL
select SWAP_IO_SPACE
select SYS_HAS_CPU_MIPS32_R1
select SYS_HAS_EARLY_PRINTK
select SYS_SUPPORTS_32BIT_KERNEL
select SYS_SUPPORTS_LITTLE_ENDIAN
select SYS_SUPPORTS_MIPS16
select SYS_SUPPORTS_ZBOOT_UART16550
select GPIOLIB
select VLYNQ
help
Support for the Texas Instruments AR7 System-on-a-Chip
family: TNETD7100, 7200 and 7300.

config ATH25
bool "Atheros AR231x/AR531x SoC support"
select CEVT_R4K
Expand Down
Loading

0 comments on commit 275f511

Please sign in to comment.