Skip to content

Commit 56dcdfe

Browse files
committed
Merge remote-tracking branch 'stable/linux-6.12.y' into rpi-6.12.y
2 parents 4bc65d7 + f08cdc6 commit 56dcdfe

File tree

169 files changed

+1846
-983
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

169 files changed

+1846
-983
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# SPDX-License-Identifier: GPL-2.0
22
VERSION = 6
33
PATCHLEVEL = 12
4-
SUBLEVEL = 27
4+
SUBLEVEL = 28
55
EXTRAVERSION =
66
NAME = Baby Opossum Posse
77

arch/arm/boot/dts/nxp/imx/imx6ul-imx6ull-opos6ul.dtsi

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,9 @@
4040
reg = <1>;
4141
interrupt-parent = <&gpio4>;
4242
interrupts = <16 IRQ_TYPE_LEVEL_LOW>;
43+
micrel,led-mode = <1>;
44+
clocks = <&clks IMX6UL_CLK_ENET_REF>;
45+
clock-names = "rmii-ref";
4346
status = "okay";
4447
};
4548
};

arch/arm64/boot/dts/freescale/imx95.dtsi

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1478,7 +1478,7 @@
14781478
reg = <0 0x4c300000 0 0x10000>,
14791479
<0 0x60100000 0 0xfe00000>,
14801480
<0 0x4c360000 0 0x10000>,
1481-
<0 0x4c340000 0 0x2000>;
1481+
<0 0x4c340000 0 0x4000>;
14821482
reg-names = "dbi", "config", "atu", "app";
14831483
ranges = <0x81000000 0x0 0x00000000 0x0 0x6ff00000 0 0x00100000>,
14841484
<0x82000000 0x0 0x10000000 0x9 0x10000000 0 0x10000000>;
@@ -1518,7 +1518,7 @@
15181518
reg = <0 0x4c300000 0 0x10000>,
15191519
<0 0x4c360000 0 0x1000>,
15201520
<0 0x4c320000 0 0x1000>,
1521-
<0 0x4c340000 0 0x2000>,
1521+
<0 0x4c340000 0 0x4000>,
15221522
<0 0x4c370000 0 0x10000>,
15231523
<0x9 0 1 0>;
15241524
reg-names = "dbi","atu", "dbi2", "app", "dma", "addr_space";
@@ -1545,7 +1545,7 @@
15451545
reg = <0 0x4c380000 0 0x10000>,
15461546
<8 0x80100000 0 0xfe00000>,
15471547
<0 0x4c3e0000 0 0x10000>,
1548-
<0 0x4c3c0000 0 0x2000>;
1548+
<0 0x4c3c0000 0 0x4000>;
15491549
reg-names = "dbi", "config", "atu", "app";
15501550
ranges = <0x81000000 0 0x00000000 0x8 0x8ff00000 0 0x00100000>,
15511551
<0x82000000 0 0x10000000 0xa 0x10000000 0 0x10000000>;
@@ -1585,7 +1585,7 @@
15851585
reg = <0 0x4c380000 0 0x10000>,
15861586
<0 0x4c3e0000 0 0x1000>,
15871587
<0 0x4c3a0000 0 0x1000>,
1588-
<0 0x4c3c0000 0 0x2000>,
1588+
<0 0x4c3c0000 0 0x4000>,
15891589
<0 0x4c3f0000 0 0x10000>,
15901590
<0xa 0 1 0>;
15911591
reg-names = "dbi", "atu", "dbi2", "app", "dma", "addr_space";

arch/arm64/boot/dts/st/stm32mp251.dtsi

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -114,14 +114,13 @@
114114
};
115115

116116
intc: interrupt-controller@4ac00000 {
117-
compatible = "arm,cortex-a7-gic";
117+
compatible = "arm,gic-400";
118118
#interrupt-cells = <3>;
119-
#address-cells = <1>;
120119
interrupt-controller;
121120
reg = <0x0 0x4ac10000 0x0 0x1000>,
122-
<0x0 0x4ac20000 0x0 0x2000>,
123-
<0x0 0x4ac40000 0x0 0x2000>,
124-
<0x0 0x4ac60000 0x0 0x2000>;
121+
<0x0 0x4ac20000 0x0 0x20000>,
122+
<0x0 0x4ac40000 0x0 0x20000>,
123+
<0x0 0x4ac60000 0x0 0x20000>;
125124
};
126125

127126
psci {

arch/arm64/kernel/proton-pack.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -879,10 +879,12 @@ static u8 spectre_bhb_loop_affected(void)
879879
static const struct midr_range spectre_bhb_k132_list[] = {
880880
MIDR_ALL_VERSIONS(MIDR_CORTEX_X3),
881881
MIDR_ALL_VERSIONS(MIDR_NEOVERSE_V2),
882+
{},
882883
};
883884
static const struct midr_range spectre_bhb_k38_list[] = {
884885
MIDR_ALL_VERSIONS(MIDR_CORTEX_A715),
885886
MIDR_ALL_VERSIONS(MIDR_CORTEX_A720),
887+
{},
886888
};
887889
static const struct midr_range spectre_bhb_k32_list[] = {
888890
MIDR_ALL_VERSIONS(MIDR_CORTEX_A78),

arch/parisc/include/uapi/asm/socket.h

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -132,11 +132,15 @@
132132
#define SO_PASSPIDFD 0x404A
133133
#define SO_PEERPIDFD 0x404B
134134

135-
#define SO_DEVMEM_LINEAR 78
135+
#define SCM_TS_OPT_ID 0x404C
136+
137+
#define SO_RCVPRIORITY 0x404D
138+
139+
#define SO_DEVMEM_LINEAR 0x404E
136140
#define SCM_DEVMEM_LINEAR SO_DEVMEM_LINEAR
137-
#define SO_DEVMEM_DMABUF 79
141+
#define SO_DEVMEM_DMABUF 0x404F
138142
#define SCM_DEVMEM_DMABUF SO_DEVMEM_DMABUF
139-
#define SO_DEVMEM_DONTNEED 80
143+
#define SO_DEVMEM_DONTNEED 0x4050
140144

141145
#if !defined(__KERNEL__)
142146

arch/parisc/math-emu/driver.c

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,19 @@ handle_fpe(struct pt_regs *regs)
9797

9898
memcpy(regs->fr, frcopy, sizeof regs->fr);
9999
if (signalcode != 0) {
100-
force_sig_fault(signalcode >> 24, signalcode & 0xffffff,
101-
(void __user *) regs->iaoq[0]);
102-
return -1;
100+
int sig = signalcode >> 24;
101+
102+
if (sig == SIGFPE) {
103+
/*
104+
* Clear floating point trap bit to avoid trapping
105+
* again on the first floating-point instruction in
106+
* the userspace signal handler.
107+
*/
108+
regs->fr[0] &= ~(1ULL << 38);
109+
}
110+
force_sig_fault(sig, signalcode & 0xffffff,
111+
(void __user *) regs->iaoq[0]);
112+
return -1;
103113
}
104114

105115
return signalcode ? -1 : 0;

arch/powerpc/boot/wrapper

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -234,10 +234,8 @@ fi
234234

235235
# suppress some warnings in recent ld versions
236236
nowarn="-z noexecstack"
237-
if ! ld_is_lld; then
238-
if [ "$LD_VERSION" -ge "$(echo 2.39 | ld_version)" ]; then
239-
nowarn="$nowarn --no-warn-rwx-segments"
240-
fi
237+
if "${CROSS}ld" -v --no-warn-rwx-segments >/dev/null 2>&1; then
238+
nowarn="$nowarn --no-warn-rwx-segments"
241239
fi
242240

243241
platformo=$object/"$platform".o

arch/powerpc/mm/book3s64/radix_pgtable.c

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1132,6 +1132,19 @@ int __meminit radix__vmemmap_populate(unsigned long start, unsigned long end, in
11321132
pmd_t *pmd;
11331133
pte_t *pte;
11341134

1135+
/*
1136+
* Make sure we align the start vmemmap addr so that we calculate
1137+
* the correct start_pfn in altmap boundary check to decided whether
1138+
* we should use altmap or RAM based backing memory allocation. Also
1139+
* the address need to be aligned for set_pte operation.
1140+
1141+
* If the start addr is already PMD_SIZE aligned we will try to use
1142+
* a pmd mapping. We don't want to be too aggressive here beacause
1143+
* that will cause more allocations in RAM. So only if the namespace
1144+
* vmemmap start addr is PMD_SIZE aligned we will use PMD mapping.
1145+
*/
1146+
1147+
start = ALIGN_DOWN(start, PAGE_SIZE);
11351148
for (addr = start; addr < end; addr = next) {
11361149
next = pmd_addr_end(addr, end);
11371150

@@ -1157,8 +1170,8 @@ int __meminit radix__vmemmap_populate(unsigned long start, unsigned long end, in
11571170
* in altmap block allocation failures, in which case
11581171
* we fallback to RAM for vmemmap allocation.
11591172
*/
1160-
if (altmap && (!IS_ALIGNED(addr, PMD_SIZE) ||
1161-
altmap_cross_boundary(altmap, addr, PMD_SIZE))) {
1173+
if (!IS_ALIGNED(addr, PMD_SIZE) || (altmap &&
1174+
altmap_cross_boundary(altmap, addr, PMD_SIZE))) {
11621175
/*
11631176
* make sure we don't create altmap mappings
11641177
* covering things outside the device.

arch/x86/boot/compressed/mem.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,11 @@ static bool early_is_tdx_guest(void)
3434

3535
void arch_accept_memory(phys_addr_t start, phys_addr_t end)
3636
{
37-
static bool sevsnp;
38-
3937
/* Platform-specific memory-acceptance call goes here */
4038
if (early_is_tdx_guest()) {
4139
if (!tdx_accept_memory(start, end))
4240
panic("TDX: Failed to accept memory\n");
43-
} else if (sevsnp || (sev_get_status() & MSR_AMD64_SEV_SNP_ENABLED)) {
44-
sevsnp = true;
41+
} else if (early_is_sevsnp_guest()) {
4542
snp_accept_memory(start, end);
4643
} else {
4744
error("Cannot accept memory: unknown platform\n");

arch/x86/boot/compressed/sev.c

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -644,3 +644,43 @@ void sev_prep_identity_maps(unsigned long top_level_pgt)
644644

645645
sev_verify_cbit(top_level_pgt);
646646
}
647+
648+
bool early_is_sevsnp_guest(void)
649+
{
650+
static bool sevsnp;
651+
652+
if (sevsnp)
653+
return true;
654+
655+
if (!(sev_get_status() & MSR_AMD64_SEV_SNP_ENABLED))
656+
return false;
657+
658+
sevsnp = true;
659+
660+
if (!snp_vmpl) {
661+
unsigned int eax, ebx, ecx, edx;
662+
663+
/*
664+
* CPUID Fn8000_001F_EAX[28] - SVSM support
665+
*/
666+
eax = 0x8000001f;
667+
ecx = 0;
668+
native_cpuid(&eax, &ebx, &ecx, &edx);
669+
if (eax & BIT(28)) {
670+
struct msr m;
671+
672+
/* Obtain the address of the calling area to use */
673+
boot_rdmsr(MSR_SVSM_CAA, &m);
674+
boot_svsm_caa = (void *)m.q;
675+
boot_svsm_caa_pa = m.q;
676+
677+
/*
678+
* The real VMPL level cannot be discovered, but the
679+
* memory acceptance routines make no use of that so
680+
* any non-zero value suffices here.
681+
*/
682+
snp_vmpl = U8_MAX;
683+
}
684+
}
685+
return true;
686+
}

arch/x86/boot/compressed/sev.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,14 @@
1313
bool sev_snp_enabled(void);
1414
void snp_accept_memory(phys_addr_t start, phys_addr_t end);
1515
u64 sev_get_status(void);
16+
bool early_is_sevsnp_guest(void);
1617

1718
#else
1819

1920
static inline bool sev_snp_enabled(void) { return false; }
2021
static inline void snp_accept_memory(phys_addr_t start, phys_addr_t end) { }
2122
static inline u64 sev_get_status(void) { return 0; }
23+
static inline bool early_is_sevsnp_guest(void) { return false; }
2224

2325
#endif
2426

arch/x86/events/core.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -753,7 +753,7 @@ void x86_pmu_enable_all(int added)
753753
}
754754
}
755755

756-
static inline int is_x86_event(struct perf_event *event)
756+
int is_x86_event(struct perf_event *event)
757757
{
758758
int i;
759759

arch/x86/events/intel/core.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4333,7 +4333,7 @@ static struct perf_guest_switch_msr *intel_guest_get_msrs(int *nr, void *data)
43334333
arr[pebs_enable] = (struct perf_guest_switch_msr){
43344334
.msr = MSR_IA32_PEBS_ENABLE,
43354335
.host = cpuc->pebs_enabled & ~cpuc->intel_ctrl_guest_mask,
4336-
.guest = pebs_mask & ~cpuc->intel_ctrl_host_mask,
4336+
.guest = pebs_mask & ~cpuc->intel_ctrl_host_mask & kvm_pmu->pebs_enable,
43374337
};
43384338

43394339
if (arr[pebs_enable].host) {

arch/x86/events/perf_event.h

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,9 +110,16 @@ static inline bool is_topdown_event(struct perf_event *event)
110110
return is_metric_event(event) || is_slots_event(event);
111111
}
112112

113+
int is_x86_event(struct perf_event *event);
114+
115+
static inline bool check_leader_group(struct perf_event *leader, int flags)
116+
{
117+
return is_x86_event(leader) ? !!(leader->hw.flags & flags) : false;
118+
}
119+
113120
static inline bool is_branch_counters_group(struct perf_event *event)
114121
{
115-
return event->group_leader->hw.flags & PERF_X86_EVENT_BRANCH_COUNTERS;
122+
return check_leader_group(event->group_leader, PERF_X86_EVENT_BRANCH_COUNTERS);
116123
}
117124

118125
struct amd_nb {

block/blk-mq-cpumap.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,6 @@ void blk_mq_map_hw_queues(struct blk_mq_queue_map *qmap,
8787
return;
8888

8989
fallback:
90-
WARN_ON_ONCE(qmap->nr_queues > 1);
91-
blk_mq_clear_mq_map(qmap);
90+
blk_mq_map_queues(qmap);
9291
}
9392
EXPORT_SYMBOL_GPL(blk_mq_map_hw_queues);

drivers/accel/ivpu/ivpu_drv.c

Lines changed: 12 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,6 @@
3636
__stringify(DRM_IVPU_DRIVER_MINOR) "."
3737
#endif
3838

39-
static struct lock_class_key submitted_jobs_xa_lock_class_key;
40-
4139
int ivpu_dbg_mask;
4240
module_param_named(dbg_mask, ivpu_dbg_mask, int, 0644);
4341
MODULE_PARM_DESC(dbg_mask, "Driver debug mask. See IVPU_DBG_* macros.");
@@ -260,6 +258,9 @@ static int ivpu_open(struct drm_device *dev, struct drm_file *file)
260258
if (ret)
261259
goto err_xa_erase;
262260

261+
file_priv->job_limit.min = FIELD_PREP(IVPU_JOB_ID_CONTEXT_MASK, (file_priv->ctx.id - 1));
262+
file_priv->job_limit.max = file_priv->job_limit.min | IVPU_JOB_ID_JOB_MASK;
263+
263264
mutex_unlock(&vdev->context_list_lock);
264265
drm_dev_exit(idx);
265266

@@ -452,26 +453,6 @@ static const struct drm_driver driver = {
452453
.minor = DRM_IVPU_DRIVER_MINOR,
453454
};
454455

455-
static void ivpu_context_abort_invalid(struct ivpu_device *vdev)
456-
{
457-
struct ivpu_file_priv *file_priv;
458-
unsigned long ctx_id;
459-
460-
mutex_lock(&vdev->context_list_lock);
461-
462-
xa_for_each(&vdev->context_xa, ctx_id, file_priv) {
463-
if (!file_priv->has_mmu_faults || file_priv->aborted)
464-
continue;
465-
466-
mutex_lock(&file_priv->lock);
467-
ivpu_context_abort_locked(file_priv);
468-
file_priv->aborted = true;
469-
mutex_unlock(&file_priv->lock);
470-
}
471-
472-
mutex_unlock(&vdev->context_list_lock);
473-
}
474-
475456
static irqreturn_t ivpu_irq_thread_handler(int irq, void *arg)
476457
{
477458
struct ivpu_device *vdev = arg;
@@ -485,9 +466,6 @@ static irqreturn_t ivpu_irq_thread_handler(int irq, void *arg)
485466
case IVPU_HW_IRQ_SRC_IPC:
486467
ivpu_ipc_irq_thread_handler(vdev);
487468
break;
488-
case IVPU_HW_IRQ_SRC_MMU_EVTQ:
489-
ivpu_context_abort_invalid(vdev);
490-
break;
491469
case IVPU_HW_IRQ_SRC_DCT:
492470
ivpu_pm_dct_irq_thread_handler(vdev);
493471
break;
@@ -604,13 +582,21 @@ static int ivpu_dev_init(struct ivpu_device *vdev)
604582
xa_init_flags(&vdev->context_xa, XA_FLAGS_ALLOC | XA_FLAGS_LOCK_IRQ);
605583
xa_init_flags(&vdev->submitted_jobs_xa, XA_FLAGS_ALLOC1);
606584
xa_init_flags(&vdev->db_xa, XA_FLAGS_ALLOC1);
607-
lockdep_set_class(&vdev->submitted_jobs_xa.xa_lock, &submitted_jobs_xa_lock_class_key);
608585
INIT_LIST_HEAD(&vdev->bo_list);
609586

587+
vdev->db_limit.min = IVPU_MIN_DB;
588+
vdev->db_limit.max = IVPU_MAX_DB;
589+
590+
INIT_WORK(&vdev->context_abort_work, ivpu_context_abort_thread_handler);
591+
610592
ret = drmm_mutex_init(&vdev->drm, &vdev->context_list_lock);
611593
if (ret)
612594
goto err_xa_destroy;
613595

596+
ret = drmm_mutex_init(&vdev->drm, &vdev->submitted_jobs_lock);
597+
if (ret)
598+
goto err_xa_destroy;
599+
614600
ret = drmm_mutex_init(&vdev->drm, &vdev->bo_list_lock);
615601
if (ret)
616602
goto err_xa_destroy;

0 commit comments

Comments
 (0)