Skip to content

Commit 0429d7f

Browse files
committed
Merge tag 'v6.1.146' into orange-pi-6.1-rk35xx
This is the 6.1.146 stable release * tag 'v6.1.146' of https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux: Linux 6.1.146 rseq: Fix segfault on registration when rseq_cs is non-zero ksmbd: fix potential use-after-free in oplock/lease break ack kasan: remove kasan_find_vm_area() to prevent possible deadlock x86: Fix X86_FEATURE_VERW_CLEAR definition x86/mm: Disable hugetlb page table sharing on 32-bit vhost-scsi: protect vq->log_used with vq->mutex Input: atkbd - do not skip atkbd_deactivate() when skipping ATKBD_CMD_GETID HID: quirks: Add quirk for 2 Chicony Electronics HP 5MP Cameras HID: Add IGNORE quirk for SMARTLINKTECHNOLOGY vt: add missing notification when switching back to text mode btrfs: fix assertion when building free space tree HID: lenovo: Add support for ThinkPad X1 Tablet Thin Keyboard Gen2 net: usb: qmi_wwan: add SIMCom 8230C composition ALSA: hda/realtek - Enable mute LED on HP Pavilion Laptop 15-eg100 ASoC: amd: yc: add quirk for Acer Nitro ANV15-41 internal mic um: vector: Reduce stack usage in vector_eth_configure() atm: idt77252: Add missing `dma_map_error()` bnxt_en: Set DMA unmap len correctly for XDP_REDIRECT bnxt_en: Fix DCB ETS validation net: ll_temac: Fix missing tx_pending check in ethtools_set_ringparam() can: m_can: m_can_handle_lost_msg(): downgrade msg lost in rx message to debug level net: phy: microchip: limit 100M workaround to link-down events on LAN88xx ibmvnic: Fix hardcoded NUM_RX_STATS/NUM_TX_STATS with dynamic sizeof net: appletalk: Fix device refcount leak in atrtr_create() netfilter: flowtable: account for Ethernet header in nf_flow_pppoe_proto() erofs: fix to add missing tracepoint in erofs_read_folio() erofs: adapt folios for z_erofs_read_folio() erofs: avoid on-stack pagepool directly passed by arguments erofs: allocate extra bvec pages directly instead of retrying erofs: clean up z_erofs_pcluster_readmore() erofs: remove the member readahead from struct z_erofs_decompress_frontend nbd: fix uaf in nbd_genl_connect() error path raid10: cleanup memleak at raid10_make_request md/raid1: Fix stack memory use after return in raid1_reshape drm/tegra: nvdec: Fix dma_alloc_coherent error check wifi: zd1211rw: Fix potential NULL pointer dereference in zd_mac_tx_to_dev() usb: dwc3: Abort suspend on soft disconnect failure usb: cdnsp: Fix issue with CV Bad Descriptor test usb: cdnsp: Replace snprintf() with the safer scnprintf() variant usb:cdnsp: remove TRB_FLUSH_ENDPOINT command Input: xpad - support Acer NGR 200 Controller usb: xhci: quirk for data loss in ISOC transfers xhci: Allow RPM on the USB controller (1022:43f7) by default btrfs: propagate last_unlink_trans earlier when doing a rmdir fs: export anon_inode_make_secure_inode() and fix secretmem LSM bypass netlink: make sure we allow at least one dump skb netlink: Fix rmem check in netlink_broadcast_deliver(). ksmbd: fix a mount write count leak in ksmbd_vfs_kern_path_locked() smb: server: make use of rdma_destroy_qp() pwm: mediatek: Ensure to disable clocks in error path maple_tree: fix mt_destroy_walk() on root leaf node kallsyms: fix build without execinfo Revert "ACPI: battery: negate current when discharging" usb: gadget: u_serial: Fix race condition in TTY wakeup drm/gem: Fix race in drm_gem_handle_create_tail() drm/ttm: fix error handling in ttm_buffer_object_transfer drm/sched: Increment job count before swapping tail spsc queue wifi: prevent A-MSDU attacks in mesh networks pinctrl: qcom: msm: mark certain pins as invalid for interrupts md/md-bitmap: fix GPF in bitmap_get_stats() gre: Fix IPv6 multicast route creation. KVM: SVM: Reject SEV{-ES} intra host migration if vCPU creation is in-flight KVM: x86/xen: Allow 'out of range' event channel ports in IRQ routing table. x86/mce: Make sure CMCI banks are cleared during shutdown on Intel x86/mce: Don't remove sysfs if thresholding sysfs init fails x86/mce/amd: Fix threshold limit reset ipmi:msghandler: Fix potential memory corruption in ipmi_create_user() x86/boot: Compile boot code with -std=gnu11 too rxrpc: Fix oops due to non-existence of prealloc backlog struct maple_tree: fix MA_STATE_PREALLOC flag in mas_preallocate() net/sched: Abort __tc_modify_qdisc if parent class does not exist atm: clip: Fix NULL pointer dereference in vcc_sendmsg() atm: clip: Fix infinite recursive call of clip_push(). atm: clip: Fix memory leak of struct clip_vcc. atm: clip: Fix potential null-ptr-deref in to_atmarpd(). net: phy: smsc: Fix link failure in forced mode with Auto-MDIX net: phy: smsc: Fix Auto-MDIX configuration when disabled by strap vsock: Fix IOCTL_VM_SOCKETS_GET_LOCAL_CID to check also `transport_local` vsock: Fix transport_* TOCTOU vsock: Fix transport_{g2h,h2g} TOCTOU tipc: Fix use-after-free in tipc_conn_close(). netlink: Fix wraparounds of sk->sk_rmem_alloc. fix proc_sys_compare() handling of in-lookup dentries Bluetooth: hci_sync: Fix not disabling advertising instance perf: Revert to requiring CAP_SYS_ADMIN for uprobes ASoC: fsl_asrc: use internal measured ratio for non-ideal ratio mode platform/x86: ideapad-laptop: use usleep_range() for EC polling drm/exynos: exynos7_drm_decon: add vblank check in IRQ handling Signed-off-by: Khusika Dhamar Gusti <[email protected]> Conflicts: drivers/usb/host/xhci.h
2 parents e8582e3 + 3369c6d commit 0429d7f

Some content is hidden

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

86 files changed

+901
-589
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 = 1
4-
SUBLEVEL = 145
4+
SUBLEVEL = 146
55
EXTRAVERSION =
66
NAME = Curry Ramen
77

arch/um/drivers/vector_kern.c

Lines changed: 13 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1600,35 +1600,19 @@ static void vector_eth_configure(
16001600

16011601
device->dev = dev;
16021602

1603-
*vp = ((struct vector_private)
1604-
{
1605-
.list = LIST_HEAD_INIT(vp->list),
1606-
.dev = dev,
1607-
.unit = n,
1608-
.options = get_transport_options(def),
1609-
.rx_irq = 0,
1610-
.tx_irq = 0,
1611-
.parsed = def,
1612-
.max_packet = get_mtu(def) + ETH_HEADER_OTHER,
1613-
/* TODO - we need to calculate headroom so that ip header
1614-
* is 16 byte aligned all the time
1615-
*/
1616-
.headroom = get_headroom(def),
1617-
.form_header = NULL,
1618-
.verify_header = NULL,
1619-
.header_rxbuffer = NULL,
1620-
.header_txbuffer = NULL,
1621-
.header_size = 0,
1622-
.rx_header_size = 0,
1623-
.rexmit_scheduled = false,
1624-
.opened = false,
1625-
.transport_data = NULL,
1626-
.in_write_poll = false,
1627-
.coalesce = 2,
1628-
.req_size = get_req_size(def),
1629-
.in_error = false,
1630-
.bpf = NULL
1631-
});
1603+
INIT_LIST_HEAD(&vp->list);
1604+
vp->dev = dev;
1605+
vp->unit = n;
1606+
vp->options = get_transport_options(def);
1607+
vp->parsed = def;
1608+
vp->max_packet = get_mtu(def) + ETH_HEADER_OTHER;
1609+
/*
1610+
* TODO - we need to calculate headroom so that ip header
1611+
* is 16 byte aligned all the time
1612+
*/
1613+
vp->headroom = get_headroom(def);
1614+
vp->coalesce = 2;
1615+
vp->req_size = get_req_size(def);
16321616

16331617
dev->features = dev->hw_features = (NETIF_F_SG | NETIF_F_FRAGLIST);
16341618
INIT_WORK(&vp->reset_tx, vector_reset_tx);

arch/x86/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ config X86
124124
select ARCH_WANTS_DYNAMIC_TASK_STRUCT
125125
select ARCH_WANTS_NO_INSTR
126126
select ARCH_WANT_GENERAL_HUGETLB
127-
select ARCH_WANT_HUGE_PMD_SHARE
127+
select ARCH_WANT_HUGE_PMD_SHARE if X86_64
128128
select ARCH_WANT_HUGETLB_PAGE_OPTIMIZE_VMEMMAP if X86_64
129129
select ARCH_WANT_LD_ORPHAN_WARN
130130
select ARCH_WANTS_THP_SWAP if X86_64

arch/x86/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ endif
4343

4444
# How to compile the 16-bit code. Note we always compile for -march=i386;
4545
# that way we can complain to the user if the CPU is insufficient.
46-
REALMODE_CFLAGS := -m16 -g -Os -DDISABLE_BRANCH_PROFILING -D__DISABLE_EXPORTS \
46+
REALMODE_CFLAGS := -std=gnu11 -m16 -g -Os -DDISABLE_BRANCH_PROFILING -D__DISABLE_EXPORTS \
4747
-Wall -Wstrict-prototypes -march=i386 -mregparm=3 \
4848
-fno-strict-aliasing -fomit-frame-pointer -fno-pic \
4949
-mno-mmx -mno-sse $(call cc-option,-fcf-protection=none)

arch/x86/include/asm/cpufeatures.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -429,8 +429,8 @@
429429
#define X86_FEATURE_V_TSC_AUX (19*32+ 9) /* "" Virtual TSC_AUX */
430430
#define X86_FEATURE_SME_COHERENT (19*32+10) /* "" AMD hardware-enforced cache coherency */
431431

432+
#define X86_FEATURE_VERW_CLEAR (20*32+ 5) /* "" The memory form of VERW mitigates TSA */
432433
#define X86_FEATURE_AUTOIBRS (20*32+ 8) /* "" Automatic IBRS */
433-
#define X86_FEATURE_VERW_CLEAR (20*32+ 10) /* "" The memory form of VERW mitigates TSA */
434434
#define X86_FEATURE_SBPB (20*32+27) /* "" Selective Branch Prediction Barrier */
435435
#define X86_FEATURE_IBPB_BRTYPE (20*32+28) /* "" MSR_PRED_CMD[IBPB] flushes all branch type predictions */
436436
#define X86_FEATURE_SRSO_NO (20*32+29) /* "" CPU is not affected by SRSO */

arch/x86/kernel/cpu/mce/amd.c

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -333,7 +333,6 @@ static void smca_configure(unsigned int bank, unsigned int cpu)
333333

334334
struct thresh_restart {
335335
struct threshold_block *b;
336-
int reset;
337336
int set_lvt_off;
338337
int lvt_off;
339338
u16 old_limit;
@@ -428,13 +427,13 @@ static void threshold_restart_bank(void *_tr)
428427

429428
rdmsr(tr->b->address, lo, hi);
430429

431-
if (tr->b->threshold_limit < (hi & THRESHOLD_MAX))
432-
tr->reset = 1; /* limit cannot be lower than err count */
433-
434-
if (tr->reset) { /* reset err count and overflow bit */
435-
hi =
436-
(hi & ~(MASK_ERR_COUNT_HI | MASK_OVERFLOW_HI)) |
437-
(THRESHOLD_MAX - tr->b->threshold_limit);
430+
/*
431+
* Reset error count and overflow bit.
432+
* This is done during init or after handling an interrupt.
433+
*/
434+
if (hi & MASK_OVERFLOW_HI || tr->set_lvt_off) {
435+
hi &= ~(MASK_ERR_COUNT_HI | MASK_OVERFLOW_HI);
436+
hi |= THRESHOLD_MAX - tr->b->threshold_limit;
438437
} else if (tr->old_limit) { /* change limit w/o reset */
439438
int new_count = (hi & THRESHOLD_MAX) +
440439
(tr->old_limit - tr->b->threshold_limit);

arch/x86/kernel/cpu/mce/core.c

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2707,15 +2707,9 @@ static int mce_cpu_dead(unsigned int cpu)
27072707
static int mce_cpu_online(unsigned int cpu)
27082708
{
27092709
struct timer_list *t = this_cpu_ptr(&mce_timer);
2710-
int ret;
27112710

27122711
mce_device_create(cpu);
2713-
2714-
ret = mce_threshold_create_device(cpu);
2715-
if (ret) {
2716-
mce_device_remove(cpu);
2717-
return ret;
2718-
}
2712+
mce_threshold_create_device(cpu);
27192713
mce_reenable_cpu();
27202714
mce_start_timer(t);
27212715
return 0;

arch/x86/kernel/cpu/mce/intel.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -500,6 +500,7 @@ void mce_intel_feature_init(struct cpuinfo_x86 *c)
500500
void mce_intel_feature_clear(struct cpuinfo_x86 *c)
501501
{
502502
intel_clear_lmce();
503+
cmci_clear();
503504
}
504505

505506
bool intel_filter_mce(struct mce *m)

arch/x86/kvm/svm/sev.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1755,6 +1755,10 @@ static int sev_check_source_vcpus(struct kvm *dst, struct kvm *src)
17551755
struct kvm_vcpu *src_vcpu;
17561756
unsigned long i;
17571757

1758+
if (src->created_vcpus != atomic_read(&src->online_vcpus) ||
1759+
dst->created_vcpus != atomic_read(&dst->online_vcpus))
1760+
return -EBUSY;
1761+
17581762
if (!sev_es_guest(src))
17591763
return 0;
17601764

arch/x86/kvm/xen.c

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1536,8 +1536,19 @@ int kvm_xen_setup_evtchn(struct kvm *kvm,
15361536
{
15371537
struct kvm_vcpu *vcpu;
15381538

1539-
if (ue->u.xen_evtchn.port >= max_evtchn_port(kvm))
1540-
return -EINVAL;
1539+
/*
1540+
* Don't check for the port being within range of max_evtchn_port().
1541+
* Userspace can configure what ever targets it likes; events just won't
1542+
* be delivered if/while the target is invalid, just like userspace can
1543+
* configure MSIs which target non-existent APICs.
1544+
*
1545+
* This allow on Live Migration and Live Update, the IRQ routing table
1546+
* can be restored *independently* of other things like creating vCPUs,
1547+
* without imposing an ordering dependency on userspace. In this
1548+
* particular case, the problematic ordering would be with setting the
1549+
* Xen 'long mode' flag, which changes max_evtchn_port() to allow 4096
1550+
* instead of 1024 event channels.
1551+
*/
15411552

15421553
/* We only support 2 level event channels for now */
15431554
if (ue->u.xen_evtchn.priority != KVM_IRQ_ROUTING_XEN_EVTCHN_PRIO_2LEVEL)

0 commit comments

Comments
 (0)