id stringlengths 40 40 | instruction stringlengths 68 308 | input stringlengths 17 33.4k | output stringlengths 100 30k |
|---|---|---|---|
0d2dd02d74e6377268f56b90261de0fae8f0d2cb | Analyze and fix the following issue in the Linux kernel code: drm/amd/pm: add missing NotifyPowerSource message mapping for SMU13.0.7 | Problem Details:
Otherwise, the power source switching will fail due to message
unavailable.
Fixes: bf4823267a81 ("drm/amd/pm: fix possible power mode mismatch between driver and PMFW")
Signed-off-by: Evan Quan <evan.quan@amd.com>
Reviewed-by: Guchun Chen <guchun.chen@amd.com>
Signed-off-by: Alex Deucher <alexander.de... | ```diff
diff --git a/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_7_ppt.c b/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_7_ppt.c
index 98a33f8ee209..bba621615abf 100644
--- a/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_7_ppt.c
+++ b/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_7_ppt.c
@@ -125,6 +125,7 @@ static struct... |
a34fc1bcd2c4d8b09dcfc0b95ac65bca1e579bd7 | Analyze and fix the following issue in the Linux kernel code: drm/radeon: reintroduce radeon_dp_work_func content | Problem Details:
Put back the radeon_dp_work_func logic. It seems that
handling DP RX interrupts is necessary to make some
panels work. This was removed with the MST support,
but it regresses some systems so add it back. While
we are here, add the proper mutex locking.
Link: https://gitlab.freedesktop.org/drm/amd/-... | ```diff
diff --git a/drivers/gpu/drm/radeon/radeon_irq_kms.c b/drivers/gpu/drm/radeon/radeon_irq_kms.c
index 3377fbc71f65..c4dda908666c 100644
--- a/drivers/gpu/drm/radeon/radeon_irq_kms.c
+++ b/drivers/gpu/drm/radeon/radeon_irq_kms.c
@@ -99,6 +99,16 @@ static void radeon_hotplug_work_func(struct work_struct *work)
... |
60ecaaf54886b0642d5c4744f7fbf1ff0d6b3e42 | Analyze and fix the following issue in the Linux kernel code: drm:amd:amdgpu: Fix missing buffer object unlock in failure path | Problem Details:
smatch warning -
1) drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c:3615 gfx_v9_0_kiq_resume()
warn: inconsistent returns 'ring->mqd_obj->tbo.base.resv'.
2) drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c:6901 gfx_v10_0_kiq_resume()
warn: inconsistent returns 'ring->mqd_obj->tbo.base.resv'.
Signed-off-by: Sukrut Bellar... | ```diff
diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c b/drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c
index 1ec076517c96..ab44c1391d52 100644
--- a/drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c
@@ -6892,8 +6892,10 @@ static int gfx_v10_0_kiq_resume(struct amdgpu_device *adev)
ret... |
5f7fdb0f255756b594cc45c2c08b0140bc4a1761 | Analyze and fix the following issue in the Linux kernel code: thermal: intel: int340x: Add new line for UUID display | Problem Details:
Prior to the commit "763bd29fd3d1 ("thermal: int340x_thermal: Use
sysfs_emit_at() instead of scnprintf()", there was a new line after each
UUID string.
With the newline removed, existing user space like "thermald" fails to
compare each supported UUID as it is using getline() to read UUID and
apply cor... | ```diff
diff --git a/drivers/thermal/intel/int340x_thermal/int3400_thermal.c b/drivers/thermal/intel/int340x_thermal/int3400_thermal.c
index 810231b59dcd..5e1164226ada 100644
--- a/drivers/thermal/intel/int340x_thermal/int3400_thermal.c
+++ b/drivers/thermal/intel/int340x_thermal/int3400_thermal.c
@@ -131,7 +131,7 @@ s... |
50da4496761b44752dfdf8096cbee399058aa7da | Analyze and fix the following issue in the Linux kernel code: dt-bindings: phy: qcom,qmp-ufs: fix the sc8180x regs | Problem Details:
sc8180x ufs phy requires to describe five reg areas for the phy to work,
so move the description to the correct place documenting tx, rx lane
1, 2 and pcs.
Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Link: https://lore.kernel.org/r/202303... | ```diff
diff --git a/Documentation/devicetree/bindings/phy/qcom,msm8996-qmp-ufs-phy.yaml b/Documentation/devicetree/bindings/phy/qcom,msm8996-qmp-ufs-phy.yaml
index 80a5348dbfde..881ba543fd46 100644
--- a/Documentation/devicetree/bindings/phy/qcom,msm8996-qmp-ufs-phy.yaml
+++ b/Documentation/devicetree/bindings/phy/qco... |
91e648fcccf38fed558c7c5330d77e229bbf24ef | Analyze and fix the following issue in the Linux kernel code: dt-bindings: phy: qcom,qmp-pcie: fix the sc8180x regs | Problem Details:
sc8180x pcie phy requires to describe six reg areas for the phy to work,
so move the description to the correct place documenting tx, rx lane 1,
2 and pcs and pcs misc.
Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Link: https://lore.kernel... | ```diff
diff --git a/Documentation/devicetree/bindings/phy/qcom,ipq8074-qmp-pcie-phy.yaml b/Documentation/devicetree/bindings/phy/qcom,ipq8074-qmp-pcie-phy.yaml
index 62045dcfb20c..3d42ee3901a1 100644
--- a/Documentation/devicetree/bindings/phy/qcom,ipq8074-qmp-pcie-phy.yaml
+++ b/Documentation/devicetree/bindings/phy/... |
8557dc27126949c702bd3aafe8a7e0b7e4fcb44c | Analyze and fix the following issue in the Linux kernel code: md/raid5: fix miscalculation of 'end_sector' in raid5_read_one_chunk() | Problem Details:
'end_sector' is compared to 'rdev->recovery_offset', which is offset to
rdev, however, commit e82ed3a4fbb5 ("md/raid6: refactor
raid5_read_one_chunk") changes the calculation of 'end_sector' to offset
to the array. Fix this miscalculation.
Fixes: e82ed3a4fbb5 ("md/raid6: refactor raid5_read_one_chunk"... | ```diff
diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c
index 4739ed891e75..9ea285fbc4a6 100644
--- a/drivers/md/raid5.c
+++ b/drivers/md/raid5.c
@@ -5516,7 +5516,7 @@ static int raid5_read_one_chunk(struct mddev *mddev, struct bio *raid_bio)
sector = raid5_compute_sector(conf, raid_bio->bi_iter.bi_sector, 0,
... |
249b62c448de7117c18531d626aed6e153cdfd75 | Analyze and fix the following issue in the Linux kernel code: cpufreq: amd-pstate: Remove fast_switch_possible flag from active driver | Problem Details:
amd_pstate active mode driver is only compatible with static governors.
Therefore it doesn't need fast_switch functionality. Remove
fast_switch_possible flag from amd_pstate active mode driver.
Fixes: ffa5096a7c33 ("cpufreq: amd-pstate: implement Pstate EPP support for the AMD processors")
Signed-off-... | ```diff
diff --git a/drivers/cpufreq/amd-pstate.c b/drivers/cpufreq/amd-pstate.c
index 45711fc0a856..ac54779f5a49 100644
--- a/drivers/cpufreq/amd-pstate.c
+++ b/drivers/cpufreq/amd-pstate.c
@@ -1102,7 +1102,6 @@ static int amd_pstate_epp_cpu_init(struct cpufreq_policy *policy)
policy->policy = CPUFREQ_POLICY_POWERSA... |
4badf2eb1e986bdbf34dd2f5d4c979553a86fe54 | Analyze and fix the following issue in the Linux kernel code: cpufreq: amd-pstate: Add ->fast_switch() callback | Problem Details:
Schedutil normally calls the adjust_perf callback for drivers with
adjust_perf callback available and fast_switch_possible flag set.
However, when frequency invariance is disabled and schedutil tries to
invoke fast_switch. So, there is a chance of kernel crash if this
function pointer is not set. To pr... | ```diff
diff --git a/drivers/cpufreq/amd-pstate.c b/drivers/cpufreq/amd-pstate.c
index 5a3d4aa0f45a..45711fc0a856 100644
--- a/drivers/cpufreq/amd-pstate.c
+++ b/drivers/cpufreq/amd-pstate.c
@@ -444,9 +444,8 @@ static int amd_pstate_verify(struct cpufreq_policy_data *policy)
return 0;
}
-static int amd_pstate_targ... |
61e150fb310729c98227a5edf6e4a3619edc3702 | Analyze and fix the following issue in the Linux kernel code: parisc: Fix flush_dcache_page() for usage from irq context | Problem Details:
Since at least kernel 6.1, flush_dcache_page() is called with IRQs
disabled, e.g. from aio_complete().
But the current implementation for flush_dcache_page() on parisc
unintentionally re-enables IRQs, which may lead to deadlocks.
Fix it by using xa_lock_irqsave() and xa_unlock_irqrestore()
for the fl... | ```diff
diff --git a/arch/parisc/include/asm/cacheflush.h b/arch/parisc/include/asm/cacheflush.h
index 0bdee6724132..c8b6928cee1e 100644
--- a/arch/parisc/include/asm/cacheflush.h
+++ b/arch/parisc/include/asm/cacheflush.h
@@ -48,6 +48,10 @@ void flush_dcache_page(struct page *page);
#define flush_dcache_mmap_lock(m... |
847aea98e01cf084efcb84490b3060af343d1458 | Analyze and fix the following issue in the Linux kernel code: PM: hibernate: Correct spelling mistake in a comment | Problem Details:
Fix a typo in a comment in kernel/power/snapshot.c
Signed-off-by: Wang Honghui <honghui.wang@ucas.com.cn>
[ rjw: Subject and changelog edits ]
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> | ```diff
diff --git a/kernel/power/snapshot.c b/kernel/power/snapshot.c
index cd8b7b35f1e8..b27affb7503f 100644
--- a/kernel/power/snapshot.c
+++ b/kernel/power/snapshot.c
@@ -398,7 +398,7 @@ struct mem_zone_bm_rtree {
unsigned int blocks; /* Number of Bitmap Blocks */
};
-/* strcut bm_position is used for bro... |
e8afd0d9fccc27c8ad263db5cf5952cfcf72d6fe | Analyze and fix the following issue in the Linux kernel code: PCI: pciehp: Cancel bringup sequence if card is not present | Problem Details:
If a PCIe hotplug slot has an Attention Button, the normal hot-add flow is:
- Slot is empty and slot power is off
- User inserts card in slot and presses Attention Button
- OS blinks Power Indicator for 5 seconds
- After 5 seconds, OS turns on Power Indicator, turns on slot power, and
enum... | ```diff
diff --git a/drivers/pci/hotplug/pciehp_ctrl.c b/drivers/pci/hotplug/pciehp_ctrl.c
index 17a9243d98f4..dcdbfcf404dd 100644
--- a/drivers/pci/hotplug/pciehp_ctrl.c
+++ b/drivers/pci/hotplug/pciehp_ctrl.c
@@ -257,6 +257,14 @@ void pciehp_handle_presence_or_link_change(struct controller *ctrl, u32 events)
presen... |
2e41e3ca4729455e002bcb585f0d3749ee66d572 | Analyze and fix the following issue in the Linux kernel code: PM: suspend: Fix pm_suspend_target_state handling for !CONFIG_PM | Problem Details:
Move the pm_suspend_target_state definition for CONFIG_SUSPEND
unset from the wakeup code into the headers so as to allow it
to still be used elsewhere when CONFIG_SUSPEND is not set.
Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
[ rjw: Changelog and subject edits ]
Signed-off-by: Rafael ... | ```diff
diff --git a/drivers/base/power/wakeup.c b/drivers/base/power/wakeup.c
index 7cc0c0cf8eaa..a917219feea6 100644
--- a/drivers/base/power/wakeup.c
+++ b/drivers/base/power/wakeup.c
@@ -19,11 +19,6 @@
#include "power.h"
-#ifndef CONFIG_SUSPEND
-suspend_state_t pm_suspend_target_state;
-#define pm_suspend_targ... |
31cb1304ad8bd27b7d2abd8669fb887fb47d8eaf | Analyze and fix the following issue in the Linux kernel code: powercap: intel_rapl: Remove unused field in struct rapl_if_priv | Problem Details:
After commit f1e8d7560d30 ("powercap/intel_rapl: enumerate Psys RAPL
domain together with package RAPL domain"), the platform_rapl_domain field
is not used anymore. Remove it from rapl_if_priv structure.
Fixes: f1e8d7560d30 ("powercap/intel_rapl: enumerate Psys RAPL domain together with package RAPL d... | ```diff
diff --git a/include/linux/intel_rapl.h b/include/linux/intel_rapl.h
index 9f4b6f5b822f..828557645770 100644
--- a/include/linux/intel_rapl.h
+++ b/include/linux/intel_rapl.h
@@ -124,7 +124,6 @@ struct reg_action {
*/
struct rapl_if_priv {
struct powercap_control_type *control_type;
- struct rapl_domain *p... |
12e6f6dc78e4f4a418648fb1a9c0cd2ae9b3430b | Analyze and fix the following issue in the Linux kernel code: drm/i915/display: Handle GMD_ID identification in display code | Problem Details:
For platforms with GMD_ID support (i.e., everything MTL and beyond),
identification of the display IP present should be based on the contents
of the GMD_ID register rather than a PCI devid match.
Note that since GMD_ID readout requires access to the PCI BAR, a slight
change to the driver init sequence... | ```diff
diff --git a/drivers/gpu/drm/i915/display/intel_display_device.c b/drivers/gpu/drm/i915/display/intel_display_device.c
index 3e2f4cd0b9f5..a513ac8f71a3 100644
--- a/drivers/gpu/drm/i915/display/intel_display_device.c
+++ b/drivers/gpu/drm/i915/display/intel_display_device.c
@@ -5,7 +5,10 @@
#include <drm/i91... |
e5d1c8722083f0332dcd3c85fa1273d85fb6bed8 | Analyze and fix the following issue in the Linux kernel code: PM: domains: fix integer overflow issues in genpd_parse_state() | Problem Details:
Currently, while calculating residency and latency values, right
operands may overflow if resulting values are big enough.
To prevent this, albeit unlikely case, play it safe and convert
right operands to left ones' type s64.
Found by Linux Verification Center (linuxtesting.org) with static
analysis ... | ```diff
diff --git a/drivers/base/power/domain.c b/drivers/base/power/domain.c
index 32084e38b73d..51b9d4eaab5e 100644
--- a/drivers/base/power/domain.c
+++ b/drivers/base/power/domain.c
@@ -2939,10 +2939,10 @@ static int genpd_parse_state(struct genpd_power_state *genpd_state,
err = of_property_read_u32(state_node... |
428d603fcaeb3c8135f9983c35619925f1a56f49 | Analyze and fix the following issue in the Linux kernel code: net: pcs: xpcs: correct pause resolution | Problem Details:
xpcs was indicating symmetric pause should be enabled regardless of
the advertisements by either party. Fix this to use
linkmode_resolve_pause() now that we're no longer obliterating the
link partner's advertisement by logically anding it with our own.
This is transitional, the function will be entire... | ```diff
diff --git a/drivers/net/pcs/pcs-xpcs.c b/drivers/net/pcs/pcs-xpcs.c
index 90920a7ba136..eec10392e584 100644
--- a/drivers/net/pcs/pcs-xpcs.c
+++ b/drivers/net/pcs/pcs-xpcs.c
@@ -538,11 +538,20 @@ static void xpcs_resolve_lpa_c73(struct dw_xpcs *xpcs,
struct phylink_link_state *state)
{
__ETHTOOL_DECLA... |
1f94ba198bda5738bd26cb7633dca4b33a43dff2 | Analyze and fix the following issue in the Linux kernel code: net: pcs: xpcs: correct lp_advertising contents | Problem Details:
lp_advertising is supposed to reflect the link partner's advertisement
unmodified by the local advertisement, but xpcs bitwise ands it with
the local advertisement prior to calculating the resolution of the
negotiation.
Fix this by moving the bitwise and to xpcs_resolve_lpa_c73() so it can
place the r... | ```diff
diff --git a/drivers/net/pcs/pcs-xpcs.c b/drivers/net/pcs/pcs-xpcs.c
index 2165859a063c..90920a7ba136 100644
--- a/drivers/net/pcs/pcs-xpcs.c
+++ b/drivers/net/pcs/pcs-xpcs.c
@@ -531,18 +531,19 @@ static int xpcs_read_lpa_c73(struct dw_xpcs *xpcs,
mii_c73_mod_linkmode(state->lp_advertising, lpa);
- linkmo... |
335b4223466dd75f9f3ea4918187afbadd22e5c8 | Analyze and fix the following issue in the Linux kernel code: x86/pci/xen: populate MSI sysfs entries | Problem Details:
Commit bf5e758f02fc ("genirq/msi: Simplify sysfs handling") reworked the
creation of sysfs entries for MSI IRQs. The creation used to be in
msi_domain_alloc_irqs_descs_locked after calling ops->domain_alloc_irqs.
Then it moved into __msi_domain_alloc_irqs which is an implementation of
domain_alloc_irqs... | ```diff
diff --git a/arch/x86/pci/xen.c b/arch/x86/pci/xen.c
index 8babce71915f..014c508e914d 100644
--- a/arch/x86/pci/xen.c
+++ b/arch/x86/pci/xen.c
@@ -198,7 +198,7 @@ static int xen_setup_msi_irqs(struct pci_dev *dev, int nvec, int type)
i++;
}
kfree(v);
- return 0;
+ return msi_device_populate_sysfs(&dev->d... |
686b21b5f6ca2f8a716f9a4ade07246dbfb2713e | Analyze and fix the following issue in the Linux kernel code: drm: Add fdinfo memory stats | Problem Details:
Add support to dump GEM stats to fdinfo.
v2: Fix typos, change size units to match docs, use div_u64
v3: Do it in core
v4: more kerneldoc
v5: doc fixes
v6: Actually use u64, bit more comment docs
Signed-off-by: Rob Clark <robdclark@chromium.org>
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
Re... | ```diff
diff --git a/Documentation/gpu/drm-usage-stats.rst b/Documentation/gpu/drm-usage-stats.rst
index 552195fb1ea3..d012eb56885e 100644
--- a/Documentation/gpu/drm-usage-stats.rst
+++ b/Documentation/gpu/drm-usage-stats.rst
@@ -52,6 +52,9 @@ String shall contain the name this driver registered as via the respective
... |
0020582a8afe9a8570f80ec503c59bf049a616de | Analyze and fix the following issue in the Linux kernel code: drm/docs: Fix usage stats typos | Problem Details:
Fix a couple missing ':'s.
Signed-off-by: Rob Clark <robdclark@chromium.org>
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Acked-by: Dave Airlie <airlied@redhat.com>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20230524155956.382440... | ```diff
diff --git a/Documentation/gpu/drm-usage-stats.rst b/Documentation/gpu/drm-usage-stats.rst
index b46327356e80..72d069e5dacb 100644
--- a/Documentation/gpu/drm-usage-stats.rst
+++ b/Documentation/gpu/drm-usage-stats.rst
@@ -105,7 +105,7 @@ object belong to this client, in the respective memory region.
Default u... |
8fafac202d18230bb9926bda48e563fd2cce2a4f | Analyze and fix the following issue in the Linux kernel code: xen/pvcalls-back: fix double frees with pvcalls_new_active_socket() | Problem Details:
In the pvcalls_new_active_socket() function, most error paths call
pvcalls_back_release_active(fedata->dev, fedata, map) which calls
sock_release() on "sock". The bug is that the caller also frees sock.
Fix this by making every error path in pvcalls_new_active_socket()
release the sock, and don't fre... | ```diff
diff --git a/drivers/xen/pvcalls-back.c b/drivers/xen/pvcalls-back.c
index 1f5219e12cc3..7beaf2c41fbb 100644
--- a/drivers/xen/pvcalls-back.c
+++ b/drivers/xen/pvcalls-back.c
@@ -325,8 +325,10 @@ static struct sock_mapping *pvcalls_new_active_socket(
void *page;
map = kzalloc(sizeof(*map), GFP_KERNEL);
- ... |
09e8c253415b8eb9ca29a2131d2ebf17743534c5 | Analyze and fix the following issue in the Linux kernel code: block: Fix bio_flagged() so that gcc can better optimise it | Problem Details:
Fix bio_flagged() so that multiple instances of it, such as:
if (bio_flagged(bio, BIO_PAGE_REFFED) ||
bio_flagged(bio, BIO_PAGE_PINNED))
can be combined by the gcc optimiser into a single test in assembly
(arguably, this is a compiler optimisation issue[1]).
The missed optimisation stems from ... | ```diff
diff --git a/include/linux/bio.h b/include/linux/bio.h
index b3e7529ff55e..7f53be035cf0 100644
--- a/include/linux/bio.h
+++ b/include/linux/bio.h
@@ -229,7 +229,7 @@ static inline void bio_cnt_set(struct bio *bio, unsigned int count)
static inline bool bio_flagged(struct bio *bio, unsigned int bit)
{
- ret... |
c37222082f23c456664d1c3182a714670ab8f9a4 | Analyze and fix the following issue in the Linux kernel code: splice: Fix filemap_splice_read() to use the correct inode | Problem Details:
Fix filemap_splice_read() to use file->f_mapping->host, not file->f_inode,
as the source of the file size because in the case of a block device,
file->f_inode points to the block-special file (which is typically 0
length) and not the backing store.
Fixes: 07073eb01c5f ("splice: Add a func to do a spli... | ```diff
diff --git a/mm/filemap.c b/mm/filemap.c
index b4c9bd368b7e..a2006936a6ae 100644
--- a/mm/filemap.c
+++ b/mm/filemap.c
@@ -2900,7 +2900,7 @@ ssize_t filemap_splice_read(struct file *in, loff_t *ppos,
do {
cond_resched();
- if (*ppos >= i_size_read(file_inode(in)))
+ if (*ppos >= i_size_read(in->f_mappi... |
3eb96946f0be6bf447cbdf219aba22bc42672f92 | Analyze and fix the following issue in the Linux kernel code: block: make bio_check_eod work for zero sized devices | Problem Details:
Since the dawn of time bio_check_eod has a check for a non-zero size of
the device. This doesn't really make any sense as we never want to send
I/O to a device that's been set to zero size, or never moved out of that.
I am a bit surprised we haven't caught this for a long time, but the
removal of the... | ```diff
diff --git a/block/blk-core.c b/block/blk-core.c
index 00c74330fa92..1da77e7d6289 100644
--- a/block/blk-core.c
+++ b/block/blk-core.c
@@ -520,7 +520,7 @@ static inline int bio_check_eod(struct bio *bio)
sector_t maxsector = bdev_nr_sectors(bio->bi_bdev);
unsigned int nr_sectors = bio_sectors(bio);
- if (... |
33d418da6f476b15e4510e0a590062583f63cd36 | Analyze and fix the following issue in the Linux kernel code: riscv: Fix unused variable warning when BUILTIN_DTB is set | Problem Details:
commit ef69d2559fe9 ("riscv: Move early dtb mapping into the fixmap
region") wrongly moved the #ifndef CONFIG_BUILTIN_DTB surrounding the pa
variable definition in create_fdt_early_page_table(), so move it back to
its right place to quiet the following warning:
../arch/riscv/mm/init.c: In function ‘cr... | ```diff
diff --git a/arch/riscv/mm/init.c b/arch/riscv/mm/init.c
index 747e5b1ef02d..c6bb966e4123 100644
--- a/arch/riscv/mm/init.c
+++ b/arch/riscv/mm/init.c
@@ -922,9 +922,9 @@ static void __init create_kernel_page_table(pgd_t *pgdir, bool early)
static void __init create_fdt_early_page_table(uintptr_t fix_fdt_va,
... |
9a2cb1b31c040e2f1b313e2f7921f0f5e6b66d82 | Analyze and fix the following issue in the Linux kernel code: drm/i915: Replace all non-returning strlcpy with strscpy | Problem Details:
strlcpy() reads the entire source buffer first.
This read may exceed the destination size limit.
This is both inefficient and can lead to linear read
overflows if a source string is not NUL-terminated [1].
In an effort to remove strlcpy() completely [2], replace
strlcpy() here with strscpy().
No return... | ```diff
diff --git a/drivers/gpu/drm/i915/selftests/i915_perf.c b/drivers/gpu/drm/i915/selftests/i915_perf.c
index 24dde5531423..d4608b220123 100644
--- a/drivers/gpu/drm/i915/selftests/i915_perf.c
+++ b/drivers/gpu/drm/i915/selftests/i915_perf.c
@@ -28,7 +28,7 @@ alloc_empty_config(struct i915_perf *perf)
oa_config-... |
8e0285ab95a9baf374f2c13eb152221c8ecb3f28 | Analyze and fix the following issue in the Linux kernel code: ARM/musb: omap2: Remove global GPIO numbers from TUSB6010 | Problem Details:
The TUSB6010 (MUSB) device is picking up some GPIO lines
hardcoded by number and passing on to the TUSB6010 device
when registering it.
Instead of nasty workarounds, provide a GPIO descriptor
table and then make the TUSB6010 MUSB glue driver pick up
the GPIO lines directly, convert it to an IRQ and pa... | ```diff
diff --git a/arch/arm/mach-omap2/board-n8x0.c b/arch/arm/mach-omap2/board-n8x0.c
index 50b88eb23f9f..564bf80a2621 100644
--- a/arch/arm/mach-omap2/board-n8x0.c
+++ b/arch/arm/mach-omap2/board-n8x0.c
@@ -10,8 +10,8 @@
#include <linux/clk.h>
#include <linux/delay.h>
-#include <linux/gpio.h>
#include <linux/g... |
078dc5194c0ac1b8e2fc088be2168a1104e16f72 | Analyze and fix the following issue in the Linux kernel code: ARM: omap2: Rewrite WLAN quirk to use GPIO descriptors | Problem Details:
The OMAP2 platform data quirk is using the global GPIO numberspace
to obtain two WLAN GPIOs to drive power and xcvr reset GPIO
lines during start-up.
Rewrite the quirk to use a GPIO descriptor table so we avoid using
global GPIO numbers.
This gets rid of the final dependency on the legacy <linux/gpio... | ```diff
diff --git a/arch/arm/mach-omap2/pdata-quirks.c b/arch/arm/mach-omap2/pdata-quirks.c
index 3264c4e77a8a..c1c0121f478d 100644
--- a/arch/arm/mach-omap2/pdata-quirks.c
+++ b/arch/arm/mach-omap2/pdata-quirks.c
@@ -8,7 +8,6 @@
#include <linux/davinci_emac.h>
#include <linux/gpio/machine.h>
#include <linux/gpio/c... |
94075d16beefc2304e756e3b23d8ecf0f36eecd7 | Analyze and fix the following issue in the Linux kernel code: ARM: omap2: Get USB hub reset GPIO from descriptor | Problem Details:
This switches the USB hub GPIO reset line handling in the
OMAP2 pdata quirks over to using GPIO descriptors to avoid using
the global GPIO numberspace.
Since the GPIOs are exported and assumedly used by some kind
of userspace we cannot simply use hogs in the device tree.
Fixes: 92bf78b33b0b ("gpio: o... | ```diff
diff --git a/arch/arm/mach-omap2/pdata-quirks.c b/arch/arm/mach-omap2/pdata-quirks.c
index c363ad8d6a06..3264c4e77a8a 100644
--- a/arch/arm/mach-omap2/pdata-quirks.c
+++ b/arch/arm/mach-omap2/pdata-quirks.c
@@ -98,31 +98,43 @@ static struct iommu_platform_data omap3_iommu_isp_pdata = {
};
#endif
-static voi... |
d5f4fa60d63aa54ae33339895b88d8932b6037ed | Analyze and fix the following issue in the Linux kernel code: ARM/gpio: Push OMAP2 quirk down into TWL4030 driver | Problem Details:
The TWL4030 GPIO driver has a custom platform data .set_up()
callback to call back into the platform and do misc stuff such
as hog and export a GPIO for WLAN PWR on a specific OMAP3 board.
Avoid all the kludgery in the platform data and the boardfile
and just put the quirks right into the driver. Make... | ```diff
diff --git a/arch/arm/mach-omap2/omap_device.c b/arch/arm/mach-omap2/omap_device.c
index 4afa2f08e668..fca7869c8075 100644
--- a/arch/arm/mach-omap2/omap_device.c
+++ b/arch/arm/mach-omap2/omap_device.c
@@ -244,7 +244,6 @@ static int _omap_device_notifier_call(struct notifier_block *nb,
case BUS_NOTIFY_ADD_DE... |
c729baa8604226a8f878296bd145ab4046c80b12 | Analyze and fix the following issue in the Linux kernel code: ARM: omap1: Exorcise the legacy GPIO header | Problem Details:
After fixing all the offending users referencing the global GPIO
numberspace in OMAP1, a few sites still remain including the
legacy <linus/gpio.h> header for no reason.
Delete the last remaining users, and OMAP1 is free from legacy
GPIO dependencies.
Fixes: 92bf78b33b0b ("gpio: omap: use dynamic all... | ```diff
diff --git a/arch/arm/mach-omap1/devices.c b/arch/arm/mach-omap1/devices.c
index 5304699c7a97..8b2c5f911e97 100644
--- a/arch/arm/mach-omap1/devices.c
+++ b/arch/arm/mach-omap1/devices.c
@@ -6,7 +6,6 @@
*/
#include <linux/dma-mapping.h>
-#include <linux/gpio.h>
#include <linux/module.h>
#include <linux/k... |
df89de979f0e09e1896d59312362ce1657b848eb | Analyze and fix the following issue in the Linux kernel code: ARM: omap1: Make serial wakeup GPIOs use descriptors | Problem Details:
The code in serial.c looks up GPIOs corresponding to a line
on the UART when muxed in as GPIO to use this as a wakeup
on serial activity for OMAP1.
Utilize the NULL device to define some board-specific
GPIO lookups and use these to immediately look up the
same GPIOs, set as input and convert to IRQ nu... | ```diff
diff --git a/arch/arm/mach-omap1/board-nokia770.c b/arch/arm/mach-omap1/board-nokia770.c
index dd1a8f439fac..5ea27ca26abf 100644
--- a/arch/arm/mach-omap1/board-nokia770.c
+++ b/arch/arm/mach-omap1/board-nokia770.c
@@ -294,6 +294,13 @@ static struct gpiod_lookup_table nokia770_irq_gpio_table = {
/* GPIO used... |
084b6f216778b4109123b396b531f12ff6c354e9 | Analyze and fix the following issue in the Linux kernel code: ARM: omap1: Fix up the Nokia 770 board device IRQs | Problem Details:
The platform devices on the Nokia 770 is using some
board-specific IRQs that get statically assigned to platform
devices in the boardfile.
This does not work with dynamic IRQ chip bases.
Utilize the NULL device to define some board-specific
GPIO lookups and use these to immediately look up the
same G... | ```diff
diff --git a/arch/arm/mach-omap1/board-nokia770.c b/arch/arm/mach-omap1/board-nokia770.c
index 9583417f5bea..dd1a8f439fac 100644
--- a/arch/arm/mach-omap1/board-nokia770.c
+++ b/arch/arm/mach-omap1/board-nokia770.c
@@ -6,7 +6,7 @@
*/
#include <linux/clkdev.h>
#include <linux/irq.h>
-#include <linux/gpio.h>
... |
e519f0bb64efc2c9c8b67bb2d114dda458bdc34d | Analyze and fix the following issue in the Linux kernel code: ARM/mmc: Convert old mmci-omap to GPIO descriptors | Problem Details:
A recent change to the OMAP driver making it use a dynamic GPIO
base created problems with some old OMAP1 board files, among
them Nokia 770, SX1 and also the OMAP2 Nokia n8x0.
Fix up all instances of GPIOs being used for the MMC driver
by pushing the handling of power, slot selection and MMC
"cover" i... | ```diff
diff --git a/arch/arm/mach-omap1/board-nokia770.c b/arch/arm/mach-omap1/board-nokia770.c
index dde74694cb4c..9583417f5bea 100644
--- a/arch/arm/mach-omap1/board-nokia770.c
+++ b/arch/arm/mach-omap1/board-nokia770.c
@@ -184,27 +184,23 @@ static struct omap_usb_config nokia770_usb_config __initdata = {
#if IS_... |
767d83361aaa6a1ecb4d5b89eeb38a267239917a | Analyze and fix the following issue in the Linux kernel code: Input: ads7846 - Convert to use software nodes | Problem Details:
The Nokia 770 is using GPIOs from the global numberspace on the
CBUS node to pass down to the LCD controller. This regresses when we
let the OMAP GPIO driver use dynamic GPIO base.
The Nokia 770 now has dynamic allocation of IRQ numbers, so this
needs to be fixed for it to work.
As this is the only u... | ```diff
diff --git a/arch/arm/mach-omap1/board-nokia770.c b/arch/arm/mach-omap1/board-nokia770.c
index a501a473ffd6..dde74694cb4c 100644
--- a/arch/arm/mach-omap1/board-nokia770.c
+++ b/arch/arm/mach-omap1/board-nokia770.c
@@ -8,15 +8,16 @@
#include <linux/irq.h>
#include <linux/gpio.h>
#include <linux/gpio/machine.... |
480c82daa3e41873421dc2c9e2918ad7e21d7a0b | Analyze and fix the following issue in the Linux kernel code: ARM: omap1: Remove reliance on GPIO numbers from SX1 | Problem Details:
It appears this happens because the OMAP driver now
allocates GPIO numbers dynamically, so all that is
references by number is a bit up in the air.
Utilize the NULL device to define some board-specific
GPIO lookups and use these to immediately look up the
same GPIOs, convert to IRQ numbers and pass as... | ```diff
diff --git a/arch/arm/mach-omap1/board-sx1.c b/arch/arm/mach-omap1/board-sx1.c
index 0c0cdd5e77c7..a13c630be7b7 100644
--- a/arch/arm/mach-omap1/board-sx1.c
+++ b/arch/arm/mach-omap1/board-sx1.c
@@ -11,7 +11,8 @@
* Maintainters : Vladimir Ananiev (aka Vovan888), Sergge
* oslik.ru
*/
-#include <linux/gpio.h>... |
4c40db6249ff1da335b276bdd6c3c3462efbc2ab | Analyze and fix the following issue in the Linux kernel code: ARM: omap1: Remove reliance on GPIO numbers from PalmTE | Problem Details:
It appears this happens because the OMAP driver now
allocates GPIO numbers dynamically, so all that is
references by number is a bit up in the air.
Utilize the NULL device to define some board-specific
GPIO lookups and use these to immediately look up the
same GPIOs, convert to IRQ numbers and pass as... | ```diff
diff --git a/arch/arm/mach-omap1/board-palmte.c b/arch/arm/mach-omap1/board-palmte.c
index f79c497f04d5..49b7757cb2fd 100644
--- a/arch/arm/mach-omap1/board-palmte.c
+++ b/arch/arm/mach-omap1/board-palmte.c
@@ -13,7 +13,8 @@
*
* Copyright (c) 2006 Andrzej Zaborowski <balrog@zabor.org>
*/
-#include <linux... |
fa1ae0cd897b089b5cc05ab471518ad13db2d567 | Analyze and fix the following issue in the Linux kernel code: ARM: omap1: Drop header on AMS Delta | Problem Details:
The AMS Delta board uses GPIO descriptors exclusively and
does not have any dependencies on the legacy <linux/gpio.h>
header, so just drop it.
Acked-by: Janusz Krzysztofik <jmkrzyszt@gmail.com>
Fixes: 92bf78b33b0b ("gpio: omap: use dynamic allocation of base")
Signed-off-by: Linus Walleij <linus.walle... | ```diff
diff --git a/arch/arm/mach-omap1/board-ams-delta.c b/arch/arm/mach-omap1/board-ams-delta.c
index 9108c871d129..ac47ab9fe096 100644
--- a/arch/arm/mach-omap1/board-ams-delta.c
+++ b/arch/arm/mach-omap1/board-ams-delta.c
@@ -11,7 +11,6 @@
#include <linux/gpio/driver.h>
#include <linux/gpio/machine.h>
#include ... |
c32c81f3dbdfd68f6ab20a29ad86f811aed36e4e | Analyze and fix the following issue in the Linux kernel code: ARM/mfd/gpio: Fixup TPS65010 regression on OMAP1 OSK1 | Problem Details:
Aaro reports problems on the OSK1 board after we altered
the dynamic base for GPIO allocations.
It appears this happens because the OMAP driver now
allocates GPIO numbers dynamically, so all that is
references by number is a bit up in the air.
Let's bite the bullet and try to just move the gpio_chip
... | ```diff
diff --git a/arch/arm/mach-omap1/board-osk.c b/arch/arm/mach-omap1/board-osk.c
index df758c1f9237..a8ca8d427182 100644
--- a/arch/arm/mach-omap1/board-osk.c
+++ b/arch/arm/mach-omap1/board-osk.c
@@ -25,7 +25,8 @@
* with this program; if not, write to the Free Software Foundation, Inc.,
* 675 Mass Ave, Camb... |
a9f0e3d5a089d0844abb679a5e99f15010d53e25 | Analyze and fix the following issue in the Linux kernel code: KVM: arm64: Reload PTE after invoking walker callback on preorder traversal | Problem Details:
The preorder callback on the kvm_pgtable_stage2_map() path can replace
a table with a block, then recursively free the detached table. The
higher-level walking logic stashes the old page table entry and
then walks the freed table, invoking the leaf callback and
potentially freeing pgtable pages prematu... | ```diff
diff --git a/arch/arm64/include/asm/kvm_pgtable.h b/arch/arm64/include/asm/kvm_pgtable.h
index dc3c072e862f..93bd0975b15f 100644
--- a/arch/arm64/include/asm/kvm_pgtable.h
+++ b/arch/arm64/include/asm/kvm_pgtable.h
@@ -632,9 +632,9 @@ int kvm_pgtable_stage2_flush(struct kvm_pgtable *pgt, u64 addr, u64 size);
... |
0b5d5c436a5c572a45f976cfd34a6741e143e5d9 | Analyze and fix the following issue in the Linux kernel code: mmc: pwrseq: sd8787: Fix WILC CHIP_EN and RESETN toggling order | Problem Details:
Chapter "5.3 Power-Up/Down Sequence" of WILC1000 [1] and WILC3000 [2]
states that CHIP_EN must be pulled HIGH first, RESETN second. Fix the
order of these signals in the driver.
Use the mmc_pwrseq_ops as driver data as the delay between signals is
specific to SDIO card type anyway.
[1] https://ww1.mi... | ```diff
diff --git a/drivers/mmc/core/pwrseq_sd8787.c b/drivers/mmc/core/pwrseq_sd8787.c
index 2e120ad83020..0c5f5e371e1f 100644
--- a/drivers/mmc/core/pwrseq_sd8787.c
+++ b/drivers/mmc/core/pwrseq_sd8787.c
@@ -28,7 +28,6 @@ struct mmc_pwrseq_sd8787 {
struct mmc_pwrseq pwrseq;
struct gpio_desc *reset_gpio;
struct... |
a99d21cefd351c8aaa20b83a3c942340e5789d45 | Analyze and fix the following issue in the Linux kernel code: mmc: vub300: fix invalid response handling | Problem Details:
We may get an empty response with zero length at the beginning of
the driver start and get following UBSAN error. Since there is no
content(SDRT_NONE) for the response, just return and skip the response
handling to avoid this problem.
Test pass : SDIO wifi throughput test with this patch
[ 126.98068... | ```diff
diff --git a/drivers/mmc/host/vub300.c b/drivers/mmc/host/vub300.c
index e4c4bfac3763..9ec593d52f0f 100644
--- a/drivers/mmc/host/vub300.c
+++ b/drivers/mmc/host/vub300.c
@@ -1713,6 +1713,9 @@ static void construct_request_response(struct vub300_mmc_host *vub300,
int bytes = 3 & less_cmd;
int words = less_c... |
4bd65789ba847f39e37e0041c10aad5dff1760b6 | Analyze and fix the following issue in the Linux kernel code: drm: shmobile: Make DRM_SHMOBILE visible on Renesas SoC platforms | Problem Details:
The LCD Controller supported by the drm-shmob driver is present
on SuperH SH-Mobile SoCs, and on Renesas ARM SH/R-Mobile SoCs.
Unfortunately its config option is not visible on either, so the user
can never enable the support.
Fix this by dropping the dependency on ARM (for SuperH), and by widening
th... | ```diff
diff --git a/drivers/gpu/drm/shmobile/Kconfig b/drivers/gpu/drm/shmobile/Kconfig
index 4ec5dc74a6b0..ad14112999ad 100644
--- a/drivers/gpu/drm/shmobile/Kconfig
+++ b/drivers/gpu/drm/shmobile/Kconfig
@@ -1,8 +1,8 @@
# SPDX-License-Identifier: GPL-2.0
config DRM_SHMOBILE
tristate "DRM Support for SH Mobile"
-... |
e79d85c6c217221ea32354a5ac0587a7ccea02b9 | Analyze and fix the following issue in the Linux kernel code: drm/fb-helper: Fix height, width, and accel_flags in fb_var | Problem Details:
Fbtest contains some very simple validation of the fbdev userspace API
contract. When used with shmob-drm, it reports the following warnings
and errors:
height changed from 68 to 0
height was rounded down
width changed from 111 to 0
width was rounded down
accel_flags changed from ... | ```diff
diff --git a/drivers/gpu/drm/drm_fb_helper.c b/drivers/gpu/drm/drm_fb_helper.c
index 6bb1b8b27d7a..fd27f1978635 100644
--- a/drivers/gpu/drm/drm_fb_helper.c
+++ b/drivers/gpu/drm/drm_fb_helper.c
@@ -1545,17 +1545,19 @@ static void drm_fb_helper_fill_pixel_fmt(struct fb_var_screeninfo *var,
}
}
-static void... |
5565a8e1a09a3ed2ac438a9e4f4c84c11037611d | Analyze and fix the following issue in the Linux kernel code: dma-buf/sw_sync: Replace all non-returning strlcpy with strscpy | Problem Details:
strlcpy() reads the entire source buffer first.
This read may exceed the destination size limit.
This is both inefficient and can lead to linear read
overflows if a source string is not NUL-terminated [1].
In an effort to remove strlcpy() completely [2], replace
strlcpy() here with strscpy().
No return... | ```diff
diff --git a/drivers/dma-buf/sw_sync.c b/drivers/dma-buf/sw_sync.c
index 348b3a9170fa..63f0aeb66db6 100644
--- a/drivers/dma-buf/sw_sync.c
+++ b/drivers/dma-buf/sw_sync.c
@@ -85,7 +85,7 @@ static struct sync_timeline *sync_timeline_create(const char *name)
kref_init(&obj->kref);
obj->context = dma_fence_c... |
95856d1f3c223c015780fffb8373a827fc4efd2e | Analyze and fix the following issue in the Linux kernel code: regmap: sdw: check for invalid multi-register writes config | Problem Details:
SoundWire code as it is only supports Bulk register writes and
it does not support multi-register writes.
Any drivers that set can_multi_write and use regmap_multi_reg_write() will
easily endup with programming the hardware incorrectly without any errors.
So, add this check in bus code to be able to ... | ```diff
diff --git a/drivers/base/regmap/regmap-sdw.c b/drivers/base/regmap/regmap-sdw.c
index 09899ae99fc1..159c0b740b00 100644
--- a/drivers/base/regmap/regmap-sdw.c
+++ b/drivers/base/regmap/regmap-sdw.c
@@ -59,6 +59,10 @@ static int regmap_sdw_config_check(const struct regmap_config *config)
if (config->pad_bits ... |
6e7a6d4797ef521c0762914610ed682e102b9d36 | Analyze and fix the following issue in the Linux kernel code: ASoC: codecs: wsa881x: do not set can_multi_write flag | Problem Details:
regmap-sdw does not support multi register writes, so there is
no point in setting this flag. This also leads to incorrect
programming of WSA codecs with regmap_multi_reg_write() call.
This invalid configuration should have been rejected by regmap-sdw.
Fixes: a0aab9e1404a ("ASoC: codecs: add wsa881x ... | ```diff
diff --git a/sound/soc/codecs/wsa881x.c b/sound/soc/codecs/wsa881x.c
index f709231b1277..97f6873a0a8c 100644
--- a/sound/soc/codecs/wsa881x.c
+++ b/sound/soc/codecs/wsa881x.c
@@ -645,7 +645,6 @@ static struct regmap_config wsa881x_regmap_config = {
.readable_reg = wsa881x_readable_register,
.reg_format_endi... |
40ba0411074485e2cf1bf8ee0f3db27bdff88394 | Analyze and fix the following issue in the Linux kernel code: ASoC: codecs: wsa883x: do not set can_multi_write flag | Problem Details:
regmap-sdw does not support multi register writes, so there is
no point in setting this flag. This also leads to incorrect
programming of WSA codecs with regmap_multi_reg_write() call.
This invalid configuration should have been rejected by regmap-sdw.
Fixes: 43b8c7dc85a1 ("ASoC: codecs: add wsa883x ... | ```diff
diff --git a/sound/soc/codecs/wsa883x.c b/sound/soc/codecs/wsa883x.c
index c609cb63dae6..e80b53143569 100644
--- a/sound/soc/codecs/wsa883x.c
+++ b/sound/soc/codecs/wsa883x.c
@@ -946,7 +946,6 @@ static struct regmap_config wsa883x_regmap_config = {
.writeable_reg = wsa883x_writeable_register,
.reg_format_en... |
0006fa2d3fa0320a385bd19c9c98b70ad3db7197 | Analyze and fix the following issue in the Linux kernel code: ALSA: emu10k1: fix multi-channel capture config for E-MU cards | Problem Details:
On SB cards the number of captured channels is derived from the voice
mask mixer control. But for E-MU cards this wasn't actually "wired up",
so changing the mask would simply mess up the recording.
We could fix that, but the channel routing through the FPGA makes the
masking redundant. So instead we ... | ```diff
diff --git a/sound/pci/emu10k1/emupcm.c b/sound/pci/emu10k1/emupcm.c
index 4216df399305..550caefa0ce4 100644
--- a/sound/pci/emu10k1/emupcm.c
+++ b/sound/pci/emu10k1/emupcm.c
@@ -495,6 +495,12 @@ static int snd_emu10k1_capture_prepare(struct snd_pcm_substream *substream)
snd_emu10k1_ptr_write(emu, ADCCR, 0, ... |
872e5b2b5ee3f5b346d58dc4b89f0ca92065b61e | Analyze and fix the following issue in the Linux kernel code: ALSA: emu10k1: fix support for 24 kHz capture | Problem Details:
We need to specify that the hardware supports non-standard rates, as
otherwise the sound core creates a constraint which limits the rate to
the specified standard rates. That also made the rate constraint we were
already adding meaningless.
Signed-off-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>... | ```diff
diff --git a/sound/pci/emu10k1/emupcm.c b/sound/pci/emu10k1/emupcm.c
index 40616d343d48..8279d8a4f589 100644
--- a/sound/pci/emu10k1/emupcm.c
+++ b/sound/pci/emu10k1/emupcm.c
@@ -1006,7 +1006,7 @@ static const struct snd_pcm_hardware snd_emu10k1_capture =
SNDRV_PCM_INFO_RESUME |
SNDRV_PCM_INFO_MMAP_... |
d2baa153c328efbbc3c4b939662e058b2cb544fd | Analyze and fix the following issue in the Linux kernel code: ALSA: emu10k1: fix capture buffer size confusion | Problem Details:
The buffer size register sets the size of the whole buffer, not just one
period. We actually handled it like that, except that the constraint was
set on the wrong parameter. The period size is implicitly constrained by
the buffer size and the fixed period count of 2.
Signed-off-by: Oswald Buddenhagen ... | ```diff
diff --git a/sound/pci/emu10k1/emupcm.c b/sound/pci/emu10k1/emupcm.c
index e34b02e9f890..40616d343d48 100644
--- a/sound/pci/emu10k1/emupcm.c
+++ b/sound/pci/emu10k1/emupcm.c
@@ -122,7 +122,7 @@ static int snd_emu10k1_pcm_channel_alloc(struct snd_emu10k1_pcm *epcm,
return 0;
}
-static const unsigned int ca... |
b04b076fb56560b39d695ac3744db457e12278fd | Analyze and fix the following issue in the Linux kernel code: crypto: nx - fix build warnings when DEBUG_FS is not enabled | Problem Details:
Fix build warnings when DEBUG_FS is not enabled by using an empty
do-while loop instead of a value:
In file included from ../drivers/crypto/nx/nx.c:27:
../drivers/crypto/nx/nx.c: In function 'nx_register_algs':
../drivers/crypto/nx/nx.h:173:33: warning: statement with no effect [-Wunused-value]
173 ... | ```diff
diff --git a/drivers/crypto/nx/Makefile b/drivers/crypto/nx/Makefile
index d00181a26dd6..483cef62acee 100644
--- a/drivers/crypto/nx/Makefile
+++ b/drivers/crypto/nx/Makefile
@@ -1,7 +1,6 @@
# SPDX-License-Identifier: GPL-2.0
obj-$(CONFIG_CRYPTO_DEV_NX_ENCRYPT) += nx-crypto.o
nx-crypto-objs := nx.o \
- nx... |
6dbecb9b51321bfaf8e7f26fc163d547abcbee86 | Analyze and fix the following issue in the Linux kernel code: ALSA: emu10k1: don't limit multi-channel playback to two periods | Problem Details:
For unclear reasons, the extra voice was set up with half the buffer
size instead of the period size. Commit 27ae958cf6 ("emu10k1 driver -
add multichannel device hw:x,3 [2-8/8]") mentions half-loop interrupts,
so maybe this was an artifact of an earlier iteration of the patch.
While at it, also fix p... | ```diff
diff --git a/sound/pci/emu10k1/emupcm.c b/sound/pci/emu10k1/emupcm.c
index 0572dfb80943..2764e7867b33 100644
--- a/sound/pci/emu10k1/emupcm.c
+++ b/sound/pci/emu10k1/emupcm.c
@@ -429,15 +429,16 @@ static int snd_emu10k1_efx_playback_prepare(struct snd_pcm_substream *substream)
struct snd_pcm_runtime *runtime ... |
6ab39f99927eed605728b02d512438d828183c97 | Analyze and fix the following issue in the Linux kernel code: crypto: x86/aria - Use 16 byte alignment for GFNI constant vectors | Problem Details:
The GFNI routines in the AVX version of the ARIA implementation now use
explicit VMOVDQA instructions to load the constant input vectors, which
means they must be 16 byte aligned. So ensure that this is the case, by
dropping the section split and the incorrect .align 8 directive, and
emitting the const... | ```diff
diff --git a/arch/x86/crypto/aria-aesni-avx-asm_64.S b/arch/x86/crypto/aria-aesni-avx-asm_64.S
index 7c1abc513f34..9556dacd9841 100644
--- a/arch/x86/crypto/aria-aesni-avx-asm_64.S
+++ b/arch/x86/crypto/aria-aesni-avx-asm_64.S
@@ -773,8 +773,6 @@
.octa 0x3F893781E95FE1576CDA64D2BA0CB204
#ifdef CONFIG_AS_GF... |
6a038f0183dd5d3e289f6c1fe6962de9b31f8fd2 | Analyze and fix the following issue in the Linux kernel code: drm/panel: samsung-s6d7aa0: use pointer for drm_mode in panel desc struct | Problem Details:
Fixes compilation issues with older GCC versions and Clang after
changes introduced in commit 6810bb390282 ("drm/panel: Add Samsung
S6D7AA0 panel controller driver"). Tested with GCC 13.1.1, GCC 6.4.0
and Clang 16.0.3.
Fixes the following errors with Clang:
drivers/gpu/drm/panel/panel-samsung-s6d7a... | ```diff
diff --git a/drivers/gpu/drm/panel/panel-samsung-s6d7aa0.c b/drivers/gpu/drm/panel/panel-samsung-s6d7aa0.c
index f532aa018428..102e1fc7ee38 100644
--- a/drivers/gpu/drm/panel/panel-samsung-s6d7aa0.c
+++ b/drivers/gpu/drm/panel/panel-samsung-s6d7aa0.c
@@ -37,7 +37,7 @@ struct s6d7aa0_panel_desc {
unsigned int ... |
b7a9a503c38d665c05a789132b632d81ec0b2703 | Analyze and fix the following issue in the Linux kernel code: fs: use UB-safe check for signed addition overflow in remap_verify_area | Problem Details:
The following warning pops up with enabled UBSAN in tests fstests/generic/303:
[23127.529395] UBSAN: Undefined behaviour in fs/read_write.c:1725:7
[23127.529400] signed integer overflow:
[23127.529403] 4611686018427322368 + 9223372036854775807 cannot be represented in type 'long long int'
[231... | ```diff
diff --git a/fs/remap_range.c b/fs/remap_range.c
index 1331a890f2f2..87ae4f0dc3aa 100644
--- a/fs/remap_range.c
+++ b/fs/remap_range.c
@@ -15,6 +15,7 @@
#include <linux/mount.h>
#include <linux/fs.h>
#include <linux/dax.h>
+#include <linux/overflow.h>
#include "internal.h"
#include <linux/uaccess.h>
@@ -... |
493f349e38d022057b3b6e13f589f108269c42b0 | Analyze and fix the following issue in the Linux kernel code: memblock: Add flags and nid info in memblock debugfs | Problem Details:
Currently, the memblock debugfs can display the count of memblock_type and
the base and end of the reg. However, when memblock_mark_*() or
memblock_set_node() is executed on some range, the information in the
existing debugfs cannot make it clear why the address is not consecutive.
For example,
cat /s... | ```diff
diff --git a/mm/memblock.c b/mm/memblock.c
index 9e28c1286ec6..c5c80d9bcea3 100644
--- a/mm/memblock.c
+++ b/mm/memblock.c
@@ -2158,12 +2158,19 @@ void __init memblock_free_all(void)
}
#if defined(CONFIG_DEBUG_FS) && defined(CONFIG_ARCH_KEEP_MEMBLOCK)
+static const char * const flagname[] = {
+ [ilog2(MEMBL... |
fc493f83a25835c14cd96379c1a07459230881bc | Analyze and fix the following issue in the Linux kernel code: Fix some coding style errors in memblock.c | Problem Details:
This patch removes the initialization of some static variables to 0 and
`false` in the memblock source file, according to the coding style
guidelines.
Signed-off-by: Claudio Migliorelli <claudio.migliorelli@mail.polimi.it>
Link: https://lore.kernel.org/r/87r0sa7mm8.fsf@mail.polimi.it
Signed-off-by: Mi... | ```diff
diff --git a/mm/memblock.c b/mm/memblock.c
index 3feafea06ab2..9e28c1286ec6 100644
--- a/mm/memblock.c
+++ b/mm/memblock.c
@@ -156,10 +156,10 @@ static __refdata struct memblock_type *memblock_memory = &memblock.memory;
} while (0)
static int memblock_debug __initdata_memblock;
-static bool system_has_some... |
35216718c9ac2aef934ea9cd229572d4996807b2 | Analyze and fix the following issue in the Linux kernel code: pinctrl: at91: fix a couple NULL vs IS_ERR() checks | Problem Details:
The devm_kasprintf_strarray() function doesn't return NULL on error,
it returns error pointers. Update the checks accordingly.
Fixes: f494c1913cbb ("pinctrl: at91: use devm_kasprintf() to avoid potential leaks (part 2)")
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Reviewed-by: Claudiu Bez... | ```diff
diff --git a/drivers/pinctrl/pinctrl-at91.c b/drivers/pinctrl/pinctrl-at91.c
index 871209c24153..39956d821ad7 100644
--- a/drivers/pinctrl/pinctrl-at91.c
+++ b/drivers/pinctrl/pinctrl-at91.c
@@ -1389,8 +1389,8 @@ static int at91_pinctrl_probe(struct platform_device *pdev)
char **names;
names = devm_kasp... |
6b0db163ff9200a55dc77a652dad1d4b0a853f63 | Analyze and fix the following issue in the Linux kernel code: ARM: dts: at91: sama7g5ek: fix debounce delay property for shdwc | Problem Details:
There is no atmel,shdwc-debouncer property for SHDWC. The right DT property
is debounce-delay-us. Use it.
Fixes: 16b161bcf5d4 ("ARM: dts: at91: sama7g5: add shdwc node")
Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com>
Acked-by: Nicolas Ferre <nicolas.ferre@microchip.com>
Link: https://lor... | ```diff
diff --git a/arch/arm/boot/dts/at91-sama7g5ek.dts b/arch/arm/boot/dts/at91-sama7g5ek.dts
index aa5cc0e98bba..217e9b96c61e 100644
--- a/arch/arm/boot/dts/at91-sama7g5ek.dts
+++ b/arch/arm/boot/dts/at91-sama7g5ek.dts
@@ -792,7 +792,7 @@
};
&shdwc {
- atmel,shdwc-debouncer = <976>;
+ debounce-delay-us = <976>;... |
772be1da8e51ad087b88372e8df10ba4a571f9af | Analyze and fix the following issue in the Linux kernel code: pinctrl: at91-pio4: Enable Push-Pull configuration | Problem Details:
Enable push-pull configuration. Remove integer value argument from
open-drain configuration as it is discarded when pinconf function is
called from gpiolib. Add push-pull do debug and get functions.
Signed-off-by: Ryan Wanner <Ryan.Wanner@microchip.com>
Acked-by: Nicolas Ferre <nicolas.ferre@microchip... | ```diff
diff --git a/drivers/pinctrl/pinctrl-at91-pio4.c b/drivers/pinctrl/pinctrl-at91-pio4.c
index 2fe40acb6a3e..d402ac4b10db 100644
--- a/drivers/pinctrl/pinctrl-at91-pio4.c
+++ b/drivers/pinctrl/pinctrl-at91-pio4.c
@@ -762,6 +762,11 @@ static int atmel_conf_pin_config_group_get(struct pinctrl_dev *pctldev,
retu... |
ccd4923d18d5698a5910d516646ce125b9155d47 | Analyze and fix the following issue in the Linux kernel code: ARM: at91: pm: fix imbalanced reference counter for ethernet devices | Problem Details:
The of_find_device_by_node() function is returning a struct platform_device
object with the embedded struct device member's reference counter
incremented. This needs to be dropped when done with the platform device
returned by of_find_device_by_node().
at91_pm_eth_quirk_is_valid() calls of_find_device... | ```diff
diff --git a/arch/arm/mach-at91/pm.c b/arch/arm/mach-at91/pm.c
index 60dc56d8acfb..437dd0352fd4 100644
--- a/arch/arm/mach-at91/pm.c
+++ b/arch/arm/mach-at91/pm.c
@@ -334,16 +334,14 @@ static bool at91_pm_eth_quirk_is_valid(struct at91_pm_quirk_eth *eth)
pdev = of_find_device_by_node(eth->np);
if (!pdev)
... |
878ecb0897f4737a4c9401f3523fd49589025671 | Analyze and fix the following issue in the Linux kernel code: ipv6: Fix out-of-bounds access in ipv6_find_tlv() | Problem Details:
optlen is fetched without checking whether there is more than one byte to parse.
It can lead to out-of-bounds access.
Found by InfoTeCS on behalf of Linux Verification Center
(linuxtesting.org) with SVACE.
Fixes: c61a40432509 ("[IPV6]: Find option offset by type.")
Signed-off-by: Gavrilov Ilia <Ilia.... | ```diff
diff --git a/net/ipv6/exthdrs_core.c b/net/ipv6/exthdrs_core.c
index da46c4284676..49e31e4ae7b7 100644
--- a/net/ipv6/exthdrs_core.c
+++ b/net/ipv6/exthdrs_core.c
@@ -143,6 +143,8 @@ int ipv6_find_tlv(const struct sk_buff *skb, int offset, int type)
optlen = 1;
break;
default:
+ if (len < 2)
+ g... |
dafb82e7d39767f11660705a518a551251fbdfe4 | Analyze and fix the following issue in the Linux kernel code: ALSA: ump: Correct snd_ump_midi1_msg_program definition | Problem Details:
The #endif is placed obviously at a wrong position, which caused a
build error on the big endian machine.
Fixes: 0b5288f5fe63 ("ALSA: ump: Add legacy raw MIDI support")
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Link: https://lore.kernel.org/r/20230524135448.3ecad334@canb.auug.org.au
Signe... | ```diff
diff --git a/include/sound/ump_msg.h b/include/sound/ump_msg.h
index c76c39944a5f..a594ef951b54 100644
--- a/include/sound/ump_msg.h
+++ b/include/sound/ump_msg.h
@@ -192,13 +192,13 @@ struct snd_ump_midi1_msg_program {
u32 program:8;
u32 reserved:8;
#else
-#endif
u32 reserved:8;
u32 program:8;
u32 c... |
04910d8cbfed65dad21c31723c6c1a8d9f990fb6 | Analyze and fix the following issue in the Linux kernel code: net: ethernet: mtk_eth_soc: fix QoS on DSA MAC on non MTK_NETSYS_V2 SoCs | Problem Details:
The commit c6d96df9fa2c ("net: ethernet: mtk_eth_soc: drop generic vlan rx
offload, only use DSA untagging") makes VLAN RX offloading to be only used
on the SoCs without the MTK_NETSYS_V2 ability (which are not just MT7621
and MT7622). The commit disables the proper handling of special tagged
(DSA) fra... | ```diff
diff --git a/drivers/net/ethernet/mediatek/mtk_eth_soc.c b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
index a75fd072082c..834c644b67db 100644
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
@@ -3269,18 +3269,14 @@ static int mtk_open(struct net_device *dev)
... |
88a9ded93453dea6748572242faf30f199be4f41 | Analyze and fix the following issue in the Linux kernel code: thunderbolt: dma_test: Update MODULE_DESCRIPTION | Problem Details:
Make the description match the core driver and the networking with
Thunderbolt/USB4 prefix. No functional changes.
Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com> | ```diff
diff --git a/drivers/thunderbolt/dma_test.c b/drivers/thunderbolt/dma_test.c
index 3bedecb236e0..c29cf620ee7d 100644
--- a/drivers/thunderbolt/dma_test.c
+++ b/drivers/thunderbolt/dma_test.c
@@ -756,5 +756,5 @@ module_exit(dma_test_exit);
MODULE_AUTHOR("Isaac Hazan <isaac.hazan@intel.com>");
MODULE_AUTHOR("... |
ccdb0900a0c3b0b56af5f547cceb64ee8d09483f | Analyze and fix the following issue in the Linux kernel code: thunderbolt: Add debug log for link controller power quirk | Problem Details:
Add a debug log to this quirk as well so we can see what quirks have
been applied when debugging.
Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com> | ```diff
diff --git a/drivers/thunderbolt/quirks.c b/drivers/thunderbolt/quirks.c
index 928689b66126..854d84148850 100644
--- a/drivers/thunderbolt/quirks.c
+++ b/drivers/thunderbolt/quirks.c
@@ -10,6 +10,7 @@
static void quirk_force_power_link(struct tb_switch *sw)
{
sw->quirks |= QUIRK_FORCE_POWER_LINK_CONTROLLER;... |
e14fd2af7a1d621c167dad761f729135a7a76ff4 | Analyze and fix the following issue in the Linux kernel code: dmaengine: at_hdmac: Extend the Flow Controller bitfield to three bits | Problem Details:
Some chips have two bits (e.g SAMA5D3), and some have three (e.g.
SAM9G45). A field width of three is compatible as long as valid
values are used for the different chips.
There is no current use of any value needing three bits, so the
fixed bug is relatively benign.
Fixes: d8840a7edcf0 ("dmaengine: a... | ```diff
diff --git a/drivers/dma/at_hdmac.c b/drivers/dma/at_hdmac.c
index 6362013b90df..ee3a219e3a89 100644
--- a/drivers/dma/at_hdmac.c
+++ b/drivers/dma/at_hdmac.c
@@ -132,7 +132,7 @@
#define ATC_DST_PIP BIT(12) /* Destination Picture-in-Picture enabled */
#define ATC_SRC_DSCR_DIS BIT(16) /* Src Descriptor fetc... |
2a6c7e8cc74e58ba94b8c897035a8ef7f7349f76 | Analyze and fix the following issue in the Linux kernel code: dmaengine: at_hdmac: Repair bitfield macros for peripheral ID handling | Problem Details:
The MSB part of the peripheral IDs need to go into the ATC_SRC_PER_MSB
and ATC_DST_PER_MSB fields. Not the LSB part.
This fixes a severe regression for TSE-850 devices (compatible
axentia,tse850v3) where output to the audio I2S codec (the main
purpose of the device) simply do not work.
Fixes: d8840a7... | ```diff
diff --git a/drivers/dma/at_hdmac.c b/drivers/dma/at_hdmac.c
index 8858470246e1..6362013b90df 100644
--- a/drivers/dma/at_hdmac.c
+++ b/drivers/dma/at_hdmac.c
@@ -153,8 +153,6 @@
#define ATC_AUTO BIT(31) /* Auto multiple buffer tx enable */
/* Bitfields in CFG */
-#define ATC_PER_MSB(h) ((0x30U & (h)) >> ... |
a1a5f2c887252dec161c1e12e04303ca9ba56fa9 | Analyze and fix the following issue in the Linux kernel code: dmaengine: pl330: rename _start to prevent build error | Problem Details:
"_start" is used in several arches and proably should be reserved
for ARCH usage. Using it in a driver for a private symbol can cause
a build error when it conflicts with ARCH usage of the same symbol.
Therefore rename pl330's "_start" to "pl330_start_thread" so that there
is no conflict and no build ... | ```diff
diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c
index 0d9257fbdfb0..b4731fe6bbc1 100644
--- a/drivers/dma/pl330.c
+++ b/drivers/dma/pl330.c
@@ -1050,7 +1050,7 @@ static bool _trigger(struct pl330_thread *thrd)
return true;
}
-static bool _start(struct pl330_thread *thrd)
+static bool pl330_start_thr... |
2f5edd03ca0d7221a88236b344b84f3fc301b1e3 | Analyze and fix the following issue in the Linux kernel code: sysctl: Refactor base paths registrations | Problem Details:
This is part of the general push to deprecate register_sysctl_paths and
register_sysctl_table. The old way of doing this through
register_sysctl_base and DECLARE_SYSCTL_BASE macro is replaced with a
call to register_sysctl_init. The 5 base paths affected are: "kernel",
"vm", "debug", "dev" and "fs".
W... | ```diff
diff --git a/fs/sysctls.c b/fs/sysctls.c
index c701273c9432..76a0aee8c229 100644
--- a/fs/sysctls.c
+++ b/fs/sysctls.c
@@ -29,11 +29,10 @@ static struct ctl_table fs_shared_sysctls[] = {
{ }
};
-DECLARE_SYSCTL_BASE(fs, fs_shared_sysctls);
-
static int __init init_fs_sysctls(void)
{
- return register_sysc... |
8a02fb71d7192ff1a9a47c9d937624966c6e09af | Analyze and fix the following issue in the Linux kernel code: net: fix skb leak in __skb_tstamp_tx() | Problem Details:
Commit 50749f2dd685 ("tcp/udp: Fix memleaks of sk and zerocopy skbs with
TX timestamp.") added a call to skb_orphan_frags_rx() to fix leaks with
zerocopy skbs. But it ended up adding a leak of its own. When
skb_orphan_frags_rx() fails, the function just returns, leaking the skb
it just cloned. Free it ... | ```diff
diff --git a/net/core/skbuff.c b/net/core/skbuff.c
index 515ec5cdc79c..cea28d30abb5 100644
--- a/net/core/skbuff.c
+++ b/net/core/skbuff.c
@@ -5224,8 +5224,10 @@ void __skb_tstamp_tx(struct sk_buff *orig_skb,
} else {
skb = skb_clone(orig_skb, GFP_ATOMIC);
- if (skb_orphan_frags_rx(skb, GFP_ATOMIC))
+ ... |
d6c36cbc5e533f48bd89a7b5f339bd82b8b4378a | Analyze and fix the following issue in the Linux kernel code: r8169: Use a raw_spinlock_t for the register locks. | Problem Details:
The driver's interrupt service routine is requested with the
IRQF_NO_THREAD if MSI is available. This means that the routine is
invoked in hardirq context even on PREEMPT_RT. The routine itself is
relatively short and schedules a worker, performs register access and
schedules NAPI. On PREEMPT_RT, sched... | ```diff
diff --git a/drivers/net/ethernet/realtek/r8169_main.c b/drivers/net/ethernet/realtek/r8169_main.c
index a7e376e7e689..4b19803a7dd0 100644
--- a/drivers/net/ethernet/realtek/r8169_main.c
+++ b/drivers/net/ethernet/realtek/r8169_main.c
@@ -616,10 +616,10 @@ struct rtl8169_private {
struct work_struct work;
... |
368d3cb406cdd074d1df2ad9ec06d1bfcb664882 | Analyze and fix the following issue in the Linux kernel code: page_pool: fix inconsistency for page_pool_ring_[un]lock() | Problem Details:
page_pool_ring_[un]lock() use in_softirq() to decide which
spin lock variant to use, and when they are called in the
context with in_softirq() being false, spin_lock_bh() is
called in page_pool_ring_lock() while spin_unlock() is
called in page_pool_ring_unlock(), because spin_lock_bh()
has disabled the... | ```diff
diff --git a/include/net/page_pool.h b/include/net/page_pool.h
index c8ec2f34722b..126f9e294389 100644
--- a/include/net/page_pool.h
+++ b/include/net/page_pool.h
@@ -399,22 +399,4 @@ static inline void page_pool_nid_changed(struct page_pool *pool, int new_nid)
page_pool_update_nid(pool, new_nid);
}
-stat... |
e30fbc618e97b38dbb49f1d44dcd0778d3f23b8c | Analyze and fix the following issue in the Linux kernel code: tracing/histograms: Allow variables to have some modifiers | Problem Details:
Modifiers are used to change the behavior of keys. For instance, they
can grouped into buckets, converted to syscall names (from the syscall
identifier), show task->comm of the current pid, be an array of longs
that represent a stacktrace, and more.
It was found that nothing stopped a value from takin... | ```diff
diff --git a/kernel/trace/trace_events_hist.c b/kernel/trace/trace_events_hist.c
index 486cca3c2b75..543cb7dc84ad 100644
--- a/kernel/trace/trace_events_hist.c
+++ b/kernel/trace/trace_events_hist.c
@@ -4238,13 +4238,19 @@ static int __create_val_field(struct hist_trigger_data *hist_data,
goto out;
}
- /... |
633c8b9409f564ce4b7f7944c595ffac27ed1ff4 | Analyze and fix the following issue in the Linux kernel code: f2fs: fix the wrong condition to determine atomic context | Problem Details:
Should use !in_task for irq context.
Cc: stable@vger.kernel.org
Fixes: 1aa161e43106 ("f2fs: fix scheduling while atomic in decompression path")
Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> | ```diff
diff --git a/fs/f2fs/compress.c b/fs/f2fs/compress.c
index 11653fa79289..10b545a1088e 100644
--- a/fs/f2fs/compress.c
+++ b/fs/f2fs/compress.c
@@ -743,7 +743,7 @@ void f2fs_decompress_cluster(struct decompress_io_ctx *dic, bool in_task)
ret = -EFSCORRUPTED;
/* Avoid f2fs_commit_super in irq context */
-... |
aaecdaf922835ed9a8ce56cdd9a8d40fe630257a | Analyze and fix the following issue in the Linux kernel code: tracing/user_events: Remove RCU lock while pinning pages | Problem Details:
pin_user_pages_remote() can reschedule which means we cannot hold any
RCU lock while using it. Now that enablers are not exposed out to the
tracing register callbacks during fork(), there is clearly no need to
require the RCU lock as event_mutex is enough to protect changes.
Remove unneeded RCU usages... | ```diff
diff --git a/kernel/trace/trace_events_user.c b/kernel/trace/trace_events_user.c
index 599aab46a94b..d34a59630e70 100644
--- a/kernel/trace/trace_events_user.c
+++ b/kernel/trace/trace_events_user.c
@@ -439,9 +439,8 @@ static bool user_event_enabler_exists(struct user_event_mm *mm,
unsigned long uadd... |
95a9359ee22ff2efbad6b090fcfa3a97f5902f95 | Analyze and fix the following issue in the Linux kernel code: tpm: tpm_tis: Disable interrupts for AEON UPX-i11 | Problem Details:
Interrupts got recently enabled for tpm_tis.
The interrupts initially works on the device but they will stop arriving
after circa ~200 interrupts. On system reboot/shutdown this will cause a
long wait (120000 jiffies).
[jarkko@kernel.org: fix a merge conflict and adjust the commit message]
Fixes: e64... | ```diff
diff --git a/drivers/char/tpm/tpm_tis.c b/drivers/char/tpm/tpm_tis.c
index 709b4e13bd6e..7db3593941ea 100644
--- a/drivers/char/tpm/tpm_tis.c
+++ b/drivers/char/tpm/tpm_tis.c
@@ -138,6 +138,13 @@ static const struct dmi_system_id tpm_tis_dmi_table[] = {
DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad L490"),
},... |
4be47a5d59cbc9396a6ffd327913eb4c8d67a32f | Analyze and fix the following issue in the Linux kernel code: spi: mt65xx: make sure operations completed before unloading | Problem Details:
When unloading the spi-mt65xx kernel module during an ongoing spi-mem
operation the kernel will Oops shortly after unloading the module.
This is because wait_for_completion_timeout was still running and
returning into the no longer loaded module:
Internal error: Oops: 0000000096000005 [#1] SMP
Modules... | ```diff
diff --git a/drivers/spi/spi-mt65xx.c b/drivers/spi/spi-mt65xx.c
index 21c321f43766..d7432e2219d8 100644
--- a/drivers/spi/spi-mt65xx.c
+++ b/drivers/spi/spi-mt65xx.c
@@ -1275,6 +1275,9 @@ static int mtk_spi_remove(struct platform_device *pdev)
struct mtk_spi *mdata = spi_master_get_devdata(master);
int ret... |
feee70f4568650cf44c573488798ffc0a2faeea3 | Analyze and fix the following issue in the Linux kernel code: Input: xpad - delete a Razer DeathAdder mouse VID/PID entry | Problem Details:
While doing my research to improve the xpad device names I noticed
that the 1532:0037 VID/PID seems to be used by the DeathAdder 2013,
so that Razer Sabertooth instance looked wrong and very suspect to
me. I didn't see any mention in the official drivers, either.
After doing more research, it turns ou... | ```diff
diff --git a/drivers/input/joystick/xpad.c b/drivers/input/joystick/xpad.c
index 28be88e0e96a..f33622fe946f 100644
--- a/drivers/input/joystick/xpad.c
+++ b/drivers/input/joystick/xpad.c
@@ -281,7 +281,6 @@ static const struct xpad_device {
{ 0x1430, 0xf801, "RedOctane Controller", 0, XTYPE_XBOX360 },
{ 0x1... |
912b625b4dcf23f6c16a950227715c75ef027e7b | Analyze and fix the following issue in the Linux kernel code: vfio/pci: demote hiding ecap messages to debug level | Problem Details:
Seeing a burst of messages like this:
vfio-pci 0000:98:00.0: vfio_ecap_init: hiding ecap 0x19@0x1d0
vfio-pci 0000:98:00.0: vfio_ecap_init: hiding ecap 0x25@0x200
vfio-pci 0000:98:00.0: vfio_ecap_init: hiding ecap 0x26@0x210
vfio-pci 0000:98:00.0: vfio_ecap_init: hiding ecap 0x27@0x250
... | ```diff
diff --git a/drivers/vfio/pci/vfio_pci_config.c b/drivers/vfio/pci/vfio_pci_config.c
index 948cdd464f4e..1d95fe435f0e 100644
--- a/drivers/vfio/pci/vfio_pci_config.c
+++ b/drivers/vfio/pci/vfio_pci_config.c
@@ -1643,8 +1643,8 @@ static int vfio_ecap_init(struct vfio_pci_core_device *vdev)
}
if (!len) {
... |
4ef4aee67eed640064fff95a693c0184cedb7bec | Analyze and fix the following issue in the Linux kernel code: cifs: Fix cifs_limit_bvec_subset() to correctly check the maxmimum size | Problem Details:
Fix cifs_limit_bvec_subset() so that it limits the span to the maximum
specified and won't return with a size greater than max_size.
Fixes: d08089f649a0 ("cifs: Change the I/O paths to use an iterator rather than a page list")
Cc: stable@vger.kernel.org # 6.3
Reported-by: Shyam Prasad N <sprasad@micro... | ```diff
diff --git a/fs/cifs/file.c b/fs/cifs/file.c
index ba7f2e09d6c8..df88b8c04d03 100644
--- a/fs/cifs/file.c
+++ b/fs/cifs/file.c
@@ -3353,9 +3353,10 @@ static size_t cifs_limit_bvec_subset(const struct iov_iter *iter, size_t max_siz
while (n && ix < nbv) {
len = min3(n, bvecs[ix].bv_len - skip, max_size);
... |
f3ae82534ab221f24225dbf03120462e8ae64636 | Analyze and fix the following issue in the Linux kernel code: iio: imu: inv_icm42600: avoid frequent timestamp jitter | Problem Details:
We are currently synchronizing every time the data timestamp with
the IT timestamp, leading to system jitter jamming timestamps.
To fix that and keep it simple, let's just synchronize when the
delta is bigger than the acceptable jitter, and keep
synchronization at the jitter value.
The result is much ... | ```diff
diff --git a/drivers/iio/imu/inv_icm42600/inv_icm42600_timestamp.c b/drivers/iio/imu/inv_icm42600/inv_icm42600_timestamp.c
index 7f2dc41f807b..37cbf08acb3a 100644
--- a/drivers/iio/imu/inv_icm42600/inv_icm42600_timestamp.c
+++ b/drivers/iio/imu/inv_icm42600/inv_icm42600_timestamp.c
@@ -93,8 +93,8 @@ static bool... |
4752354af71043e6fd72ef5490ed6da39e6cab4a | Analyze and fix the following issue in the Linux kernel code: vfio/type1: check pfn valid before converting to struct page | Problem Details:
Check physical PFN is valid before converting the PFN to a struct page
pointer to be returned to caller of vfio_pin_pages().
vfio_pin_pages() pins user pages with contiguous IOVA.
If the IOVA of a user page to be pinned belongs to vma of vm_flags
VM_PFNMAP, pin_user_pages_remote() will return -EFAULT ... | ```diff
diff --git a/drivers/vfio/vfio_iommu_type1.c b/drivers/vfio/vfio_iommu_type1.c
index 3d4dd9420c30..0d2f805468e1 100644
--- a/drivers/vfio/vfio_iommu_type1.c
+++ b/drivers/vfio/vfio_iommu_type1.c
@@ -860,6 +860,11 @@ static int vfio_iommu_type1_pin_pages(void *iommu_data,
if (ret)
goto pin_unwind;
+ if... |
1ca04f21b204e99dd704146231adfb79ea2fb366 | Analyze and fix the following issue in the Linux kernel code: remoteproc: stm32: Fix error code in stm32_rproc_parse_dt() | Problem Details:
There is a cut and paste bug so this code was returning the wrong
variable. It should have been "ddata->hold_boot_rst" instead of
"ddata->rst".
Fixes: de598695a2ad ("remoteproc: stm32: Allow hold boot management by the SCMI reset controller")
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Re... | ```diff
diff --git a/drivers/remoteproc/stm32_rproc.c b/drivers/remoteproc/stm32_rproc.c
index 0e322697d210..a7457777aae4 100644
--- a/drivers/remoteproc/stm32_rproc.c
+++ b/drivers/remoteproc/stm32_rproc.c
@@ -755,7 +755,7 @@ static int stm32_rproc_parse_dt(struct platform_device *pdev,
ddata->hold_boot_rst = devm... |
320805ab61e5f1e2a5729ae266e16bec2904050c | Analyze and fix the following issue in the Linux kernel code: Drivers: hv: vmbus: Fix vmbus_wait_for_unload() to scan present CPUs | Problem Details:
vmbus_wait_for_unload() may be called in the panic path after other
CPUs are stopped. vmbus_wait_for_unload() currently loops through
online CPUs looking for the UNLOAD response message. But the values of
CONFIG_KEXEC_CORE and crash_kexec_post_notifiers affect the path used
to stop the other CPUs, and ... | ```diff
diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c
index 007f26d5f1a4..2f4d09ce027a 100644
--- a/drivers/hv/channel_mgmt.c
+++ b/drivers/hv/channel_mgmt.c
@@ -829,11 +829,22 @@ static void vmbus_wait_for_unload(void)
if (completion_done(&vmbus_connection.unload_event))
goto completed;
-... |
acd4d219798769a6c1080bcfa7953e165dd8d681 | Analyze and fix the following issue in the Linux kernel code: ASoC: mediatek: mt6359: fix kselftest error of playback gain | Problem Details:
kselftest tries to read/write the default value. The default register
value of playback gain is 0x1F(mute), but max gain we specified is 0x12.
The range of the control is 0x0~0x12 and mute(0x1F) is only used in the
driver internally. To solve the problem, implement a new callback
mt6359_get_playback_vo... | ```diff
diff --git a/sound/soc/codecs/mt6359.c b/sound/soc/codecs/mt6359.c
index d6a93da2644e..65e6d4d08b6a 100644
--- a/sound/soc/codecs/mt6359.c
+++ b/sound/soc/codecs/mt6359.c
@@ -360,8 +360,34 @@ static int mt6359_put_volsw(struct snd_kcontrol *kcontrol,
(struct soc_mixer_control *)kcontrol->private_value;
un... |
e2d035f5a7d597bbabc268e236ec6c0408c4af0e | Analyze and fix the following issue in the Linux kernel code: ASoC: cs35l41: Fix default regmap values for some registers | Problem Details:
Several values do not match the defaults of CS35L41, fix them.
Signed-off-by: Stefan Binding <sbinding@opensource.cirrus.com>
Acked-by: Mark Brown <broonie@kernel.org>
Link: https://lore.kernel.org/r/20230414152552.574502-4-sbinding@opensource.cirrus.com
Signed-off-by: Mark Brown <broonie@kernel.org> | ```diff
diff --git a/sound/soc/codecs/cs35l41-lib.c b/sound/soc/codecs/cs35l41-lib.c
index 8538e2871c5f..1e4205295a0d 100644
--- a/sound/soc/codecs/cs35l41-lib.c
+++ b/sound/soc/codecs/cs35l41-lib.c
@@ -46,7 +46,7 @@ static const struct reg_default cs35l41_reg[] = {
{ CS35L41_DSP1_RX5_SRC, 0x00000020 },
{ CS35L41... |
22a94021e7d2b456c6abb59ad0a7ce4e94933d4a | Analyze and fix the following issue in the Linux kernel code: regulator: rk808: revert to synchronous probing | Problem Details:
The rk808 driver registers a bunch of regulator devices in a loop.
If one of the later regulators fails to register (usually because
its input supply is not yet available) everything will be unrolled
(i.e. previously registered regulators will be unregistered). With
asynchronous registration there migh... | ```diff
diff --git a/drivers/regulator/rk808-regulator.c b/drivers/regulator/rk808-regulator.c
index 71a1ca8b917e..5f14d6dd4593 100644
--- a/drivers/regulator/rk808-regulator.c
+++ b/drivers/regulator/rk808-regulator.c
@@ -1355,7 +1355,7 @@ static struct platform_driver rk808_regulator_driver = {
.probe = rk808_regul... |
1b9e86d445a0f5c6d8dcbaf11508cb5dfb5848a8 | Analyze and fix the following issue in the Linux kernel code: regulator: rk808: fix asynchronous probing | Problem Details:
If the probe routine fails with -EPROBE_DEFER after taking over the
OF node from its parent driver, reprobing triggers pinctrl_bind_pins()
and that will fail. Fix this by setting of_node_reused, so that the
device does not try to setup pin muxing.
For me this always happens once the driver is marked t... | ```diff
diff --git a/drivers/regulator/rk808-regulator.c b/drivers/regulator/rk808-regulator.c
index 3637e81654a8..80ba782d8923 100644
--- a/drivers/regulator/rk808-regulator.c
+++ b/drivers/regulator/rk808-regulator.c
@@ -1336,6 +1336,7 @@ static int rk808_regulator_probe(struct platform_device *pdev)
config.dev =... |
7a2280e8dcd2f1f436db9631287c0b21cf6a92b0 | Analyze and fix the following issue in the Linux kernel code: drm/i915: Wait for active retire before i915_active_fini() | Problem Details:
i915_active_fini() finalizes the debug object, which can occur before
the active retires and deactivates the debug object. Wait for one
final time before calling i915_active_fini();
Closes:: https://gitlab.freedesktop.org/drm/intel/-/issues/8311
Signed-off-by: Nirmoy Das <nirmoy.das@intel.com>
Reviewe... | ```diff
diff --git a/drivers/gpu/drm/i915/i915_vma.c b/drivers/gpu/drm/i915/i915_vma.c
index 20a44788999e..bad698bece27 100644
--- a/drivers/gpu/drm/i915/i915_vma.c
+++ b/drivers/gpu/drm/i915/i915_vma.c
@@ -1710,6 +1710,8 @@ static void release_references(struct i915_vma *vma, struct intel_gt *gt,
if (vm_ddestroy)
... |
37cee4876a45a5c3da79a83d34ed4f3c68548aef | Analyze and fix the following issue in the Linux kernel code: drm/bridge: dw-hdmi: Replace all non-returning strlcpy with strscpy | Problem Details:
strlcpy() reads the entire source buffer first.
This read may exceed the destination size limit.
This is both inefficient and can lead to linear read
overflows if a source string is not NUL-terminated [1].
In an effort to remove strlcpy() completely [2], replace
strlcpy() here with strscpy().
No return... | ```diff
diff --git a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c
index 603bb3c51027..9d6dcaf317a1 100644
--- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c
+++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c
@@ -533,7 +533,7 @@ static struct i2c_adapter *dw_hdmi_i2c_adapter(struct dw_... |
1464e48d69ab7a50a377c9d39f5e5eb3cee2722e | Analyze and fix the following issue in the Linux kernel code: drm/bridge: anx7625: Prevent endless probe loop | Problem Details:
During probe, the driver registers i2c dummy devices and populates the
aux bus, which registers a device for the panel. After doing that, the
driver can still defer probe if needed. This ordering of operations is
troublesome however, because the deferred probe work will retry probing
all pending device... | ```diff
diff --git a/drivers/gpu/drm/bridge/analogix/anx7625.c b/drivers/gpu/drm/bridge/analogix/anx7625.c
index 093e7b9a570f..c86531f7b072 100644
--- a/drivers/gpu/drm/bridge/analogix/anx7625.c
+++ b/drivers/gpu/drm/bridge/analogix/anx7625.c
@@ -1686,6 +1686,14 @@ static int anx7625_parse_dt(struct device *dev,
if (... |
a13bd91be22318768d55470cbc0b0f4488ef9edf | Analyze and fix the following issue in the Linux kernel code: block/rq_qos: protect rq_qos apis with a new lock | Problem Details:
commit 50e34d78815e ("block: disable the elevator int del_gendisk")
move rq_qos_exit() from disk_release() to del_gendisk(), this will
introduce some problems:
1) If rq_qos_add() is triggered by enabling iocost/iolatency through
cgroupfs, then it can concurrent with del_gendisk(), it's not safe to
... | ```diff
diff --git a/block/blk-cgroup.c b/block/blk-cgroup.c
index 0ce64dd73cfe..1c6716f51fff 100644
--- a/block/blk-cgroup.c
+++ b/block/blk-cgroup.c
@@ -748,6 +748,13 @@ int blkg_conf_open_bdev(struct blkg_conf_ctx *ctx)
return -ENODEV;
}
+ mutex_lock(&bdev->bd_queue->rq_qos_mutex);
+ if (!disk_live(bdev->bd_d... |
46930b7cc7727271c9c27aac1fdc97a8645e2d00 | Analyze and fix the following issue in the Linux kernel code: block: fix bio-cache for passthru IO | Problem Details:
commit <8af870aa5b847> ("block: enable bio caching use for passthru IO")
introduced bio-cache for passthru IO. In case when nr_vecs are greater
than BIO_INLINE_VECS, bio and bvecs are allocated from mempool (instead
of percpu cache) and REQ_ALLOC_CACHE is cleared. This causes the side
effect of not fre... | ```diff
diff --git a/block/blk-map.c b/block/blk-map.c
index 04c55f1c492e..46eed2e627c3 100644
--- a/block/blk-map.c
+++ b/block/blk-map.c
@@ -248,7 +248,7 @@ static struct bio *blk_rq_map_bio_alloc(struct request *rq,
{
struct bio *bio;
- if (rq->cmd_flags & REQ_ALLOC_CACHE) {
+ if (rq->cmd_flags & REQ_ALLOC_CACH... |
3e94d54e83cafd2b562bb6d15bb2f72d76200fb5 | Analyze and fix the following issue in the Linux kernel code: blk-mq: fix race condition in active queue accounting | Problem Details:
If multiple CPUs are sharing the same hardware queue, it can
cause leak in the active queue counter tracking when __blk_mq_tag_busy()
is executed simultaneously.
Fixes: ee78ec1077d3 ("blk-mq: blk_mq_tag_busy is no need to return a value")
Signed-off-by: Tian Lan <tian.lan@twosigma.com>
Reviewed-by: Mi... | ```diff
diff --git a/block/blk-mq-tag.c b/block/blk-mq-tag.c
index d6af9d431dc6..dfd81cab5788 100644
--- a/block/blk-mq-tag.c
+++ b/block/blk-mq-tag.c
@@ -39,16 +39,20 @@ void __blk_mq_tag_busy(struct blk_mq_hw_ctx *hctx)
{
unsigned int users;
+ /*
+ * calling test_bit() prior to test_and_set_bit() is intentional... |
8a2b20a997a3779ae9fcae268f2959eb82ec05a1 | Analyze and fix the following issue in the Linux kernel code: blk-wbt: fix that wbt can't be disabled by default | Problem Details:
commit b11d31ae01e6 ("blk-wbt: remove unnecessary check in
wbt_enable_default()") removes the checking of CONFIG_BLK_WBT_MQ by
mistake, which is used to control enable or disable wbt by default.
Fix the problem by adding back the checking. This patch also do a litter
cleanup to make related code more ... | ```diff
diff --git a/block/blk-wbt.c b/block/blk-wbt.c
index e49a48684532..9ec2a2f1eda3 100644
--- a/block/blk-wbt.c
+++ b/block/blk-wbt.c
@@ -730,14 +730,16 @@ void wbt_enable_default(struct gendisk *disk)
{
struct request_queue *q = disk->queue;
struct rq_qos *rqos;
- bool disable_flag = q->elevator &&
- te... |
06c6796e0304234da65e70577f354cb194086521 | Analyze and fix the following issue in the Linux kernel code: cpu/hotplug: Fix off by one in cpuhp_bringup_mask() | Problem Details:
cpuhp_bringup_mask() iterates over a cpumask and starts all present CPUs up
to a caller provided upper limit.
The limit variable is decremented and checked for 0 before invoking
cpu_up(), which is obviously off by one and prevents the bringup of the
last CPU when the limit is equal to the number of pr... | ```diff
diff --git a/kernel/cpu.c b/kernel/cpu.c
index 005f863a3d2b..88a7ede322bd 100644
--- a/kernel/cpu.c
+++ b/kernel/cpu.c
@@ -1770,9 +1770,6 @@ static void __init cpuhp_bringup_mask(const struct cpumask *mask, unsigned int n
for_each_cpu(cpu, mask) {
struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu)... |
632478a05821bc1c9b55c3a1dd0fb1be7bfa1acc | Analyze and fix the following issue in the Linux kernel code: tracing/timerlat: Always wakeup the timerlat thread | Problem Details:
While testing rtla timerlat auto analysis, I reach a condition where
the interface was not receiving tracing data. I was able to manually
reproduce the problem with these steps:
# echo 0 > tracing_on # disable trace
# echo 1 > osnoise/stop_tracing_us # stop trace if timerlat irq... | ```diff
diff --git a/kernel/trace/trace_osnoise.c b/kernel/trace/trace_osnoise.c
index efbbec2caff8..e97e3fa5cbed 100644
--- a/kernel/trace/trace_osnoise.c
+++ b/kernel/trace/trace_osnoise.c
@@ -1652,6 +1652,8 @@ static enum hrtimer_restart timerlat_irq(struct hrtimer *timer)
osnoise_stop_tracing();
notify_new_... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.