id stringlengths 40 40 | instruction stringlengths 68 308 | input stringlengths 17 33.4k | output stringlengths 100 30k |
|---|---|---|---|
41d78cb724f4b40b7548af420ccfe524b14023bb | Analyze and fix the following issue in the Linux kernel code: Revert "ALSA: usb: Increase volume range that triggers a warning" | Problem Details:
UAC uses 2 bytes to store volume values, so the maximum volume range is
0xFFFF (65535, val = -32768/32767/1).
The reverted commit bumpped the range of triggering the warning to >
65535, effectively making the range check a no-op. It didn't fix
anything but covered any potential problems and deviated f... | ```diff
diff --git a/sound/usb/mixer.c b/sound/usb/mixer.c
index ac8c71ba9483..df0d3df9c7ec 100644
--- a/sound/usb/mixer.c
+++ b/sound/usb/mixer.c
@@ -1813,10 +1813,11 @@ static void __build_feature_ctl(struct usb_mixer_interface *mixer,
range = (cval->max - cval->min) / cval->res;
/*
- * There are definitely de... |
3d1973a0c76a78a4728cff13648a188ed486cf44 | Analyze and fix the following issue in the Linux kernel code: x86/boot: Handle relative CONFIG_EFI_SBAT_FILE file paths | Problem Details:
CONFIG_EFI_SBAT_FILE can be a relative path. When compiling using a different
output directory (O=) the build currently fails because it can't find the
filename set in CONFIG_EFI_SBAT_FILE:
arch/x86/boot/compressed/sbat.S: Assembler messages:
arch/x86/boot/compressed/sbat.S:6: Error: file not foun... | ```diff
diff --git a/arch/x86/boot/compressed/Makefile b/arch/x86/boot/compressed/Makefile
index 68f9d7a1683b..b8b2b7bea1d3 100644
--- a/arch/x86/boot/compressed/Makefile
+++ b/arch/x86/boot/compressed/Makefile
@@ -113,6 +113,7 @@ vmlinux-objs-$(CONFIG_EFI_SBAT) += $(obj)/sbat.o
ifdef CONFIG_EFI_SBAT
$(obj)/sbat.o:... |
44d93cf1abb6a85d65c3b4b027c82d44263de6a5 | Analyze and fix the following issue in the Linux kernel code: wifi: UHR: define DPS/DBE/P-EDCA elements and fix size parsing | Problem Details:
Add UHR Operation and Capability definitions and parsing helpers:
- Define ieee80211_uhr_dps_info, ieee80211_uhr_dbe_info,
ieee80211_uhr_p_edca_info with masks.
- Update ieee80211_uhr_oper_size_ok() to account for optional
DPS/DBE/P-EDCA blocks.
- Move NPCA pointer position after DPS Operation Par... | ```diff
diff --git a/include/linux/ieee80211-uhr.h b/include/linux/ieee80211-uhr.h
index 132acced7d79..9729d23e4766 100644
--- a/include/linux/ieee80211-uhr.h
+++ b/include/linux/ieee80211-uhr.h
@@ -29,11 +29,216 @@ struct ieee80211_uhr_operation {
#define IEEE80211_UHR_NPCA_PARAMS_MOPLEN 0x00400000
#define IEEE8021... |
f20c73b0460d15301cf1bddf0f85d060a38a75df | Analyze and fix the following issue in the Linux kernel code: ipvs: use more keys for connection hashing | Problem Details:
Simon Kirby reported long time ago that IPVS connection hashing
based only on the client address/port (caddr, cport) as hash keys
is not suitable for setups that accept traffic on multiple virtual
IPs and ports. It can happen for multiple VIP:VPORT services, for
single or many fwmark service(s) that ma... | ```diff
diff --git a/include/net/ip_vs.h b/include/net/ip_vs.h
index 3d595bd99eb3..72d325c81313 100644
--- a/include/net/ip_vs.h
+++ b/include/net/ip_vs.h
@@ -786,51 +786,48 @@ struct ip_vs_conn_param {
__u8 pe_data_len;
};
+/* Hash node in conn_tab */
+struct ip_vs_conn_hnode {
+ struct hlist_bl_node node; /*... |
1ac252ad036cdb18f5fb7f76bb6061adfed9cedf | Analyze and fix the following issue in the Linux kernel code: rculist_bl: add hlist_bl_for_each_entry_continue_rcu | Problem Details:
Change the old hlist_bl_first_rcu to hlist_bl_first_rcu_dereference
to indicate that it is a RCU dereference.
Add hlist_bl_next_rcu and hlist_bl_first_rcu to use RCU pointers
and use them to fix sparse warnings.
Add hlist_bl_for_each_entry_continue_rcu.
Signed-off-by: Julian Anastasov <ja@ssi.bg>
Si... | ```diff
diff --git a/include/linux/rculist_bl.h b/include/linux/rculist_bl.h
index 0b952d06eb0b..36363b876e53 100644
--- a/include/linux/rculist_bl.h
+++ b/include/linux/rculist_bl.h
@@ -8,21 +8,31 @@
#include <linux/list_bl.h>
#include <linux/rcupdate.h>
+/* return the first ptr or next element in an RCU protected... |
f462fdf3d6a405ada5cf51241d56a47ead152968 | Analyze and fix the following issue in the Linux kernel code: ntfs: reduce stack usage in ntfs_write_mft_block() | Problem Details:
The use of two large arrays in this function makes the stack frame exceed
the warning limit in some configurations, especially with KASAN enabled.
When CONFIG_PAGE_SIZE is set to 65536, each of the arrays contains 128
pointers, so the combined size is 2KB:
fs/ntfs/mft.c: In function 'ntfs_write_mft_bl... | ```diff
diff --git a/fs/ntfs/mft.c b/fs/ntfs/mft.c
index 6d88922ddba9..b313793a397c 100644
--- a/fs/ntfs/mft.c
+++ b/fs/ntfs/mft.c
@@ -2704,9 +2704,11 @@ static int ntfs_write_mft_block(struct folio *folio, struct writeback_control *w
struct ntfs_inode *ni = NTFS_I(vi);
struct ntfs_volume *vol = ni->vol;
u8 *kadd... |
a58d487fb1a52579d3c37544ea371da78ed70c45 | Analyze and fix the following issue in the Linux kernel code: drm/ttm/tests: Fix build failure on PREEMPT_RT | Problem Details:
Fix a compile error in the kunit tests when CONFIG_PREEMPT_RT is
enabled, and the normal mutex is converted into a rtmutex.
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202602261547.3bM6yVAS-lkp@intel.com/
Reviewed-by: Jouni Högander <jouni.hogander@inte... | ```diff
diff --git a/drivers/gpu/drm/ttm/tests/ttm_bo_test.c b/drivers/gpu/drm/ttm/tests/ttm_bo_test.c
index d468f8322072..f3103307b5df 100644
--- a/drivers/gpu/drm/ttm/tests/ttm_bo_test.c
+++ b/drivers/gpu/drm/ttm/tests/ttm_bo_test.c
@@ -222,13 +222,13 @@ static void ttm_bo_reserve_interrupted(struct kunit *test)
K... |
3dce5bb82c97fc2ac28d80d496120a6525ce3fb7 | Analyze and fix the following issue in the Linux kernel code: exfat: Fix bitwise operation having different size | Problem Details:
cpos has type loff_t (long long), while s_blocksize has type u32. The
inversion wil happen on u32, the coercion to s64 happens afterwards and
will do 0-left-paddding, resulting in the upper bits getting masked out.
Cast s_blocksize to loff_t before negating it.
Found by static code analysis using Klo... | ```diff
diff --git a/fs/exfat/dir.c b/fs/exfat/dir.c
index 3a4853693d8b..e710dd196e2f 100644
--- a/fs/exfat/dir.c
+++ b/fs/exfat/dir.c
@@ -249,7 +249,7 @@ get_new:
*/
if (err == -EIO) {
cpos += 1 << (sb->s_blocksize_bits);
- cpos &= ~(sb->s_blocksize - 1);
+ cpos &= ~(loff_t)(sb->s_blocksize - 1);
}
... |
0fb59eaca18f1254ecdce34354eec3cb1b3b5e10 | Analyze and fix the following issue in the Linux kernel code: pmdomain: rockchip: Fix PD_VCODEC for RK3588 | Problem Details:
>From the RK3588 TRM Table 7-1 RK3588 Voltage Domain and Power Domain Summary,
PD_RKVDEC0/1 and PD_VENC0/1 rely on VD_VCODEC which require extra voltages to
be applied, otherwise it breaks RK3588-evb1-v10 board after vdec support landed[1].
The panic looks like below:
rockchip-pm-domain fd8d8000.pow... | ```diff
diff --git a/drivers/pmdomain/rockchip/pm-domains.c b/drivers/pmdomain/rockchip/pm-domains.c
index 997e93c12951..44d34840ede7 100644
--- a/drivers/pmdomain/rockchip/pm-domains.c
+++ b/drivers/pmdomain/rockchip/pm-domains.c
@@ -1311,7 +1311,7 @@ static const struct rockchip_domain_info rk3576_pm_domains[] = {
s... |
6432f15c818cb30eec7c4ca378ecdebd9796f741 | Analyze and fix the following issue in the Linux kernel code: mm/slab: change stride type from unsigned short to unsigned int | Problem Details:
Commit 7a8e71bc619d ("mm/slab: use stride to access slabobj_ext")
defined the type of slab->stride as unsigned short, because the author
initially planned to store stride within the lower 16 bits of the
page_type field, but later stored it in unused bits in the counters
field instead.
However, the ide... | ```diff
diff --git a/mm/slab.h b/mm/slab.h
index f6ef862b60ef..e9ab292acd22 100644
--- a/mm/slab.h
+++ b/mm/slab.h
@@ -59,7 +59,7 @@ struct freelist_counters {
* to save memory. In case ->stride field is not available,
* such optimizations are disabled.
*/
- unsigned short stride;
+ unsigne... |
fb1091febd668398aa84c161b8d9a1834321e021 | Analyze and fix the following issue in the Linux kernel code: mm/slab: allow sheaf refill if blocking is not allowed | Problem Details:
Ming Lei reported [1] a regression in the ublk null target benchmark due
to sheaves. The profile shows that the alloc_from_pcs() fastpath fails
and allocations fall back to ___slab_alloc(). It also shows the
allocations happen through mempool_alloc().
The strategy of mempool_alloc() is to call the und... | ```diff
diff --git a/mm/slub.c b/mm/slub.c
index b1e9f16ba435..20cb4f3b636d 100644
--- a/mm/slub.c
+++ b/mm/slub.c
@@ -4567,7 +4567,7 @@ __pcs_replace_empty_main(struct kmem_cache *s, struct slub_percpu_sheaves *pcs,
struct slab_sheaf *empty = NULL;
struct slab_sheaf *full;
struct node_barn *barn;
- bool can_allo... |
144d47f9053634a9587c4ce217c8d7672934f38d | Analyze and fix the following issue in the Linux kernel code: drm/imagination: Ensure struct pvr_device->power is initialized | Problem Details:
When pvr_power_domains_init() handles <=1 power domains, the content of
struct pvr_device->power was previously left uninitialized.
Fixes: e19cc5ab347e3 ("drm/imagination: Use dev_pm_domain_attach_list()")
Reviewed-by: Alessio Belle <alessio.belle@imgtec.com>
Link: https://patch.msgid.link/20260227-si... | ```diff
diff --git a/drivers/gpu/drm/imagination/pvr_power.c b/drivers/gpu/drm/imagination/pvr_power.c
index 5a1fda685f2c..7a8765c0c1ed 100644
--- a/drivers/gpu/drm/imagination/pvr_power.c
+++ b/drivers/gpu/drm/imagination/pvr_power.c
@@ -598,8 +598,8 @@ int pvr_power_domains_init(struct pvr_device *pvr_dev)
struct d... |
218ea788a69308008c233381605a4b18cc140a5e | Analyze and fix the following issue in the Linux kernel code: drm/imagination: Detach pm domains if linking fails | Problem Details:
There's a missing call to dev_pm_domain_detach_list() in the error path of
pvr_power_domains_init(); if creating the second stage of device links
fails then the struct dev_pm_domain_list will be left dangling.
Fixes: e19cc5ab347e3 ("drm/imagination: Use dev_pm_domain_attach_list()")
Reviewed-by: Aless... | ```diff
diff --git a/drivers/gpu/drm/imagination/pvr_power.c b/drivers/gpu/drm/imagination/pvr_power.c
index be8018085b2d..5a1fda685f2c 100644
--- a/drivers/gpu/drm/imagination/pvr_power.c
+++ b/drivers/gpu/drm/imagination/pvr_power.c
@@ -661,6 +661,8 @@ err_unlink:
while (--i >= 0)
device_link_del(domain_links[i]... |
713ec926d8256d5989043ec95620b88a79924aa3 | Analyze and fix the following issue in the Linux kernel code: drm/imagination: Check for NULL struct dev_pm_domain_list | Problem Details:
While dev_pm_domain_detach_list() itself contains the necessary NULL check,
the access to struct dev_pm_domain_list->num_pds does not and thus faults
on devices with <=1 power domains (where the struct dev_pm_domain_list
machinery is skipped for simplicity).
This can be reproduced on AM625, which prod... | ```diff
diff --git a/drivers/gpu/drm/imagination/pvr_power.c b/drivers/gpu/drm/imagination/pvr_power.c
index 006a72ed5064..be8018085b2d 100644
--- a/drivers/gpu/drm/imagination/pvr_power.c
+++ b/drivers/gpu/drm/imagination/pvr_power.c
@@ -668,14 +668,16 @@ void pvr_power_domains_fini(struct pvr_device *pvr_dev)
{
st... |
f5c8f824a495e849492f09a43bd965a8f4d86cb2 | Analyze and fix the following issue in the Linux kernel code: drm/i915/psr: Fix for Panel Replay X granularity DPCD register handling | Problem Details:
DP specification is saying value 0xff 0xff in PANEL REPLAY SELECTIVE UPDATE
X GRANULARITY CAPABILITY registers (0xb2 and 0xb3) means full-line
granularity. Take this into account when handling Panel Replay X
granularity informed by the panel.
Fixes: 1cc854647450 ("drm/i915/psr: Use SU granularity info... | ```diff
diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c
index 5bea2eda744b..9296ca3a4ff4 100644
--- a/drivers/gpu/drm/i915/display/intel_psr.c
+++ b/drivers/gpu/drm/i915/display/intel_psr.c
@@ -1306,9 +1306,14 @@ static bool psr2_granularity_check(struct intel_crtc_state... |
aac9b27f7c1f2b2cf7f50a9ca633ecbbcaf22af9 | Analyze and fix the following issue in the Linux kernel code: ata: libata: cancel pending work after clearing deferred_qc | Problem Details:
Syzbot reported a WARN_ON() in ata_scsi_deferred_qc_work(), caused by
ap->ops->qc_defer() returning non-zero before issuing the deferred qc.
ata_scsi_schedule_deferred_qc() is called during each command completion.
This function will check if there is a deferred QC, and if
ap->ops->qc_defer() returns ... | ```diff
diff --git a/drivers/ata/libata-eh.c b/drivers/ata/libata-eh.c
index b373cceb95d2..563432400f72 100644
--- a/drivers/ata/libata-eh.c
+++ b/drivers/ata/libata-eh.c
@@ -659,6 +659,7 @@ void ata_scsi_cmd_error_handler(struct Scsi_Host *host, struct ata_port *ap,
*/
WARN_ON_ONCE(qc->flags & ATA_QCFLAG_ACTI... |
61ded1083b264ff67ca8c2de822c66b6febaf9a8 | Analyze and fix the following issue in the Linux kernel code: drm/sched: Fix kernel-doc warning for drm_sched_job_done() | Problem Details:
There is a kernel-doc warning for the scheduler:
Warning: drivers/gpu/drm/scheduler/sched_main.c:367 function parameter 'result' not described in 'drm_sched_job_done'
Fix the warning by describing the undocumented error code.
Fixes: 539f9ee4b52a ("drm/scheduler: properly forward fence errors")
Signe... | ```diff
diff --git a/drivers/gpu/drm/scheduler/sched_main.c b/drivers/gpu/drm/scheduler/sched_main.c
index e6ee35406165..2d5cb21a05b6 100644
--- a/drivers/gpu/drm/scheduler/sched_main.c
+++ b/drivers/gpu/drm/scheduler/sched_main.c
@@ -361,6 +361,7 @@ static void drm_sched_run_free_queue(struct drm_gpu_scheduler *sched)... |
e98266e823a1fa06fe6499df61aeaac2fd6f7a49 | Analyze and fix the following issue in the Linux kernel code: fs/ntfs3: prevent uninitialized lcn caused by zero len | Problem Details:
syzbot reported a uninit-value in ntfs_iomap_begin [1].
Since runs was not touched yet, run_lookup_entry() immediately fails
and returns false, which makes the value of "*len" 0.
Simultaneously, the new value and err value are also 0, causing the
logic in attr_data_get_block_locked() to jump directly ... | ```diff
diff --git a/fs/ntfs3/inode.c b/fs/ntfs3/inode.c
index 398913595a55..733d4c86edba 100644
--- a/fs/ntfs3/inode.c
+++ b/fs/ntfs3/inode.c
@@ -827,6 +827,11 @@ static int ntfs_iomap_begin(struct inode *inode, loff_t offset, loff_t length,
return err;
}
+ if (!clen) {
+ /* broken file? */
+ return -EINVAL;
... |
0ca1a8331c0fa5e57844e003a5d667a15b1e002c | Analyze and fix the following issue in the Linux kernel code: xfs: fix race between healthmon unmount and read_iter | Problem Details:
xfs/1879 on one of my test VMs got stuck due to the xfs_io healthmon
subcommand sleeping in wait_event_interruptible at:
xfs_healthmon_read_iter+0x558/0x5f8 [xfs]
vfs_read+0x248/0x320
ksys_read+0x78/0x120
Looking at xfs_healthmon_read_iter, in !O_NONBLOCK mode it will sleep
until the mount cookie ... | ```diff
diff --git a/fs/xfs/xfs_healthmon.c b/fs/xfs/xfs_healthmon.c
index 4a06d6632f65..26c325d34bd1 100644
--- a/fs/xfs/xfs_healthmon.c
+++ b/fs/xfs/xfs_healthmon.c
@@ -141,6 +141,16 @@ xfs_healthmon_detach(
hm->mount_cookie = DETACHED_MOUNT_COOKIE;
spin_unlock(&xfs_healthmon_lock);
+ /*
+ * Wake up any reader... |
6270b8ac2f41858952074b23c2d3d9aa2fe1bfa9 | Analyze and fix the following issue in the Linux kernel code: xfs: remove scratch field from struct xfs_gc_bio | Problem Details:
The scratch field in struct xfs_gc_bio is unused. Remove it.
Fixes: 102f444b57b3 ("xfs: rework zone GC buffer management")
Signed-off-by: Damien Le Moal <dlemoal@kernel.org>
Reviewed-by: Carlos Maiolino <cmaiolino@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Darrick J. Wong <dj... | ```diff
diff --git a/fs/xfs/xfs_zone_gc.c b/fs/xfs/xfs_zone_gc.c
index 7efeecd2d85f..309f70098524 100644
--- a/fs/xfs/xfs_zone_gc.c
+++ b/fs/xfs/xfs_zone_gc.c
@@ -96,7 +96,6 @@ struct xfs_gc_bio {
*/
xfs_fsblock_t old_startblock;
xfs_daddr_t new_daddr;
- struct xfs_zone_scratch *scratch;
/* Are we writi... |
b3b1d3ae1d87bc9398fb715c945968bf4c75a09a | Analyze and fix the following issue in the Linux kernel code: ata: libata-core: Disable LPM on ST1000DM010-2EP102 | Problem Details:
According to a user report, the ST1000DM010-2EP102 has problems with LPM,
causing random system freezes. The drive belongs to the same BarraCuda
family as the ST2000DM008-2FR102 which has the same issue.
Cc: stable@vger.kernel.org
Fixes: 7627a0edef54 ("ata: ahci: Drop low power policy board type")
Rep... | ```diff
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
index ccbf320524da..76b012f544ea 100644
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
@@ -4189,6 +4189,7 @@ static const struct ata_dev_quirks_entry __ata_dev_quirks[] = {
ATA_QUIRK_FIRMWARE_WARN },
/* Seagate disks ... |
5c3daa5301693d2e5364483a3405649a0fdaed98 | Analyze and fix the following issue in the Linux kernel code: power: sequencing: pcie-m2: Fix device node reference leak in probe | Problem Details:
In pwrseq_pcie_m2_probe(), ctx->of_node acquires an explicit reference
to the device node using of_node_get(), but there is no corresponding
of_node_put() in the driver's error handling paths or removal.
Since the ctx is tied to the lifecycle of the platform device, there
is no need to hold an additio... | ```diff
diff --git a/drivers/power/sequencing/pwrseq-pcie-m2.c b/drivers/power/sequencing/pwrseq-pcie-m2.c
index d31a7dd8b35c..dadb4aad9d5d 100644
--- a/drivers/power/sequencing/pwrseq-pcie-m2.c
+++ b/drivers/power/sequencing/pwrseq-pcie-m2.c
@@ -109,7 +109,7 @@ static int pwrseq_pcie_m2_probe(struct platform_device *p... |
a08aaf3968aec5d05cd32c801b8cc0c61da69c41 | Analyze and fix the following issue in the Linux kernel code: RDMA/ionic: Preserve and set Ethernet source MAC after ib_ud_header_init() | Problem Details:
ionic_build_hdr() populated the Ethernet source MAC (hdr->eth.smac_h) by
passing the header’s storage directly to rdma_read_gid_l2_fields().
However, ib_ud_header_init() is called after that and re-initializes the
UD header, which wipes the previously written smac_h. As a result, packets
are emitted wi... | ```diff
diff --git a/drivers/infiniband/hw/ionic/ionic_controlpath.c b/drivers/infiniband/hw/ionic/ionic_controlpath.c
index 4842931f5316..a5671da3db64 100644
--- a/drivers/infiniband/hw/ionic/ionic_controlpath.c
+++ b/drivers/infiniband/hw/ionic/ionic_controlpath.c
@@ -508,6 +508,7 @@ static int ionic_build_hdr(struct... |
29a3edd7004bb635d299fb9bc6f0ea4ef13ed5a2 | Analyze and fix the following issue in the Linux kernel code: RDMA/irdma: Fix double free related to rereg_user_mr | Problem Details:
If IB_MR_REREG_TRANS is set during rereg_user_mr, the
umem will be released and a new one will be allocated
in irdma_rereg_mr_trans. If any step of irdma_rereg_mr_trans
fails after the new umem is allocated, it releases the umem,
but does not set iwmr->region to NULL. The problem is that
this failure i... | ```diff
diff --git a/drivers/infiniband/hw/irdma/verbs.c b/drivers/infiniband/hw/irdma/verbs.c
index 7251cd7a2147..a20d25585993 100644
--- a/drivers/infiniband/hw/irdma/verbs.c
+++ b/drivers/infiniband/hw/irdma/verbs.c
@@ -3723,6 +3723,7 @@ static int irdma_rereg_mr_trans(struct irdma_mr *iwmr, u64 start, u64 len,
e... |
d799984233a50abd2667a7d17a9a710a3f10ebe2 | Analyze and fix the following issue in the Linux kernel code: PCI: endpoint: pci-epf-vntb: Stop cmd_handler work in epf_ntb_epc_cleanup | Problem Details:
Disable the delayed work before clearing BAR mappings and doorbells to
avoid running the handler after resources have been torn down.
Unable to handle kernel paging request at virtual address ffff800083f46004
[...]
Internal error: Oops: 0000000096000007 [#1] SMP
[...]
Call trace:
epf_ntb... | ```diff
diff --git a/drivers/pci/endpoint/functions/pci-epf-vntb.c b/drivers/pci/endpoint/functions/pci-epf-vntb.c
index 42c870ee3956..805353528967 100644
--- a/drivers/pci/endpoint/functions/pci-epf-vntb.c
+++ b/drivers/pci/endpoint/functions/pci-epf-vntb.c
@@ -942,6 +942,7 @@ err_config_interrupt:
*/
static void e... |
3446beddba450c8d6f9aca2f028712ac527fead3 | Analyze and fix the following issue in the Linux kernel code: PCI: endpoint: pci-epf-ntb: Remove duplicate resource teardown | Problem Details:
epf_ntb_epc_destroy() duplicates the teardown that the caller is
supposed to do later. This leads to an oops when .allow_link fails or
when .drop_link is performed. Remove the helper.
Also drop pci_epc_put(). EPC device refcounting is tied to configfs EPC
group lifetime, and pci_epc_put() in the .drop... | ```diff
diff --git a/drivers/pci/endpoint/functions/pci-epf-ntb.c b/drivers/pci/endpoint/functions/pci-epf-ntb.c
index a3a588e522e7..2bdcc35b652c 100644
--- a/drivers/pci/endpoint/functions/pci-epf-ntb.c
+++ b/drivers/pci/endpoint/functions/pci-epf-ntb.c
@@ -1494,47 +1494,6 @@ err_alloc_peer_mem:
return ret;
}
-/*... |
0da63230d3ec1ec5fcc443a2314233e95bfece54 | Analyze and fix the following issue in the Linux kernel code: PCI: endpoint: pci-epf-vntb: Remove duplicate resource teardown | Problem Details:
epf_ntb_epc_destroy() duplicates the teardown that the caller is
supposed to perform later. This leads to an oops when .allow_link fails
or when .drop_link is performed. The following is an example oops of the
former case:
Unable to handle kernel paging request at virtual address dead000000000108
... | ```diff
diff --git a/drivers/pci/endpoint/functions/pci-epf-vntb.c b/drivers/pci/endpoint/functions/pci-epf-vntb.c
index 148a3b160812..42c870ee3956 100644
--- a/drivers/pci/endpoint/functions/pci-epf-vntb.c
+++ b/drivers/pci/endpoint/functions/pci-epf-vntb.c
@@ -763,19 +763,6 @@ static void epf_ntb_mw_bar_clear(struct ... |
6910944bf0b92fea63d5a7aeed69e4b9c14fd01b | Analyze and fix the following issue in the Linux kernel code: perf test type profiling: Remote typedef on struct | Problem Details:
The typedef creates an issue where the struct or the typedef may
appear in the output and cause the "perf data type profiling tests" to
fail. Let's remove the typedef to keep the test passing.
Fixes: 335047109d7d ("perf tests: Test annotate with data type profiling and C")
Signed-off-by: Ian Rogers <i... | ```diff
diff --git a/tools/perf/tests/shell/data_type_profiling.sh b/tools/perf/tests/shell/data_type_profiling.sh
index 2a7f8f7c42d0..fb47b7213b33 100755
--- a/tools/perf/tests/shell/data_type_profiling.sh
+++ b/tools/perf/tests/shell/data_type_profiling.sh
@@ -8,7 +8,7 @@ set -e
# data type profiling manifestation
... |
fbdfa8da05b6ae44114fc4f9b3e83e1736fd411c | Analyze and fix the following issue in the Linux kernel code: selftests: tc-testing: fix list_categories() crash on list type | Problem Details:
list_categories() builds a set directly from the 'category'
field of each test case. Since 'category' is a list,
set(map(...)) attempts to insert lists into a set, which
raises:
TypeError: unhashable type: 'list'
Flatten category lists and collect unique category names
using set.update() instead.
... | ```diff
diff --git a/tools/testing/selftests/tc-testing/tdc_helper.py b/tools/testing/selftests/tc-testing/tdc_helper.py
index 0440d252c4c5..bc447ca57333 100644
--- a/tools/testing/selftests/tc-testing/tdc_helper.py
+++ b/tools/testing/selftests/tc-testing/tdc_helper.py
@@ -38,10 +38,14 @@ def list_test_cases(testlist)... |
04e707cb77c272cb0bb2e2e3c5c7f844d804a089 | Analyze and fix the following issue in the Linux kernel code: powerpc/crash: adjust the elfcorehdr size | Problem Details:
With crash hotplug support enabled, additional memory is allocated to
the elfcorehdr kexec segment to accommodate resources added during
memory hotplug events. However, the kdump FDT is not updated with the
same size, which can result in elfcorehdr corruption in the kdump
kernel.
Update elf_headers_sz... | ```diff
diff --git a/arch/powerpc/kexec/file_load_64.c b/arch/powerpc/kexec/file_load_64.c
index e7ef8b2a2554..5f6d50e4c3d4 100644
--- a/arch/powerpc/kexec/file_load_64.c
+++ b/arch/powerpc/kexec/file_load_64.c
@@ -450,6 +450,11 @@ static int load_elfcorehdr_segment(struct kimage *image, struct kexec_buf *kbuf)
kbuf-... |
20197b967a6a29dab81495f25a988515bda84cfe | Analyze and fix the following issue in the Linux kernel code: powerpc/kexec/core: use big-endian types for crash variables | Problem Details:
Use explicit word-sized big-endian types for kexec and crash related
variables. This makes the endianness unambiguous and avoids type
mismatches that trigger sparse warnings.
The change addresses sparse warnings like below (seen on both 32-bit
and 64-bit builds):
CHECK ../arch/powerpc/kexec/core.c
... | ```diff
diff --git a/arch/powerpc/kexec/core.c b/arch/powerpc/kexec/core.c
index 104c05520bf0..dc44f11be353 100644
--- a/arch/powerpc/kexec/core.c
+++ b/arch/powerpc/kexec/core.c
@@ -23,6 +23,7 @@
#include <asm/firmware.h>
#define cpu_to_be_ulong __PASTE(cpu_to_be, BITS_PER_LONG)
+#define __be_word __PASTE(__be, BI... |
0ee95a1d458630272d0415d0ffa9424fcb606c90 | Analyze and fix the following issue in the Linux kernel code: powerpc/uaccess: Fix inline assembly for clang build on PPC32 | Problem Details:
Test robot reports the following error with clang-16.0.6:
In file included from kernel/rseq.c:75:
include/linux/rseq_entry.h:141:3: error: invalid operand for instruction
unsafe_get_user(offset, &ucs->post_commit_offset, efault);
^
include/linux/uaccess.h... | ```diff
diff --git a/arch/powerpc/include/asm/uaccess.h b/arch/powerpc/include/asm/uaccess.h
index ba1d878c3f40..570b3d91e2e4 100644
--- a/arch/powerpc/include/asm/uaccess.h
+++ b/arch/powerpc/include/asm/uaccess.h
@@ -255,7 +255,7 @@ __gus_failed: \
".section .fixup,\"ax\"\n" \
"4: li %0,%3\n" \
" l... |
e39bb9e02b68942f8e9359d2a3efe7d37ae6be0e | Analyze and fix the following issue in the Linux kernel code: tracing: Fix WARN_ON in tracing_buffers_mmap_close | Problem Details:
When a process forks, the child process copies the parent's VMAs but the
user_mapped reference count is not incremented. As a result, when both the
parent and child processes exit, tracing_buffers_mmap_close() is called
twice. On the second call, user_mapped is already 0, causing the function to
return... | ```diff
diff --git a/include/linux/ring_buffer.h b/include/linux/ring_buffer.h
index 876358cfe1b1..d862fa610270 100644
--- a/include/linux/ring_buffer.h
+++ b/include/linux/ring_buffer.h
@@ -248,6 +248,7 @@ int trace_rb_cpu_prepare(unsigned int cpu, struct hlist_node *node);
int ring_buffer_map(struct trace_buffer *... |
a5dd6f58666f22ae16b98a2177bebc3340d38fe9 | Analyze and fix the following issue in the Linux kernel code: tracing: Disable preemption in the tracepoint callbacks handling filtered pids | Problem Details:
Filtering PIDs for events triggered the following during selftests:
[37] event tracing - restricts events based on pid notrace filtering
[ 155.874095]
[ 155.874869] =============================
[ 155.876037] WARNING: suspicious RCU usage
[ 155.877287] 7.0.0-rc1-00004-g8cd473a19bc7 #7 Not tainted
... | ```diff
diff --git a/kernel/trace/trace_events.c b/kernel/trace/trace_events.c
index 9c7f26cbe171..b7343fdfd7b0 100644
--- a/kernel/trace/trace_events.c
+++ b/kernel/trace/trace_events.c
@@ -1039,6 +1039,7 @@ event_filter_pid_sched_process_exit(void *data, struct task_struct *task)
struct trace_pid_list *pid_list;
... |
cc337974cd1084f9821179eb66f4e470d9fd2ed8 | Analyze and fix the following issue in the Linux kernel code: ftrace: Disable preemption in the tracepoint callbacks handling filtered pids | Problem Details:
When function trace PID filtering is enabled, the function tracer will
attach a callback to the fork tracepoint as well as the exit tracepoint
that will add the forked child PID to the PID filtering list as well as
remove the PID that is exiting.
Commit a46023d5616e ("tracing: Guard __DECLARE_TRACE() ... | ```diff
diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
index 827fb9a0bf0d..2f72af0357e5 100644
--- a/kernel/trace/ftrace.c
+++ b/kernel/trace/ftrace.c
@@ -8611,6 +8611,7 @@ ftrace_pid_follow_sched_process_fork(void *data,
struct trace_pid_list *pid_list;
struct trace_array *tr = data;
+ guard(preempt)... |
0a663b764dbdf135a126284f454c9f01f95a87d4 | Analyze and fix the following issue in the Linux kernel code: tracing: Fix syscall events activation by ensuring refcount hits zero | Problem Details:
When multiple syscall events are specified in the kernel command line
(e.g., trace_event=syscalls:sys_enter_openat,syscalls:sys_enter_close),
they are often not captured after boot, even though they appear enabled
in the tracing/set_event file.
The issue stems from how syscall events are initialized. ... | ```diff
diff --git a/kernel/trace/trace_events.c b/kernel/trace/trace_events.c
index 9928da636c9d..9c7f26cbe171 100644
--- a/kernel/trace/trace_events.c
+++ b/kernel/trace/trace_events.c
@@ -4668,26 +4668,22 @@ static __init int event_trace_memsetup(void)
return 0;
}
-__init void
-early_enable_events(struct trace_... |
b96d0c59cdbb2a22b2545f6f3d5c6276b05761dd | Analyze and fix the following issue in the Linux kernel code: fgraph: Fix thresh_return nosleeptime double-adjust | Problem Details:
trace_graph_thresh_return() called handle_nosleeptime() and then delegated
to trace_graph_return(), which calls handle_nosleeptime() again. When
sleep-time accounting is disabled this double-adjusts calltime and can
produce bogus durations (including underflow).
Fix this by computing rettime once, app... | ```diff
diff --git a/kernel/trace/trace_functions_graph.c b/kernel/trace/trace_functions_graph.c
index 817d0f1696b6..0d2d3a2ea7dd 100644
--- a/kernel/trace/trace_functions_graph.c
+++ b/kernel/trace/trace_functions_graph.c
@@ -403,8 +403,12 @@ static void trace_graph_thresh_return(struct ftrace_graph_ret *trace,
unsi... |
6ca8379b5d36e22b04e6315c3e49a6083377c862 | Analyze and fix the following issue in the Linux kernel code: fgraph: Fix thresh_return clear per-task notrace | Problem Details:
When tracing_thresh is enabled, function graph tracing uses
trace_graph_thresh_return() as the return handler. Unlike
trace_graph_return(), it did not clear the per-task TRACE_GRAPH_NOTRACE
flag set by the entry handler for set_graph_notrace addresses. This could
leave the task permanently in "notrace"... | ```diff
diff --git a/kernel/trace/trace_functions_graph.c b/kernel/trace/trace_functions_graph.c
index 3d8239fee004..817d0f1696b6 100644
--- a/kernel/trace/trace_functions_graph.c
+++ b/kernel/trace/trace_functions_graph.c
@@ -400,14 +400,15 @@ static void trace_graph_thresh_return(struct ftrace_graph_ret *trace,
... |
26bc83b88bbbf054f0980a4a42047a8d1e210e4c | Analyze and fix the following issue in the Linux kernel code: smb: client: Compare MACs in constant time | Problem Details:
To prevent timing attacks, MAC comparisons need to be constant-time.
Replace the memcmp() with the correct function, crypto_memneq().
Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Cc: stable@vger.kernel.org
Acked-by: Paulo Alcantara (Red Hat) <pc@manguebit.org>
Signed-off-by: Eric Biggers <ebiggers@kernel.... | ```diff
diff --git a/fs/smb/client/smb1encrypt.c b/fs/smb/client/smb1encrypt.c
index 0dbbce2431ff..bf10fdeeedca 100644
--- a/fs/smb/client/smb1encrypt.c
+++ b/fs/smb/client/smb1encrypt.c
@@ -11,6 +11,7 @@
#include <linux/fips.h>
#include <crypto/md5.h>
+#include <crypto/utils.h>
#include "cifsproto.h"
#include "s... |
9e7dc228bb6d4afa74dd6bab4f3aad43126cc2db | Analyze and fix the following issue in the Linux kernel code: io_uring/mock: Fix typo in help text | Problem Details:
Fix the spelling of "subsystem".
Signed-off-by: J. Neuschäfer <j.ne@posteo.net>
Signed-off-by: Jens Axboe <axboe@kernel.dk> | ```diff
diff --git a/init/Kconfig b/init/Kconfig
index e95d43457851..74f07212db85 100644
--- a/init/Kconfig
+++ b/init/Kconfig
@@ -1897,7 +1897,7 @@ config IO_URING_MOCK_FILE
default n
depends on IO_URING
help
- Enable mock files for io_uring subststem testing. The ABI might
+ Enable mock files for io_uring s... |
46d0d6f50dab706637f4c18a470aac20a21900d3 | Analyze and fix the following issue in the Linux kernel code: net/tcp-md5: Fix MAC comparison to be constant-time | Problem Details:
To prevent timing attacks, MACs need to be compared in constant
time. Use the appropriate helper function for this.
Fixes: cfb6eeb4c860 ("[TCP]: MD5 Signature Option (RFC2385) support.")
Fixes: 658ddaaf6694 ("tcp: md5: RST: getting md5 key from listener")
Cc: stable@vger.kernel.org
Signed-off-by: Eri... | ```diff
diff --git a/net/ipv4/Kconfig b/net/ipv4/Kconfig
index 3ab6247be585..df922f9f5289 100644
--- a/net/ipv4/Kconfig
+++ b/net/ipv4/Kconfig
@@ -762,6 +762,7 @@ config TCP_AO
config TCP_MD5SIG
bool "TCP: MD5 Signature Option support (RFC2385)"
select CRYPTO_LIB_MD5
+ select CRYPTO_LIB_UTILS
help
RFC2385 sp... |
e2f27363aa6d983504c6836dd0975535e2e9dba0 | Analyze and fix the following issue in the Linux kernel code: amd-xgbe: fix sleep while atomic on suspend/resume | Problem Details:
The xgbe_powerdown() and xgbe_powerup() functions use spinlocks
(spin_lock_irqsave) while calling functions that may sleep:
- napi_disable() can sleep waiting for NAPI polling to complete
- flush_workqueue() can sleep waiting for pending work items
This causes a "BUG: scheduling while atomic" error du... | ```diff
diff --git a/drivers/net/ethernet/amd/xgbe/xgbe-drv.c b/drivers/net/ethernet/amd/xgbe/xgbe-drv.c
index 62bb4b8a68e1..8b79d88480db 100644
--- a/drivers/net/ethernet/amd/xgbe/xgbe-drv.c
+++ b/drivers/net/ethernet/amd/xgbe/xgbe-drv.c
@@ -1120,7 +1120,6 @@ int xgbe_powerdown(struct net_device *netdev, unsigned int ... |
5af6e8b54927f7a8d3c7fd02b1bdc09e93d5c079 | Analyze and fix the following issue in the Linux kernel code: netconsole: fix sysdata_release_enabled_show checking wrong flag | Problem Details:
sysdata_release_enabled_show() checks SYSDATA_TASKNAME instead of
SYSDATA_RELEASE, causing the configfs release_enabled attribute to
reflect the taskname feature state rather than the release feature
state. This is a copy-paste error from the adjacent
sysdata_taskname_enabled_show() function.
The corr... | ```diff
diff --git a/drivers/net/netconsole.c b/drivers/net/netconsole.c
index 2db116fb1a7c..3c9acd6e49e8 100644
--- a/drivers/net/netconsole.c
+++ b/drivers/net/netconsole.c
@@ -617,7 +617,7 @@ static ssize_t sysdata_release_enabled_show(struct config_item *item,
bool release_enabled;
dynamic_netconsole_mutex_lo... |
4ee7fa6cf78ff26d783d39e2949d14c4c1cd5e7f | Analyze and fix the following issue in the Linux kernel code: net: ipv4: fix ARM64 alignment fault in multipath hash seed | Problem Details:
`struct sysctl_fib_multipath_hash_seed` contains two u32 fields
(user_seed and mp_seed), making it an 8-byte structure with a 4-byte
alignment requirement.
In `fib_multipath_hash_from_keys()`, the code evaluates the entire
struct atomically via `READ_ONCE()`:
mp_seed = READ_ONCE(net->ipv4.sysctl_... | ```diff
diff --git a/include/net/ip_fib.h b/include/net/ip_fib.h
index b4495c38e0a0..318593743b6e 100644
--- a/include/net/ip_fib.h
+++ b/include/net/ip_fib.h
@@ -559,7 +559,7 @@ static inline u32 fib_multipath_hash_from_keys(const struct net *net,
siphash_aligned_key_t hash_key;
u32 mp_seed;
- mp_seed = READ_ONC... |
67edfec516d30d3e62925c397be4a1e5185802fc | Analyze and fix the following issue in the Linux kernel code: net/tcp-ao: Fix MAC comparison to be constant-time | Problem Details:
To prevent timing attacks, MACs need to be compared in constant
time. Use the appropriate helper function for this.
Fixes: 0a3a809089eb ("net/tcp: Verify inbound TCP-AO signed segments")
Cc: stable@vger.kernel.org
Signed-off-by: Eric Biggers <ebiggers@kernel.org>
Reviewed-by: Dmitry Safonov <0x7f454c... | ```diff
diff --git a/net/ipv4/Kconfig b/net/ipv4/Kconfig
index b71c22475c51..3ab6247be585 100644
--- a/net/ipv4/Kconfig
+++ b/net/ipv4/Kconfig
@@ -748,6 +748,7 @@ config TCP_SIGPOOL
config TCP_AO
bool "TCP: Authentication Option (RFC5925)"
select CRYPTO
+ select CRYPTO_LIB_UTILS
select TCP_SIGPOOL
depends on 6... |
2ffb4f5c2ccb2fa1c049dd11899aee7967deef5a | Analyze and fix the following issue in the Linux kernel code: ipv6: fix NULL pointer deref in ip6_rt_get_dev_rcu() | Problem Details:
l3mdev_master_dev_rcu() can return NULL when the slave device is being
un-slaved from a VRF. All other callers deal with this, but we lost
the fallback to loopback in ip6_rt_pcpu_alloc() -> ip6_rt_get_dev_rcu()
with commit 4832c30d5458 ("net: ipv6: put host and anycast routes on
device with address").
... | ```diff
diff --git a/net/ipv6/route.c b/net/ipv6/route.c
index 85df25c36409..7db0c837196c 100644
--- a/net/ipv6/route.c
+++ b/net/ipv6/route.c
@@ -1063,7 +1063,8 @@ static struct net_device *ip6_rt_get_dev_rcu(const struct fib6_result *res)
*/
if (netif_is_l3_slave(dev) &&
!rt6_need_strict(&res->f6i->fib6... |
e63f5918adb8efa7d9609585318db773ac7cd241 | Analyze and fix the following issue in the Linux kernel code: NFC: pn544: i2c: Replace strcpy() with strscpy() | Problem Details:
Replace strcpy() with strscpy() which limits the copy to the size of
the destination buffer. Since phy->firmware_name is an array, the
two-argument variant of strscpy() is used - the compiler deduces
the buffer size automatically.
This is a defensive cleanup. As pointed out by Jakub Kicinski
<kuba@ker... | ```diff
diff --git a/drivers/nfc/pn544/i2c.c b/drivers/nfc/pn544/i2c.c
index a0dfb3f98d5a..b31b5bef7187 100644
--- a/drivers/nfc/pn544/i2c.c
+++ b/drivers/nfc/pn544/i2c.c
@@ -526,7 +526,7 @@ static int pn544_hci_i2c_fw_download(void *phy_id, const char *firmware_name,
pr_info("Starting Firmware Download (%s)\n", fi... |
3ac88a9948792b092a4b11323e2abd1ecbe0cc68 | Analyze and fix the following issue in the Linux kernel code: rust: str: make NullTerminatedFormatter public | Problem Details:
If `CONFIG_BLOCK` is disabled, the following warnings are displayed
during build:
warning: struct `NullTerminatedFormatter` is never constructed
--> ../rust/kernel/str.rs:667:19
|
667 | pub(crate) struct NullTerminatedFormatter<'a> {
| ^^^^^^^^^^^^^^^^^^^^^^^
... | ```diff
diff --git a/rust/kernel/str.rs b/rust/kernel/str.rs
index fa87779d2253..3f8918764640 100644
--- a/rust/kernel/str.rs
+++ b/rust/kernel/str.rs
@@ -664,13 +664,13 @@ impl fmt::Write for Formatter<'_> {
///
/// * The first byte of `buffer` is always zero.
/// * The length of `buffer` is at least 1.
-pub(crate)... |
3aecb2e7b948400354399b26f3f1653bd2c1bae0 | Analyze and fix the following issue in the Linux kernel code: x86/tdx: Fix the typo in TDX_ATTR_MIGRTABLE | Problem Details:
The TD scoped TDCS attributes are defined by bit positions. In the guest
side of the TDX code, the 'tdx_attributes' string array holds pretty
print names for these attributes, which are generated via macros and
defines. Today these pretty print names are only used to print the
attribute names to dmesg.... | ```diff
diff --git a/arch/x86/coco/tdx/debug.c b/arch/x86/coco/tdx/debug.c
index cef847c8bb67..28990c2ab0a1 100644
--- a/arch/x86/coco/tdx/debug.c
+++ b/arch/x86/coco/tdx/debug.c
@@ -17,7 +17,7 @@ static __initdata const char *tdx_attributes[] = {
DEF_TDX_ATTR_NAME(ICSSD),
DEF_TDX_ATTR_NAME(LASS),
DEF_TDX_ATTR_NA... |
9621b996e4db1dbc2b3dc5d5910b7d6179397320 | Analyze and fix the following issue in the Linux kernel code: smb/client: fix buffer size for smb311_posix_qinfo in SMB311_posix_query_info() | Problem Details:
SMB311_posix_query_info() is currently unused, but it may still be used in
some stable versions, so these changes are submitted as a separate patch.
Use `sizeof(struct smb311_posix_qinfo)` instead of sizeof its pointer,
so the allocated buffer matches the actual struct size.
Fixes: b1bc1874b885 ("smb... | ```diff
diff --git a/fs/smb/client/smb2pdu.c b/fs/smb/client/smb2pdu.c
index 04e361ed2356..8a1fcc097606 100644
--- a/fs/smb/client/smb2pdu.c
+++ b/fs/smb/client/smb2pdu.c
@@ -3996,7 +3996,7 @@ SMB311_posix_query_info(const unsigned int xid, struct cifs_tcon *tcon,
u64 persistent_fid, u64 volatile_fid,
struct sm... |
12c43a062acb0ac137fc2a4a106d4d084b8c5416 | Analyze and fix the following issue in the Linux kernel code: smb/client: fix buffer size for smb311_posix_qinfo in smb2_compound_op() | Problem Details:
Use `sizeof(struct smb311_posix_qinfo)` instead of sizeof its pointer,
so the allocated buffer matches the actual struct size.
Fixes: 6a5f6592a0b6 ("SMB311: Add support for query info using posix extensions (level 100)")
Reported-by: ChenXiaoSong <chenxiaosong@kylinos.cn>
Signed-off-by: ZhangGuoDong <... | ```diff
diff --git a/fs/smb/client/smb2inode.c b/fs/smb/client/smb2inode.c
index 195a38fd61e8..1c4663ed7e69 100644
--- a/fs/smb/client/smb2inode.c
+++ b/fs/smb/client/smb2inode.c
@@ -325,7 +325,7 @@ replay_again:
cfile->fid.volatile_fid,
SMB_FIND_FILE_POSIX_INFO,
SMB2_O_INFO_FILE, 0,
- ... |
48f7a50c027dd2abb9e7b8a6ecc8e531d87f2c21 | Analyze and fix the following issue in the Linux kernel code: stop_machine: Fix the documentation for a NULL cpus argument | Problem Details:
A recent refactoring of the kernel-docs for stop machine changed the
description of the cpus parameter from "NULL = any online cpu"
to "NULL = run on each online CPU".
However the callback is only executed on a single CPU, not all of them.
The old wording was a bit ambiguous and could have been read b... | ```diff
diff --git a/include/linux/stop_machine.h b/include/linux/stop_machine.h
index 72820503514c..01011113d226 100644
--- a/include/linux/stop_machine.h
+++ b/include/linux/stop_machine.h
@@ -99,7 +99,7 @@ static inline void print_stop_info(const char *log_lvl, struct task_struct *task
* stop_machine: freeze the m... |
56145d237385ca0e7ca9ff7b226aaf2eb8ef368b | Analyze and fix the following issue in the Linux kernel code: bpf: Fix a UAF issue in bpf_trampoline_link_cgroup_shim | Problem Details:
The root cause of this bug is that when 'bpf_link_put' reduces the
refcount of 'shim_link->link.link' to zero, the resource is considered
released but may still be referenced via 'tr->progs_hlist' in
'cgroup_shim_find'. The actual cleanup of 'tr->progs_hlist' in
'bpf_shim_tramp_link_release' is deferre... | ```diff
diff --git a/kernel/bpf/trampoline.c b/kernel/bpf/trampoline.c
index 84db9e658e52..f02254a21585 100644
--- a/kernel/bpf/trampoline.c
+++ b/kernel/bpf/trampoline.c
@@ -1002,10 +1002,8 @@ int bpf_trampoline_link_cgroup_shim(struct bpf_prog *prog,
mutex_lock(&tr->mutex);
shim_link = cgroup_shim_find(tr, bpf_... |
658342fd75b582cbb06544d513171c3d645faead | Analyze and fix the following issue in the Linux kernel code: power: supply: axp288_charger: Do not cancel work before initializing it | Problem Details:
Driver registered devm handler to cancel_work_sync() before even the
work was initialized, thus leading to possible warning from
kernel/workqueue.c on (!work->func) check, if the error path was hit
before the initialization happened.
Use devm_work_autocancel() on each work item independently, which
ha... | ```diff
diff --git a/drivers/power/supply/axp288_charger.c b/drivers/power/supply/axp288_charger.c
index ac05942e4e6a..ca52c2c82b2c 100644
--- a/drivers/power/supply/axp288_charger.c
+++ b/drivers/power/supply/axp288_charger.c
@@ -10,6 +10,7 @@
#include <linux/acpi.h>
#include <linux/bitops.h>
#include <linux/module... |
68e6343fbf54ef7dd6f3f94e93afa42a9fe0eaf7 | Analyze and fix the following issue in the Linux kernel code: power: supply: cpcap-battery: fix typo in config name | Problem Details:
Rename cpcap_battery_unkown_data to
cpcap_battery_unknown_data to correct a spelling mistake
in the identifier.
No functional change.
Signed-off-by: Jaime Saguillo Revilla <jaime.saguillo@gmail.com>
Link: https://patch.msgid.link/20260219212353.49416-1-jaime.saguillo@gmail.com
Signed-off-by: Sebastia... | ```diff
diff --git a/drivers/power/supply/cpcap-battery.c b/drivers/power/supply/cpcap-battery.c
index 507fdc1c866d..f58269c75509 100644
--- a/drivers/power/supply/cpcap-battery.c
+++ b/drivers/power/supply/cpcap-battery.c
@@ -387,7 +387,7 @@ static const struct cpcap_battery_config cpcap_battery_bw8x_data = {
* Safe... |
9a44949da669708f19d29141e65b3ac774d08f5a | Analyze and fix the following issue in the Linux kernel code: power: supply: max17042: avoid overflow when determining health | Problem Details:
If vmax has the default value of INT_MAX (e.g. because not specified in
DT), battery health is reported as over-voltage. This is because adding
any value to vmax (the vmax tolerance in this case) causes it to wrap
around, making it negative and smaller than the measured battery
voltage.
Avoid that by ... | ```diff
diff --git a/drivers/power/supply/max17042_battery.c b/drivers/power/supply/max17042_battery.c
index b9277f81a25d..39091fb31711 100644
--- a/drivers/power/supply/max17042_battery.c
+++ b/drivers/power/supply/max17042_battery.c
@@ -201,7 +201,7 @@ static int max17042_get_battery_health(struct max17042_chip *chip... |
e370b67c2ceb3e3c4577da0a882b1ede87ef485e | Analyze and fix the following issue in the Linux kernel code: power: supply: max17042: fix a comment typo (then -> than) | Problem Details:
Fix this trivial typo where than should be used instead of then.
Reviewed-by: Peter Griffin <peter.griffin@linaro.org>
Signed-off-by: André Draszik <andre.draszik@linaro.org>
Link: https://patch.msgid.link/20260302-max77759-fg-v3-4-3c5f01dbda23@linaro.org
Signed-off-by: Sebastian Reichel <sebastian.re... | ```diff
diff --git a/drivers/power/supply/max17042_battery.c b/drivers/power/supply/max17042_battery.c
index acea176101fa..07759d4fdc37 100644
--- a/drivers/power/supply/max17042_battery.c
+++ b/drivers/power/supply/max17042_battery.c
@@ -131,7 +131,7 @@ static int max17042_get_status(struct max17042_chip *chip, int *s... |
04bb8d0e5d1c8d5a9079b35b4e6f0868f734698b | Analyze and fix the following issue in the Linux kernel code: iio: ABI: fix current_trigger description | Problem Details:
Triggers exist under /sys/bus/iio/devices/, not under /sys/class/iio.
/sys/class/iio does not even exist. Use the current path.
Signed-off-by: Cosmin Tanislav <cosmin-gabriel.tanislav.xa@renesas.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> | ```diff
diff --git a/Documentation/ABI/testing/sysfs-bus-iio b/Documentation/ABI/testing/sysfs-bus-iio
index 5f87dcee78f7..4fc9f6bd4281 100644
--- a/Documentation/ABI/testing/sysfs-bus-iio
+++ b/Documentation/ABI/testing/sysfs-bus-iio
@@ -1428,7 +1428,7 @@ KernelVersion: 2.6.35
Contact: linux-iio@vger.kernel.org
Desc... |
b06ccbabe2506fd70b9167a644978b049150224a | Analyze and fix the following issue in the Linux kernel code: sched_ext: Fix starvation of scx_enable() under fair-class saturation | Problem Details:
During scx_enable(), the READY -> ENABLED task switching loop changes the
calling thread's sched_class from fair to ext. Since fair has higher
priority than ext, saturating fair-class workloads can indefinitely starve
the enable thread, hanging the system. This was introduced when the enable
path switc... | ```diff
diff --git a/kernel/sched/ext.c b/kernel/sched/ext.c
index eab6e09b6442..ba51969718f5 100644
--- a/kernel/sched/ext.c
+++ b/kernel/sched/ext.c
@@ -4975,20 +4975,30 @@ static int validate_ops(struct scx_sched *sch, const struct sched_ext_ops *ops)
return 0;
}
-static int scx_enable(struct sched_ext_ops *ops... |
554a1c34c11a057d01819ce9bb04653a8ffc8071 | Analyze and fix the following issue in the Linux kernel code: igc: Fix trigger of incorrect irq in igc_xsk_wakeup function | Problem Details:
This patch addresses the issue where the igc_xsk_wakeup function
was triggering an incorrect IRQ for tx-0 when the i226 is configured
with only 2 combined queues or in an environment with 2 active CPU cores.
This prevented XDP Zero-copy send functionality in such split IRQ
configurations.
The fix impl... | ```diff
diff --git a/drivers/net/ethernet/intel/igc/igc_main.c b/drivers/net/ethernet/intel/igc/igc_main.c
index 27e5c2109138..b2e8d0c0f827 100644
--- a/drivers/net/ethernet/intel/igc/igc_main.c
+++ b/drivers/net/ethernet/intel/igc/igc_main.c
@@ -6906,28 +6906,29 @@ static int igc_xdp_xmit(struct net_device *dev, int n... |
d4c13ab36273a8c318ba06799793cc1f5d9c6fa1 | Analyze and fix the following issue in the Linux kernel code: igb: Fix trigger of incorrect irq in igb_xsk_wakeup | Problem Details:
The current implementation in the igb_xsk_wakeup expects
the Rx and Tx queues to share the same irq. This would lead
to triggering of incorrect irq in split irq configuration.
This patch addresses this issue which could impact environments
with 2 active cpu cores
or when the number of queues is reduced... | ```diff
diff --git a/drivers/net/ethernet/intel/igb/igb_xsk.c b/drivers/net/ethernet/intel/igb/igb_xsk.c
index 30ce5fbb5b77..ce4a7b58cad2 100644
--- a/drivers/net/ethernet/intel/igb/igb_xsk.c
+++ b/drivers/net/ethernet/intel/igb/igb_xsk.c
@@ -524,6 +524,16 @@ bool igb_xmit_zc(struct igb_ring *tx_ring, struct xsk_buff_p... |
b84852170153671bb0fa6737a6e48370addd8e1a | Analyze and fix the following issue in the Linux kernel code: iavf: fix netdev->max_mtu to respect actual hardware limit | Problem Details:
iavf sets LIBIE_MAX_MTU as netdev->max_mtu, ignoring vf_res->max_mtu
from PF [1]. This allows setting an MTU beyond the actual hardware
limit, causing TX queue timeouts [2].
Set correct netdev->max_mtu using vf_res->max_mtu from the PF.
Note that currently PF drivers such as ice/i40e set the frame si... | ```diff
diff --git a/drivers/net/ethernet/intel/iavf/iavf_main.c b/drivers/net/ethernet/intel/iavf/iavf_main.c
index bceaf4b1b85d..86c1964f42e1 100644
--- a/drivers/net/ethernet/intel/iavf/iavf_main.c
+++ b/drivers/net/ethernet/intel/iavf/iavf_main.c
@@ -2793,7 +2793,22 @@ static void iavf_init_config_adapter(struct ia... |
636cc3bd12f499c74eaf5dc9a7d5b832f1bb24ed | Analyze and fix the following issue in the Linux kernel code: libie: don't unroll if fwlog isn't supported | Problem Details:
The libie_fwlog_deinit() function can be called during driver unload
even when firmware logging was never properly initialized. This led to call
trace:
[ 148.576156] Oops: Oops: 0000 [#1] SMP NOPTI
[ 148.576167] CPU: 80 UID: 0 PID: 12843 Comm: rmmod Kdump: loaded Not tainted 6.17.0-rc7next-queue-3oc... | ```diff
diff --git a/drivers/net/ethernet/intel/libie/fwlog.c b/drivers/net/ethernet/intel/libie/fwlog.c
index 79020d990859..4d0c8370386b 100644
--- a/drivers/net/ethernet/intel/libie/fwlog.c
+++ b/drivers/net/ethernet/intel/libie/fwlog.c
@@ -1049,6 +1049,10 @@ void libie_fwlog_deinit(struct libie_fwlog *fwlog)
{
in... |
fe868b499d16f55bbeea89992edb98043c9de416 | Analyze and fix the following issue in the Linux kernel code: ice: Fix memory leak in ice_set_ringparam() | Problem Details:
In ice_set_ringparam, tx_rings and xdp_rings are allocated before
rx_rings. If the allocation of rx_rings fails, the code jumps to
the done label leaking both tx_rings and xdp_rings. Furthermore, if
the setup of an individual Rx ring fails during the loop, the code jumps
to the free_tx label which rele... | ```diff
diff --git a/drivers/net/ethernet/intel/ice/ice_ethtool.c b/drivers/net/ethernet/intel/ice/ice_ethtool.c
index 29e341251754..b9be10b58856 100644
--- a/drivers/net/ethernet/intel/ice/ice_ethtool.c
+++ b/drivers/net/ethernet/intel/ice/ice_ethtool.c
@@ -3332,7 +3332,7 @@ process_rx:
rx_rings = kzalloc_objs(*rx_r... |
fb4903b3354aed4a2301180cf991226f896c87ed | Analyze and fix the following issue in the Linux kernel code: ice: fix retry for AQ command 0x06EE | Problem Details:
Executing ethtool -m can fail reporting a netlink I/O error while firmware
link management holds the i2c bus used to communicate with the module.
According to Intel(R) Ethernet Controller E810 Datasheet Rev 2.8 [1]
Section 3.3.10.4 Read/Write SFF EEPROM (0x06EE)
request should to be retried upon recei... | ```diff
diff --git a/drivers/net/ethernet/intel/ice/ice_common.c b/drivers/net/ethernet/intel/ice/ice_common.c
index fd32c318d3f5..ce11fea122d0 100644
--- a/drivers/net/ethernet/intel/ice/ice_common.c
+++ b/drivers/net/ethernet/intel/ice/ice_common.c
@@ -1816,6 +1816,7 @@ static bool ice_should_retry_sq_send_cmd(u16 op... |
326256c0a72d4877cec1d4df85357da106233128 | Analyze and fix the following issue in the Linux kernel code: ice: reintroduce retry mechanism for indirect AQ | Problem Details:
Add retry mechanism for indirect Admin Queue (AQ) commands. To do so we
need to keep the command buffer.
This technically reverts commit 43a630e37e25
("ice: remove unused buffer copy code in ice_sq_send_cmd_retry()"),
but combines it with a fix in the logic by using a kmemdup() call,
making it more ro... | ```diff
diff --git a/drivers/net/ethernet/intel/ice/ice_common.c b/drivers/net/ethernet/intel/ice/ice_common.c
index 74fe74225277..fd32c318d3f5 100644
--- a/drivers/net/ethernet/intel/ice/ice_common.c
+++ b/drivers/net/ethernet/intel/ice/ice_common.c
@@ -1841,6 +1841,7 @@ ice_sq_send_cmd_retry(struct ice_hw *hw, struct... |
eef33aa44935d001747ca97703c08dd6f9031162 | Analyze and fix the following issue in the Linux kernel code: ice: fix adding AQ LLDP filter for VF | Problem Details:
The referenced commit came from a misunderstanding of the FW LLDP filter
AQ (Admin Queue) command due to the error in the internal documentation.
Contrary to the assumptions in the original commit, VFs can be added and
deleted from this filter without any problems. Introduced dev_info message
proved to... | ```diff
diff --git a/drivers/net/ethernet/intel/ice/ice_common.c b/drivers/net/ethernet/intel/ice/ice_common.c
index 6cd63190f55d..74fe74225277 100644
--- a/drivers/net/ethernet/intel/ice/ice_common.c
+++ b/drivers/net/ethernet/intel/ice/ice_common.c
@@ -6391,7 +6391,7 @@ int ice_lldp_fltr_add_remove(struct ice_hw *hw,... |
f35043d0f973504e5f199be6287159dc5b373deb | Analyze and fix the following issue in the Linux kernel code: KVM: SVM: Serialize updates to global OS-Visible Workarounds variables | Problem Details:
Guard writes to the global osvw_status and osvw_len variables with a
spinlock to ensure enabling virtualization on multiple CPUs in parallel
doesn't effectively drop any writes due to writing back stale data. Don't
bother taking the lock when the boot CPU doesn't support the feature, as
that check is ... | ```diff
diff --git a/arch/x86/kvm/svm/svm.c b/arch/x86/kvm/svm/svm.c
index e0da247ee594..9d611bfbcc8c 100644
--- a/arch/x86/kvm/svm/svm.c
+++ b/arch/x86/kvm/svm/svm.c
@@ -77,6 +77,7 @@ static bool erratum_383_found __read_mostly;
* are published and we know what the new status bits are
*/
static uint64_t osvw_len ... |
3875ceb592d3cb23dc932165cc1eeb74cf4dc319 | Analyze and fix the following issue in the Linux kernel code: crypto: testmgr - Fix stale references to aes-generic | Problem Details:
Due to commit a2484474272e ("crypto: aes - Replace aes-generic with
wrapper around lib"), the "aes-generic" driver name has been replaced
with "aes-lib". Update a couple testmgr entries that were added
concurrently with this change.
Fixes: a22d48cbe558 ("crypto: testmgr - Add test vectors for authenc... | ```diff
diff --git a/crypto/testmgr.c b/crypto/testmgr.c
index 49b607f65f63..4985411dedae 100644
--- a/crypto/testmgr.c
+++ b/crypto/testmgr.c
@@ -4132,7 +4132,7 @@ static const struct alg_test_desc alg_test_descs[] = {
.fips_allowed = 1,
}, {
.alg = "authenc(hmac(sha224),cbc(aes))",
- .generic_driver = "authe... |
e4eb6e4dd6348dd00e19c2275e3fbaed304ca3bd | Analyze and fix the following issue in the Linux kernel code: drm/msm: Fix dma_free_attrs() buffer size | Problem Details:
The gpummu->table buffer is alloc'd with size TABLE_SIZE + 32 in
a2xx_gpummu_new() but freed with size TABLE_SIZE in
a2xx_gpummu_destroy().
Change the free size to match the allocation.
Fixes: c2052a4e5c99 ("drm/msm: implement a2xx mmu")
Cc: <stable@vger.kernel.org>
Signed-off-by: Thomas Fourier <fou... | ```diff
diff --git a/drivers/gpu/drm/msm/adreno/a2xx_gpummu.c b/drivers/gpu/drm/msm/adreno/a2xx_gpummu.c
index 0407c9bc8c1b..4467b04527cd 100644
--- a/drivers/gpu/drm/msm/adreno/a2xx_gpummu.c
+++ b/drivers/gpu/drm/msm/adreno/a2xx_gpummu.c
@@ -78,7 +78,7 @@ static void a2xx_gpummu_destroy(struct msm_mmu *mmu)
{
struc... |
20f644f42e3b8e729d3c3199d48e75c0b257de8f | Analyze and fix the following issue in the Linux kernel code: drm/msm/a6xx: Fix the bogus protect error on X2-85 | Problem Details:
Update the X2-85 gpu's register protect count configuration with the
correct count_max value to avoid blocking the entire MMIO region from the
UMD.
Protect configurations are a bit complicated on A8xx. There are 2 set of
protect registers with different counts: Global and Pipe-specific. The
last-span-... | ```diff
diff --git a/drivers/gpu/drm/msm/adreno/a6xx_catalog.c b/drivers/gpu/drm/msm/adreno/a6xx_catalog.c
index 550a53a7865e..38561f26837e 100644
--- a/drivers/gpu/drm/msm/adreno/a6xx_catalog.c
+++ b/drivers/gpu/drm/msm/adreno/a6xx_catalog.c
@@ -1759,7 +1759,7 @@ static const u32 x285_protect_regs[] = {
A6XX_PROTECT... |
2b8060418dffaa4fcd9173dd5830a763a4b32e99 | Analyze and fix the following issue in the Linux kernel code: sched_deadline, docs: fix cpuset example for cgroupv2 | Problem Details:
Documenation/scheduler/sched-deadline.rst provides two examples for how
to setup cgroup and cpuset for deadline tasks: one for cgroup v1 and one
cgroup v2. The code block in the latter is not properly html rendered as
the :: marker is missing.
Add the :: marker before the code block for the cgroup v2 ... | ```diff
diff --git a/Documentation/scheduler/sched-deadline.rst b/Documentation/scheduler/sched-deadline.rst
index ec543a12f848..d23e4afe1a9a 100644
--- a/Documentation/scheduler/sched-deadline.rst
+++ b/Documentation/scheduler/sched-deadline.rst
@@ -700,7 +700,8 @@ Deadline Task Scheduling
5.2 Using cgroup v2 cpuset ... |
6d9c2e9575b8630e17571a77eef8ade84a2a6344 | Analyze and fix the following issue in the Linux kernel code: docs: kdoc_parser: fix parser to support multi-word types | Problem Details:
The regular expression currently expects a single word for the
type, but it may be something like "struct foo".
Add support for it.
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Acked-by: Randy Dunlap <rdunlap@infradead.org>
Tested-by: Randy Dunlap <rdunlap@infradead.org>
Reviewed... | ```diff
diff --git a/tools/lib/python/kdoc/kdoc_parser.py b/tools/lib/python/kdoc/kdoc_parser.py
index 39ff27d421eb..22a820d33dc8 100644
--- a/tools/lib/python/kdoc/kdoc_parser.py
+++ b/tools/lib/python/kdoc/kdoc_parser.py
@@ -1018,14 +1018,14 @@ class KernelDoc:
default_val = None
- r= KernRe(OPTIO... |
9bbf22b87d866fa1e6a1f9f6376d2ef458b6dcc7 | Analyze and fix the following issue in the Linux kernel code: docs: kdoc_parser: fix the default_value logic for variables | Problem Details:
The indentation is wrong for the second regex, which causes
problems on variables with defaults.
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Acked-by: Randy Dunlap <rdunlap@infradead.org>
Tested-by: Randy Dunlap <rdunlap@infradead.org>
Reviewed-by: Aleksandr Loktionov <aleksandr.l... | ```diff
diff --git a/tools/lib/python/kdoc/kdoc_parser.py b/tools/lib/python/kdoc/kdoc_parser.py
index 9c9443281c40..4bf55244870f 100644
--- a/tools/lib/python/kdoc/kdoc_parser.py
+++ b/tools/lib/python/kdoc/kdoc_parser.py
@@ -1027,9 +1027,9 @@ class KernelDoc:
default_val = r.group(2)
else:
... |
4fd349f03dc51bc2f9cd2ea9f6309b0bc2b848ca | Analyze and fix the following issue in the Linux kernel code: docs: kdoc_parser: fix variable regexes to work with size_t | Problem Details:
The regular expressions meant to pick variable types are too
naive: they forgot that the type word may contain underlines.
It also means that we need to change the regex which detects
var attributes to handle "const".
Co-developed-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Mauro Carvalho... | ```diff
diff --git a/tools/lib/python/kdoc/kdoc_parser.py b/tools/lib/python/kdoc/kdoc_parser.py
index 9643ffb7584a..9c9443281c40 100644
--- a/tools/lib/python/kdoc/kdoc_parser.py
+++ b/tools/lib/python/kdoc/kdoc_parser.py
@@ -981,8 +981,9 @@ class KernelDoc:
"""
VAR_ATTRIBS = [
"extern",... |
8eb49357ffa229c9b65a002f655c1280dc09769a | Analyze and fix the following issue in the Linux kernel code: docs: kdoc_re: don't go past the end of a line | Problem Details:
The logic which checks if the line ends with ";" is currently
broken: it may try to read past the buffer.
Fix it by checking before trying to access line[pos].
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Acked-by: Randy Dunlap <rdunlap@infradead.org>
Tested-by: Randy Dunlap <rdun... | ```diff
diff --git a/tools/lib/python/kdoc/kdoc_re.py b/tools/lib/python/kdoc/kdoc_re.py
index 774dd747ecb0..6c44fcce0415 100644
--- a/tools/lib/python/kdoc/kdoc_re.py
+++ b/tools/lib/python/kdoc/kdoc_re.py
@@ -269,7 +269,7 @@ class NestedMatch:
out += new_sub
# Drop end ';' if any
- ... |
2b144a30a407d29b7e6d24549f5316175115e788 | Analyze and fix the following issue in the Linux kernel code: docs: kdoc_re: add support for groups() | Problem Details:
Add an equivalent to re groups() method.
This is useful on debug messages.
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Acked-by: Randy Dunlap <rdunlap@infradead.org>
Tested-by: Randy Dunlap <rdunlap@infradead.org>
Reviewed-by: Aleksandr Loktionov <aleksandr.loktionov@intel.com>
Si... | ```diff
diff --git a/tools/lib/python/kdoc/kdoc_re.py b/tools/lib/python/kdoc/kdoc_re.py
index 0bf9e01cdc57..774dd747ecb0 100644
--- a/tools/lib/python/kdoc/kdoc_re.py
+++ b/tools/lib/python/kdoc/kdoc_re.py
@@ -106,6 +106,13 @@ class KernRe:
return self.last_match.group(num)
+ def groups(self):
+ ... |
6801cc493603b273698de501702ccc8751fb6689 | Analyze and fix the following issue in the Linux kernel code: docs: sysctl: add documentation for crypto and debug | Problem Details:
Add documentation for the /proc/sys/crypto and /proc/sys/debug
directories in the admin-guide. This includes tunables for FIPS
mode (fips_enabled, fips_name, fips_version), exception-trace,
and kprobes-optimization.
The documentation is based on source code analysis and addresses
stylistic feedback to... | ```diff
diff --git a/Documentation/admin-guide/sysctl/crypto.rst b/Documentation/admin-guide/sysctl/crypto.rst
new file mode 100644
index 000000000000..b707bd314a64
--- /dev/null
+++ b/Documentation/admin-guide/sysctl/crypto.rst
@@ -0,0 +1,47 @@
+=================
+/proc/sys/crypto/
+=================
+
+These files sh... |
8350d14725a459fba899d5642b7ced786424d33c | Analyze and fix the following issue in the Linux kernel code: Documentation: process: backporting: fix missing subject | Problem Details:
Add the missing "it" in the sentence:
"even though it could have been changed by other patches."
This is a grammatical error in the Error handling section.
Signed-off-by: Ariful Islam Shoikot <islamarifulshoikat@gmail.com>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Message-ID: <20260226120129.18... | ```diff
diff --git a/Documentation/process/backporting.rst b/Documentation/process/backporting.rst
index c42779fbcd33..0de9eacd46a7 100644
--- a/Documentation/process/backporting.rst
+++ b/Documentation/process/backporting.rst
@@ -432,7 +432,7 @@ The same goes for added ``return``, ``break``, and ``continue``
statemen... |
19d2f0b97a131198efc2c4ca3eb7f980bba8c2b4 | Analyze and fix the following issue in the Linux kernel code: cxl/port: Fix use after free of parent_port in cxl_detach_ep() | Problem Details:
cxl_detach_ep() is called during bottom-up removal when all CXL memory
devices beneath a switch port have been removed. For each port in the
hierarchy it locks both the port and its parent, removes the endpoint,
and if the port is now empty, marks it dead and unregisters the port
by calling delete_swit... | ```diff
diff --git a/drivers/cxl/core/port.c b/drivers/cxl/core/port.c
index 0c5957d1d329..c5aacd7054f1 100644
--- a/drivers/cxl/core/port.c
+++ b/drivers/cxl/core/port.c
@@ -552,10 +552,13 @@ static void cxl_port_release(struct device *dev)
xa_destroy(&port->dports);
xa_destroy(&port->regions);
ida_free(&cxl_por... |
aa029f7a51d74401ebd05388ed573ad18b2830a8 | Analyze and fix the following issue in the Linux kernel code: drm/i915/overlay: Fix oops on unload | Problem Details:
Apparently I failed to test the unload case properly and
thus didn't notice that the i915_overlay_is_active() needs
i915->overlay after fetch_and_zero() already cleared it.
Stop using fetch_and_zero() and only clear the pointer at
the end to avoid the oops.
Fixes: 38d9a352c45e ("drm/i915/overlay: Extr... | ```diff
diff --git a/drivers/gpu/drm/i915/i915_overlay.c b/drivers/gpu/drm/i915/i915_overlay.c
index 28518dbb5b8e..04d5ad6aba5a 100644
--- a/drivers/gpu/drm/i915/i915_overlay.c
+++ b/drivers/gpu/drm/i915/i915_overlay.c
@@ -482,9 +482,8 @@ static void __iomem *i915_overlay_setup(struct drm_device *drm,
static void i915... |
4d2956e0094d9a7b04395185bc81467fa0ae1ccc | Analyze and fix the following issue in the Linux kernel code: Documentation/maintainer-tip: Fix grammar | Problem Details:
s/a empty newline/an empty newline/
Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Message-ID: <20260302135141.3213-2-thorsten.blum@linux.dev> | ```diff
diff --git a/Documentation/process/maintainer-tip.rst b/Documentation/process/maintainer-tip.rst
index 41d5855700cd..b2b14439be22 100644
--- a/Documentation/process/maintainer-tip.rst
+++ b/Documentation/process/maintainer-tip.rst
@@ -352,7 +352,7 @@ following tag ordering scheme:
Changelog text starts he... |
b09621cc0dfd7d2ae8557ee9d0d7ca6dc75145e5 | Analyze and fix the following issue in the Linux kernel code: i40e: Add missing wordpart.h header | Problem Details:
When cleaning up another header I have met this build error:
drivers/net/ethernet/intel/i40e/i40e_hmc.h:105:22: error: implicit declaration of function 'upper_32_bits' [-Wimplicit-function-declaration]
105 | val1 = (u32)(upper_32_bits(pa)); \
This is due to mi... | ```diff
diff --git a/drivers/net/ethernet/intel/i40e/i40e_hmc.h b/drivers/net/ethernet/intel/i40e/i40e_hmc.h
index 480e3a883cc7..967711405919 100644
--- a/drivers/net/ethernet/intel/i40e/i40e_hmc.h
+++ b/drivers/net/ethernet/intel/i40e/i40e_hmc.h
@@ -4,6 +4,8 @@
#ifndef _I40E_HMC_H_
#define _I40E_HMC_H_
+#include <... |
f6312e71759ddb10b20fbdb9ee01b9546cabd4e3 | Analyze and fix the following issue in the Linux kernel code: selftests/bpf: Add tests for ctx fixed offset support | Problem Details:
Add tests to ensure PTR_TO_CTX supports fixed offsets for program types
that don't rewrite accesses to it. Ensure that variable offsets and
negative offsets are still rejected. An extra test also checks writing
into ctx with modified offset for syscall progs. Other program types do
not support writes (... | ```diff
diff --git a/tools/testing/selftests/bpf/progs/verifier_ctx.c b/tools/testing/selftests/bpf/progs/verifier_ctx.c
index 5ebf7d9bcc55..371780290c0d 100644
--- a/tools/testing/selftests/bpf/progs/verifier_ctx.c
+++ b/tools/testing/selftests/bpf/progs/verifier_ctx.c
@@ -292,4 +292,80 @@ padding_access("cgroup/post_... |
5a6baf204610589f8a5b5a1cd69d1fe661d9d3cd | Analyze and fix the following issue in the Linux kernel code: fuse: fix uninit-value in fuse_dentry_revalidate() | Problem Details:
fuse_dentry_revalidate() may be called with a dentry that didn't had
->d_time initialised. The issue was found with KMSAN, where lookup_open()
calls __d_alloc(), followed by d_revalidate(), as shown below:
=====================================================
BUG: KMSAN: uninit-value in fuse_dentry_r... | ```diff
diff --git a/fs/fuse/dir.c b/fs/fuse/dir.c
index 70d3e631266e..b658b6baf72f 100644
--- a/fs/fuse/dir.c
+++ b/fs/fuse/dir.c
@@ -480,6 +480,11 @@ static int fuse_dentry_init(struct dentry *dentry)
fd->dentry = dentry;
RB_CLEAR_NODE(&fd->node);
dentry->d_fsdata = fd;
+ /*
+ * Initialising d_time (epoch) to ... |
147dae12985947cdb9e1918142f06482c5077a81 | Analyze and fix the following issue in the Linux kernel code: sparc/PCI: Initialize msi_addr_mask for OF-created PCI devices | Problem Details:
Recent changes replaced the use of no_64bit_msi with msi_addr_mask, which
is now expected to be initialized to DMA_BIT_MASK(64) during PCI device
setup. On SPARC systems, this initialization was inadvertently missed for
devices instantiated from device tree nodes, leaving msi_addr_mask unset
for OF-cre... | ```diff
diff --git a/arch/sparc/kernel/pci.c b/arch/sparc/kernel/pci.c
index 7e41574634b3..1603d50fdcad 100644
--- a/arch/sparc/kernel/pci.c
+++ b/arch/sparc/kernel/pci.c
@@ -355,6 +355,13 @@ static struct pci_dev *of_create_pci_dev(struct pci_pbm_info *pbm,
dev->error_state = pci_channel_io_normal;
dev->dma_mask =... |
2185904ff8b5da76a4353e5d1236caa78e0d98e3 | Analyze and fix the following issue in the Linux kernel code: powerpc/pci: Initialize msi_addr_mask for OF-created PCI devices | Problem Details:
Recent changes replaced the use of no_64bit_msi with msi_addr_mask. As a
result, msi_addr_mask is now expected to be initialized to DMA_BIT_MASK(64)
when a pci_dev is set up. However, this initialization was missed on
powerpc due to differences in the device initialization path compared to
other (x86)... | ```diff
diff --git a/arch/powerpc/kernel/pci_of_scan.c b/arch/powerpc/kernel/pci_of_scan.c
index 756043dd06e9..fb9fbf0d1796 100644
--- a/arch/powerpc/kernel/pci_of_scan.c
+++ b/arch/powerpc/kernel/pci_of_scan.c
@@ -212,6 +212,13 @@ struct pci_dev *of_create_pci_dev(struct device_node *node,
dev->error_state = pci_cha... |
1336b579f6079fb8520be03624fcd9ba443c930b | Analyze and fix the following issue in the Linux kernel code: sched_ext: Remove redundant css_put() in scx_cgroup_init() | Problem Details:
The iterator css_for_each_descendant_pre() walks the cgroup hierarchy
under cgroup_lock(). It does not increment the reference counts on
yielded css structs.
According to the cgroup documentation, css_put() should only be used
to release a reference obtained via css_get() or css_tryget_online().
Since... | ```diff
diff --git a/kernel/sched/ext.c b/kernel/sched/ext.c
index 2ba69b302368..eab6e09b6442 100644
--- a/kernel/sched/ext.c
+++ b/kernel/sched/ext.c
@@ -3589,7 +3589,6 @@ static int scx_cgroup_init(struct scx_sched *sch)
ret = SCX_CALL_OP_RET(sch, SCX_KF_UNLOCKED, cgroup_init, NULL,
css->cgroup, &args);... |
0f475ee0ebce5c9492b260027cd95270191675fa | Analyze and fix the following issue in the Linux kernel code: btrfs: abort transaction on failure to update root in the received subvol ioctl | Problem Details:
If we failed to update the root we don't abort the transaction, which is
wrong since we already used the transaction to remove an item from the
uuid tree.
Fixes: dd5f9615fc5c ("Btrfs: maintain subvolume items in the UUID tree")
CC: stable@vger.kernel.org # 3.12+
Reviewed-by: Anand Jain <asj@kernel.org... | ```diff
diff --git a/fs/btrfs/ioctl.c b/fs/btrfs/ioctl.c
index 56d17eedaf90..5805ac2078f2 100644
--- a/fs/btrfs/ioctl.c
+++ b/fs/btrfs/ioctl.c
@@ -3984,7 +3984,8 @@ static long _btrfs_ioctl_set_received_subvol(struct file *file,
ret = btrfs_update_root(trans, fs_info->tree_root,
&root->root_key, &root->root_it... |
87f2c46003fce4d739138aab4af1942b1afdadac | Analyze and fix the following issue in the Linux kernel code: btrfs: fix transaction abort on set received ioctl due to item overflow | Problem Details:
If the set received ioctl fails due to an item overflow when attempting to
add the BTRFS_UUID_KEY_RECEIVED_SUBVOL we have to abort the transaction
since we did some metadata updates before.
This means that if a user calls this ioctl with the same received UUID
field for a lot of subvolumes, we will hi... | ```diff
diff --git a/fs/btrfs/ioctl.c b/fs/btrfs/ioctl.c
index 1d22c5c05b50..56d17eedaf90 100644
--- a/fs/btrfs/ioctl.c
+++ b/fs/btrfs/ioctl.c
@@ -3929,6 +3929,25 @@ static long _btrfs_ioctl_set_received_subvol(struct file *file,
goto out;
}
+ received_uuid_changed = memcmp(root_item->received_uuid, sa->uuid,
+ ... |
e1b18b959025e6b5dbad668f391f65d34b39595a | Analyze and fix the following issue in the Linux kernel code: btrfs: fix transaction abort when snapshotting received subvolumes | Problem Details:
Currently a user can trigger a transaction abort by snapshotting a
previously received snapshot a bunch of times until we reach a
BTRFS_UUID_KEY_RECEIVED_SUBVOL item overflow (the maximum item size we
can store in a leaf). This is very likely not common in practice, but
if it happens, it turns the file... | ```diff
diff --git a/fs/btrfs/transaction.c b/fs/btrfs/transaction.c
index 463238ca8a4d..8d887ffcdba1 100644
--- a/fs/btrfs/transaction.c
+++ b/fs/btrfs/transaction.c
@@ -1905,6 +1905,22 @@ static noinline int create_pending_snapshot(struct btrfs_trans_handle *trans,
ret = btrfs_uuid_tree_add(trans, new_root_item->r... |
2d1ababdedd4ba38867c2500eb7f95af5ddeeef7 | Analyze and fix the following issue in the Linux kernel code: btrfs: fix transaction abort on file creation due to name hash collision | Problem Details:
If we attempt to create several files with names that result in the same
hash, we have to pack them in same dir item and that has a limit inherent
to the leaf size. However if we reach that limit, we trigger a transaction
abort and turns the filesystem into RO mode. This allows for a malicious
user to ... | ```diff
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c
index d28d55beaacd..b409efe1857e 100644
--- a/fs/btrfs/inode.c
+++ b/fs/btrfs/inode.c
@@ -6610,6 +6610,25 @@ int btrfs_create_new_inode(struct btrfs_trans_handle *trans,
int ret;
bool xa_reserved = false;
+ if (!args->orphan && !args->subvol) {
+ /*
+ * ... |
ae1238b77feafa2f7f10bcd0432a99e098a98ec6 | Analyze and fix the following issue in the Linux kernel code: btrfs: read key again after incrementing slot in move_existing_remaps() | Problem Details:
Fix move_existing_remaps() so that if we increment the slot because the
key we encounter isn't a REMAP_BACKREF, we don't reuse the objectid and
offset of the old item.
Link: https://lore.kernel.org/linux-btrfs/20260125123908.2096548-1-clm@meta.com/
Reported-by: Chris Mason <clm@fb.com>
Fixes: bbea42df... | ```diff
diff --git a/fs/btrfs/relocation.c b/fs/btrfs/relocation.c
index cdb53c0b26ec..fcfbe1b1dab4 100644
--- a/fs/btrfs/relocation.c
+++ b/fs/btrfs/relocation.c
@@ -4399,6 +4399,8 @@ static int move_existing_remaps(struct btrfs_fs_info *fs_info,
leaf = path->nodes[0];
}
+
+ btrfs_item_key_to_cpu(leaf, &k... |
b2840e33127ce0eea880504b7f133e780f567a9b | Analyze and fix the following issue in the Linux kernel code: btrfs: add missing RCU unlock in error path in try_release_subpage_extent_buffer() | Problem Details:
Call rcu_read_lock() before exiting the loop in
try_release_subpage_extent_buffer() because there is a rcu_read_unlock()
call past the loop.
This has been detected by the Clang thread-safety analyzer.
Fixes: ad580dfa388f ("btrfs: fix subpage deadlock in try_release_subpage_extent_buffer()")
CC: stabl... | ```diff
diff --git a/fs/btrfs/extent_io.c b/fs/btrfs/extent_io.c
index 3df399dc8856..051309e90079 100644
--- a/fs/btrfs/extent_io.c
+++ b/fs/btrfs/extent_io.c
@@ -4494,6 +4494,7 @@ static int try_release_subpage_extent_buffer(struct folio *folio)
*/
if (!test_and_clear_bit(EXTENT_BUFFER_TREE_REF, &eb->bflags)) {... |
683853b166f051eba43088092d4d1d85cd8ac3cd | Analyze and fix the following issue in the Linux kernel code: drm/i915/dp: Ack only the handled device service IRQs | Problem Details:
Only those IRQs should be acked that are handled, however for SST all
IRQs triggered by the sink are acked. This can be a problem for flags
that are reserved/reading zero at a given moment, but become used for
some purpose - with a side-effect if set - in a future DPCD revision.
Fix the above by ackin... | ```diff
diff --git a/drivers/gpu/drm/i915/display/intel_dp.c b/drivers/gpu/drm/i915/display/intel_dp.c
index 413d6872812b..17439a415926 100644
--- a/drivers/gpu/drm/i915/display/intel_dp.c
+++ b/drivers/gpu/drm/i915/display/intel_dp.c
@@ -4929,6 +4929,14 @@ intel_dp_mst_disconnect(struct intel_dp *intel_dp)
drm_dp_ms... |
d036488a24d3d7feb5b6f56a1b6b76854f54847c | Analyze and fix the following issue in the Linux kernel code: drm/i915/dp: Print debug message for a sink connected off request | Problem Details:
So far the CONNECTED_OFF_ENTRY_REQUESTED request was accepted only
implicitly, by acking all the IRQs raised by the sink. Make this
explicit by printing a debug message.
Reviewed-by: Luca Coelho <luciano.coelho@intel.com>
Signed-off-by: Imre Deak <imre.deak@intel.com>
Link: https://patch.msgid.link/20... | ```diff
diff --git a/drivers/gpu/drm/i915/display/intel_dp.c b/drivers/gpu/drm/i915/display/intel_dp.c
index 4ca0c9cca65e..bd6c5eb5786c 100644
--- a/drivers/gpu/drm/i915/display/intel_dp.c
+++ b/drivers/gpu/drm/i915/display/intel_dp.c
@@ -5877,6 +5877,8 @@ static void intel_dp_handle_device_service_irq(struct intel_dp ... |
fbb003f8f722a0c7c8f409973d59dfcc8a54578c | Analyze and fix the following issue in the Linux kernel code: drm/i915/dp: Fix the link service IRQ DPCD_REV check | Problem Details:
The DP_LINK_SERVICE_IRQ_VECTOR_ESI0 DPCD register is supported only
since DPCD REV 1.2, so fix the revision check accordingly.
Reviewed-by: Luca Coelho <luciano.coelho@intel.com>
Signed-off-by: Imre Deak <imre.deak@intel.com>
Link: https://patch.msgid.link/20260225164618.1261368-11-imre.deak@intel.com | ```diff
diff --git a/drivers/gpu/drm/i915/display/intel_dp.c b/drivers/gpu/drm/i915/display/intel_dp.c
index f04f15e15849..d63c3d69e9fc 100644
--- a/drivers/gpu/drm/i915/display/intel_dp.c
+++ b/drivers/gpu/drm/i915/display/intel_dp.c
@@ -5812,7 +5812,7 @@ static bool intel_dp_check_link_service_irq(struct intel_dp *in... |
e0f252bb36dea780971af4736622d2c7be60d122 | Analyze and fix the following issue in the Linux kernel code: drm/i915/dp: Fix the device service IRQ DPCD_REV check | Problem Details:
The DP_DEVICE_SERVICE_IRQ_VECTOR DPCD register is supported since DPCD
REV 1.0, so read it out always. Flags added only by later DPCD revisions
are defined as reserved/must-be-zero by earlier DP Standard versions.
Reviewed-by: Luca Coelho <luciano.coelho@intel.com>
Signed-off-by: Imre Deak <imre.deak@... | ```diff
diff --git a/drivers/gpu/drm/i915/display/intel_dp.c b/drivers/gpu/drm/i915/display/intel_dp.c
index 4ecf5f6699f6..f04f15e15849 100644
--- a/drivers/gpu/drm/i915/display/intel_dp.c
+++ b/drivers/gpu/drm/i915/display/intel_dp.c
@@ -5790,9 +5790,6 @@ static void intel_dp_check_device_service_irq(struct intel_dp *... |
6997aa23db7ea1c1c062da0e9bf984465872b8d4 | Analyze and fix the following issue in the Linux kernel code: drm/i915/dp: Don't clobber the encoder state in the HPD IRQ handler | Problem Details:
The intel_dp_get_dpcd() function called from an HPD IRQ handler reads
out the DPRX capabilities from the sink and updates these in the
intel_dp encoder state. Since the IRQ handler can run in parallel with
the encoder/connector detection (intel_dp_detect()) which also calls
intel_dp_get_dpcd(), the enc... | ```diff
diff --git a/drivers/gpu/drm/i915/display/intel_dp.c b/drivers/gpu/drm/i915/display/intel_dp.c
index 73703cd6e1cc..7a89f26f2db7 100644
--- a/drivers/gpu/drm/i915/display/intel_dp.c
+++ b/drivers/gpu/drm/i915/display/intel_dp.c
@@ -5856,9 +5856,7 @@ static bool intel_dp_check_link_service_irq(struct intel_dp *in... |
90b86782d4993da94089671723c993551cc1fb3e | Analyze and fix the following issue in the Linux kernel code: drm/i915/dp: Handle a tunneling IRQ after acking it | Problem Details:
HPD IRQs in general should be handled after acking them. The
1. Read IRQ register (read DP_DEVICE_SERVICE_IRQ_VECTOR,
DP_LINK_SERVICE_IRQ_VECTOR_ESI0)
2. Handle IRQ
3. Ack IRQ (write DP_DEVICE_SERVICE_IRQ_VECTOR,
DP_LINK_SERVICE_IRQ_VECTOR_ESI0)
sequence would miss a new interrupt triggered aft... | ```diff
diff --git a/drivers/gpu/drm/i915/display/intel_dp.c b/drivers/gpu/drm/i915/display/intel_dp.c
index 8f0309c5c91f..2e7a4df48afa 100644
--- a/drivers/gpu/drm/i915/display/intel_dp.c
+++ b/drivers/gpu/drm/i915/display/intel_dp.c
@@ -5491,17 +5491,10 @@ intel_dp_check_mst_status(struct intel_dp *intel_dp)
drm... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.