id
stringlengths
40
40
instruction
stringlengths
68
308
input
stringlengths
17
33.4k
output
stringlengths
100
30k
a752447af5b61f19e9c50322d9b07cea9a086084
Analyze and fix the following issue in the Linux kernel code: crypto: talitos - sparse check endian fixes
Problem Details: Signed-off-by: Kim Phillips <kim.phillips@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
```diff diff --git a/drivers/crypto/talitos.c b/drivers/crypto/talitos.c index 1444f8c4dbdd..71e146562d82 100644 --- a/drivers/crypto/talitos.c +++ b/drivers/crypto/talitos.c @@ -161,7 +161,7 @@ struct talitos_private { static void to_talitos_ptr(struct talitos_ptr *talitos_ptr, dma_addr_t dma_addr) { talitos_ptr->...
0b798247453299c895e3fa1629101dd5e94901b2
Analyze and fix the following issue in the Linux kernel code: crypto: talitos - fix checkpatch warning
Problem Details: WARNING: kfree(NULL) is safe this check is probably not required + if (priv->chan[i].fifo) + kfree(priv->chan[i].fifo); Signed-off-by: Kim Phillips <kim.phillips@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
```diff diff --git a/drivers/crypto/talitos.c b/drivers/crypto/talitos.c index bbf39991c0d0..1444f8c4dbdd 100644 --- a/drivers/crypto/talitos.c +++ b/drivers/crypto/talitos.c @@ -2333,8 +2333,7 @@ static int talitos_remove(struct of_device *ofdev) talitos_unregister_rng(dev); for (i = 0; i < priv->num_channels; ...
1d11911a8c572041880c8d86229f6ed971f6f7e2
Analyze and fix the following issue in the Linux kernel code: crypto: talitos - fix warning: 'alg' may be used uninitialized in this function
Problem Details: drivers/crypto/talitos.c: In function 'talitos_probe': drivers/crypto/talitos.c:2363: warning: 'alg' may be used uninitialized in this function drivers/crypto/talitos.c:2363: note: 'alg' was declared here Signed-off-by: Kim Phillips <kim.phillips@freescale.com> Signed-off-by: Herbert Xu <herbert@gondo...
```diff diff --git a/drivers/crypto/talitos.c b/drivers/crypto/talitos.c index 97f4af1d8a64..bbf39991c0d0 100644 --- a/drivers/crypto/talitos.c +++ b/drivers/crypto/talitos.c @@ -2389,6 +2389,9 @@ static struct talitos_crypto_alg *talitos_alg_alloc(struct device *dev, DESC_HDR_MODE0_MDEU_SHA256; } break; + ...
9f5f9ffe50e90ed73040d2100db8bfc341cee352
Analyze and fix the following issue in the Linux kernel code: powerpc/perf: Fix sampling enable for PPC970
Problem Details: The logic to distinguish marked instruction events from ordinary events on PPC970 and derivatives was flawed. The result is that instruction sampling didn't get enabled in the PMU for some marked instruction events, so they would never trigger. This fixes it by adding the appropriate break statements...
```diff diff --git a/arch/powerpc/kernel/ppc970-pmu.c b/arch/powerpc/kernel/ppc970-pmu.c index 8eff48e20dba..3fee685de4df 100644 --- a/arch/powerpc/kernel/ppc970-pmu.c +++ b/arch/powerpc/kernel/ppc970-pmu.c @@ -169,9 +169,11 @@ static int p970_marked_instr_event(u64 event) switch (unit) { case PM_VPU: mask = 0x4...
095a0f6df246bdc57b57d616c4698e41fbd3bf43
Analyze and fix the following issue in the Linux kernel code: SOUND-OSS: Remove sh_dac_audio
Problem Details: Remove the SH DAC oss driver since there is an equivalent alsa driver. oss has been deprecated for years. Furthermore this driver has BKL code which we are trying to remove. Rather than attempt to fix this, simply remove the driver. Signed-off-by: John Kacur <jkacur@redhat.com> Acked-by: Paul Mundt <l...
```diff diff --git a/sound/oss/Kconfig b/sound/oss/Kconfig index a513651fa149..76c090218073 100644 --- a/sound/oss/Kconfig +++ b/sound/oss/Kconfig @@ -545,11 +545,3 @@ config SOUND_KAHLUA endif # SOUND_OSS -config SOUND_SH_DAC_AUDIO - tristate "SuperH DAC audio support" - depends on CPU_SH3 && HIGH_RES_TIMERS - -c...
831bd2e6a6c09588fdde453ecb858f050ac1b942
Analyze and fix the following issue in the Linux kernel code: e1000e: 82579 unaccounted missed packets
Problem Details: On 82579, there is a hardware bug that can cause received packets to not get transferred from the PHY to the MAC due to K1 (a power saving feature of the PHY-MAC interconnect similar to ASPM L1). Since the MAC controls the accounting of missed packets, these will go unnoticed. Workaround the issue by...
```diff diff --git a/drivers/net/e1000e/hw.h b/drivers/net/e1000e/hw.h index 66ed08f726fb..ba302a5c2c30 100644 --- a/drivers/net/e1000e/hw.h +++ b/drivers/net/e1000e/hw.h @@ -57,6 +57,7 @@ enum e1e_registers { E1000_SCTL = 0x00024, /* SerDes Control - RW */ E1000_FCAL = 0x00028, /* Flow Control Address Low ...
46eb3b64dddd20f44e76b08676fa642dd374bf1d
Analyze and fix the following issue in the Linux kernel code: jump label/x86/sparc64: Remove !CC_OPTIMIZE_FOR_SIZE config conditions
Problem Details: The !CC_OPTIMIZE_FOR_SIZE was added to enable the jump label functionality because Jason noticed that the gcc option would not optimize the labels and may even hurt performance. But this is a gcc problem not a kernel one. Removing this condition should add motivation to the gcc developers to actually ...
```diff diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig index a81b04e07fe7..9212cd42a832 100644 --- a/arch/sparc/Kconfig +++ b/arch/sparc/Kconfig @@ -30,7 +30,7 @@ config SPARC select PERF_USE_VMALLOC select HAVE_DMA_ATTRS select HAVE_DMA_API_DEBUG - select HAVE_ARCH_JUMP_LABEL if !CC_OPTIMIZE_FOR_SIZE + sel...
561f8182dbf24b1be9207038aa5f82e34be4bad1
Analyze and fix the following issue in the Linux kernel code: ipmi: fix hardcoded ipmi device exit path warning
Problem Details: When modprobe.conf has options ipmi_si type="kcs" ports=0xCA2 regspacings="4" ipmi_si can be loaded properly, but when try to unload it get: Sep 20 15:00:27 xx abrt: Kerneloops: Reported 1 kernel oopses to Abrt Sep 20 15:00:27 xx abrtd: Directory 'kerneloops-1285020027-1' creation detected Sep 20 15:...
```diff diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_intf.c index 2be457a0c0c3..7bd7c45b53ef 100644 --- a/drivers/char/ipmi/ipmi_si_intf.c +++ b/drivers/char/ipmi/ipmi_si_intf.c @@ -305,6 +305,9 @@ static int num_force_kipmid; #ifdef CONFIG_PCI static int pci_registered; #endif +#ifdef C...
f501ed524b26ba1b739b7f7feb0a0e1496878769
Analyze and fix the following issue in the Linux kernel code: rtc: s3c: balance state changes of wakeup flag
Problem Details: This change resolves a problem about unbalanced calls of enable_irq_wakeup() and disable_irq_wakeup() for alarm interrupt. Bug reproduction: root@eb600:~# echo 0 > /sys/class/rtc/rtc0/wakealarm WARNING: at kernel/irq/manage.c:361 set_irq_wake+0x7c/0xe4() Unbalanced IRQ 46 wake disable Modules linke...
```diff diff --git a/drivers/rtc/rtc-s3c.c b/drivers/rtc/rtc-s3c.c index a0d3ec89d412..f57a87f4ae96 100644 --- a/drivers/rtc/rtc-s3c.c +++ b/drivers/rtc/rtc-s3c.c @@ -310,11 +310,6 @@ static int s3c_rtc_setalarm(struct device *dev, struct rtc_wkalrm *alrm) s3c_rtc_setaie(alrm->enabled); - if (alrm->enabled) - en...
a247c3a97a0216b18a46243eda26081f1928ec37
Analyze and fix the following issue in the Linux kernel code: rmap: fix walk during fork
Problem Details: The below bug in fork led to the rmap walk finding the parent huge-pmd twice instead of just once, because the anon_vma_chain objects of the child vma still point to the vma->vm_mm of the parent. The patch fixes it by making the rmap walk accurate during fork. It's not a big deal normally but it wort...
```diff diff --git a/kernel/fork.c b/kernel/fork.c index b7e9d60a675d..c445f8cc408d 100644 --- a/kernel/fork.c +++ b/kernel/fork.c @@ -356,10 +356,10 @@ static int dup_mmap(struct mm_struct *mm, struct mm_struct *oldmm) if (IS_ERR(pol)) goto fail_nomem_policy; vma_set_policy(tmp, pol); + tmp->vm_mm = mm; ...
df08cdc7ef606509debe7677c439be0ca48790e4
Analyze and fix the following issue in the Linux kernel code: drivers/pci/intel-iommu.c: fix build with older gcc's
Problem Details: drivers/pci/intel-iommu.c: In function `__iommu_calculate_agaw': drivers/pci/intel-iommu.c:437: sorry, unimplemented: inlining failed in call to 'width_to_agaw': function body not available drivers/pci/intel-iommu.c:445: sorry, unimplemented: called from here Move the offending function (and its sibli...
```diff diff --git a/drivers/pci/intel-iommu.c b/drivers/pci/intel-iommu.c index c3ceebb5be84..5ac2aa783f58 100644 --- a/drivers/pci/intel-iommu.c +++ b/drivers/pci/intel-iommu.c @@ -71,6 +71,49 @@ #define DMA_32BIT_PFN IOVA_PFN(DMA_BIT_MASK(32)) #define DMA_64BIT_PFN IOVA_PFN(DMA_BIT_MASK(64)) +/* page table han...
cb1dcc0ff4b57873210100fc9d70defa81af43d4
Analyze and fix the following issue in the Linux kernel code: uml: fix compile warning
Problem Details: This fixes: incompatible pointer type: => 89 arch/um/kernel/exec.c: warning: passing argument 2 of 'execve1' from incompatible pointer type: => 69, 85 arch/um/kernel/exec.c: warning: passing argument 3 of 'execve1' from incompatible pointer type: => 69, 85 which was introduced by d762...
```diff diff --git a/arch/um/kernel/exec.c b/arch/um/kernel/exec.c index cd145eda3579..49b5e1eb3262 100644 --- a/arch/um/kernel/exec.c +++ b/arch/um/kernel/exec.c @@ -62,7 +62,7 @@ static long execve1(const char *file, return error; } -long um_execve(const char *file, char __user *__user *argv, char __user *__user...
1c2499ae87f828eabddf6483b0dfc11da1100c07
Analyze and fix the following issue in the Linux kernel code: /proc/pid/smaps: fix dirty pages accounting
Problem Details: Currently, /proc/<pid>/smaps has wrong dirty pages accounting. Shared_Dirty and Private_Dirty output only pte dirty pages and ignore PG_dirty page flag. It is difference against documentation, but also inconsistent against Referenced field. (Referenced checks both pte and page flags) This patch fixe...
```diff diff --git a/fs/proc/task_mmu.c b/fs/proc/task_mmu.c index 271afc48b9a5..1dbca4e8cc16 100644 --- a/fs/proc/task_mmu.c +++ b/fs/proc/task_mmu.c @@ -363,13 +363,13 @@ static int smaps_pte_range(pmd_t *pmd, unsigned long addr, unsigned long end, mss->referenced += PAGE_SIZE; mapcount = page_mapcount(page); ...
142092e577255e33a4ab74c6baad04c9fb887927
Analyze and fix the following issue in the Linux kernel code: fbcon: fix lockdep warning from fbcon_deinit()
Problem Details: Fix the lockdep warning: [ 13.657164] INFO: trying to register non-static key. [ 13.657169] the code is fine but needs lockdep annotation. [ 13.657171] turning off the locking correctness validator. [ 13.657177] Pid: 622, comm: modprobe Not tainted 2.6.36-rc3c #8 [ 13.657180] Call Trace: [ ...
```diff diff --git a/drivers/video/console/fbcon.c b/drivers/video/console/fbcon.c index 84f842331dfa..7ccc967831f0 100644 --- a/drivers/video/console/fbcon.c +++ b/drivers/video/console/fbcon.c @@ -3508,7 +3508,7 @@ static void fbcon_exit(void) softback_buf = 0UL; for (i = 0; i < FB_MAX; i++) { - int pending; +...
a5757c2a474a15f87e5baa9a4caacc31cde2bae6
Analyze and fix the following issue in the Linux kernel code: efifb: support the EFI framebuffer on more Apple hardware
Problem Details: Enable the EFI framebuffer on 14 more Macs, including the iMac11,1 iMac10,1 iMac8,1 Macmini3,1 Macmini4,1 MacBook5,1 MacBook6,1 MacBook7,1 MacBookPro2,2 MacBookPro5,2 MacBookPro5,3 MacBookPro6,1 MacBookPro6,2 and MacBookPro7,1 Information gathered from various user submissions. https://bugzilla.r...
```diff diff --git a/drivers/video/efifb.c b/drivers/video/efifb.c index c082b616f390..70477c2e4b61 100644 --- a/drivers/video/efifb.c +++ b/drivers/video/efifb.c @@ -39,17 +39,31 @@ enum { M_I20, /* 20-Inch iMac */ M_I20_SR, /* 20-Inch iMac (Santa Rosa) */ M_I24, /* 24-Inch iMac */ + M_I24_8_1, /* 24-Inch iMac...
85a00d9bbfb4704fbf368944b1cb9fed8f1598c5
Analyze and fix the following issue in the Linux kernel code: efifb: check that the base address is plausible on pci systems
Problem Details: Some Apple machines have identical DMI data but different memory configurations for the video. Given that, check that the address in our table is actually within the range of a PCI BAR on a VGA device in the machine. This also fixes up the return value from set_system(), which has always been wrong, ...
```diff diff --git a/MAINTAINERS b/MAINTAINERS index 726433a17998..4d4881d909da 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -2199,6 +2199,12 @@ W: http://acpi4asus.sf.net S: Maintained F: drivers/platform/x86/eeepc-laptop.c +EFIFB FRAMEBUFFER DRIVER +L: linux-fbdev@vger.kernel.org +M: Peter Jones <pjones@redhat.c...
d1908362ae0b97374eb8328fbb471576332f9fb1
Analyze and fix the following issue in the Linux kernel code: vmscan: check all_unreclaimable in direct reclaim path
Problem Details: M. Vefa Bicakci reported 2.6.35 kernel hang up when hibernation on his 32bit 3GB mem machine. (https://bugzilla.kernel.org/show_bug.cgi?id=16771). Also he bisected the regression to commit bb21c7ce18eff8e6e7877ca1d06c6db719376e3c Author: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Date: ...
```diff diff --git a/mm/vmscan.c b/mm/vmscan.c index c391c320dbaf..c5dfabf25f11 100644 --- a/mm/vmscan.c +++ b/mm/vmscan.c @@ -1804,12 +1804,11 @@ static void shrink_zone(int priority, struct zone *zone, * If a zone is deemed to be full of pinned pages then just give it a light * scan then give up on it. */ -stat...
710224fa2750cf449c02dd115548acebfdd2c86a
Analyze and fix the following issue in the Linux kernel code: arm: fix "arm: fix pci_set_consistent_dma_mask for dmabounce devices"
Problem Details: This fixes the regression caused by the commit 6fee48cd330c68 ("dma-mapping: arm: use generic pci_set_dma_mask and pci_set_consistent_dma_mask"). ARM needs to clip the dma coherent mask for dmabounce devices. This restores the old trick. Note that strictly speaking, the DMA API doesn't allow architec...
```diff diff --git a/arch/arm/common/it8152.c b/arch/arm/common/it8152.c index 7974baacafce..1bec96e85196 100644 --- a/arch/arm/common/it8152.c +++ b/arch/arm/common/it8152.c @@ -271,6 +271,14 @@ int dma_needs_bounce(struct device *dev, dma_addr_t dma_addr, size_t size) ((dma_addr + size - PHYS_OFFSET) >= SZ_64M); ...
c227e69028473c7c7994a9b0a2cc0034f3f7e0fe
Analyze and fix the following issue in the Linux kernel code: /proc/vmcore: fix seeking
Problem Details: Commit 73296bc611 ("procfs: Use generic_file_llseek in /proc/vmcore") broke seeking on /proc/vmcore. This changes it back to use default_llseek in order to restore the original behaviour. The problem with generic_file_llseek is that it only allows seeks up to inode->i_sb->s_maxbytes, which is zero on...
```diff diff --git a/fs/proc/vmcore.c b/fs/proc/vmcore.c index 91c817ff02c3..2367fb3f70bc 100644 --- a/fs/proc/vmcore.c +++ b/fs/proc/vmcore.c @@ -163,7 +163,7 @@ static ssize_t read_vmcore(struct file *file, char __user *buffer, static const struct file_operations proc_vmcore_operations = { .read = read_vmcore, ...
a9e31765e7d528858e1b0c202b823cf4df7577ca
Analyze and fix the following issue in the Linux kernel code: ipmi: fix acpi probe print
Problem Details: After d9e1b6c45059ccf ("ipmi: fix ACPI detection with regspacing") we get [ 11.026326] ipmi_si: probing via ACPI [ 11.030019] ipmi_si 00:09: (null) regsize 1 spacing 1 irq 0 [ 11.035594] ipmi_si: Adding ACPI-specified kcs state machine on an old system with only one range for ipmi kcs range. T...
```diff diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_intf.c index 3822b4f49c84..2be457a0c0c3 100644 --- a/drivers/char/ipmi/ipmi_si_intf.c +++ b/drivers/char/ipmi/ipmi_si_intf.c @@ -2126,7 +2126,7 @@ static int __devinit ipmi_pnp_probe(struct pnp_dev *dev, { struct acpi_device *acpi_dev;...
767b68e96993e29e3480d7ecdd9c4b84667c5762
Analyze and fix the following issue in the Linux kernel code: Prevent freeing uninitialized pointer in compat_do_readv_writev
Problem Details: In 32-bit compatibility mode, the error handling for compat_do_readv_writev() may free an uninitialized pointer, potentially leading to all sorts of ugly memory corruption. This is reliably triggerable by unprivileged users by invoking the readv()/writev() syscalls with an invalid iovec pointer. The ...
```diff diff --git a/fs/compat.c b/fs/compat.c index 718c7062aec1..0644a154672b 100644 --- a/fs/compat.c +++ b/fs/compat.c @@ -1153,7 +1153,7 @@ static ssize_t compat_do_readv_writev(int type, struct file *file, { compat_ssize_t tot_len; struct iovec iovstack[UIO_FASTIOV]; - struct iovec *iov; + struct iovec *iov ...
69f93faa57ed6c91b32aae1dcff7282fcb2872f5
Analyze and fix the following issue in the Linux kernel code: DMAENGINE: ste_dma40: fix possible use of uninitialized variable
Problem Details: Signed-off-by: Jonas Aaberg <jonas.aberg@stericsson.com> Signed-off-by: Linus Walleij <linus.walleij@stericsson.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com>
```diff diff --git a/drivers/dma/ste_dma40.c b/drivers/dma/ste_dma40.c index 2b209fa004ba..ac325e918171 100644 --- a/drivers/dma/ste_dma40.c +++ b/drivers/dma/ste_dma40.c @@ -684,12 +684,12 @@ static void d40_config_write(struct d40_chan *d40c) static void d40_desc_load(struct d40_chan *d40c, struct d40_desc *d40d) ...
0246e77b4d374bb37aa08c3fcadad20012e85ea0
Analyze and fix the following issue in the Linux kernel code: DMAENGINE: ste_dma40: fix bug related to callback handling
Problem Details: The callback got called even when it was not supposed to. Also removed some not needed interrupt trigger on/off code. Signed-off-by: Jonas Aaberg <jonas.aberg@stericsson.com> Signed-off-by: Linus Walleij <linus.walleij@stericsson.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com>
```diff diff --git a/drivers/dma/ste_dma40.c b/drivers/dma/ste_dma40.c index 1adaebf49774..a6a7d66df77a 100644 --- a/drivers/dma/ste_dma40.c +++ b/drivers/dma/ste_dma40.c @@ -878,7 +878,7 @@ static void dma_tasklet(unsigned long data) spin_unlock_irqrestore(&d40c->lock, flags); - if (callback) + if (callback && (...
be8cb7dfd92420b12dfd6831c2d638f4f46bdfdf
Analyze and fix the following issue in the Linux kernel code: DMAENGINE: ste_dma40: Fix failed to restart logical channel bug
Problem Details: A transfer that runs in the different direction on the same channel will now be resumed when the other is suspend/stopped. Signed-off-by: Jonas Aaberg <jonas.aberg@stericsson.com> Signed-off-by: Linus Walleij <linus.walleij@stericsson.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com>
```diff diff --git a/drivers/dma/ste_dma40.c b/drivers/dma/ste_dma40.c index df2e1a30ee7e..8aff86594141 100644 --- a/drivers/dma/ste_dma40.c +++ b/drivers/dma/ste_dma40.c @@ -640,19 +640,15 @@ static void d40_config_set_event(struct d40_chan *d40c, bool do_enable) static u32 d40_chan_has_events(struct d40_chan *d40c...
ec5a32f67c603b11d68eb283d94eb89a4f6cfce1
Analyze and fix the following issue in the Linux kernel code: atl1: fix resume
Problem Details: adapter->cmb.cmb is initialized when the device is opened and freed when it's closed. Accessing it unconditionally during resume results either in a crash (NULL pointer dereference, when the interface has not been opened yet) or data corruption (when the interface has been used and brought down adapter...
```diff diff --git a/drivers/net/atlx/atl1.c b/drivers/net/atlx/atl1.c index 63b9ba0cc67e..bbd6e3009be0 100644 --- a/drivers/net/atlx/atl1.c +++ b/drivers/net/atlx/atl1.c @@ -2847,10 +2847,11 @@ static int atl1_resume(struct pci_dev *pdev) pci_enable_wake(pdev, PCI_D3cold, 0); atl1_reset_hw(&adapter->hw); - adapt...
52159d98be6f26c48f5e02c7ab3c9848a85979b5
Analyze and fix the following issue in the Linux kernel code: jump label: Convert dynamic debug to use jump labels
Problem Details: Convert the 'dynamic debug' infrastructure to use jump labels. Signed-off-by: Jason Baron <jbaron@redhat.com> LKML-Reference: <b77627358cea3e27d7be4386f45f66219afb8452.1284733808.git.jbaron@redhat.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
```diff diff --git a/include/linux/dynamic_debug.h b/include/linux/dynamic_debug.h index 52c0da4bdd18..bef3cda44c4c 100644 --- a/include/linux/dynamic_debug.h +++ b/include/linux/dynamic_debug.h @@ -1,6 +1,8 @@ #ifndef _DYNAMIC_DEBUG_H #define _DYNAMIC_DEBUG_H +#include <linux/jump_label.h> + /* dynamic_printk_ena...
d6120b8afacec587f5feb37781bc751bc5d68a10
Analyze and fix the following issue in the Linux kernel code: netfilter: nf_nat_snmp: fix checksum calculation (v4)
Problem Details: Fix checksum calculation in nf_nat_snmp_basic. Based on patches by Clark Wang <wtweeker@163.com> and Stephen Hemminger <shemminger@vyatta.com>. https://bugzilla.kernel.org/show_bug.cgi?id=17622 Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
```diff diff --git a/net/ipv4/netfilter/nf_nat_snmp_basic.c b/net/ipv4/netfilter/nf_nat_snmp_basic.c index 1679e2c0963d..ee5f419d0a56 100644 --- a/net/ipv4/netfilter/nf_nat_snmp_basic.c +++ b/net/ipv4/netfilter/nf_nat_snmp_basic.c @@ -893,13 +893,15 @@ static void fast_csum(__sum16 *csum, unsigned char s[4]; if (...
15cdeadaa5d76009e20c7792aed69f5a73808f97
Analyze and fix the following issue in the Linux kernel code: netfilter: fix a race in nf_ct_ext_create()
Problem Details: As soon as rcu_read_unlock() is called, there is no guarantee current thread can safely derefence t pointer, rcu protected. Fix is to copy t->alloc_size in a temporary variable. Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Reviewed-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Signed-off-...
```diff diff --git a/net/netfilter/nf_conntrack_extend.c b/net/netfilter/nf_conntrack_extend.c index 7dcf7a404190..8d9e4c949b96 100644 --- a/net/netfilter/nf_conntrack_extend.c +++ b/net/netfilter/nf_conntrack_extend.c @@ -48,15 +48,17 @@ nf_ct_ext_create(struct nf_ct_ext **ext, enum nf_ct_ext_id id, gfp_t gfp) { un...
b46ffb854554ff939701bdd492b81558da5706fc
Analyze and fix the following issue in the Linux kernel code: netfilter: fix ipt_REJECT TCP RST routing for indev == outdev
Problem Details: ip_route_me_harder can't create the route cache when the outdev is the same with the indev for the skbs whichout a valid protocol set. __mkroute_input functions has this check: 1998 if (skb->protocol != htons(ETH_P_IP)) { 1999 /* Not IP (i.e. ARP). Do not create route, if it is...
```diff diff --git a/net/ipv4/netfilter/ipt_REJECT.c b/net/ipv4/netfilter/ipt_REJECT.c index b254dafaf429..43eec80c0e7c 100644 --- a/net/ipv4/netfilter/ipt_REJECT.c +++ b/net/ipv4/netfilter/ipt_REJECT.c @@ -112,6 +112,7 @@ static void send_reset(struct sk_buff *oldskb, int hook) /* ip_route_me_harder expects skb->dst...
e95dffa4304186ad87963255f3e5e96b5c41849f
Analyze and fix the following issue in the Linux kernel code: sunrpc/cache: fix recent breakage of cache_clean_deferred
Problem Details: commit 6610f720e9e8103c22d1f1ccf8fbb695550a571f broke cache_clean_deferred as entries are no longer added to the pending list for subsequent revisiting. So put those requests back on the pending list. Signed-off-by: NeilBrown <neilb@suse.de> Signed-off-by: J. Bruce Fields <bfields@redhat.com>
```diff diff --git a/net/sunrpc/cache.c b/net/sunrpc/cache.c index ac2c6e6abe65..ff733dfef3b8 100644 --- a/net/sunrpc/cache.c +++ b/net/sunrpc/cache.c @@ -671,8 +671,10 @@ void cache_clean_deferred(void *owner) spin_lock(&cache_defer_lock); list_for_each_entry_safe(dreq, tmp, &cache_defer_list, recent) { - if (d...
0077ca0b5c986477e33451b797b6e7dc92a8bbc0
Analyze and fix the following issue in the Linux kernel code: ASoC: Fix multi-componentism
Problem Details: Spot the build testing. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
```diff diff --git a/sound/soc/soc-cache.c b/sound/soc/soc-cache.c index 15d2779074ef..f6b0d2829ea9 100644 --- a/sound/soc/soc-cache.c +++ b/sound/soc/soc-cache.c @@ -204,7 +204,7 @@ static int snd_soc_8_16_write(struct snd_soc_codec *codec, unsigned int reg, data[2] = value & 0xff; if (!snd_soc_codec_volatile_re...
9a81c16b527528ad307843be5571111aa8d35a80
Analyze and fix the following issue in the Linux kernel code: powerpc: fix double syscall restarts
Problem Details: Make sigreturn zero regs->trap, make do_signal() do the same on all paths. As it is, signal interrupting e.g. read() from fd 512 (== ERESTARTSYS) with another signal getting unblocked when the first handler finishes will lead to restart one insn earlier than it ought to. Same for multiple signals wit...
```diff diff --git a/arch/powerpc/kernel/signal.c b/arch/powerpc/kernel/signal.c index 7109f5b1baa8..2300426e531a 100644 --- a/arch/powerpc/kernel/signal.c +++ b/arch/powerpc/kernel/signal.c @@ -138,6 +138,7 @@ static int do_signal_pending(sigset_t *oldset, struct pt_regs *regs) ti->local_flags &= ~_TLF_RESTORE_SIG...
e92049a1bbc4d84504b4c7886cf048fc5750259f
Analyze and fix the following issue in the Linux kernel code: Staging: ft1000: fix mode of firmware image file
Problem Details: It should not be executable. Cc: Marek Belisko <marek.belisko@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
```diff diff --git a/drivers/staging/ft1000/ft1000-pcmcia/ft1000.img b/drivers/staging/ft1000/ft1000-pcmcia/ft1000.img old mode 100755 new mode 100644 ```
43589a832d3189afaaa0efd30a10a16f15891425
Analyze and fix the following issue in the Linux kernel code: Staging: ft1000: fix build
Problem Details: This fixes the build for the ft100-usb driver so it builds properly. Cc: Marek Belisko <marek.belisko@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
```diff diff --git a/drivers/staging/ft1000/ft1000-usb/ft1000_chdev.c b/drivers/staging/ft1000/ft1000-usb/ft1000_chdev.c index c135c9da63b1..5e75ee844860 100644 --- a/drivers/staging/ft1000/ft1000-usb/ft1000_chdev.c +++ b/drivers/staging/ft1000/ft1000-usb/ft1000_chdev.c @@ -51,7 +51,7 @@ extern void CardSendCommand(str...
74ff3a68ed11f1e9eede4fe301f42cc3cdf7396a
Analyze and fix the following issue in the Linux kernel code: OMAP: hwmod: improve documentation, clean up function names
Problem Details: This patch: - adds more documentation to the hwmod code - fixes some documentation typos elsewhere in the file - changes the _sysc_*() function names to appear in (verb, noun) order, to match the rest of the function names. This patch should not result in any functional change. Signed-off-by: Pa...
```diff diff --git a/arch/arm/mach-omap2/omap_hwmod.c b/arch/arm/mach-omap2/omap_hwmod.c index d694067e6e9a..c3a5889d8add 100644 --- a/arch/arm/mach-omap2/omap_hwmod.c +++ b/arch/arm/mach-omap2/omap_hwmod.c @@ -13,10 +13,102 @@ * it under the terms of the GNU General Public License version 2 as * published by the F...
5786aee8bf6d747ea59595601a19e78ad33d6929
Analyze and fix the following issue in the Linux kernel code: vhost: fix log ctx signalling
Problem Details: The log eventfd signalling got put in dead code. We didn't notice because qemu currently does polling instead of eventfd select. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
```diff diff --git a/drivers/vhost/vhost.c b/drivers/vhost/vhost.c index c579dcc9200c..dd3d6f7406f8 100644 --- a/drivers/vhost/vhost.c +++ b/drivers/vhost/vhost.c @@ -858,11 +858,12 @@ int vhost_log_write(struct vhost_virtqueue *vq, struct vhost_log *log, if (r < 0) return r; len -= l; - if (!len) + if (!le...
12e5272585901217e919da810c801e5084ee0cb1
Analyze and fix the following issue in the Linux kernel code: HID: trivial formatting fix
Problem Details: Added blank line after declarations. Signed-off-by: Alan Ott <alan@signal11.us> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
```diff diff --git a/drivers/hid/usbhid/hid-core.c b/drivers/hid/usbhid/hid-core.c index b729c0286679..ff90069f4a69 100644 --- a/drivers/hid/usbhid/hid-core.c +++ b/drivers/hid/usbhid/hid-core.c @@ -810,6 +810,7 @@ static int usbhid_output_raw_report(struct hid_device *hid, __u8 *buf, size_t co if (usbhid->urbout) { ...
d47372e852391d0c6553dfbc7c4c56b89b527e13
Analyze and fix the following issue in the Linux kernel code: ASoC: Fix soc-cache buffer overflow bug
Problem Details: Make sure we stay within the cache boundaries when updating the register cache. Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
```diff diff --git a/sound/soc/soc-cache.c b/sound/soc/soc-cache.c index adbc68ce9050..15d2779074ef 100644 --- a/sound/soc/soc-cache.c +++ b/sound/soc/soc-cache.c @@ -203,8 +203,9 @@ static int snd_soc_8_16_write(struct snd_soc_codec *codec, unsigned int reg, data[1] = (value >> 8) & 0xff; data[2] = value & 0xff; ...
0873a5ae747847ee55a63db409dff3476e45bcd9
Analyze and fix the following issue in the Linux kernel code: ALSA: oxygen: fix analog capture on Claro halo cards
Problem Details: On the HT-Omega Claro halo card, the ADC data must be captured from the second I2S input. Using the default first input, which isn't connected to anything, would result in silence. Signed-off-by: Erik J. Staab <ejs@insightbb.com> Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Cc: <stable@kernel....
```diff diff --git a/sound/pci/oxygen/oxygen.c b/sound/pci/oxygen/oxygen.c index 289cb4dacfc7..6c0a11adb2a8 100644 --- a/sound/pci/oxygen/oxygen.c +++ b/sound/pci/oxygen/oxygen.c @@ -543,6 +543,10 @@ static int __devinit get_oxygen_model(struct oxygen *chip, chip->model.suspend = claro_suspend; chip->model.resume...
692ebd17c2905313fff3c504c249c6a0faad16ec
Analyze and fix the following issue in the Linux kernel code: bdi: Fix warnings in __mark_inode_dirty for /dev/zero and friends
Problem Details: Inodes of devices such as /dev/zero can get dirty for example via utime(2) syscall or due to atime update. Backing device of such inodes (zero_bdi, etc.) is however unable to handle dirty inodes and thus __mark_inode_dirty complains. In fact, inode should be rather dirtied against backing device of th...
```diff diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c index 81e086d8aa57..5581122bd2c0 100644 --- a/fs/fs-writeback.c +++ b/fs/fs-writeback.c @@ -52,8 +52,6 @@ struct wb_writeback_work { #define CREATE_TRACE_POINTS #include <trace/events/writeback.h> -#define inode_to_bdi(inode) ((inode)->i_mapping->backing_de...
0fbecd400dd0a82d465b3086f209681e8c54cb0f
Analyze and fix the following issue in the Linux kernel code: drm/ttm: Clear the ghost cpu_writers flag on ttm_buffer_object_transfer.
Problem Details: It makes sense for a BO to move after a process has requested exclusive RW access on it (e.g. because the BO used to be located in unmappable VRAM and we intercepted the CPU access from the fault handler). If we let the ghost object inherit cpu_writers from the original object, ttm_bo_release_list() w...
```diff diff --git a/drivers/gpu/drm/ttm/ttm_bo_util.c b/drivers/gpu/drm/ttm/ttm_bo_util.c index 7cffb3e04232..3451a82adba7 100644 --- a/drivers/gpu/drm/ttm/ttm_bo_util.c +++ b/drivers/gpu/drm/ttm/ttm_bo_util.c @@ -351,6 +351,7 @@ static int ttm_buffer_object_transfer(struct ttm_buffer_object *bo, INIT_LIST_HEAD(&fbo...
e5e03ce1e5c6c015cabf274b24976dff408dc07f
Analyze and fix the following issue in the Linux kernel code: caif: Fix function NULL pointer check.
Problem Details: Check that receive function pointer is not null before calling it. Signed-off-by: Sjur Braendeland <sjur.brandeland@stericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net>
```diff diff --git a/net/caif/caif_dev.c b/net/caif/caif_dev.c index 0fd01dd17c48..b99369a055d1 100644 --- a/net/caif/caif_dev.c +++ b/net/caif/caif_dev.c @@ -173,7 +173,7 @@ static int receive(struct sk_buff *skb, struct net_device *dev, net = dev_net(dev); pkt = cfpkt_fromnative(CAIF_DIR_IN, skb); caifd = caif_...
b04367df66eb63444d38c43d15f5e39499d85ae6
Analyze and fix the following issue in the Linux kernel code: caif: Minor fixes in log prints.
Problem Details: Use pr_debug for flow control printouts, and refine an error printout. Signed-off-by: Sjur Braendeland <sjur.brandeland@stericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net>
```diff diff --git a/net/caif/caif_socket.c b/net/caif/caif_socket.c index fd1f5df0827c..3943398f70cd 100644 --- a/net/caif/caif_socket.c +++ b/net/caif/caif_socket.c @@ -159,9 +159,7 @@ static int caif_queue_rcv_skb(struct sock *sk, struct sk_buff *skb) if (atomic_read(&sk->sk_rmem_alloc) + skb->truesize >= (un...
9c44c9fa78c5a449699491f0355189e2a09c242a
Analyze and fix the following issue in the Linux kernel code: caif: Remove buggy re-definition of pr_debug
Problem Details: Remove debugging quirk redefining pr_debug to pr_warning. Signed-off-by: Sjur Brændeland <sjur.brandeland@stericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net>
```diff diff --git a/net/caif/chnl_net.c b/net/caif/chnl_net.c index 86aac24b0225..84a422c98941 100644 --- a/net/caif/chnl_net.c +++ b/net/caif/chnl_net.c @@ -30,9 +30,6 @@ #define CONNECT_TIMEOUT (5 * HZ) #define CAIF_NET_DEFAULT_QUEUE_LEN 500 -#undef pr_debug -#define pr_debug pr_warn - /*This list is protected ...
d9fd1b2857154f1ac32ca041641ba947525ff7fa
Analyze and fix the following issue in the Linux kernel code: tmspci: fix tr%d in printk
Problem Details: tmspci driver uses dev->name before register_netdev() and so prints tr%d in initialization messages. Fix it by using dev_info. Found and tested on real hardware. Signed-off-by: Meelis Roos <mroos@linux.ee> Signed-off-by: David S. Miller <davem@davemloft.net>
```diff diff --git a/drivers/net/tokenring/tmspci.c b/drivers/net/tokenring/tmspci.c index d4c7c0c0a3d6..d3e788a9cd1c 100644 --- a/drivers/net/tokenring/tmspci.c +++ b/drivers/net/tokenring/tmspci.c @@ -125,18 +125,16 @@ static int __devinit tms_pci_attach(struct pci_dev *pdev, const struct pci_devic dev->irq = pci_...
027360c5644b59d99db30e3515a8ec72350207b9
Analyze and fix the following issue in the Linux kernel code: Staging: line6: minor coding style cleanups
Problem Details: This fixes up all of the remaining coding style issues that make any sense to make in the line6 driver. Cc: Markus Grabner <grabner@icg.tugraz.at> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
```diff diff --git a/drivers/staging/line6/audio.c b/drivers/staging/line6/audio.c index b1488d321c7b..61db1f99b0c8 100644 --- a/drivers/staging/line6/audio.c +++ b/drivers/staging/line6/audio.c @@ -37,7 +37,9 @@ int line6_init_audio(struct usb_line6 *line6) strcpy(card->id, line6->properties->id); strcpy(card->dri...
73da16c28ed0724755afdb95c7dd6b166381be10
Analyze and fix the following issue in the Linux kernel code: ethtool: Fix build due to lack of ethtool.h include.
Problem Details: net/core/ethtool.c: In function 'ethtool_get_regs': net/core/ethtool.c:818:2: error: implicit declaration of function 'vmalloc' net/core/ethtool.c:818:9: warning: assignment makes pointer from integer without a cast net/core/ethtool.c:833:2: error: implicit declaration of function 'vfree' Signed-off-b...
```diff diff --git a/net/core/ethtool.c b/net/core/ethtool.c index dae2fd053c2b..7d7e572cedc7 100644 --- a/net/core/ethtool.c +++ b/net/core/ethtool.c @@ -19,6 +19,7 @@ #include <linux/netdevice.h> #include <linux/bitops.h> #include <linux/uaccess.h> +#include <linux/vmalloc.h> #include <linux/slab.h> /* ```
10ed61c432c013705ef6a2bebad139fc5d72e274
Analyze and fix the following issue in the Linux kernel code: sfc: Fix build due to lack of vmalloc.h include.
Problem Details: drivers/net/sfc/filter.c: In function ‘efx_probe_filters’: drivers/net/sfc/filter.c:422: error: implicit declaration of function ‘vmalloc’ drivers/net/sfc/filter.c:422: warning: assignment makes pointer from integer without a cast drivers/net/sfc/filter.c: In function ‘efx_remove_filters’: drivers/net/...
```diff diff --git a/drivers/net/sfc/net_driver.h b/drivers/net/sfc/net_driver.h index ea6691c83fba..b3f2bf436735 100644 --- a/drivers/net/sfc/net_driver.h +++ b/drivers/net/sfc/net_driver.h @@ -29,6 +29,7 @@ #include <linux/device.h> #include <linux/highmem.h> #include <linux/workqueue.h> +#include <linux/vmalloc.h...
3d13008e7345fa7a79d8f6438150dc15d6ba6e9d
Analyze and fix the following issue in the Linux kernel code: ip: fix truesize mismatch in ip fragmentation
Problem Details: Special care should be taken when slow path is hit in ip_fragment() : When walking through frags, we transfert truesize ownership from skb to frags. Then if we hit a slow_path condition, we must undo this or risk uncharging frags->truesize twice, and in the end, having negative socket sk_wmem_alloc co...
```diff diff --git a/net/ipv4/ip_output.c b/net/ipv4/ip_output.c index 04b69896df5f..7649d7750075 100644 --- a/net/ipv4/ip_output.c +++ b/net/ipv4/ip_output.c @@ -488,9 +488,8 @@ int ip_fragment(struct sk_buff *skb, int (*output)(struct sk_buff *)) * we can switch to copy when see the first bad fragment. */ if ...
96835af970e5d6aeedf868e53590a947be5e4a7a
Analyze and fix the following issue in the Linux kernel code: OMAP: hwmod: Fix softreset for modules with optional clocks
Problem Details: Some modules (like GPIO, DSS...) require optionals clock to be enabled in order to complete the sofreset properly. Add a HWMOD_CONTROL_OPT_CLKS_IN_RESET flag to force all optional clocks to be enabled before reset. Disabled them once the reset is done. TODO: For the moment it is very hard to understan...
```diff diff --git a/arch/arm/mach-omap2/omap_hwmod.c b/arch/arm/mach-omap2/omap_hwmod.c index 5027879b062f..f320cfb911d5 100644 --- a/arch/arm/mach-omap2/omap_hwmod.c +++ b/arch/arm/mach-omap2/omap_hwmod.c @@ -546,6 +546,36 @@ static int _disable_clocks(struct omap_hwmod *oh) return 0; } +static void _enable_opti...
2cb068149c365f1c2b10f2ece6786139527dcc16
Analyze and fix the following issue in the Linux kernel code: OMAP: hwmod: Fix softreset status check for some new OMAP4 IPs
Problem Details: In OMAP3 a specific SYSSTATUS register was used to get the softreset status. Starting in OMAP4, some IPs does not have SYSSTATUS register and instead use the SYSC softreset bit to provide the status. Other cases might exist: - Some IPs like McBSP does have a softreset control but no reset status. - So...
```diff diff --git a/arch/arm/mach-omap2/omap_hwmod.c b/arch/arm/mach-omap2/omap_hwmod.c index 8c279235ea87..5027879b062f 100644 --- a/arch/arm/mach-omap2/omap_hwmod.c +++ b/arch/arm/mach-omap2/omap_hwmod.c @@ -967,6 +967,12 @@ static int _read_hardreset(struct omap_hwmod *oh, const char *name) * enabled for this to ...
9eecabcb9a924f1e11ba670365fd4babe423045c
Analyze and fix the following issue in the Linux kernel code: intel-iommu: Abort IOMMU setup for igfx if BIOS gave no shadow GTT space
Problem Details: Yet another BIOS bug; Lenovo this time (X201). Red Hat bug #593516. Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
```diff diff --git a/drivers/pci/intel-iommu.c b/drivers/pci/intel-iommu.c index c3ceebb5be84..dee88c6cb3ef 100644 --- a/drivers/pci/intel-iommu.c +++ b/drivers/pci/intel-iommu.c @@ -3761,6 +3761,23 @@ static void __devinit quirk_iommu_rwbf(struct pci_dev *dev) DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x2a40, q...
ff4d3e186b7b92c74a4f64360f723c603193f344
Analyze and fix the following issue in the Linux kernel code: OMAP4: prcm: Fix global warm reset bit position
Problem Details: OMAP4 platform has different register bits for Warm and Cold Resets. Write one into appropriate bits. Signed-off-by: Rajeev Kulkarni <rajeevk@ti.com> Cc: Leed Aguilar <leed.aguilar@ti.com> [b-cousson@ti.com: Change the define with the proper one from omap4 headers] Signed-off-by: Benoit Cousson <b-cou...
```diff diff --git a/arch/arm/mach-omap2/prcm.c b/arch/arm/mach-omap2/prcm.c index c20137497c92..96f461682c91 100644 --- a/arch/arm/mach-omap2/prcm.c +++ b/arch/arm/mach-omap2/prcm.c @@ -33,6 +33,7 @@ #include "cm.h" #include "prm.h" #include "prm-regbits-24xx.h" +#include "prm-regbits-44xx.h" static void __iomem...
9b579114efc4bd00532de33c783b4cb4638910ff
Analyze and fix the following issue in the Linux kernel code: OMAP: hwmod: Fix omap_hwmod_reset wrong state test
Problem Details: The reset function wrongly used the state flag as a bit mask and was trying to re-enable after a reset. hwmod is still enabled for the PRCM point of view after a softreset so there is no need to re-enable. Remove the state check from omap_hwmod_reset since the _reset function is checking that as well...
```diff diff --git a/arch/arm/mach-omap2/omap_hwmod.c b/arch/arm/mach-omap2/omap_hwmod.c index 5bb25e319b76..100115ff1d96 100644 --- a/arch/arm/mach-omap2/omap_hwmod.c +++ b/arch/arm/mach-omap2/omap_hwmod.c @@ -1434,19 +1434,17 @@ void omap_hwmod_ocp_barrier(struct omap_hwmod *oh) * * Under some conditions, a drive...
d141d97437a3c84aa18cfd5c8d91b89c4173f25c
Analyze and fix the following issue in the Linux kernel code: NFS: Fix NFSv3 debugging messages in fs/nfs/nfs3proc.c
Problem Details: Clean up. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
```diff diff --git a/fs/nfs/nfs3proc.c b/fs/nfs/nfs3proc.c index 4e9d941ab548..f8446b38dcb4 100644 --- a/fs/nfs/nfs3proc.c +++ b/fs/nfs/nfs3proc.c @@ -671,7 +671,8 @@ nfs3_proc_readdir(struct dentry *dentry, struct rpc_cred *cred, nfs_free_fattr(res.dir_attr); out: - dprintk("NFS reply readdir: %d\n", status); + d...
d688e11007419fd060ae74d8d952a5c4ece735aa
Analyze and fix the following issue in the Linux kernel code: NFSv4.1: Fix the slotid initialisation in nfs_async_rename()
Problem Details: This fixes an Oopsable condition that was introduced by commit d3d4152a5d59af9e13a73efa9e9c24383fbe307f (nfs: make sillyrename an async operation) Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
```diff diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index c46e45e9b33f..72aa7067b85d 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c @@ -2550,6 +2550,7 @@ static void nfs4_proc_unlink_setup(struct rpc_message *msg, struct inode *dir) args->bitmask = server->cache_consistency_bitmask; res->server = s...
f7732d6573c4f29fc1ca5d384bbf82ddfa115030
Analyze and fix the following issue in the Linux kernel code: NFS: Fix a use-after-free case in nfs_async_rename()
Problem Details: The call to nfs_async_rename_release() after rpc_run_task() is incorrect. The rpc_run_task() is always guaranteed to call the ->rpc_release() method. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
```diff diff --git a/fs/nfs/unlink.c b/fs/nfs/unlink.c index 698b3e6367ff..47530aacebfd 100644 --- a/fs/nfs/unlink.c +++ b/fs/nfs/unlink.c @@ -426,7 +426,6 @@ nfs_async_rename(struct inode *old_dir, struct inode *new_dir, .rpc_client = NFS_CLIENT(old_dir), .flags = RPC_TASK_ASYNC, }; - struct rpc_task *task; ...
e933ec7c4ebd7e7daaad67b22e5f4a9a0ab102ea
Analyze and fix the following issue in the Linux kernel code: OMAP1: PM: add simple runtime PM layer to manage clocks
Problem Details: On OMAP1, we do not have omap_device + omap_hwmod to manage the device-specific idle, enable and shutdown. Instead, just enable/disable device clocks automatically at the runtime PM level. This allows drivers to not have any OMAP1 specific clock management and allows them to simply use the runtime PM...
```diff diff --git a/arch/arm/mach-omap1/Makefile b/arch/arm/mach-omap1/Makefile index facfaeb1ae5c..9a304d854e33 100644 --- a/arch/arm/mach-omap1/Makefile +++ b/arch/arm/mach-omap1/Makefile @@ -12,7 +12,7 @@ obj-$(CONFIG_OMAP_MPU_TIMER) += time.o obj-$(CONFIG_OMAP_32K_TIMER) += timer32k.o # Power Management -obj-$...
6cdee91257bee23a46dc869ca62469b67cba2c7e
Analyze and fix the following issue in the Linux kernel code: OMAP: PM debugfs removing OMAP3 hardcodings.
Problem Details: This patch removes omap3 hardcodings from pm-debug.c so that enabling PM debugfs support does break compilation for other OMAP's. This is a preparatory patch for supporting OMAP4 pm entries through PM debugfs. Signed-off-by: Thara Gopinath <thara@ti.com> Signed-off-by: Kevin Hilman <khilman@deeprootsy...
```diff diff --git a/arch/arm/mach-omap2/pm-debug.c b/arch/arm/mach-omap2/pm-debug.c index 723b44e252fd..056ff17f7c38 100644 --- a/arch/arm/mach-omap2/pm-debug.c +++ b/arch/arm/mach-omap2/pm-debug.c @@ -37,6 +37,10 @@ #include "pm.h" int omap2_pm_debug; +u32 enable_off_mode; +u32 sleep_while_idle; +u32 wakeup_timer...
584c5b7cf06194464240280483ee0376cdddbbae
Analyze and fix the following issue in the Linux kernel code: staging: usbip: Process event flags without delay
Problem Details: The way the event handler works can cause it to delay events until eventual wakeup for another event. For example, on device detach (vhci): - Write to sysfs detach file -> usbip_event_add(VDEV_EVENT_DOWN) -> wakeup() #define VDEV_EVENT_DOWN (USBIP_EH_SHUTDOWN | USBIP_EH_RESET). - Event ...
```diff diff --git a/drivers/staging/usbip/usbip_event.c b/drivers/staging/usbip/usbip_event.c index a2566f1075d5..af3832b03e4b 100644 --- a/drivers/staging/usbip/usbip_event.c +++ b/drivers/staging/usbip/usbip_event.c @@ -38,21 +38,13 @@ static int event_handler(struct usbip_device *ud) ud->eh_ops.shutdown(ud); ...
7aed48d9a7a9f72f8f1ad187d5d41510a7696813
Analyze and fix the following issue in the Linux kernel code: staging: rtl8192e: Fix indent of some functions
Problem Details: Signed-off-by: Mike McCormack <mikem@ring3k.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
```diff diff --git a/drivers/staging/rtl8192e/r8192E_core.c b/drivers/staging/rtl8192e/r8192E_core.c index 58e7037b8b72..34a8450f72bb 100644 --- a/drivers/staging/rtl8192e/r8192E_core.c +++ b/drivers/staging/rtl8192e/r8192E_core.c @@ -850,8 +850,9 @@ void rtl8192_set_chan(struct net_device *dev,short ch) void rtl819...
0fe212f7e3347c7d146258c9bc893bfd118df71e
Analyze and fix the following issue in the Linux kernel code: staging: w35und: Add locking problems to TODO list
Problem Details: The w35und uses atomics such as "ThreadCount" and "FireCount" to emulate locking in the TX paths, for example. Document this bug in the TODO list. Cc: Lars Lindley <lindley@coyote.org> Cc: Pavel Machek <pavel@ucw.cz> Cc: Ruslan Pisarev <ruslan@rpisarev.org.ua> Signed-off-by: Pekka Enberg <penberg@kern...
```diff diff --git a/drivers/staging/winbond/TODO b/drivers/staging/winbond/TODO index 43bee56a7df6..b4c592a96844 100644 --- a/drivers/staging/winbond/TODO +++ b/drivers/staging/winbond/TODO @@ -6,6 +6,7 @@ TODO: - remove unused ioctls - use cfg80211 for regulatory stuff - fix 4k stack problems + - fix locking pr...
5fb108555b35ce35f997899e2a4ad074f3496949
Analyze and fix the following issue in the Linux kernel code: staging: w35und: Kill dead HAL macros in wbhal_f.h
Problem Details: Fixes an uninitialized variable access in _rx_iq_calibration_loop_winbond(): CC [M] drivers/staging/winbond/phy_calibration.o drivers/staging/winbond/phy_calibration.c: In function ‘_rx_iq_calibration_loop_winbond’: drivers/staging/winbond/phy_calibration.c:1138: warning: ‘val’ is used uninit...
```diff diff --git a/drivers/staging/winbond/phy_calibration.c b/drivers/staging/winbond/phy_calibration.c index 5c1f05392db9..2b375ba3812a 100644 --- a/drivers/staging/winbond/phy_calibration.c +++ b/drivers/staging/winbond/phy_calibration.c @@ -1132,18 +1132,6 @@ u8 _rx_iq_calibration_loop_winbond(struct hw_data *phw...
fa6d52938906305356555e37e38939c7bad8fd7a
Analyze and fix the following issue in the Linux kernel code: ASoC: Fix soc-cache buffer overflow bug
Problem Details: Make sure we stay within the cache boundaries when updating the register cache. Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
```diff diff --git a/sound/soc/soc-cache.c b/sound/soc/soc-cache.c index 12281111f100..28bf1ff980ce 100644 --- a/sound/soc/soc-cache.c +++ b/sound/soc/soc-cache.c @@ -203,8 +203,9 @@ static int snd_soc_8_16_write(struct snd_soc_codec *codec, unsigned int reg, data[1] = (value >> 8) & 0xff; data[2] = value & 0xff; ...
77b3d3facfb32913a85f40156e7d4a70b18d0bd6
Analyze and fix the following issue in the Linux kernel code: staging: iio: max1363 add _index attribute registration
Problem Details: Also fixes a missing NULL to terminate one of the attribute arrays. Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
```diff diff --git a/drivers/staging/iio/adc/max1363_core.c b/drivers/staging/iio/adc/max1363_core.c index d59a8d2f4202..06c602467c6e 100644 --- a/drivers/staging/iio/adc/max1363_core.c +++ b/drivers/staging/iio/adc/max1363_core.c @@ -385,13 +385,21 @@ static struct attribute_group max1363_dev_attr_group = { static ...
88b76d1da59c7bf06ebc301dbee5e35d59277a6e
Analyze and fix the following issue in the Linux kernel code: staging: iio: adis16300 add _type attributes for all scan elements
Problem Details: Note some of the in driver type specifications do not match the data sheet. I am assuming the datasheet is correct. This bug would not have been apparent in the driver as these values were unusued. Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Manuel Stahl <manuel.stahl@iis.fraunho...
```diff diff --git a/drivers/staging/iio/imu/adis16300_ring.c b/drivers/staging/iio/imu/adis16300_ring.c index 0e09051e5545..3f67858fff8e 100644 --- a/drivers/staging/iio/imu/adis16300_ring.c +++ b/drivers/staging/iio/imu/adis16300_ring.c @@ -19,9 +19,11 @@ static IIO_SCAN_EL_C(in_supply, ADIS16300_SCAN_SUPPLY, IIO_...
74b3c444a963ba55aef89b33a1bcaada9a4c206f
Analyze and fix the following issue in the Linux kernel code: x86, setup: Fix earlyprintk=serial,0x3f8,115200
Problem Details: earlyprintk can take and I/O port, so we need to handle this case in the setup code too, otherwise 0x3f8 will be treated as a baud rate. Signed-off-by: Yinghai Lu <yinghai@kernel.org> LKML-Reference: <4C7B05A6.4010801@kernel.org> Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
```diff diff --git a/arch/x86/boot/early_serial_console.c b/arch/x86/boot/early_serial_console.c index 407a8e26f0a7..5df2869c874b 100644 --- a/arch/x86/boot/early_serial_console.c +++ b/arch/x86/boot/early_serial_console.c @@ -58,7 +58,19 @@ static void parse_earlyprintk(void) if (arg[pos] == ',') pos++; - if...
83d9f65bdae6f6b34d75282c6618d3f50846849a
Analyze and fix the following issue in the Linux kernel code: x86, setup: Fix earlyprintk=serial,ttyS0,115200
Problem Details: Torsten reported that there is garbage output, after commit 8fee13a48e4879fba57725f6d9513df4bfa8e9f3 (x86, setup: enable early console output from the decompressor) It turns out we missed the offset for that case. Reported-by: Torsten Kaiser <just.for.lkml@googlemail.com> Signed-off-by: Yinghai Lu <y...
```diff diff --git a/arch/x86/boot/early_serial_console.c b/arch/x86/boot/early_serial_console.c index 030f4b93e255..407a8e26f0a7 100644 --- a/arch/x86/boot/early_serial_console.c +++ b/arch/x86/boot/early_serial_console.c @@ -58,7 +58,7 @@ static void parse_earlyprintk(void) if (arg[pos] == ',') pos++; - if ...
26c15cfd291f8b4ee40b4bbdf5e3772adfd704f5
Analyze and fix the following issue in the Linux kernel code: ipvs: changes related to service usecnt
Problem Details: Change the usage of svc usecnt during command execution: - we check if svc is registered but we do not need to hold usecnt reference while under __ip_vs_mutex, only the packet handling needs it during scheduling - change __ip_vs_service_get to __ip_vs_service_find and __ip_vs_svc_fwm_get to __ip_vs_s...
```diff diff --git a/net/netfilter/ipvs/ip_vs_app.c b/net/netfilter/ipvs/ip_vs_app.c index e76f87f4aca8..a475edee0912 100644 --- a/net/netfilter/ipvs/ip_vs_app.c +++ b/net/netfilter/ipvs/ip_vs_app.c @@ -103,8 +103,8 @@ ip_vs_app_inc_new(struct ip_vs_app *app, __u16 proto, __u16 port) goto out; list_add(&inc->a_l...
abdd8f510686da0a58e475bc0143d1069e5f53da
Analyze and fix the following issue in the Linux kernel code: ALSA: hda - Apply ALC269 VAIO fix-up to all Sony laptops with ALC269
Problem Details: We've applied a fix-up for ALC269 VAIO only for two models. But all Sony VAIO models with ALC269 codec seem to require the similar fix. Let's apply it with vendor-id mask. Signed-off-by: Takashi Iwai <tiwai@suse.de>
```diff diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index f2a30447f26f..eea88b7ddb9f 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c @@ -14731,8 +14731,7 @@ static const struct alc_fixup alc269_fixups[] = { }; static struct snd_pci_quirk alc269_fixup_tbl...
6f0b31c31860a0be60663f76a305ca2d78e5e99f
Analyze and fix the following issue in the Linux kernel code: Fix typo interrest[ing|ed] => interest[ing|ed]
Problem Details: Fix typos with interrest*. Signed-off-by: Thomas Weber <weber@corscience.de> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
```diff diff --git a/drivers/char/stallion.c b/drivers/char/stallion.c index f2167f8e5aab..d7d7d4f9e760 100644 --- a/drivers/char/stallion.c +++ b/drivers/char/stallion.c @@ -3180,7 +3180,7 @@ static void stl_cd1400flush(struct stlport *portp) /* * Return the current state of data flow on this port. This is only -...
90fa539ca3f07323da5a90f5c8f4e5cd952875e7
Analyze and fix the following issue in the Linux kernel code: ath9k: clean up / fix aggregation session flush
Problem Details: The tid aggregation cleanup is a bit fragile, as it discards failed subframes in some places, and retransmits them in others. This could block the cleanup of an existing aggregation session, if a retransmission for a tid is issued, yet the tid is never scheduled again because of the cleanup state. Fix...
```diff diff --git a/drivers/net/wireless/ath/ath9k/xmit.c b/drivers/net/wireless/ath/ath9k/xmit.c index d629bfbdfab4..e53433e3e4cc 100644 --- a/drivers/net/wireless/ath/ath9k/xmit.c +++ b/drivers/net/wireless/ath/ath9k/xmit.c @@ -61,6 +61,8 @@ static int ath_tx_num_badfrms(struct ath_softc *sc, struct ath_buf *bf, ...
231c3a1f0630c07a584905507a1cb7b705a56ab7
Analyze and fix the following issue in the Linux kernel code: ath9k: fix an aggregation start related race condition
Problem Details: A new aggregation session start can be issued by mac80211, even when the cleanup of the previous session has not completed yet. Since the data structure for the session is not recreated, this could corrupt the block ack window and lock up the aggregation session. Fix this by delaying the new session un...
```diff diff --git a/drivers/net/wireless/ath/ath9k/ath9k.h b/drivers/net/wireless/ath/ath9k/ath9k.h index 79217c3c92e5..004533d2ca5f 100644 --- a/drivers/net/wireless/ath/ath9k/ath9k.h +++ b/drivers/net/wireless/ath/ath9k/ath9k.h @@ -346,8 +346,8 @@ void ath_tx_tasklet(struct ath_softc *sc); void ath_tx_edma_tasklet(...
9ee82d541095cb64bf16a1f5d7573a8cddc125aa
Analyze and fix the following issue in the Linux kernel code: wl1271: bugfix: use bitwise-AND instead of logical-AND
Problem Details: typo - while looking for specific bits we should do a bitwise-AND instead of logical-AND. Signed-off-by: Eliad Peller <eliad@wizery.com> Acked-by: Luciano Coelho <luciano.coelho@nokia.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
```diff diff --git a/drivers/net/wireless/wl12xx/wl1271_main.c b/drivers/net/wireless/wl12xx/wl1271_main.c index af26150109e3..776cd7c41148 100644 --- a/drivers/net/wireless/wl12xx/wl1271_main.c +++ b/drivers/net/wireless/wl12xx/wl1271_main.c @@ -1634,7 +1634,7 @@ static void wl1271_op_bss_info_changed(struct ieee80211...
2c7808d9345b91bb19f6bfaebf7b9e0916b0859a
Analyze and fix the following issue in the Linux kernel code: carl9170: fix hang in AP mode when HT STA does PSM
Problem Details: This is a obvious bug, skb_queue_walk does not work if the iterator gets removed from the queue. Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
```diff diff --git a/drivers/net/wireless/ath/carl9170/main.c b/drivers/net/wireless/ath/carl9170/main.c index ea49d54ce03b..43de9dfa5820 100644 --- a/drivers/net/wireless/ath/carl9170/main.c +++ b/drivers/net/wireless/ath/carl9170/main.c @@ -1412,7 +1412,7 @@ static void carl9170_op_sta_notify(struct ieee80211_hw *hw,...
78ec789bd397249a9bb412ca91bd360079e7b446
Analyze and fix the following issue in the Linux kernel code: carl9170: fix state downgrade during reset
Problem Details: Don't mark the device as completely dead just yet. If all goes to plan and carl9170_reboot succeeds then we can skip the expensive userspace-driven reinitialization anyway. And if it doesn't and carl9170_reboot fails, then carl9170_usb_cancel_urbs will do the necessary steps. Signed-off-by: Christian...
```diff diff --git a/drivers/net/wireless/ath/carl9170/usb.c b/drivers/net/wireless/ath/carl9170/usb.c index 1e7c2748d85a..eb789a9e4f15 100644 --- a/drivers/net/wireless/ath/carl9170/usb.c +++ b/drivers/net/wireless/ath/carl9170/usb.c @@ -846,8 +846,6 @@ int carl9170_usb_restart(struct ar9170 *ar) carl9170_usb_stop...
e278c5a90368408bd191743e7c6f978f068f4b8d
Analyze and fix the following issue in the Linux kernel code: carl9170: fix noise dBm conversion
Problem Details: Ever since carl9170 gained support to read the noisefloor, the reported noisefloor level was pretty poor. Initially I assumed that something was wrong in the PHY setup and it would be impossible to fix without any guidances. But this was not the case. In fact the nf readings were correct and the thing...
```diff diff --git a/drivers/net/wireless/ath/carl9170/phy.c b/drivers/net/wireless/ath/carl9170/phy.c index fe265e3e6ac4..7df8f711f5d8 100644 --- a/drivers/net/wireless/ath/carl9170/phy.c +++ b/drivers/net/wireless/ath/carl9170/phy.c @@ -1558,9 +1558,9 @@ static int carl9170_set_power_cal(struct ar9170 *ar, u32 freq, ...
651d9375dca9997ef2b05639191756da73b0cf8d
Analyze and fix the following issue in the Linux kernel code: ath5k: Fix TX queues stopping
Problem Details: It does not make sense to stop queues for NF calibration. This will not stop transmissions from the card, if there are queued packets. If we run out of TX buffers we need to stop all queues, not only one. Signed-off-by: Bruno Randolf <br1@einfach.org> Signed-off-by: John W. Linville <linville@tuxdriv...
```diff diff --git a/drivers/net/wireless/ath/ath5k/base.c b/drivers/net/wireless/ath/ath5k/base.c index 776f415e8567..92d139bbcc31 100644 --- a/drivers/net/wireless/ath/ath5k/base.c +++ b/drivers/net/wireless/ath/ath5k/base.c @@ -1489,7 +1489,7 @@ static int ath5k_tx_queue(struct ieee80211_hw *hw, struct sk_buff *skb,...
cfddc11c429a655e418ffc111372cc69dee6a1a5
Analyze and fix the following issue in the Linux kernel code: ath5k: Fix queue debug file
Problem Details: Take txq lock in debug file and fix reporting of used buffers. Signed-off-by: Bruno Randolf <br1@einfach.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
```diff diff --git a/drivers/net/wireless/ath/ath5k/debug.c b/drivers/net/wireless/ath/ath5k/debug.c index 1b7c6d7fde93..b2c610ba8b7e 100644 --- a/drivers/net/wireless/ath/ath5k/debug.c +++ b/drivers/net/wireless/ath/ath5k/debug.c @@ -763,7 +763,7 @@ static ssize_t read_file_queue(struct file *file, char __user *user_b...
ce2220d1da0bad9583af38a03ad508968d554c0f
Analyze and fix the following issue in the Linux kernel code: ath/ath5k/ath9k: Fix crypto capabilities merge issue
Problem Details: Fixing up a merge issue / concurrent development: Remove unneeded ath_crypt_caps flags, as per "ath9k_hw: remove useless hw capability flags" (364734fafbba0c3133e482db78149b9a823ae7a5), but set the AESCCM flag for ath9k. common ath code still needs a flag for this because there is ath5k hardware which...
```diff diff --git a/drivers/net/wireless/ath/ath.h b/drivers/net/wireless/ath/ath.h index c5584077d1de..dd236c3b52f6 100644 --- a/drivers/net/wireless/ath/ath.h +++ b/drivers/net/wireless/ath/ath.h @@ -72,13 +72,8 @@ struct ath_regulatory { }; enum ath_crypt_caps { - ATH_CRYPT_CAP_MIC_AESCCM = BIT(0), - ATH_CRYPT...
c807666a08800ab387298817db5a6f6e11606adb
Analyze and fix the following issue in the Linux kernel code: carl9170: update AR9170 phy initvals
Problem Details: This patch is loosely based on an ath9k patch called: "ath9k_hw: sync initvals for ar9001 and ar9002 with Atheros" It includes the following changes/fixes: - AGC setting improvements - timing changes for improved performance Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by...
```diff diff --git a/drivers/net/wireless/ath/carl9170/phy.c b/drivers/net/wireless/ath/carl9170/phy.c index 47709c13d964..71dea9707e21 100644 --- a/drivers/net/wireless/ath/carl9170/phy.c +++ b/drivers/net/wireless/ath/carl9170/phy.c @@ -85,11 +85,12 @@ static struct carl9170_phy_init ar5416_phy_init[] = { { 0x1c584...
817f2c842d6c38acfd58d20d29ba583ec467ae35
Analyze and fix the following issue in the Linux kernel code: Fix various typos of valid in comments
Problem Details: Fix various typos of valid. Signed-off-by: Nikanth Karthikesan <knikanth@suse.de> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
```diff diff --git a/drivers/char/pcmcia/cm4000_cs.c b/drivers/char/pcmcia/cm4000_cs.c index ec73d9f6d9ed..273be76be988 100644 --- a/drivers/char/pcmcia/cm4000_cs.c +++ b/drivers/char/pcmcia/cm4000_cs.c @@ -1667,7 +1667,7 @@ static int cmm_open(struct inode *inode, struct file *filp) /* opening will always block sinc...
0bc79f7f58f5d0670c776818e38f482555bc27ae
Analyze and fix the following issue in the Linux kernel code: Doc: Fix typo s/packages/packaged
Problem Details: Fix typo s/packages/packaged in Documentation/vm/numa_memory_policy.txt. Signed-off-by: Nikanth Karthikesan <knikanth@suse.de> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
```diff diff --git a/Documentation/vm/numa_memory_policy.txt b/Documentation/vm/numa_memory_policy.txt index 6690fc34ef6d..4e7da6543424 100644 --- a/Documentation/vm/numa_memory_policy.txt +++ b/Documentation/vm/numa_memory_policy.txt @@ -424,7 +424,7 @@ a command line tool, numactl(8), exists that allows one to: + ...
41945f6ccf1e86f87fddf6b32db9cf431c05fb54
Analyze and fix the following issue in the Linux kernel code: perf: Avoid RCU vs preemption assumptions
Problem Details: The per-pmu per-cpu context patch converted things from get_cpu_var() to this_cpu_ptr(), but that only works if rcu_read_lock() actually disables preemption, and since there is no such guarantee, we need to fix that. Use the newly introduced {get,put}_cpu_ptr(). Signed-off-by: Peter Zijlstra <a.p.zij...
```diff diff --git a/kernel/perf_event.c b/kernel/perf_event.c index baae1367e945..c16158c77dfd 100644 --- a/kernel/perf_event.c +++ b/kernel/perf_event.c @@ -3836,18 +3836,20 @@ static void perf_event_task_event(struct perf_task_event *task_event) rcu_read_lock(); list_for_each_entry_rcu(pmu, &pmus, entry) { - ...
f6c3f1686e7ec1dd8725a9a3dcb857dfd0c7a5bf
Analyze and fix the following issue in the Linux kernel code: sched: Fix nohz balance kick
Problem Details: There's a situation where the nohz balancer will try to wake itself: cpu-x is idle which is also ilb_cpu got a scheduler tick during idle and the nohz_kick_needed() in trigger_load_balance() checks for rq_x->nr_running which might not be zero (because of someone waking a task on this rq etc) and this ...
```diff diff --git a/kernel/sched_fair.c b/kernel/sched_fair.c index a171138a9402..db3f674ca49d 100644 --- a/kernel/sched_fair.c +++ b/kernel/sched_fair.c @@ -3630,7 +3630,7 @@ static inline int nohz_kick_needed(struct rq *rq, int cpu) if (time_before(now, nohz.next_balance)) return 0; - if (!rq->nr_running) + i...
cdd59983118c02d9c5ba0c116ded1faef47ec452
Analyze and fix the following issue in the Linux kernel code: drm/i915: Drop crtc->fb pin on disable.
Problem Details: In order to handle disable_functions() where the framebuffer is decoupled from the crtc we need to unpin the fb in order to prevent a leak. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=29857 Reported-by: Sitsofe Wheeler <sitsofe@yahoo.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.u...
```diff diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index 461bf4879e0a..e6f7ebfe86e5 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c @@ -2487,6 +2487,20 @@ static void intel_crtc_dpms(struct drm_crtc *crtc, int mode) } } +sta...
6eecba33f2fc24544073631dc1b23b7a312e644b
Analyze and fix the following issue in the Linux kernel code: drm/i915: Disable output polling across suspend & resume
Problem Details: Suspending (especially hibernating) may take a finite amount of time, during which a hotplug event may trigger and we will attempt to handle it with inconsistent state. Disable hotplug polling around suspend and resume. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=30070 Reported-by: Rui Tiag...
```diff diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c index dd7a0de7212c..048c54bdfd4c 100644 --- a/drivers/gpu/drm/i915/i915_dma.c +++ b/drivers/gpu/drm/i915/i915_dma.c @@ -1172,10 +1172,8 @@ static void i915_switcheroo_set_state(struct pci_dev *pdev, enum vga_switcheroo_ /* i915 re...
bdd30729b68d708c970125aab363931134698f2d
Analyze and fix the following issue in the Linux kernel code: intel-gtt: kill mask_memory functions
Problem Details: That indirection mess can now go. Add a dummy i81x gtt_driver to avoid a NULL pointer check. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
```diff diff --git a/drivers/char/agp/intel-gtt.c b/drivers/char/agp/intel-gtt.c index 44722c6790b2..bb222d5f322b 100644 --- a/drivers/char/agp/intel-gtt.c +++ b/drivers/char/agp/intel-gtt.c @@ -69,20 +69,6 @@ static struct gatt_mask intel_i810_masks[] = #define INTEL_AGP_CACHED_MEMORY_LLC_MLC 3 #define INTEL_...
92f49d9cec0052e09d938ac913d8e9ab432a0584
Analyze and fix the following issue in the Linux kernel code: drm/i915: fix HAS_BSD with a device info flag
Problem Details: Signed-off-by: Xiang, Haihao <haihao.xiang@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
```diff diff --git a/drivers/gpu/drm/i915/i915_drv.c b/drivers/gpu/drm/i915/i915_drv.c index 2ddac06d5967..393696cee86d 100644 --- a/drivers/gpu/drm/i915/i915_drv.c +++ b/drivers/gpu/drm/i915/i915_drv.c @@ -125,6 +125,7 @@ static const struct intel_device_info intel_g33_info = { static const struct intel_device_info i...
b84d5f0c22914d37d709add54c66e741c404fa56
Analyze and fix the following issue in the Linux kernel code: drm/i915: Inline i915_gem_ring_retire_request()
Problem Details: Change the semantics to retire any buffer older than the current seqno rather than repeatedly calling calling the function to retire the buffer at the head of the list matching the request seqno. Whilst this should have no semantic impact on the implementation, Daniel was wondering if there was a bug ...
```diff diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c index 71a2723545b9..1c02798bb7e4 100644 --- a/drivers/gpu/drm/i915/i915_gem.c +++ b/drivers/gpu/drm/i915/i915_gem.c @@ -1667,47 +1667,6 @@ i915_retire_commands(struct drm_device *dev, struct intel_ring_buffer *ring) I915_GEM_DOMA...
82690bba375586ab93d74265710c2fd5788c8178
Analyze and fix the following issue in the Linux kernel code: drm/i915/debug: Dump BSD ring buffers to debugfs
Problem Details: Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
```diff diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c index 361a825c2363..ac48115429ed 100644 --- a/drivers/gpu/drm/i915/i915_debugfs.c +++ b/drivers/gpu/drm/i915/i915_debugfs.c @@ -40,9 +40,10 @@ #if defined(CONFIG_DEBUG_FS) -#define ACTIVE_LIST 1 -#define FLUSHING_LIST 2 ...
792e6d3389061ad449429b9ba228eb758c247ea0
Analyze and fix the following issue in the Linux kernel code: dccp tfrc/ccid-3: computing the loss rate from the Loss Event Rate
Problem Details: This adds a function to take care of the following, separate cases occurring in the computation of the Loss Rate p: * 1/(2^32-1) is mapped into 0% as per RFC 4342, 8.5; * 1/0 is mapped into 100%, the maximum; * to avoid that p = 1/x is rounded down to 0 when x is very large, since this me...
```diff diff --git a/net/dccp/ccids/ccid3.c b/net/dccp/ccids/ccid3.c index 90bc0a7da8e4..9715eebf1551 100644 --- a/net/dccp/ccids/ccid3.c +++ b/net/dccp/ccids/ccid3.c @@ -400,10 +400,10 @@ static void ccid3_hc_tx_packet_recv(struct sock *sk, struct sk_buff *skb) /* Update loss event rate (which is scaled by 1e6) */...
180be2a0420a0d680285e9352c0db85016b9ed2a
Analyze and fix the following issue in the Linux kernel code: cfq-iosched: fix a kernel OOPs when usb key is inserted
Problem Details: Mike reported a kernel crash when a usb key hotplug is performed while all kernel thrads are not in a root cgroup and are running in one of the child cgroups of blkio controller. BUG: unable to handle kernel NULL pointer dereference at 0000002c IP: [<c11c7b08>] cfq_get_queue+0x232/0x412 *pde = 0000...
```diff diff --git a/block/cfq-iosched.c b/block/cfq-iosched.c index f65c6f01c475..9eba291eb6fd 100644 --- a/block/cfq-iosched.c +++ b/block/cfq-iosched.c @@ -1019,10 +1019,20 @@ cfq_find_alloc_cfqg(struct cfq_data *cfqd, struct cgroup *cgroup, int create) */ atomic_set(&cfqg->ref, 1); - /* Add group onto cgroup...
a45dc2d2b8d1afa57c91dcfac224e50ffcd3f805
Analyze and fix the following issue in the Linux kernel code: block: fix blk_rq_map_kern bio direction flag
Problem Details: This bug was introduced in 7b6d91daee5cac6402186ff224c3af39d79f4a0e "block: unify flags for struct bio and struct request" Cc: Boaz Harrosh <bharrosh@panasas.com> Signed-off-by: Benny Halevy <bhalevy@panasas.com> Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
```diff diff --git a/block/blk-map.c b/block/blk-map.c index c65d7593f7f1..ade0a08c9099 100644 --- a/block/blk-map.c +++ b/block/blk-map.c @@ -307,7 +307,7 @@ int blk_rq_map_kern(struct request_queue *q, struct request *rq, void *kbuf, return PTR_ERR(bio); if (rq_data_dir(rq) == WRITE) - bio->bi_rw |= (1 << REQ...
13f808cf8ddb5f3ca0f0271473c6c02a4b32580b
Analyze and fix the following issue in the Linux kernel code: ASoC: Fix merge issue with WM8962 control addition
Problem Details: Let's not add the core controls twice. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
```diff diff --git a/sound/soc/codecs/wm8962.c b/sound/soc/codecs/wm8962.c index 30984dd15c48..7de519479801 100644 --- a/sound/soc/codecs/wm8962.c +++ b/sound/soc/codecs/wm8962.c @@ -1744,8 +1744,6 @@ static int wm8962_probe(struct snd_soc_codec *codec) wm8962->reg_cache[WM8962_HPOUTL_VOLUME] |= WM8962_HPOUT_VU; wm...
0f9f1ee9d1412d45a22bfd69dfd4d4324b506e9e
Analyze and fix the following issue in the Linux kernel code: ALSA: hda - Add Dell Latitude E6400 model quirk
Problem Details: BugLink: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/643891 Set the Dell Latitude E6400 (1028:0233) SSID to use AD1984_DELL_DESKTOP Cc: stable@kernel.org Signed-off-by: Luke Yelavich <luke.yelavich@canonical.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
```diff diff --git a/sound/pci/hda/patch_analog.c b/sound/pci/hda/patch_analog.c index b697fd2a6f8b..10bbbaf6ebc3 100644 --- a/sound/pci/hda/patch_analog.c +++ b/sound/pci/hda/patch_analog.c @@ -3641,6 +3641,7 @@ static struct snd_pci_quirk ad1984_cfg_tbl[] = { /* Lenovo Thinkpad T61/X61 */ SND_PCI_QUIRK_VENDOR(0x1...
d2520a426dc3033c00077e923a553fc6c98c7564
Analyze and fix the following issue in the Linux kernel code: Input: joydev - fix JSIOCSAXMAP ioctl
Problem Details: Fixed JSIOCSAXMAP ioctl to update absmap, the map from hardware axis to event axis in addition to abspam. This fixes a regression introduced by 999b874f. Signed-off-by: Kenneth Waters <kwwaters@gmail.com> Cc: stable@kernel.org Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
```diff diff --git a/drivers/input/joydev.c b/drivers/input/joydev.c index d85bd8a7967d..22239e988498 100644 --- a/drivers/input/joydev.c +++ b/drivers/input/joydev.c @@ -483,6 +483,9 @@ static int joydev_handle_JSIOCSAXMAP(struct joydev *joydev, memcpy(joydev->abspam, abspam, len); + for (i = 0; i < joydev->nabs...
9396d3174b761685d6fefb1103e66b96a2e5db6d
Analyze and fix the following issue in the Linux kernel code: ALSA: hdmi - fix surround41 channel mapping
Problem Details: Channel 2 and channel 3 were all wrongly mapped to HDMI slot 4. This shows up as a bug that one channel is "lost" when playing in surround41 mode. Signed-off-by: Jerry Zhou <jerry.zhou@intel.com> Signed-off-by: Wu Fengguang <fengguang.wu@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
```diff diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c index 1f4ae1aeca44..d3e49aa5b9ec 100644 --- a/sound/pci/hda/patch_hdmi.c +++ b/sound/pci/hda/patch_hdmi.c @@ -193,7 +193,7 @@ static int hdmi_channel_mapping[0x32][8] = { /* 4ch */ [0x03] = { 0x00, 0x11, 0x23, 0x32, 0x44, 0xf5, 0xf6, 0xf7 ...
05c5e7698bdc54b3079a3517d86077f49ebcc788
Analyze and fix the following issue in the Linux kernel code: sparc64: Fix race in signal instruction flushing.
Problem Details: If another cpu does a very wide munmap() on the signal frame area, it can tear down the page table hierarchy from underneath us. Borrow an idea from the 64-bit fault path's get_user_insn(), and disable cross call interrupts during the page table traversal to lock them in place while we operate. Repor...
```diff diff --git a/arch/sparc/kernel/signal32.c b/arch/sparc/kernel/signal32.c index ea22cd373c64..76b67c4c6aa4 100644 --- a/arch/sparc/kernel/signal32.c +++ b/arch/sparc/kernel/signal32.c @@ -453,6 +453,64 @@ static int save_fpu_state32(struct pt_regs *regs, __siginfo_fpu_t __user *fpu) return err; } +/* The I-...
46b30ea9bc3698bc1d1e6fd726c9601d46fa0a91
Analyze and fix the following issue in the Linux kernel code: percpu: fix pcpu_last_unit_cpu
Problem Details: pcpu_first/last_unit_cpu are used to track which cpu has the first and last units assigned. This in turn is used to determine the span of a chunk for man/unmap cache flushes and whether an address belongs to the first chunk or not in per_cpu_ptr_to_phys(). When the number of possible CPUs isn't power...
```diff diff --git a/mm/percpu.c b/mm/percpu.c index 58c572b18b07..c76ef3891e0d 100644 --- a/mm/percpu.c +++ b/mm/percpu.c @@ -1401,9 +1401,9 @@ int __init pcpu_setup_first_chunk(const struct pcpu_alloc_info *ai, if (pcpu_first_unit_cpu == NR_CPUS) pcpu_first_unit_cpu = cpu; + pcpu_last_unit_cpu = cpu; ...