Linux 6.1.86
Greg Kroah-Hartman
maintainerI'm announcing the release of the 6.1.86 kernel.
All users of the 6.1 kernel series must upgrade.
The updated 6.1.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-6.1.y
and can be browsed at the normal kernel.org git web browser:
https://git.kernel.org/?p=linux/kernel/git/stable/linux-stable.git;a=summary
thanks,
greg k-h
------------
Makefile | 2 arch/arm64/boot/dts/rockchip/rk3328.dtsi | 11 +- arch/arm64/boot/dts/rockchip/rk3399.dtsi | 12 +- arch/x86/events/amd/lbr.c | 6 - block/blk-stat.c | 2 drivers/acpi/sleep.c | 12 -- drivers/bluetooth/btintel.c | 2 drivers/bluetooth/btmtk.c | 1 drivers/bluetooth/btmtk.h | 1 drivers/bus/mhi/host/init.c | 1 drivers/bus/mhi/host/internal.h | 9 + drivers/bus/mhi/host/pm.c | 20 +++ drivers/cpufreq/cpufreq.c | 17 ++- drivers/cpuidle/driver.c | 3 drivers/firmware/tegra/bpmp-debugfs.c | 2 drivers/gpu/drm/amd/amdkfd/kfd_chardev.c | 4 drivers/gpu/drm/amd/display/modules/inc/mod_stats.h | 4 drivers/gpu/drm/drm_panel_orientation_quirks.c | 12 ++ drivers/gpu/drm/vc4/vc4_plane.c | 5 drivers/infiniband/core/cm.c | 20 +++ drivers/input/rmi4/rmi_driver.c | 6 - drivers/input/touchscreen/imagis.c | 20 +-- drivers/media/pci/sta2x11/sta2x11_vip.c | 9 - drivers/misc/vmw_vmci/vmci_datagram.c | 6 - drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c | 9 - drivers/net/ethernet/broadcom/bnx2x/bnx2x_ethtool.c | 2 drivers/net/ethernet/broadcom/bnx2x/bnx2x_link.c | 14 +- drivers/net/ethernet/intel/ice/ice_virtchnl.c | 9 - drivers/net/ethernet/intel/ice/ice_virtchnl.h | 9 + drivers/net/ethernet/pensando/ionic/ionic_lif.c | 5 drivers/net/pcs/pcs-xpcs.c | 4 drivers/net/wireless/ath/ath11k/mhi.c | 2 drivers/net/wireless/ath/ath9k/antenna.c | 2 drivers/net/wireless/broadcom/brcm80211/brcmfmac/dmi.c | 9 + drivers/net/wireless/intel/iwlwifi/pcie/drv.c | 1 drivers/net/wireless/realtek/rtw89/pci.h | 2 drivers/nvme/host/pci.c | 3 drivers/pinctrl/renesas/core.c | 4 drivers/platform/x86/intel/vbtn.c | 5 drivers/platform/x86/touchscreen_dmi.c | 9 + drivers/scsi/lpfc/lpfc_nportdisc.c | 6 - drivers/scsi/scsi_lib.c | 52 +++++----- drivers/scsi/sd.c | 4 drivers/soundwire/dmi-quirks.c | 8 + drivers/thermal/thermal_of.c | 12 +- drivers/thunderbolt/quirks.c | 14 ++ drivers/thunderbolt/tb.c | 49 +++++++++ drivers/thunderbolt/tb.h | 4 drivers/tty/n_gsm.c | 3 drivers/usb/gadget/function/uvc_video.c | 3 drivers/usb/host/sl811-hcd.c | 2 drivers/usb/typec/tcpm/tcpci.c | 1 drivers/video/fbdev/core/fbmon.c | 7 - drivers/video/fbdev/via/accel.c | 4 drivers/virtio/virtio.c | 10 + fs/btrfs/export.c | 9 + fs/btrfs/send.c | 10 + fs/btrfs/volumes.c | 12 ++ fs/ext4/mballoc.c | 5 fs/ext4/super.c | 12 ++ fs/isofs/inode.c | 18 +++ fs/orangefs/super.c | 2 fs/pstore/zone.c | 2 fs/sysv/itree.c | 10 - include/linux/randomize_kstack.h | 2 include/linux/rcupdate.h | 4 include/linux/skbuff.h | 11 ++ include/linux/sunrpc/sched.h | 2 include/scsi/scsi_device.h | 51 ++------- include/uapi/linux/input-event-codes.h | 1 io_uring/io_uring.c | 25 +++- kernel/dma/direct.c | 9 - kernel/panic.c | 8 + kernel/trace/ring_buffer.c | 2 net/mpls/mpls_gso.c | 3 net/netfilter/nf_tables_api.c | 47 ++++++--- net/smc/smc_pnet.c | 10 + scripts/gcc-plugins/stackleak_plugin.c | 2 sound/firewire/amdtp-stream.c | 12 +- sound/firewire/amdtp-stream.h | 4 sound/soc/intel/boards/sof_sdw.c | 11 ++ sound/soc/soc-core.c | 3 tools/iio/iio_utils.c | 2 tools/lib/perf/evlist.c | 18 ++- tools/lib/perf/include/internal/evlist.h | 4 tools/power/x86/x86_energy_perf_policy/x86_energy_perf_policy.c | 1 tools/testing/ktest/ktest.pl | 1 87 files changed, 544 insertions(+), 224 deletions(-)
Alban Boyé (1):
platform/x86: touchscreen_dmi: Add an extra entry for a variant of the Chuwi Vi8 tablet
Aleksandr Burakov (1):
fbdev: viafb: fix typo in hw_bitblt_1 and hw_bitblt_2
Alex Henrie (1):
isofs: handle CDs with bad root inode but good Joliet root directory
Ard Biesheuvel (1):
gcc-plugins/stackleak: Avoid .head.text section
Aric Cyr (1):
drm/amd/display: Fix nanosec stat overflow
Arnd Bergmann (1):
media: sta2x11: fix irq handler cast
Baochen Qiang (1):
wifi: ath11k: decrease MHI channel buffer length to 8KB
C Cheng (1):
cpuidle: Avoid potential overflow in integer multiplication
Chancel Liu (1):
ASoC: soc-core.c: Skip dummy codec when adding platforms
Colin Ian King (1):
usb: sl811-hcd: only defined function checkdone if QUIRK2 is defined
Dai Ngo (1):
SUNRPC: increase size of rpc_wait_queue.qlen from unsigned short to unsigned int
Daniel Drake (1):
Revert "ACPI: PM: Block ASUS B1400CEAE from suspend to idle by default"
Dave Airlie (1):
amdkfd: use calloc instead of kzalloc to avoid integer overflow
David Hildenbrand (1):
virtio: reenable config if freezing device failed
David Sterba (3):
btrfs: handle chunk tree lookup error in btrfs_relocate_sys_chunks()
btrfs: export: handle invalid inode or root reference in btrfs_get_parent()
btrfs: send: handle path ref underflow in header iterate_inode_ref()
Dmitry Antipov (1):
wifi: ath9k: fix LNA selection in ath_ant_try_scan()
Duje Mihanović (1):
Input: imagis - use FIELD_GET where applicable
Edward Adam Davis (1):
Bluetooth: btintel: Fix null ptr deref in btintel_read_version
Eric Dumazet (1):
net/smc: reduce rtnl pressure in smc_pnet_create_pnetids_list()
Florian Westphal (2):
net: skbuff: add overflow debug check to pull/push helpers
net: mpls: error out if inner headers are not set
Geert Uytterhoeven (1):
pinctrl: renesas: checker: Limit cfg reg enum checks to provided IDs
Gergo Koteles (1):
Input: allocate keycode for Display refresh rate toggle
Greg Kroah-Hartman (3):
Revert "scsi: sd: usb_storage: uas: Access media prior to querying device properties" Revert "scsi: core: Add struct for args to execution functions"
Linux 6.1.86
Gwendal Grignou (1):
platform/x86: intel-vbtn: Update tablet mode switch at end of probe
Hans de Goede (1):
wifi: brcmfmac: Add DMI nvram filename quirk for ACEPC W5 Pro
Harshit Mogalapalli (1):
VMCI: Fix memcpy() run-time warning in dg_dispatch_as_host()
Ian Rogers (1):
libperf evlist: Avoid out-of-bounds access
Jacob Keller (1):
ice: use relative VSI index for VFs instead of PF VSI number
Jeffrey Hugo (1):
bus: mhi: host: Add MHI_PM_SYS_ERR_FAIL state
Jens Axboe (1):
io_uring: clear opcode specific data for an early failure
Jiawei Fu (iBug) (1):
drivers/nvme: Add quirks for device 126f:2262
Johan Jonker (2):
arm64: dts: rockchip: fix rk3328 hdmi ports node
arm64: dts: rockchip: fix rk3399 hdmi ports node
John Ogness (1):
panic: Flush kernel log buffer at the end
Justin Tee (1):
scsi: lpfc: Fix possible memory leak in lpfc_rcv_padisc()
Kees Cook (2):
bnx2x: Fix firmware version string character counts
randomize_kstack: Improve entropy diffusion
Konrad Dybcio (1):
thermal/of: Assume polling-delay(-passive) 0 when absent
Kunwu Chan (2):
pstore/zone: Add a null pointer check to the psz_kmsg_read
Input: synaptics-rmi4 - fail probing if memory allocation for "phys" fails
Luiz Augusto von Dentz (1):
Bluetooth: btintel: Fixe build regression
Ma Jun (1):
Revert "drm/amd/amdgpu: Fix potential ioremap() memory leaks in amdgpu_device_init()"
Manjunath Patil (1):
RDMA/cm: add timeout to cm_destroy_id wait
Marco Felsch (1):
usb: typec: tcpci: add generic tcpci fallback compatible
Markus Elfring (1):
firmware: tegra: bpmp: Return directly after a failed kzalloc() in get_filename()
Markuss Broks (1):
input/touchscreen: imagis: Correct the maximum touch area value
Martin K. Petersen (1):
scsi: sd: usb_storage: uas: Access media prior to querying device properties
Maíra Canal (1):
drm/vc4: don't check if plane->state->fb == state->fb
Michael Grzeschik (1):
usb: gadget: uvc: mark incomplete frames with UVC_STREAM_ERR
Mika Westerberg (1):
thunderbolt: Keep the domain powered when USB4 port is in redrive mode
Mike Marshall (1):
Julia Lawall reported this null pointer dereference, this should fix it.
Mukesh Sisodiya (1):
wifi: iwlwifi: pcie: Add the PCI device id for new hardware
Pablo Neira Ayuso (3):
netfilter: nf_tables: release batch on table validation from abort path
netfilter: nf_tables: release mutex after nft_gc_seq_end from abort path
netfilter: nf_tables: discard table flag update with pending basechain deletion
Paul E. McKenney (1):
rcu-tasks: Repair RCU Tasks Trace quiescence check
Petre Rodan (1):
tools: iio: replace seekdir() in iio_generic_buffer
Ping-Ke Shih (1):
wifi: rtw89: pci: enlarge RX DMA buffer to consider size of RX descriptor
Ricardo B. Marliere (1):
ktest: force $buildonly = 1 for 'make_warnings_file' test type
Rick Edgecombe (1):
dma-direct: Leak pages on dma_set_decrypted() failure
Roman Smirnov (2):
block: prevent division by zero in blk_rq_stat_sum()
fbmon: prevent division by zero in fb_videomode_from_videomode()
Samasth Norway Ananda (1):
tools/power x86_energy_perf_policy: Fix file leak in get_pkg_num()
Samuel Dionne-Riel (1):
drm: panel-orientation-quirks: Add quirk for GPD Win Mini
Sandipan Das (1):
perf/x86/amd/lbr: Discard erroneous branch entries
Serge Semin (1):
net: pcs: xpcs: Return EINVAL in the internal methods
Shannon Nelson (1):
ionic: set adminq irq affinity
Srinivasan Shanmugam (1):
drm/amd/amdgpu: Fix potential ioremap() memory leaks in amdgpu_device_init()
Takashi Iwai (1):
Bluetooth: btmtk: Add MODULE_FIRMWARE() for MT7922
Takashi Sakamoto (1):
ALSA: firewire-lib: handle quirk to calculate payload quadlets as data block counter
Tetsuo Handa (1):
sysv: don't call sb_bread() with pointers_lock held
Thadeu Lima de Souza Cascardo (1):
tty: n_gsm: require CAP_NET_ADMIN to attach N_GSM0710 ldisc
Vasiliy Kovalev (1):
VMCI: Fix possible memcpy() run-time warning in vmci_datagram_invoke_guest_handler()
Viresh Kumar (1):
cpufreq: Don't unregister cpufreq cooling on CPU hotplug
Ye Bin (1):
ext4: forbid commit inconsistent quota data when errors=remount-ro
Zhang Yi (1):
ext4: add a hint for block bitmap corrupt state in mb_groups
linke li (1):
ring-buffer: use READ_ONCE() to read cpu_buffer->commit_page in concurrent environment
mosomate (1):
ASoC: Intel: common: DMI remap for rebranded Intel NUC M15 (LAPRC710) laptops
Greg Kroah-Hartman
maintainerMakefile +1 -1
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 VERSION = 6 PATCHLEVEL = 1 -SUBLEVEL = 85 +SUBLEVEL = 86 EXTRAVERSION = NAME = Curry Ramen
arch/arm64/boot/dts/rockchip/rk3328.dtsi +10 -1
@@ -741,11 +741,20 @@ hdmi: hdmi@ff3c0000 { status = "disabled"; ports { - hdmi_in: port { + #address-cells = <1>; + #size-cells = <0>; + + hdmi_in: port@0 { + reg = <0>; + hdmi_in_vop: endpoint { remote-endpoint = <&vop_out_hdmi>; }; }; + + hdmi_out: port@1 { + reg = <1>; + }; }; };
arch/arm64/boot/dts/rockchip/rk3399.dtsi +10 -2
@@ -1906,6 +1906,7 @@ simple-audio-card,codec { hdmi: hdmi@ff940000 { compatible = "rockchip,rk3399-dw-hdmi"; reg = <0x0 0xff940000 0x0 0x20000>; + reg-io-width = <4>; interrupts = <GIC_SPI 23 IRQ_TYPE_LEVEL_HIGH 0>; clocks = <&cru PCLK_HDMI_CTRL>, <&cru SCLK_HDMI_SFR>,
@@ -1914,13 +1915,16 @@ hdmi: hdmi@ff940000 { <&cru PLL_VPLL>; clock-names = "iahb", "isfr", "cec", "grf", "ref"; power-domains = <&power RK3399_PD_HDCP>; - reg-io-width = <4>; rockchip,grf = <&grf>; #sound-dai-cells = <0>; status = "disabled"; ports { - hdmi_in: port { + #address-cells = <1>; + #size-cells = <0>; + + hdmi_in: port@0 { + reg = <0>; #address-cells = <1>; #size-cells = <0>;
@@ -1933,6 +1937,10 @@ hdmi_in_vopl: endpoint@1 { remote-endpoint = <&vopl_out_hdmi>; }; }; + + hdmi_out: port@1 { + reg = <1>; + }; }; };
arch/x86/events/amd/lbr.c +4 -2
@@ -173,9 +173,11 @@ void amd_pmu_lbr_read(void)/* * Check if a branch has been logged; if valid = 0, spec = 0 -* then no branch was recorded +* then no branch was recorded; if reserved = 1 then an +* erroneous branch was recorded (see Erratum 1452) */ -if (!entry.to.split.valid && !entry.to.split.spec) +if ((!entry.to.split.valid && !entry.to.split.spec) || + entry.to.split.reserved)continue ;perf_clear_branch_entry_bitfields (br + out);
block/blk-stat.c +1 -1
@@ -28,7 +28,7 @@ void blk_rq_stat_init(struct blk_rq_stat *stat)/* src is a per-cpu stat, mean isn't initialized */ void blk_rq_stat_sum (struct blk_rq_stat *dst,struct blk_rq_stat *src) { -if (!src->nr_samples) +if (dst->nr_samples + src->nr_samples <= dst->nr_samples)return ; dst->min =min (dst->min, src->min);
drivers/acpi/sleep.c +0 -12
@@ -385,18 +385,6 @@ static const struct dmi_system_id acpisleep_dmi_table[] __initconst = { DMI_MATCH(DMI_PRODUCT_NAME, "20GGA00L00"), }, }, -/* -* ASUS B1400CEAE hangs on resume from suspend (see -* https://bugzilla.kernel.org/show_bug.cgi?id=215742). -*/ - { - .callback = init_default_s3, - .ident = "ASUS B1400CEAE", - .matches = { - DMI_MATCH(DMI_SYS_VENDOR, "ASUSTeK COMPUTER INC."), - DMI_MATCH(DMI_PRODUCT_NAME, "ASUS EXPERTBOOK B1400CEAE"), - }, - }, {}, };
drivers/bluetooth/btintel.c +1 -1
@@ -411,7 +411,7 @@ int btintel_read_version(struct hci_dev *hdev, struct intel_version *ver)return PTR_ERR (skb); } -if (skb->len !=sizeof (*ver)) { +if (!skb || skb->len !=sizeof (*ver)) {bt_dev_err (hdev,"Intel version event size mismatch" );kfree_skb (skb);return -EILSEQ ;
drivers/bluetooth/btmtk.c +1 -0
@@ -288,4 +288,5 @@ MODULE_LICENSE("GPL");MODULE_FIRMWARE (FIRMWARE_MT7622 );MODULE_FIRMWARE (FIRMWARE_MT7663 );MODULE_FIRMWARE (FIRMWARE_MT7668 ); +MODULE_FIRMWARE (FIRMWARE_MT7922 );MODULE_FIRMWARE (FIRMWARE_MT7961 );
drivers/bluetooth/btmtk.h +1 -0
@@ -4,6 +4,7 @@#define FIRMWARE_MT7622 "mediatek/mt7622pr2h.bin"#define FIRMWARE_MT7663 "mediatek/mt7663pr2h.bin"#define FIRMWARE_MT7668 "mediatek/mt7668pr2h.bin" +#define FIRMWARE_MT7922 "mediatek/BT_RAM_CODE_MT7922_1_1_hdr.bin"#define FIRMWARE_MT7961 "mediatek/BT_RAM_CODE_MT7961_1_2_hdr.bin"#define HCI_EV_WMT 0xe4
drivers/bus/mhi/host/init.c +1 -0
@@ -62,6 +62,7 @@ static const char * const mhi_pm_state_str[] = { [MHI_PM_STATE_FW_DL_ERR] = "Firmware Download Error", [MHI_PM_STATE_SYS_ERR_DETECT] = "SYS ERROR Detect", [MHI_PM_STATE_SYS_ERR_PROCESS] = "SYS ERROR Process", + [MHI_PM_STATE_SYS_ERR_FAIL] = "SYS ERROR Failure", [MHI_PM_STATE_SHUTDOWN_PROCESS] = "SHUTDOWN Process", [MHI_PM_STATE_LD_ERR_FATAL_DETECT] = "Linkdown or Error Fatal Detect", };
drivers/bus/mhi/host/internal.h +6 -3
@@ -88,6 +88,7 @@ enum mhi_pm_state {MHI_PM_STATE_FW_DL_ERR ,MHI_PM_STATE_SYS_ERR_DETECT ,MHI_PM_STATE_SYS_ERR_PROCESS , +MHI_PM_STATE_SYS_ERR_FAIL ,MHI_PM_STATE_SHUTDOWN_PROCESS ,MHI_PM_STATE_LD_ERR_FATAL_DETECT ,MHI_PM_STATE_MAX
@@ -104,14 +105,16 @@ enum mhi_pm_state {#define MHI_PM_FW_DL_ERR BIT(7)#define MHI_PM_SYS_ERR_DETECT BIT(8)#define MHI_PM_SYS_ERR_PROCESS BIT(9) -#define MHI_PM_SHUTDOWN_PROCESS BIT(10) +#define MHI_PM_SYS_ERR_FAIL BIT(10) +#define MHI_PM_SHUTDOWN_PROCESS BIT(11)/* link not accessible */ -#define MHI_PM_LD_ERR_FATAL_DETECT BIT(11) +#define MHI_PM_LD_ERR_FATAL_DETECT BIT(12)#define MHI_REG_ACCESS_VALID (pm_state) ((pm_state & (MHI_PM_POR | MHI_PM_M0 | \ MHI_PM_M2 | MHI_PM_M3_ENTER | MHI_PM_M3_EXIT | \ MHI_PM_SYS_ERR_DETECT | MHI_PM_SYS_ERR_PROCESS | \ - MHI_PM_SHUTDOWN_PROCESS | MHI_PM_FW_DL_ERR))) + MHI_PM_SYS_ERR_FAIL | MHI_PM_SHUTDOWN_PROCESS | \ + MHI_PM_FW_DL_ERR)))#define MHI_PM_IN_ERROR_STATE (pm_state) (pm_state >= MHI_PM_FW_DL_ERR)#define MHI_PM_IN_FATAL_STATE (pm_state) (pm_state == MHI_PM_LD_ERR_FATAL_DETECT)#define MHI_DB_ACCESS_VALID (mhi_cntrl) (mhi_cntrl->pm_state & mhi_cntrl->db_access)
drivers/bus/mhi/host/pm.c +17 -3
@@ -36,7 +36,10 @@* M0 <--> M0 * M0 -> FW_DL_ERR * M0 -> M3_ENTER -> M3 -> M3_EXIT --> M0 -* L1: SYS_ERR_DETECT -> SYS_ERR_PROCESS --> POR +* L1: SYS_ERR_DETECT -> SYS_ERR_PROCESS +* SYS_ERR_PROCESS -> SYS_ERR_FAIL +* SYS_ERR_FAIL -> SYS_ERR_DETECT +* SYS_ERR_PROCESS --> POR * L2: SHUTDOWN_PROCESS -> LD_ERR_FATAL_DETECT * SHUTDOWN_PROCESS -> DISABLE * L3: LD_ERR_FATAL_DETECT <--> LD_ERR_FATAL_DETECT
@@ -93,7 +96,12 @@ static const struct mhi_pm_transitions dev_state_transitions[] = { }, {MHI_PM_SYS_ERR_PROCESS , -MHI_PM_POR |MHI_PM_SHUTDOWN_PROCESS | +MHI_PM_POR |MHI_PM_SYS_ERR_FAIL |MHI_PM_SHUTDOWN_PROCESS | +MHI_PM_LD_ERR_FATAL_DETECT + }, + { +MHI_PM_SYS_ERR_FAIL , +MHI_PM_SYS_ERR_DETECT |MHI_PM_SHUTDOWN_PROCESS |MHI_PM_LD_ERR_FATAL_DETECT },/* L2 States */
@@ -624,7 +632,13 @@ static void mhi_pm_sys_error_transition(struct mhi_controller *mhi_cntrl) !in_reset, timeout);if (!ret || in_reset) {dev_err (dev,"Device failed to exit MHI Reset state\n" ); - goto exit_sys_error_transition; +write_lock_irq (&mhi_cntrl->pm_lock); + cur_state =mhi_tryset_pm_state (mhi_cntrl, +MHI_PM_SYS_ERR_FAIL ); +write_unlock_irq (&mhi_cntrl->pm_lock); +/* Shutdown may have occurred, otherwise cleanup now */ +if (cur_state !=MHI_PM_SYS_ERR_FAIL ) + goto exit_sys_error_transition; }/*
drivers/cpufreq/cpufreq.c +11 -6
@@ -1525,7 +1525,8 @@ static int cpufreq_online(unsigned int cpu)if (cpufreq_driver->ready) cpufreq_driver->ready (policy); -if (cpufreq_thermal_control_enabled (cpufreq_driver)) +/* Register cpufreq cooling only for a new policy */ +if (new_policy &&cpufreq_thermal_control_enabled (cpufreq_driver)) policy->cdev =of_cpufreq_cooling_register (policy);pr_debug ("initialization complete\n" );
@@ -1609,11 +1610,6 @@ static void __cpufreq_offline(unsigned int cpu, struct cpufreq_policy *policy)else policy->last_policy = policy->policy; -if (cpufreq_thermal_control_enabled (cpufreq_driver)) { -cpufreq_cooling_unregister (policy->cdev); - policy->cdev =NULL ; - } -if (has_target ())cpufreq_exit_governor (policy);
@@ -1674,6 +1670,15 @@ static void cpufreq_remove_dev(struct device *dev, struct subsys_interface *sif)return ; } +/* +* Unregister cpufreq cooling once all the CPUs of the policy are +* removed. +*/ +if (cpufreq_thermal_control_enabled (cpufreq_driver)) { +cpufreq_cooling_unregister (policy->cdev); + policy->cdev =NULL ; + } +/* We did light-weight exit earlier, do full tear down now */ if (cpufreq_driver->offline) cpufreq_driver->exit (policy);
drivers/cpuidle/driver.c +2 -1
@@ -16,6 +16,7 @@#include <linux/cpumask.h> #include <linux/tick.h> #include <linux/cpu.h> +#include <linux/math64.h> #include "cpuidle.h"
@@ -185,7 +186,7 @@ static void __cpuidle_driver_init(struct cpuidle_driver *drv) s->target_residency_ns =0 ;if (s->exit_latency >0 ) - s->exit_latency_ns = s->exit_latency *NSEC_PER_USEC ; + s->exit_latency_ns =mul_u32_u32 (s->exit_latency,NSEC_PER_USEC );else if (s->exit_latency_ns <0 ) s->exit_latency_ns =0 ; }
drivers/firmware/tegra/bpmp-debugfs.c +1 -1
@@ -81,7 +81,7 @@ static const char *get_filename(struct tegra_bpmp *bpmp, root_path_buf =kzalloc (root_path_buf_len,GFP_KERNEL );if (!root_path_buf) - goto out; +return NULL ; root_path =dentry_path (bpmp->debugfs_mirror, root_path_buf, root_path_buf_len);
drivers/gpu/drm/amd/amdkfd/kfd_chardev.c +2 -2
@@ -765,8 +765,8 @@ static int kfd_ioctl_get_process_apertures_new(struct file *filp,* nodes, but not more than args->num_of_nodes as that is * the amount of memory allocated by user */ - pa =kzalloc ((sizeof (struct kfd_process_device_apertures ) * - args->num_of_nodes),GFP_KERNEL ); + pa =kcalloc (args->num_of_nodes,sizeof (struct kfd_process_device_apertures ), +GFP_KERNEL );if (!pa)return -ENOMEM ;
drivers/gpu/drm/amd/display/modules/inc/mod_stats.h +2 -2
@@ -57,10 +57,10 @@ void mod_stats_update_event(struct mod_stats *mod_stats, unsigned int length);void mod_stats_update_flip (struct mod_stats *mod_stats, -unsigned long timestamp_in_ns); +unsigned long long timestamp_in_ns);void mod_stats_update_vupdate (struct mod_stats *mod_stats, -unsigned long timestamp_in_ns); +unsigned long long timestamp_in_ns); void mod_stats_update_freesync(struct mod_stats *mod_stats, unsigned int v_total_min,
drivers/gpu/drm/drm_panel_orientation_quirks.c +12 -0
@@ -117,6 +117,12 @@ static const struct drm_dmi_panel_orientation_data lcd1080x1920_leftside_up = { .orientation = DRM_MODE_PANEL_ORIENTATION_LEFT_UP, }; +static const struct drm_dmi_panel_orientation_data lcd1080x1920_rightside_up = { + .width =1080 , + .height =1920 , + .orientation =DRM_MODE_PANEL_ORIENTATION_RIGHT_UP , +}; +static const struct drm_dmi_panel_orientation_data lcd1200x1920_rightside_up = { .width =1200 , .height =1920 ,
@@ -279,6 +285,12 @@ static const struct dmi_system_id orientation_data[] = {DMI_EXACT_MATCH (DMI_PRODUCT_NAME ,"G1618-03" ) }, .driver_data = (void *)&lcd720x1280_rightside_up, + }, { /* GPD Win Mini */ + .matches = { +DMI_EXACT_MATCH (DMI_SYS_VENDOR ,"GPD" ), +DMI_EXACT_MATCH (DMI_PRODUCT_NAME ,"G1617-01" ) + }, + .driver_data = (void *)&lcd1080x1920_rightside_up, }, { /* I.T.Works TW891 */ .matches = { DMI_EXACT_MATCH(DMI_SYS_VENDOR, "To be filled by O.E.M."),
drivers/gpu/drm/vc4/vc4_plane.c +1 -4
@@ -1415,9 +1415,6 @@ static int vc4_prepare_fb(struct drm_plane *plane,drm_gem_plane_helper_prepare_fb (plane, state); -if (plane->state->fb == state->fb) -return 0 ; -return vc4_bo_inc_usecnt (bo); }
@@ -1426,7 +1423,7 @@ static void vc4_cleanup_fb(struct drm_plane *plane, {struct vc4_bo *bo; -if (plane->state->fb == state->fb || !state->fb) +if (!state->fb)return ; bo =to_vc4_bo (&drm_fb_dma_get_gem_obj (state->fb,0 )->base);
drivers/infiniband/core/cm.c +19 -1
@@ -34,6 +34,7 @@ MODULE_AUTHOR("Sean Hefty");MODULE_DESCRIPTION ("InfiniBand CM" );MODULE_LICENSE ("Dual BSD/GPL" ); +#define CM_DESTROY_ID_WAIT_TIMEOUT 10000/* msecs */ static const char *const ibcm_rej_reason_strs[] = { [IB_CM_REJ_NO_QP ] ="no QP" , [IB_CM_REJ_NO_EEC ] ="no EEC" ,
@@ -1025,10 +1026,20 @@ static void cm_reset_to_idle(struct cm_id_private *cm_id_priv) } } +static noinline void cm_destroy_id_wait_timeout(struct ib_cm_id *cm_id) +{ +struct cm_id_private *cm_id_priv; + + cm_id_priv = container_of(cm_id, struct cm_id_private, id); +pr_err ("%s: cm_id=%p timed out. state=%d refcnt=%d\n" , __func__, + cm_id, cm_id->state,refcount_read (&cm_id_priv->refcount)); +} +static void cm_destroy_id (struct ib_cm_id *cm_id,int err) {struct cm_id_private *cm_id_priv;struct cm_work *work; +int ret; cm_id_priv = container_of(cm_id, struct cm_id_private, id);spin_lock_irq (&cm_id_priv->lock);
@@ -1135,7 +1146,14 @@ static void cm_destroy_id(struct ib_cm_id *cm_id, int err)xa_erase (&cm.local_id_table,cm_local_id (cm_id->local_id));cm_deref_id (cm_id_priv); -wait_for_completion (&cm_id_priv->comp); +do { + ret =wait_for_completion_timeout (&cm_id_priv->comp, +msecs_to_jiffies ( +CM_DESTROY_ID_WAIT_TIMEOUT )); +if (!ret)/* timeout happened */ +cm_destroy_id_wait_timeout (cm_id); + }while (!ret); +while ((work =cm_dequeue_work (cm_id_priv)) !=NULL )cm_free_work (work);
drivers/input/rmi4/rmi_driver.c +5 -1
@@ -1196,7 +1196,11 @@ static int rmi_driver_probe(struct device *dev) }rmi_driver_set_input_params (rmi_dev, data->input); data->input->phys =devm_kasprintf (dev,GFP_KERNEL , -"%s/input0" ,dev_name (dev)); +"%s/input0" ,dev_name (dev)); +if (!data->input->phys) { + retval = -ENOMEM ; + goto err; + } } retval =rmi_init_functions (data);
drivers/input/touchscreen/imagis.c +8 -12
@@ -1,5 +1,6 @@// SPDX-License-Identifier: GPL-2.0-only +#include <linux/bitfield.h> #include <linux/bits.h> #include <linux/delay.h> #include <linux/i2c.h>
@@ -23,12 +24,9 @@#define IST3038C_I2C_RETRY_COUNT 3#define IST3038C_MAX_FINGER_NUM 10#define IST3038C_X_MASK GENMASK(23, 12) -#define IST3038C_X_SHIFT 12#define IST3038C_Y_MASK GENMASK(11, 0)#define IST3038C_AREA_MASK GENMASK(27, 24) -#define IST3038C_AREA_SHIFT 24#define IST3038C_FINGER_COUNT_MASK GENMASK(15, 12) -#define IST3038C_FINGER_COUNT_SHIFT 12#define IST3038C_FINGER_STATUS_MASK GENMASK(9, 0)struct imagis_ts {
@@ -92,8 +90,7 @@ static irqreturn_t imagis_interrupt(int irq, void *dev_id) goto out; } - finger_count = (intr_message &IST3038C_FINGER_COUNT_MASK ) >> -IST3038C_FINGER_COUNT_SHIFT ; + finger_count =FIELD_GET (IST3038C_FINGER_COUNT_MASK , intr_message);if (finger_count >IST3038C_MAX_FINGER_NUM ) { dev_err(&ts->client->dev, "finger count %d is more than maximum supported\n",
@@ -101,7 +98,7 @@ static irqreturn_t imagis_interrupt(int irq, void *dev_id) goto out; } - finger_pressed = intr_message &IST3038C_FINGER_STATUS_MASK ; + finger_pressed =FIELD_GET (IST3038C_FINGER_STATUS_MASK , intr_message);for (i =0 ; i < finger_count; i++) { error = imagis_i2c_read_reg(ts,
@@ -118,12 +115,11 @@ static irqreturn_t imagis_interrupt(int irq, void *dev_id)input_mt_report_slot_state (ts->input_dev,MT_TOOL_FINGER , finger_pressed &BIT (i));touchscreen_report_pos (ts->input_dev, &ts->prop, - (finger_status &IST3038C_X_MASK ) >> -IST3038C_X_SHIFT , - finger_status &IST3038C_Y_MASK ,1 ); +FIELD_GET (IST3038C_X_MASK , finger_status), +FIELD_GET (IST3038C_Y_MASK , finger_status), + true);input_report_abs (ts->input_dev,ABS_MT_TOUCH_MAJOR , - (finger_status &IST3038C_AREA_MASK ) >> -IST3038C_AREA_SHIFT ); +FIELD_GET (IST3038C_AREA_MASK , finger_status)); }input_mt_sync_frame (ts->input_dev);
@@ -210,7 +206,7 @@ static int imagis_init_input_dev(struct imagis_ts *ts)input_set_capability (input_dev,EV_ABS ,ABS_MT_POSITION_X );input_set_capability (input_dev,EV_ABS ,ABS_MT_POSITION_Y ); -input_set_abs_params (input_dev,ABS_MT_TOUCH_MAJOR ,0 ,255 ,0 ,0 ); +input_set_abs_params (input_dev,ABS_MT_TOUCH_MAJOR ,0 ,16 ,0 ,0 );touchscreen_parse_properties (input_dev, true, &ts->prop);if (!ts->prop.max_x || !ts->prop.max_y) {
drivers/media/pci/sta2x11/sta2x11_vip.c +4 -5
@@ -756,7 +756,7 @@ static const struct video_device video_dev_template = {/** * vip_irq - interrupt routine * @irq: Number of interrupt ( not used, correct number is assumed ) -* @vip: local data structure containing all information +* @data: local data structure containing all information * * check for both frame interrupts set ( top and bottom ). * check FIFO overflow, but limit number of log messages after open.
@@ -766,8 +766,9 @@ static const struct video_device video_dev_template = {* * IRQ_HANDLED, interrupt done. */ -static irqreturn_t vip_irq (int irq,struct sta2x11_vip *vip) +static irqreturn_t vip_irq (int irq,void *data) { +struct sta2x11_vip *vip = data;unsigned int status; status =reg_read (vip,DVP_ITS );
@@ -1049,9 +1050,7 @@ static int sta2x11_vip_init_one(struct pci_dev *pdev,spin_lock_init (&vip->slock); - ret =request_irq (pdev->irq, - (irq_handler_t ) vip_irq, -IRQF_SHARED ,KBUILD_MODNAME , vip); + ret =request_irq (pdev->irq, vip_irq,IRQF_SHARED ,KBUILD_MODNAME , vip);if (ret) {dev_err (&pdev->dev,"request_irq failed\n" ); ret = -ENODEV ;
drivers/misc/vmw_vmci/vmci_datagram.c +4 -2
@@ -234,7 +234,8 @@ static int dg_dispatch_as_host(u32 context_id, struct vmci_datagram *dg) dg_info->in_dg_host_queue = true; dg_info->entry = dst_entry; -memcpy (&dg_info->msg, dg, dg_size); + dg_info->msg = *dg; +memcpy (&dg_info->msg_payload, dg +1 , dg->payload_size);INIT_WORK (&dg_info->work, dg_delayed_dispatch);schedule_work (&dg_info->work);
@@ -377,7 +378,8 @@ int vmci_datagram_invoke_guest_handler(struct vmci_datagram *dg) dg_info->in_dg_host_queue = false; dg_info->entry = dst_entry; -memcpy (&dg_info->msg, dg,VMCI_DG_SIZE (dg)); + dg_info->msg = *dg; +memcpy (&dg_info->msg_payload, dg +1 , dg->payload_size);INIT_WORK (&dg_info->work, dg_delayed_dispatch);schedule_work (&dg_info->work);
drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c +5 -4
@@ -147,10 +147,11 @@ void bnx2x_fill_fw_str(struct bnx2x *bp, char *buf, size_t buf_len) phy_fw_ver[0 ] ='\0' ;bnx2x_get_ext_phy_fw_version (&bp->link_params, - phy_fw_ver,PHY_FW_VER_LEN ); -strscpy (buf, bp->fw_ver, buf_len); - snprintf(buf + strlen(bp->fw_ver), 32 - strlen(bp->fw_ver), - "bc %d.%d.%d%s%s", + phy_fw_ver,sizeof (phy_fw_ver)); +/* This may become truncated. */ + scnprintf(buf, buf_len, + "%sbc %d.%d.%d%s%s", + bp->fw_ver, (bp->common.bc_ver & 0xff0000) >> 16, (bp->common.bc_ver & 0xff00) >> 8, (bp->common.bc_ver & 0xff),
drivers/net/ethernet/broadcom/bnx2x/bnx2x_ethtool.c +1 -1
@@ -1132,7 +1132,7 @@ static void bnx2x_get_drvinfo(struct net_device *dev, }memset (version,0 ,sizeof (version)); -bnx2x_fill_fw_str (bp, version,ETHTOOL_FWVERS_LEN ); +bnx2x_fill_fw_str (bp, version,sizeof (version));strlcat (info->fw_version, version,sizeof (info->fw_version));strscpy (info->bus_info,pci_name (bp->pdev),sizeof (info->bus_info));
drivers/net/ethernet/broadcom/bnx2x/bnx2x_link.c +7 -7
@@ -6163,8 +6163,8 @@ static void bnx2x_link_int_ack(struct link_params *params,static int bnx2x_null_format_ver (u32 spirom_ver,u8 *str,u16 *len) { - str[0 ] ='\0' ; - (*len)--; +if (*len) + str[0 ] ='\0' ;return 0 ; }
@@ -6173,7 +6173,7 @@ static int bnx2x_format_ver(u32 num, u8 *str, u16 *len)u16 ret;if (*len <10 ) { -/* Need more than 10chars for this format */ +/* Need more than 10 chars for this format */ bnx2x_null_format_ver (num, str, len);return -EINVAL ; }
@@ -6188,8 +6188,8 @@ static int bnx2x_3_seq_format_ver(u32 num, u8 *str, u16 *len) {u16 ret; -if (*len <10 ) { -/* Need more than 10chars for this format */ +if (*len <9 ) { +/* Need more than 9 chars for this format */ bnx2x_null_format_ver (num, str, len);return -EINVAL ; }
@@ -6208,7 +6208,7 @@ int bnx2x_get_ext_phy_fw_version(struct link_params *params, u8 *version,int status =0 ;u8 *ver_p = version;u16 remain_len = len; -if (version ==NULL || params ==NULL ) +if (version ==NULL || params ==NULL || len ==0 )return -EINVAL ; bp = params->bp;
@@ -11546,7 +11546,7 @@ static int bnx2x_7101_format_ver(u32 spirom_ver, u8 *str, u16 *len) str[2 ] = (spirom_ver &0xFF0000 ) >>16 ; str[3 ] = (spirom_ver &0xFF000000 ) >>24 ; str[4 ] ='\0' ; - *len -=5 ; + *len -=4 ;return 0 ; }
drivers/net/ethernet/intel/ice/ice_virtchnl.c +2 -7
@@ -493,7 +493,7 @@ static int ice_vc_get_vf_res_msg(struct ice_vf *vf, u8 *msg) vfres->rss_lut_size =ICE_VSIQF_HLUT_ARRAY_SIZE ; vfres->max_mtu =ice_vc_get_max_frame_size (vf); - vfres->vsi_res[0 ].vsi_id = vf->lan_vsi_num; + vfres->vsi_res[0 ].vsi_id =ICE_VF_VSI_ID ; vfres->vsi_res[0 ].vsi_type =VIRTCHNL_VSI_SRIOV ; vfres->vsi_res[0 ].num_queue_pairs = vsi->num_txq; ether_addr_copy(vfres->vsi_res[0].default_mac_addr,
@@ -539,12 +539,7 @@ static void ice_vc_reset_vf_msg(struct ice_vf *vf)*/ bool ice_vc_isvalid_vsi_id (struct ice_vf *vf,u16 vsi_id) { -struct ice_pf *pf = vf->pf; -struct ice_vsi *vsi; - - vsi =ice_find_vsi (pf, vsi_id); - -return (vsi && (vsi->vf == vf)); +return vsi_id ==ICE_VF_VSI_ID ; }/**
drivers/net/ethernet/intel/ice/ice_virtchnl.h +9 -0
@@ -18,6 +18,15 @@*/ #define ICE_MAX_MACADDR_PER_VF 18 +/* VFs only get a single VSI. For ice hardware, the VF does not need to know +* its VSI index. However, the virtchnl interface requires a VSI number, +* mainly due to legacy hardware. +* +* Since the VF doesn't need this information, report a static value to the VF +* instead of leaking any information about the PF or hardware setup. +*/ +#define ICE_VF_VSI_ID 1 +struct ice_virtchnl_ops {int (*get_ver_msg)(struct ice_vf *vf,u8 *msg);int (*get_vf_res_msg)(struct ice_vf *vf,u8 *msg);
drivers/net/ethernet/pensando/ionic/ionic_lif.c +4 -1
@@ -3216,9 +3216,12 @@ static int ionic_lif_adminq_init(struct ionic_lif *lif)napi_enable (&qcq->napi); -if (qcq->flags &IONIC_QCQ_F_INTR ) +if (qcq->flags &IONIC_QCQ_F_INTR ) { +irq_set_affinity_hint (qcq->intr.vector, + &qcq->intr.affinity_mask);ionic_intr_mask (idev->intr_ctrl, qcq->intr.index,IONIC_INTR_MASK_CLEAR ); + } qcq->flags |=IONIC_QCQ_F_INITED ;
drivers/net/pcs/pcs-xpcs.c +2 -2
@@ -262,7 +262,7 @@ static int xpcs_soft_reset(struct dw_xpcs *xpcs, dev =MDIO_MMD_VEND2 ;break ;default : -return -1 ; +return -EINVAL ; } ret =xpcs_write (xpcs, dev,MDIO_CTRL1 ,MDIO_CTRL1_RESET );
@@ -904,7 +904,7 @@ int xpcs_do_config(struct dw_xpcs *xpcs, phy_interface_t interface,return ret;break ;default : -return -1 ; +return -EINVAL ; }if (compat->pma_config) {
drivers/net/wireless/ath/ath11k/mhi.c +1 -1
@@ -105,7 +105,7 @@ static struct mhi_controller_config ath11k_mhi_config_qca6390 = { .max_channels = 128, .timeout_ms = 2000, .use_bounce_buf = false, - .buf_len = 0, + .buf_len = 8192, .num_channels = ARRAY_SIZE(ath11k_mhi_channels_qca6390), .ch_cfg = ath11k_mhi_channels_qca6390, .num_events = ARRAY_SIZE(ath11k_mhi_events_qca6390),
drivers/net/wireless/ath/ath9k/antenna.c +1 -1
@@ -643,7 +643,7 @@ static void ath_ant_try_scan(struct ath_ant_comb *antcomb, conf->main_lna_conf =ATH_ANT_DIV_COMB_LNA1 ; conf->alt_lna_conf =ATH_ANT_DIV_COMB_LNA1_PLUS_LNA2 ; }else if (antcomb->rssi_sub > - antcomb->rssi_lna1) { + antcomb->rssi_lna2) {/* set to A-B */ conf->main_lna_conf =ATH_ANT_DIV_COMB_LNA1 ; conf->alt_lna_conf =ATH_ANT_DIV_COMB_LNA1_MINUS_LNA2 ;
drivers/net/wireless/broadcom/brcm80211/brcmfmac/dmi.c +9 -0
@@ -82,6 +82,15 @@ static const struct dmi_system_id dmi_platform_data[] = { }, .driver_data = (void *)&acepc_t8_data, }, + { +/* ACEPC W5 Pro Cherry Trail Z8350 HDMI stick, same wifi as the T8 */ + .matches = { +DMI_MATCH (DMI_BOARD_NAME ,"T3 MRD" ), +DMI_MATCH (DMI_CHASSIS_TYPE ,"3" ), + DMI_MATCH(DMI_BIOS_VENDOR, "American Megatrends Inc."), + }, + .driver_data = (void *)&acepc_t8_data, + }, {/* Chuwi Hi8 Pro with D2D3_Hi8Pro.233 BIOS */ .matches = {
drivers/net/wireless/intel/iwlwifi/pcie/drv.c +1 -0
@@ -505,6 +505,7 @@ static const struct pci_device_id iwl_hw_card_ids[] = {/* Bz devices */ {IWL_PCI_DEVICE(0x2727, PCI_ANY_ID, iwl_bz_trans_cfg)}, + {IWL_PCI_DEVICE(0x272D, PCI_ANY_ID, iwl_bz_trans_cfg)}, {IWL_PCI_DEVICE(0x272b, PCI_ANY_ID, iwl_bz_trans_cfg)}, {IWL_PCI_DEVICE(0xA840, PCI_ANY_ID, iwl_bz_trans_cfg)}, {IWL_PCI_DEVICE(0x7740, PCI_ANY_ID, iwl_bz_trans_cfg)},
drivers/net/wireless/realtek/rtw89/pci.h +1 -1
@@ -546,7 +546,7 @@#define RTW89_PCI_TXWD_NUM_MAX 512#define RTW89_PCI_TXWD_PAGE_SIZE 128#define RTW89_PCI_ADDRINFO_MAX 4 -#define RTW89_PCI_RX_BUF_SIZE 11460 +#define RTW89_PCI_RX_BUF_SIZE (11454 + 40)/* +40 for rtw89_rxdesc_long_v2 */ #define RTW89_PCI_POLL_BDRAM_RST_CNT 100#define RTW89_PCI_MULTITAG 8
drivers/nvme/host/pci.c +3 -0
@@ -3471,6 +3471,9 @@ static const struct pci_device_id nvme_id_table[] = { NVME_QUIRK_BOGUS_NID, }, { PCI_VDEVICE(REDHAT, 0x0010), /* Qemu emulated controller */ .driver_data = NVME_QUIRK_BOGUS_NID, }, + { PCI_DEVICE(0x126f, 0x2262), /* Silicon Motion generic */ + .driver_data = NVME_QUIRK_NO_DEEPEST_PS | + NVME_QUIRK_BOGUS_NID, }, { PCI_DEVICE(0x126f, 0x2263), /* Silicon Motion unidentified */ .driver_data = NVME_QUIRK_NO_NS_DESC_LIST | NVME_QUIRK_BOGUS_NID, },
drivers/pinctrl/renesas/core.c +3 -1
@@ -921,9 +921,11 @@ static void __init sh_pfc_check_cfg_reg(const char *drvname,sh_pfc_err ("reg 0x%x: var_field_width declares %u instead of %u bits\n" , cfg_reg->reg, rw, cfg_reg->reg_width); -if (n != cfg_reg->nr_enum_ids) +if (n != cfg_reg->nr_enum_ids) {sh_pfc_err ("reg 0x%x: enum_ids[] has %u instead of %u values\n" , cfg_reg->reg, cfg_reg->nr_enum_ids, n); + n = cfg_reg->nr_enum_ids; + } check_enum_ids:sh_pfc_check_reg_enums (drvname, cfg_reg->reg, cfg_reg->enum_ids, n);
drivers/platform/x86/intel/vbtn.c +3 -2
@@ -136,8 +136,6 @@ static int intel_vbtn_input_setup(struct platform_device *device) priv->switches_dev->id.bustype =BUS_HOST ;if (priv->has_switches) { -detect_tablet_mode (&device->dev); - ret =input_register_device (priv->switches_dev);if (ret)return ret;
@@ -316,6 +314,9 @@ static int intel_vbtn_probe(struct platform_device *device)if (ACPI_FAILURE (status))dev_err (&device->dev,"Error VBDL failed with ACPI status %d\n" , status); } +// Check switches after buttons since VBDL may have side effects. +if (has_switches) +detect_tablet_mode (&device->dev);device_init_wakeup (&device->dev, true);/*
drivers/platform/x86/touchscreen_dmi.c +9 -0
@@ -1177,6 +1177,15 @@ const struct dmi_system_id touchscreen_dmi_table[] = { DMI_MATCH(DMI_BIOS_VERSION, "CHUWI.D86JLBNR"), }, }, + { +/* Chuwi Vi8 dual-boot (CWI506) */ + .driver_data = (void *)&chuwi_vi8_data, + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Insyde" ), +DMI_MATCH (DMI_PRODUCT_NAME ,"i86" ), + DMI_MATCH(DMI_BIOS_VERSION, "CHUWI2.D86JHBNR02"), + }, + }, {/* Chuwi Vi8 Plus (CWI519) */ .driver_data = (void *)&chuwi_vi8_plus_data,
drivers/scsi/lpfc/lpfc_nportdisc.c +4 -2
@@ -748,8 +748,10 @@ lpfc_rcv_padisc(struct lpfc_vport *vport, struct lpfc_nodelist *ndlp,/* Save the ELS cmd */ elsiocb->drvrTimeout = cmd; -lpfc_sli4_resume_rpi (ndlp, - lpfc_mbx_cmpl_resume_rpi, elsiocb); +if (lpfc_sli4_resume_rpi (ndlp, + lpfc_mbx_cmpl_resume_rpi, + elsiocb)) +kfree (elsiocb); goto out; } }
drivers/scsi/scsi_lib.c +27 -25
92 lines not on this page · raw message
drivers/scsi/sd.c +2 -2
@@ -3299,8 +3299,8 @@ static void sd_read_block_zero(struct scsi_disk *sdkp)put_unaligned_be32 (0 , &cmd[2 ]);/* Logical block address 0 */ put_unaligned_be16 (1 , &cmd[7 ]);/* Transfer 1 logical block */ -scsi_execute_cmd (sdkp->device, cmd,REQ_OP_DRV_IN , buffer, buf_len, -SD_TIMEOUT , sdkp->max_retries,NULL ); +scsi_execute_req (sdkp->device, cmd,DMA_FROM_DEVICE , buffer, buf_len, +NULL ,SD_TIMEOUT , sdkp->max_retries,NULL );kfree (buffer); }
drivers/soundwire/dmi-quirks.c +8 -0
@@ -130,6 +130,14 @@ static const struct dmi_system_id adr_remap_quirk_table[] = { }, .driver_data = (void *)intel_rooks_county, }, + { +/* quirk used for NUC15 LAPRC710 skew */ + .matches = { +DMI_MATCH (DMI_BOARD_VENDOR ,"Intel Corporation" ), + DMI_MATCH(DMI_BOARD_NAME, "LAPRC710"), + }, + .driver_data = (void *)intel_rooks_county, + }, { .matches = { DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc"),
drivers/thermal/thermal_of.c +8 -4
@@ -337,14 +337,18 @@ static int thermal_of_monitor_init(struct device_node *np, int *delay, int *pdelint ret; ret =of_property_read_u32 (np,"polling-delay-passive" , pdelay); -if (ret <0 ) { -pr_err ("%pOFn: missing polling-delay-passive property\n" , np); +if (ret == -EINVAL ) { + *pdelay =0 ; + }else if (ret <0 ) { +pr_err ("%pOFn: Couldn't get polling-delay-passive: %d\n" , np, ret);return ret; } ret =of_property_read_u32 (np,"polling-delay" , delay); -if (ret <0 ) { -pr_err ("%pOFn: missing polling-delay property\n" , np); +if (ret == -EINVAL ) { + *delay =0 ; + }else if (ret <0 ) { +pr_err ("%pOFn: Couldn't get polling-delay: %d\n" , np, ret);return ret; }
drivers/thunderbolt/quirks.c +14 -0
@@ -42,6 +42,12 @@ static void quirk_usb3_maximum_bandwidth(struct tb_switch *sw) } } +static void quirk_block_rpm_in_redrive (struct tb_switch *sw) +{ + sw->quirks |=QUIRK_KEEP_POWER_IN_DP_REDRIVE ; +tb_sw_dbg (sw,"preventing runtime PM in DP redrive mode\n" ); +} +struct tb_quirk {u16 hw_vendor_id;u16 hw_device_id;
@@ -85,6 +91,14 @@ static const struct tb_quirk tb_quirks[] = { quirk_usb3_maximum_bandwidth }, {0x8087 ,PCI_DEVICE_ID_INTEL_BARLOW_RIDGE_HUB_40G_BRIDGE ,0x0000 ,0x0000 , quirk_usb3_maximum_bandwidth }, +/* +* Block Runtime PM in DP redrive mode for Intel Barlow Ridge host +* controllers. +*/ + { 0x8087, PCI_DEVICE_ID_INTEL_BARLOW_RIDGE_HOST_80G_NHI, 0x0000, 0x0000, + quirk_block_rpm_in_redrive }, + { 0x8087, PCI_DEVICE_ID_INTEL_BARLOW_RIDGE_HOST_40G_NHI, 0x0000, 0x0000, + quirk_block_rpm_in_redrive },/* * CLx is not supported on AMD USB4 Yellow Carp and Pink Sardine platforms. */
drivers/thunderbolt/tb.c +48 -1
67 lines not on this page · raw message
drivers/thunderbolt/tb.h +4 -0
@@ -27,6 +27,8 @@#define QUIRK_FORCE_POWER_LINK_CONTROLLER BIT(0)/* Disable CLx if not supported */ #define QUIRK_NO_CLX BIT(1) +/* Need to keep power on while USB4 port is in redrive mode */ +#define QUIRK_KEEP_POWER_IN_DP_REDRIVE BIT(2)/** * struct tb_nvm - Structure holding NVM information
@@ -254,6 +256,7 @@ struct tb_switch {* DMA paths through this port. * @max_bw: Maximum possible bandwidth through this adapter if set to * non-zero. +* @redrive: For DP IN, if true the adapter is in redrive mode. * * In USB4 terminology this structure represents an adapter (protocol or * lane adapter).
@@ -280,6 +283,7 @@ struct tb_port {unsigned int ctl_credits;unsigned int dma_credits;unsigned int max_bw; +bool redrive; };/**
drivers/tty/n_gsm.c +3 -0
@@ -2969,6 +2969,9 @@ static int gsmld_open(struct tty_struct *tty) {struct gsm_mux *gsm; +if (!capable (CAP_NET_ADMIN )) +return -EPERM ; +if (tty->ops->write ==NULL )return -EINVAL ;
drivers/usb/gadget/function/uvc_video.c +3 -0
@@ -35,6 +35,9 @@ uvc_video_encode_header(struct uvc_video *video, struct uvc_buffer *buf, data[1 ] =UVC_STREAM_EOH | video->fid; +if (video->queue.flags &UVC_QUEUE_DROP_INCOMPLETE ) + data[1 ] |=UVC_STREAM_ERR ; +if (video->queue.buf_used ==0 && ts.tv_sec) {/* dwClockFrequency is 48 MHz */ u32 pts = ((u64 )ts.tv_sec *USEC_PER_SEC + ts.tv_nsec /NSEC_PER_USEC ) *48 ;
drivers/usb/host/sl811-hcd.c +2 -0
@@ -585,6 +585,7 @@ done(struct sl811 *sl811, struct sl811h_ep *ep, u8 bank)finish_request (sl811, ep, urb, urbstat); } +#ifdef QUIRK2 static inline u8 checkdone (struct sl811 *sl811) {u8 ctl;
@@ -616,6 +617,7 @@ static inline u8 checkdone(struct sl811 *sl811)#endif return irqstat; } +#endif static irqreturn_t sl811h_irq (struct usb_hcd *hcd) {
drivers/usb/typec/tcpm/tcpci.c +1 -0
@@ -875,6 +875,7 @@ MODULE_DEVICE_TABLE(i2c, tcpci_id);#ifdef CONFIG_OF static const struct of_device_id tcpci_of_match[] = { { .compatible ="nxp,ptn5110" , }, + { .compatible ="tcpci" , }, {}, };MODULE_DEVICE_TABLE (of, tcpci_of_match);
drivers/video/fbdev/core/fbmon.c +4 -3
@@ -1311,7 +1311,7 @@ int fb_get_mode(int flags, u32 val, struct fb_var_screeninfo *var, struct fb_infint fb_videomode_from_videomode (const struct videomode *vm,struct fb_videomode *fbmode) { -unsigned int htotal, vtotal; +unsigned int htotal, vtotal, total; fbmode->xres = vm->hactive; fbmode->left_margin = vm->hback_porch;
@@ -1344,8 +1344,9 @@ int fb_videomode_from_videomode(const struct videomode *vm, vtotal = vm->vactive + vm->vfront_porch + vm->vback_porch + vm->vsync_len;/* prevent division by zero */ -if (htotal && vtotal) { - fbmode->refresh = vm->pixelclock / (htotal * vtotal); + total = htotal * vtotal; +if (total) { + fbmode->refresh = vm->pixelclock / total;/* a mode must have htotal and vtotal != 0 or it is invalid */ }else { fbmode->refresh =0 ;
drivers/video/fbdev/via/accel.c +2 -2
@@ -115,7 +115,7 @@ static int hw_bitblt_1(void __iomem *engine, u8 op, u32 width, u32 height,if (op !=VIA_BITBLT_FILL ) { tmp = src_mem ?0 : src_addr; -if (dst_addr &0xE0000007 ) { +if (tmp &0xE0000007 ) {printk (KERN_WARNING "hw_bitblt_1: Unsupported source " "address %X\n" , tmp);return -EINVAL ;
@@ -260,7 +260,7 @@ static int hw_bitblt_2(void __iomem *engine, u8 op, u32 width, u32 height,writel (tmp, engine +0x18 ); tmp = src_mem ?0 : src_addr; -if (dst_addr &0xE0000007 ) { +if (tmp &0xE0000007 ) {printk (KERN_WARNING "hw_bitblt_2: Unsupported source " "address %X\n" , tmp);return -EINVAL ;
drivers/virtio/virtio.c +8 -2
@@ -489,13 +489,19 @@ EXPORT_SYMBOL_GPL(unregister_virtio_device);int virtio_device_freeze (struct virtio_device *dev) {struct virtio_driver *drv =drv_to_virtio (dev->dev.driver); +int ret;virtio_config_disable (dev); dev->failed = dev->config->get_status (dev) &VIRTIO_CONFIG_S_FAILED ; -if (drv && drv->freeze) -return drv->freeze (dev); +if (drv && drv->freeze) { + ret = drv->freeze (dev); +if (ret) { +virtio_config_enable (dev); +return ret; + } + }return 0 ; }
fs/btrfs/export.c +8 -1
@@ -161,8 +161,15 @@ struct dentry *btrfs_get_parent(struct dentry *child) ret =btrfs_search_slot (NULL , root, &key, path,0 ,0 );if (ret <0 ) goto fail; +if (ret ==0 ) { +/* +* Key with offset of -1 found, there would have to exist an +* inode with such number or a root with such id. +*/ + ret = -EUCLEAN ; + goto fail; + } -BUG_ON (ret ==0 );/* Key with offset of -1 found */ if (path->slots[0 ] ==0 ) { ret = -ENOENT ; goto fail;
fs/btrfs/send.c +9 -1
@@ -1015,7 +1015,15 @@ static int iterate_inode_ref(struct btrfs_root *root, struct btrfs_path *path, ret =PTR_ERR (start); goto out; } -BUG_ON (start < p->buf); +if (unlikely (start < p->buf)) { +btrfs_err (root->fs_info, +"send: path ref buffer underflow for key (%llu %u %llu)" , + found_key->objectid, + found_key->type, + found_key->offset); + ret = -EINVAL ; + goto out; + } } p->start = start; }else {
fs/btrfs/volumes.c +11 -1
@@ -3381,7 +3381,17 @@ static int btrfs_relocate_sys_chunks(struct btrfs_fs_info *fs_info)mutex_unlock (&fs_info->reclaim_bgs_lock); goto error; } -BUG_ON (ret ==0 );/* Corruption */ +if (ret ==0 ) { +/* +* On the first search we would find chunk tree with +* offset -1, which is not possible. On subsequent +* loops this would find an existing item on an invalid +* offset (one less than the previous one, wrong +* alignment and size). +*/ + ret = -EUCLEAN ; + goto error; + } ret =btrfs_previous_item (chunk_root, path, key.objectid, key.type);
fs/ext4/mballoc.c +4 -1
@@ -2905,7 +2905,10 @@ static int ext4_mb_seq_groups_show(struct seq_file *seq, void *v)for (i =0 ; i <=13 ; i++)seq_printf (seq," %-5u" , i <= blocksize_bits +1 ? sg.info.bb_counters[i] :0 ); -seq_puts (seq," ]\n" ); +seq_puts (seq," ]" ); +if (EXT4_MB_GRP_BBITMAP_CORRUPT (&sg.info)) +seq_puts (seq," Block bitmap corrupted!" ); +seq_puts (seq,"\n" );return 0 ; }
fs/ext4/super.c +12 -0
@@ -6751,6 +6751,10 @@ static int ext4_write_dquot(struct dquot *dquot)if (IS_ERR (handle))return PTR_ERR (handle); ret =dquot_commit (dquot); +if (ret <0 ) +ext4_error_err (dquot->dq_sb, -ret, +"Failed to commit dquot type %d" , + dquot->dq_id.type); err =ext4_journal_stop (handle);if (!ret) ret = err;
@@ -6767,6 +6771,10 @@ static int ext4_acquire_dquot(struct dquot *dquot)if (IS_ERR (handle))return PTR_ERR (handle); ret =dquot_acquire (dquot); +if (ret <0 ) +ext4_error_err (dquot->dq_sb, -ret, +"Failed to acquire dquot type %d" , + dquot->dq_id.type); err =ext4_journal_stop (handle);if (!ret) ret = err;
@@ -6786,6 +6794,10 @@ static int ext4_release_dquot(struct dquot *dquot)return PTR_ERR (handle); } ret =dquot_release (dquot); +if (ret <0 ) +ext4_error_err (dquot->dq_sb, -ret, +"Failed to release dquot type %d" , + dquot->dq_id.type); err =ext4_journal_stop (handle);if (!ret) ret = err;
fs/isofs/inode.c +16 -2
@@ -908,8 +908,22 @@ static int isofs_fill_super(struct super_block *s, void *data, int silent)* we then decide whether to use the Joliet descriptor. */ inode =isofs_iget (s, sbi->s_firstdatazone,0 ); -if (IS_ERR (inode)) - goto out_no_root; + +/* +* Fix for broken CDs with a corrupt root inode but a correct Joliet +* root directory. +*/ +if (IS_ERR (inode)) { +if (joliet_level && sbi->s_firstdatazone != first_data_zone) { +printk (KERN_NOTICE +"ISOFS: root inode is unusable. " +"Disabling Rock Ridge and switching to Joliet." ); + sbi->s_rock =0 ; + inode =NULL ; + }else { + goto out_no_root; + } + }/* * Fix for broken CDs with Rock Ridge and empty ISO root directory but
fs/orangefs/super.c +1 -1
@@ -527,7 +527,7 @@ struct dentry *orangefs_mount(struct file_system_type *fst, sb->s_fs_info =kzalloc (sizeof (struct orangefs_sb_info_s ),GFP_KERNEL );if (!ORANGEFS_SB (sb)) { d =ERR_PTR (-ENOMEM ); - goto free_sb_and_op; + goto free_op; } ret = orangefs_fill_sb(sb,
fs/pstore/zone.c +2 -0
@@ -973,6 +973,8 @@ static ssize_t psz_kmsg_read(struct pstore_zone *zone,char *buf =kasprintf (GFP_KERNEL ,"%s: Total %d times\n" ,kmsg_dump_reason_str (record->reason), record->count); +if (!buf) +return -ENOMEM ; hlen =strlen (buf); record->buf =krealloc (buf, hlen + size,GFP_KERNEL );if (!record->buf) {
fs/sysv/itree.c +4 -6
@@ -82,9 +82,6 @@ static inline sysv_zone_t *block_end(struct buffer_head *bh)return (sysv_zone_t *)((char *)bh->b_data + bh->b_size); } -/* -* Requires read_lock(&pointers_lock) or write_lock(&pointers_lock) -*/ static Indirect *get_branch(struct inode *inode, int depth, int offsets[],
@@ -104,15 +101,18 @@ static Indirect *get_branch(struct inode *inode, bh =sb_bread (sb, block);if (!bh) goto failure; +read_lock (&pointers_lock);if (!verify_chain (chain, p)) goto changed;add_chain (++p, bh, (sysv_zone_t *)bh->b_data + *++offsets); +read_unlock (&pointers_lock);if (!p->key) goto no_block; }return NULL ; changed: +read_unlock (&pointers_lock);brelse (bh); *err = -EAGAIN ; goto no_block;
@@ -218,9 +218,7 @@ static int get_block(struct inode *inode, sector_t iblock, struct buffer_head *b goto out; reread: -read_lock (&pointers_lock); partial =get_branch (inode, depth, offsets, chain, &err); -read_unlock (&pointers_lock);/* Simplest case - block found, no allocation needed */ if (!partial) {
@@ -290,9 +288,9 @@ static Indirect *find_shared(struct inode *inode, *top =0 ;for (k = depth; k >1 && !offsets[k-1 ]; k--) ; + partial =get_branch (inode, k, offsets, chain, &err);write_lock (&pointers_lock); - partial =get_branch (inode, k, offsets, chain, &err);if (!partial) partial = chain + k-1 ;/*
include/linux/randomize_kstack.h +1 -1
@@ -80,7 +80,7 @@ DECLARE_PER_CPU(u32, kstack_offset);if (static_branch_maybe (CONFIG_RANDOMIZE_KSTACK_OFFSET_DEFAULT , \ &randomize_kstack_offset)) { \u32 offset =raw_cpu_read (kstack_offset); \ - offset ^= (rand); \ + offset =ror32 (offset,5 ) ^ (rand); \raw_cpu_write (kstack_offset, offset); \ } \ }while (0 )
include/linux/rcupdate.h +2 -2
@@ -205,9 +205,9 @@ void rcu_tasks_trace_qs_blkd(struct task_struct *t); do { \ int ___rttq_nesting = READ_ONCE((t)->trc_reader_nesting); \ \ - if (likely(!READ_ONCE((t)->trc_reader_special.b.need_qs)) && \ + if (unlikely(READ_ONCE((t)->trc_reader_special.b.need_qs) == TRC_NEED_QS) && \ likely(!___rttq_nesting)) { \ - rcu_trc_cmpxchg_need_qs((t), 0, TRC_NEED_QS_CHECKED); \ + rcu_trc_cmpxchg_need_qs((t), TRC_NEED_QS, TRC_NEED_QS_CHECKED); \ } else if (___rttq_nesting && ___rttq_nesting != INT_MIN && \ !READ_ONCE((t)->trc_reader_special.b.blocked)) { \ rcu_tasks_trace_qs_blkd(t); \
include/linux/skbuff.h +11 -0
@@ -2603,6 +2603,8 @@ static inline void skb_put_u8(struct sk_buff *skb, u8 val)void *skb_push (struct sk_buff *skb,unsigned int len);static inline void *__skb_push (struct sk_buff *skb,unsigned int len) { +DEBUG_NET_WARN_ON_ONCE (len >INT_MAX ); + skb->data -= len; skb->len += len;return skb->data;
@@ -2611,6 +2613,8 @@ static inline void *__skb_push(struct sk_buff *skb, unsigned int len)void *skb_pull (struct sk_buff *skb,unsigned int len);static inline void *__skb_pull (struct sk_buff *skb,unsigned int len) { +DEBUG_NET_WARN_ON_ONCE (len >INT_MAX ); + skb->len -= len;if (unlikely (skb->len < skb->data_len)) {#if defined(CONFIG_DEBUG_NET )
@@ -2634,6 +2638,8 @@ void *__pskb_pull_tail(struct sk_buff *skb, int delta);static inline bool pskb_may_pull (struct sk_buff *skb,unsigned int len) { +DEBUG_NET_WARN_ON_ONCE (len >INT_MAX ); +if (likely (len <=skb_headlen (skb)))return true;if (unlikely (len > skb->len))
@@ -2796,6 +2802,11 @@ static inline void skb_set_inner_network_header(struct sk_buff *skb, skb->inner_network_header += offset; } +static inline bool skb_inner_network_header_was_set (const struct sk_buff *skb) +{ +return skb->inner_network_header >0 ; +} +static inline unsigned char *skb_inner_mac_header (const struct sk_buff *skb) {return skb->head + skb->inner_mac_header;
include/linux/sunrpc/sched.h +1 -1
@@ -186,7 +186,7 @@ struct rpc_wait_queue {unsigned char maxpriority;/* maximum priority (0 if queue is not a priority queue) */ unsigned char priority;/* current priority */ unsigned char nr;/* # tasks remaining for cookie */ -unsigned short qlen;/* total # tasks waiting in queue */ +unsigned int qlen;/* total # tasks waiting in queue */ struct rpc_timer timer_list;#if IS_ENABLED (CONFIG_SUNRPC_DEBUG ) ||IS_ENABLED (CONFIG_TRACEPOINTS )const char * name;
include/scsi/scsi_device.h +14 -37
65 lines not on this page · raw message
include/uapi/linux/input-event-codes.h +1 -0
@@ -602,6 +602,7 @@#define KEY_ALS_TOGGLE 0x230/* Ambient light sensor */ #define KEY_ROTATE_LOCK_TOGGLE 0x231/* Display rotation lock */ +#define KEY_REFRESH_RATE_TOGGLE 0x232/* Display refresh rate toggle */ #define KEY_BUTTONCONFIG 0x240/* AL Button Configuration */ #define KEY_TASKMANAGER 0x241/* AL Task/Project Manager */
io_uring/io_uring.c +16 -9
@@ -1978,6 +1978,13 @@ static void io_init_req_drain(struct io_kiocb *req) } } +static __cold int io_init_fail_req (struct io_kiocb *req,int err) +{ +/* ensure per-opcode data is cleared if we fail before prep */ +memset (&req->cmd.data,0 ,sizeof (req->cmd.data)); +return err; +} + static int io_init_req(struct io_ring_ctx *ctx, struct io_kiocb *req, const struct io_uring_sqe *sqe) __must_hold(&ctx->uring_lock)
@@ -1998,29 +2005,29 @@ static int io_init_req(struct io_ring_ctx *ctx, struct io_kiocb *req,if (unlikely (opcode >=IORING_OP_LAST )) { req->opcode =0 ; -return -EINVAL ; +return io_init_fail_req (req, -EINVAL ); } def = &io_op_defs[opcode];if (unlikely (sqe_flags & ~SQE_COMMON_FLAGS )) {/* enforce forwards compatibility on users */ if (sqe_flags & ~SQE_VALID_FLAGS ) -return -EINVAL ; +return io_init_fail_req (req, -EINVAL );if (sqe_flags &IOSQE_BUFFER_SELECT ) {if (!def->buffer_select) -return -EOPNOTSUPP ; +return io_init_fail_req (req, -EOPNOTSUPP ); req->buf_index =READ_ONCE (sqe->buf_group); }if (sqe_flags &IOSQE_CQE_SKIP_SUCCESS ) ctx->drain_disabled = true;if (sqe_flags &IOSQE_IO_DRAIN ) {if (ctx->drain_disabled) -return -EOPNOTSUPP ; +return io_init_fail_req (req, -EOPNOTSUPP );io_init_req_drain (req); } }if (unlikely (ctx->restricted || ctx->drain_active || ctx->drain_next)) {if (ctx->restricted && !io_check_restriction (ctx, req, sqe_flags)) -return -EACCES ; +return io_init_fail_req (req, -EACCES );/* knock it to the slow queue path, will be drained there */ if (ctx->drain_active) req->flags |=REQ_F_FORCE_ASYNC ;
@@ -2033,9 +2040,9 @@ static int io_init_req(struct io_ring_ctx *ctx, struct io_kiocb *req, }if (!def->ioprio && sqe->ioprio) -return -EINVAL ; +return io_init_fail_req (req, -EINVAL );if (!def->iopoll && (ctx->flags &IORING_SETUP_IOPOLL )) -return -EINVAL ; +return io_init_fail_req (req, -EINVAL );if (def->needs_file) {struct io_submit_state *state = &ctx->submit_state;
@@ -2059,12 +2066,12 @@ static int io_init_req(struct io_ring_ctx *ctx, struct io_kiocb *req, req->creds =xa_load (&ctx->personalities, personality);if (!req->creds) -return -EINVAL ; +return io_init_fail_req (req, -EINVAL );get_cred (req->creds); ret =security_uring_override_creds (req->creds);if (ret) {put_cred (req->creds); -return ret; +return io_init_fail_req (req, ret); } req->flags |=REQ_F_CREDS ; }
kernel/dma/direct.c +5 -4
@@ -296,7 +296,7 @@ void *dma_direct_alloc(struct device *dev, size_t size, }else { ret =page_address (page);if (dma_set_decrypted (dev, ret, size)) - goto out_free_pages; + goto out_leak_pages; }memset (ret,0 , size);
@@ -317,6 +317,8 @@ void *dma_direct_alloc(struct device *dev, size_t size, out_free_pages:__dma_direct_free_pages (dev, page, size);return NULL ; +out_leak_pages: +return NULL ; } void dma_direct_free(struct device *dev, size_t size,
@@ -379,12 +381,11 @@ struct page *dma_direct_alloc_pages(struct device *dev, size_t size, ret =page_address (page);if (dma_set_decrypted (dev, ret, size)) - goto out_free_pages; + goto out_leak_pages;memset (ret,0 , size); *dma_handle =phys_to_dma_direct (dev,page_to_phys (page));return page; -out_free_pages: -__dma_direct_free_pages (dev, page, size); +out_leak_pages:return NULL ; }
kernel/panic.c +8 -0
@@ -441,6 +441,14 @@ void panic(const char *fmt, ...)/* Do not scroll important messages printed above */ suppress_printk =1 ; + +/* +* The final messages may not have been printed if in a context that +* defers printing (such as NMI) and irq_work is not available. +* Explicitly flush the kernel log buffer one last time. +*/ +console_flush_on_panic (CONSOLE_FLUSH_PENDING ); +local_irq_enable ();for (i =0 ; ; i +=PANIC_TIMER_STEP ) {touch_softlockup_watchdog ();
kernel/trace/ring_buffer.c +1 -1
@@ -4431,7 +4431,7 @@ int ring_buffer_iter_empty(struct ring_buffer_iter *iter) cpu_buffer = iter->cpu_buffer; reader = cpu_buffer->reader_page; head_page = cpu_buffer->head_page; - commit_page = cpu_buffer->commit_page; + commit_page =READ_ONCE (cpu_buffer->commit_page); commit_ts = commit_page->page->time_stamp;/*
net/mpls/mpls_gso.c +3 -0
@@ -26,6 +26,9 @@ static struct sk_buff *mpls_gso_segment(struct sk_buff *skb,__be16 mpls_protocol;unsigned int mpls_hlen; +if (!skb_inner_network_header_was_set (skb)) + goto out; +skb_reset_network_header (skb); mpls_hlen =skb_inner_network_header (skb) -skb_network_header (skb);if (unlikely (!mpls_hlen || mpls_hlen %MPLS_HLEN ))
net/netfilter/nf_tables_api.c +36 -11
86 lines not on this page · raw message
net/smc/smc_pnet.c +10 -0
@@ -802,6 +802,16 @@ static void smc_pnet_create_pnetids_list(struct net *net)u8 ndev_pnetid[SMC_MAX_PNETID_LEN ];struct net_device *dev; +/* Newly created netns do not have devices. +* Do not even acquire rtnl. +*/ +if (list_empty (&net->dev_base_head)) +return ; + +/* Note: This might not be needed, because smc_pnet_netdev_event() +* is also calling smc_pnet_add_base_pnetid() when handling +* NETDEV_UP event. +*/ rtnl_lock ();for_each_netdev (net, dev)smc_pnet_add_base_pnetid (net, dev, ndev_pnetid);
scripts/gcc-plugins/stackleak_plugin.c +2 -0
@@ -467,6 +467,8 @@ static bool stackleak_gate(void)return false;if (STRING_EQUAL (section,".entry.text" ))return false; +if (STRING_EQUAL (section,".head.text" )) +return false; }return track_frame_size >=0 ;
sound/firewire/amdtp-stream.c +8 -4
@@ -771,10 +771,14 @@ static int check_cip_header(struct amdtp_stream *s, const __be32 *buf, }else {unsigned int dbc_interval; -if (*data_blocks >0 && s->ctx_data.tx.dbc_interval >0 ) - dbc_interval = s->ctx_data.tx.dbc_interval; -else - dbc_interval = *data_blocks; +if (!(s->flags &CIP_DBC_IS_PAYLOAD_QUADLETS )) { +if (*data_blocks >0 && s->ctx_data.tx.dbc_interval >0 ) + dbc_interval = s->ctx_data.tx.dbc_interval; +else + dbc_interval = *data_blocks; + }else { + dbc_interval = payload_length /sizeof (__be32); + } lost = dbc != ((*data_block_counter + dbc_interval) &0xff ); }
sound/firewire/amdtp-stream.h +4 -0
@@ -37,6 +37,9 @@* the value of current SYT_INTERVAL; e.g. initial value is not zero. * @CIP_UNAWARE_SYT: For outgoing packet, the value in SYT field of CIP is 0xffff. * For incoming packet, the value in SYT field of CIP is not handled. +* @CIP_DBC_IS_PAYLOAD_QUADLETS: Available for incoming packet, and only effective with +* CIP_DBC_IS_END_EVENT flag. The value of dbc field is the number of accumulated quadlets +* in CIP payload, instead of the number of accumulated data blocks. */ enum cip_flags {CIP_NONBLOCKING =0x00 ,
@@ -51,6 +54,7 @@ enum cip_flags {CIP_NO_HEADER =0x100 ,CIP_UNALIGHED_DBC =0x200 ,CIP_UNAWARE_SYT =0x400 , + CIP_DBC_IS_PAYLOAD_QUADLETS = 0x800, };/**
sound/soc/intel/boards/sof_sdw.c +11 -0
@@ -224,6 +224,17 @@ static const struct dmi_system_id sof_sdw_quirk_table[] = {SOF_SDW_PCH_DMIC | RT711_JD2_100K), }, + { +/* NUC15 LAPRC710 skews */ + .callback = sof_sdw_quirk_cb, + .matches = { +DMI_MATCH (DMI_BOARD_VENDOR ,"Intel Corporation" ), + DMI_MATCH(DMI_BOARD_NAME, "LAPRC710"), + }, + .driver_data = (void *)(SOF_SDW_TGL_HDMI | +SOF_SDW_PCH_DMIC | + RT711_JD2_100K), + }, /* TigerLake-SDCA devices */ { .callback = sof_sdw_quirk_cb,
sound/soc/soc-core.c +3 -0
@@ -1020,6 +1020,9 @@ int snd_soc_add_pcm_runtime(struct snd_soc_card *card,if (!snd_soc_is_matching_component (platform, component))continue ; +if (snd_soc_component_is_dummy (component) && component->num_dai) +continue ; +snd_soc_rtd_add_component (rtd, component); } }
tools/iio/iio_utils.c +1 -1
@@ -376,7 +376,7 @@ int build_channel_array(const char *device_dir, int buffer_idx, goto error_close_dir; } -seekdir (dp,0 ); +rewinddir (dp);while (ent =readdir (dp), ent) {if (strcmp (ent->d_name +strlen (ent->d_name) -strlen ("_en" ),"_en" ) ==0 ) {
tools/lib/perf/evlist.c +12 -6
@@ -233,10 +233,10 @@ u64 perf_evlist__read_format(struct perf_evlist *evlist)static void perf_evlist__id_hash (struct perf_evlist *evlist,struct perf_evsel *evsel, -int cpu,int thread,u64 id) +int cpu_map_idx,int thread,u64 id) {int hash; -struct perf_sample_id *sid =SID (evsel, cpu, thread); +struct perf_sample_id *sid =SID (evsel, cpu_map_idx, thread); sid->id = id; sid->evsel = evsel;
@@ -254,21 +254,27 @@ void perf_evlist__reset_id_hash(struct perf_evlist *evlist)void perf_evlist__id_add (struct perf_evlist *evlist,struct perf_evsel *evsel, -int cpu,int thread,u64 id) +int cpu_map_idx,int thread,u64 id) { -perf_evlist__id_hash (evlist, evsel, cpu, thread, id); +if (!SID (evsel, cpu_map_idx, thread)) +return ; + +perf_evlist__id_hash (evlist, evsel, cpu_map_idx, thread, id); evsel->id[evsel->ids++] = id; }int perf_evlist__id_add_fd (struct perf_evlist *evlist,struct perf_evsel *evsel, -int cpu,int thread,int fd) +int cpu_map_idx,int thread,int fd) {u64 read_data[4 ] = {0 , };int id_idx =1 ;/* The first entry is the counter value */ u64 id;int ret; +if (!SID (evsel, cpu_map_idx, thread)) +return -1 ; + ret =ioctl (fd,PERF_EVENT_IOC_ID , &id);if (!ret) goto add;
@@ -297,7 +303,7 @@ int perf_evlist__id_add_fd(struct perf_evlist *evlist, id = read_data[id_idx]; add: -perf_evlist__id_add (evlist, evsel, cpu, thread, id); +perf_evlist__id_add (evlist, evsel, cpu_map_idx, thread, id);return 0 ; }
tools/lib/perf/include/internal/evlist.h +2 -2
@@ -127,11 +127,11 @@ u64 perf_evlist__read_format(struct perf_evlist *evlist);void perf_evlist__id_add (struct perf_evlist *evlist,struct perf_evsel *evsel, -int cpu,int thread,u64 id); +int cpu_map_idx,int thread,u64 id);int perf_evlist__id_add_fd (struct perf_evlist *evlist,struct perf_evsel *evsel, -int cpu,int thread,int fd); +int cpu_map_idx,int thread,int fd);void perf_evlist__reset_id_hash (struct perf_evlist *evlist);
tools/power/x86/x86_energy_perf_policy/x86_energy_perf_policy.c +1 -0
@@ -1241,6 +1241,7 @@ unsigned int get_pkg_num(int cpu) retval =fscanf (fp,"%d\n" , &pkg);if (retval !=1 )errx (1 ,"%s: failed to parse" , pathname); +fclose (fp);return pkg; }
tools/testing/ktest/ktest.pl +1 -0
@@ -836,6 +836,7 @@ sub set_value { if ($lvalue =~ /^(TEST|BISECT|CONFIG_BISECT)_TYPE(\[.*\])?$/ && $prvalue !~ /^(config_|)bisect$/ && $prvalue !~ /^build$/ && + $prvalue !~ /^make_warnings_file$/ && $buildonly) { # Note if a test is something other than build, then we