id stringlengths 40 40 | instruction stringlengths 68 308 | input stringlengths 17 33.4k | output stringlengths 100 30k |
|---|---|---|---|
627d3e7abca30d6e86787c98dd7cbac0233bc5a9 | Analyze and fix the following issue in the Linux kernel code: ALSA: PCI168 snd-azt3328: some more fixups | Problem Details:
- fix problem with codec register 0x6a being write-only
by adding a software shadow register
(caused annoying noise after module loading due to _toggling_
between gameport and audio bits instead of configuring them properly)
- rename several "Wave" mixer controls to "PCM", since this is
what Wi... | ```diff
diff --git a/sound/pci/azt3328.c b/sound/pci/azt3328.c
index b832333c3023..22f18f3cfbc9 100644
--- a/sound/pci/azt3328.c
+++ b/sound/pci/azt3328.c
@@ -289,6 +289,12 @@ struct snd_azf3328 {
struct pci_dev *pci;
int irq;
+ /* register 0x6a is write-only, thus need to remember setting.
+ * If we need to add... |
0d8440657ef184907ac5add0b59c771ee8e8a77f | Analyze and fix the following issue in the Linux kernel code: cpm_uart: fix whitespace issues | Problem Details:
Signed-off-by: Kumar Gala <galak@kernel.crashing.org> | ```diff
diff --git a/drivers/serial/cpm_uart/cpm_uart.h b/drivers/serial/cpm_uart/cpm_uart.h
index 0cc39f82d7c5..3d07bec06fad 100644
--- a/drivers/serial/cpm_uart/cpm_uart.h
+++ b/drivers/serial/cpm_uart/cpm_uart.h
@@ -6,7 +6,7 @@
* Copyright (C) 2004 Freescale Semiconductor, Inc.
*
* 2006 (c) MontaVista Softwa... |
4389ed2ff61de2b1485b31bf342da913dd342f59 | Analyze and fix the following issue in the Linux kernel code: ACPI: don't walk tables if ACPI was disabled | Problem Details:
Ingo Molnar wrote:
> -tip auto-testing started triggering this spinlock corruption message
> yesterday:
>
> [ 3.976213] calling acpi_rtc_init+0x0/0xd3
> [ 3.980213] ACPI Exception (utmutex-0263): AE_BAD_PARAMETER, Thread F7C50000 could not acquire Mutex [3] [20080321]
> [ 3.992213] BUG: spinl... | ```diff
diff --git a/drivers/acpi/glue.c b/drivers/acpi/glue.c
index 2808dc60fd67..9b227d4dc9c9 100644
--- a/drivers/acpi/glue.c
+++ b/drivers/acpi/glue.c
@@ -333,6 +333,9 @@ static int __init acpi_rtc_init(void)
{
struct device *dev = get_rtc_dev();
+ if (acpi_disabled)
+ return 0;
+
if (dev) {
rtc_wake_set... |
16d752397301b95abaa95cbaf9e785d221872311 | Analyze and fix the following issue in the Linux kernel code: thermal: Create CONFIG_THERMAL_HWMON=n | Problem Details:
A bug in libsensors <= 2.10.6 is exposed
when this new hwmon I/F is enabled.
Create CONFIG_THERMAL_HWMON=n
until some time after libsensors 2.10.7 ships
so those users can run the latest kernel.
libsensors 3.x is already fixed -- those users
can use CONFIG_THERMAL_HWMON=y now.
Signed-off-by: Rene Her... | ```diff
diff --git a/Documentation/feature-removal-schedule.txt b/Documentation/feature-removal-schedule.txt
index 5b3f31faed56..46ece3fba6f9 100644
--- a/Documentation/feature-removal-schedule.txt
+++ b/Documentation/feature-removal-schedule.txt
@@ -312,3 +312,12 @@ When: 2.6.26
Why: Implementation became generic; us... |
e4ec7a00ed30429030112e5591cf3138645727c2 | Analyze and fix the following issue in the Linux kernel code: PCI: correct resource number in debug output | Problem Details:
If pci_request_region fails, make the warning include the resource number,
not the resource number + 1. | ```diff
diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c
index 8b755a7fb4ef..8e8ecc1da93d 100644
--- a/drivers/pci/pci.c
+++ b/drivers/pci/pci.c
@@ -1114,10 +1114,10 @@ int pci_request_region(struct pci_dev *pdev, int bar, const char *res_name)
err_out:
dev_warn(&pdev->dev, "BAR %d: can't reserve %s region [%#ll... |
80ccba1186d48fa728dc4b1456cc07ffb07da501 | Analyze and fix the following issue in the Linux kernel code: PCI: use dev_printk when possible | Problem Details:
Convert printks to use dev_printk().
I converted pr_debug() to dev_dbg(). Both use KERN_DEBUG and are enabled
only when DEBUG is defined.
I converted printk(KERN_DEBUG) to dev_printk(KERN_DEBUG), not to dev_dbg(),
because dev_dbg() is only enabled when DEBUG is defined.
I converted DBG(KERN_INFO) (... | ```diff
diff --git a/drivers/pci/msi.c b/drivers/pci/msi.c
index ccb1974464fb..15af618d36e2 100644
--- a/drivers/pci/msi.c
+++ b/drivers/pci/msi.c
@@ -565,9 +565,8 @@ int pci_enable_msi(struct pci_dev* dev)
/* Check whether driver already requested for MSI-X irqs */
if (dev->msix_enabled) {
- printk(KERN_INFO "P... |
b30dd56d1c3786fb0c4e442a58d9a2ea78eeabb9 | Analyze and fix the following issue in the Linux kernel code: pciehp: fix typo in hpc_release_ctlr | Problem Details:
Fix the typo in hpc_release_ctlr().
Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org> | ```diff
diff --git a/drivers/pci/hotplug/pciehp_hpc.c b/drivers/pci/hotplug/pciehp_hpc.c
index 0cfaedf2edca..c030c94a4acb 100644
--- a/drivers/pci/hotplug/pciehp_hpc.c
+++ b/drivers/pci/hotplug/pciehp_hpc.c
@@ -610,7 +610,7 @@ static void hpc_release_ctlr(struct controller *ctrl)
{
/* Mask Hot-plug Interrupt Enable ... |
9e6c29768fc05d32ba1342b9348957b24bc476c2 | Analyze and fix the following issue in the Linux kernel code: [ARM] 5117/1: pxafb: fix __devinit/exit annotations | Problem Details:
This patch fixes pxafb's init/exit annotations. It uses __devinit/exit for
probe functions and __init for init functions. g_options is left as
__devinitdata since it is used by both.
Signed-off-by: Jaya Kumar <jayakumar.lkml@gmail.com>
Acked-by: Krzysztof Helt <krzysztof.h1@wp.pl>
Acked-by: Eric Miao ... | ```diff
diff --git a/drivers/video/pxafb.c b/drivers/video/pxafb.c
index 796e0d1d5b19..fafe7db20d6d 100644
--- a/drivers/video/pxafb.c
+++ b/drivers/video/pxafb.c
@@ -1246,7 +1246,7 @@ static int pxafb_resume(struct platform_device *dev)
* cache. Once this area is remapped, all virtual memory
* access to... |
99ade2597e3f7f0ad463c489aaccd6cc605e242c | Analyze and fix the following issue in the Linux kernel code: rt2x00: Fix unbalanced mutex locking | Problem Details:
The usb_cache_mutex was not correctly released
under all circumstances. Both rt73usb as rt2500usb
didn't release the mutex under certain conditions
when the register access failed. Obviously such
failure would lead to deadlocks.
In addition under similar circumstances when the
bbp register couldn't be... | ```diff
diff --git a/drivers/net/wireless/rt2x00/rt2500usb.c b/drivers/net/wireless/rt2x00/rt2500usb.c
index fdbd0ef2be4b..61e59c17a60a 100644
--- a/drivers/net/wireless/rt2x00/rt2500usb.c
+++ b/drivers/net/wireless/rt2x00/rt2500usb.c
@@ -138,11 +138,8 @@ static void rt2500usb_bbp_write(struct rt2x00_dev *rt2x00dev,
... |
2f9ec47d0954f9d2e5a00209c2689cbc477a8c89 | Analyze and fix the following issue in the Linux kernel code: b43legacy: Fix possible NULL pointer dereference in DMA code | Problem Details:
This fixes a possible NULL pointer dereference in an error path of the
DMA allocation error checking code. This is also necessary for a future
DMA API change that is on its way into the mainline kernel that adds
an additional dev parameter to dma_mapping_error().
Signed-off-by: Michael Buesch <mb@bu3s... | ```diff
diff --git a/drivers/net/wireless/b43legacy/dma.c b/drivers/net/wireless/b43legacy/dma.c
index c990f87b107a..93ddc1cbcc8b 100644
--- a/drivers/net/wireless/b43legacy/dma.c
+++ b/drivers/net/wireless/b43legacy/dma.c
@@ -876,6 +876,7 @@ struct b43legacy_dmaring *b43legacy_setup_dmaring(struct b43legacy_wldev *dev... |
7b3abfc87ec13a81b255012b6e1bd4caeeb05aec | Analyze and fix the following issue in the Linux kernel code: b43: Fix possible MMIO access while device is down | Problem Details:
This fixes a possible MMIO access while the device is still down
from a suspend cycle. MMIO accesses with the device powered down
may cause crashes on certain devices.
Signed-off-by: Michael Buesch <mb@bu3sch.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com> | ```diff
diff --git a/drivers/net/wireless/b43/leds.c b/drivers/net/wireless/b43/leds.c
index 36a9c42df835..76f4c7bad8b8 100644
--- a/drivers/net/wireless/b43/leds.c
+++ b/drivers/net/wireless/b43/leds.c
@@ -72,6 +72,9 @@ static void b43_led_brightness_set(struct led_classdev *led_dev,
struct b43_wldev *dev = led->dev... |
c9e8eae0935f03e2d03a7ad7af80d8fc6c53e68c | Analyze and fix the following issue in the Linux kernel code: b43: Do not return TX_BUSY from op_tx | Problem Details:
Never return TX_BUSY from op_tx. It doesn't make sense to return
TX_BUSY, if we can not transmit the packet.
Drop the packet and return TX_OK.
This will fix the resume hang.
Signed-off-by: Michael Buesch <mb@bu3sch.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com> | ```diff
diff --git a/drivers/net/wireless/b43/main.c b/drivers/net/wireless/b43/main.c
index fa4b0d8b74a2..a70827793086 100644
--- a/drivers/net/wireless/b43/main.c
+++ b/drivers/net/wireless/b43/main.c
@@ -2883,12 +2883,11 @@ static int b43_op_tx(struct ieee80211_hw *hw,
if (unlikely(skb->len < 2 + 2 + 6)) {
/*... |
8d0a60032ffd472f0f7821ff388e9f438c06077a | Analyze and fix the following issue in the Linux kernel code: Blackfin arch: fix up section mismatch warning | Problem Details:
--
WARNING: vmlinux.o(.text+0x721a): Section mismatch in reference from the function ___fill_code_cplbtab() to the function .init.text:_fill_cplbtab()
The function ___fill_code_cplbtab() references
the function __init _fill_cplbtab().
This is often because ___fill_code_cplbtab lacks a __init
annotation... | ```diff
diff --git a/arch/blackfin/kernel/cplb-nompu/cplbinit.c b/arch/blackfin/kernel/cplb-nompu/cplbinit.c
index 917325bfbd84..6be0c50122e8 100644
--- a/arch/blackfin/kernel/cplb-nompu/cplbinit.c
+++ b/arch/blackfin/kernel/cplb-nompu/cplbinit.c
@@ -254,7 +254,8 @@ close_cplbtab(struct cplb_tab *table)
}
/* helper... |
71a7d1556264c1ad84b1bcf5f7a9cbc980b1e1fd | Analyze and fix the following issue in the Linux kernel code: Blackfin arch: fix bug - kernel boot fails when Spinlock and rw-lock debugging enabled | Problem Details:
Initialize the lock of bad_irq_desc properly.
The content of irq_desc array is replaced by bad_irq_desc in blackfin
arch irqchip init code. So, do it properly as common irq init code.
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org> | ```diff
diff --git a/arch/blackfin/kernel/irqchip.c b/arch/blackfin/kernel/irqchip.c
index 73647c158774..07402f57c9de 100644
--- a/arch/blackfin/kernel/irqchip.c
+++ b/arch/blackfin/kernel/irqchip.c
@@ -60,9 +60,14 @@ static struct irq_chip bad_chip = {
};
static struct irq_desc bad_irq_desc = {
+ .status = IRQ_DIS... |
9f0aecdd1cd6aacee9aa8f08031f4f2e09e454dc | Analyze and fix the following issue in the Linux kernel code: [PATCH] audit: fix kernel-doc parameter notation | Problem Details:
Fix auditfilter kernel-doc misssing parameter description:
Warning(lin2626-rc3//kernel/auditfilter.c:1551): No description found for parameter 'sessionid'
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> | ```diff
diff --git a/kernel/auditfilter.c b/kernel/auditfilter.c
index 0e0bd27e6512..75cdf262851d 100644
--- a/kernel/auditfilter.c
+++ b/kernel/auditfilter.c
@@ -1544,6 +1544,7 @@ static void audit_log_rule_change(uid_t loginuid, u32 sessionid, u32 sid,
* @data: payload data
* @datasz: size of payload data
* @lo... |
eadc49b1a8d09480f14caea292142f103a89c77a | Analyze and fix the following issue in the Linux kernel code: [SCSI] esp: Fix OOPS in esp_reset_cleanup(). | Problem Details:
OOPS reported by Friedrich Oslage <bluebird@porno-bullen.de>
The problem here is that tp->starget is set every time a lun
is allocated for a particular target so we can catch the
sdev_target parent value.
The reset handler uses the NULL'ness of this value to determine
which targets are active.
But e... | ```diff
diff --git a/drivers/scsi/esp_scsi.c b/drivers/scsi/esp_scsi.c
index a0b6d414953d..305eddef5ca1 100644
--- a/drivers/scsi/esp_scsi.c
+++ b/drivers/scsi/esp_scsi.c
@@ -2371,6 +2371,7 @@ static int esp_slave_alloc(struct scsi_device *dev)
dev->hostdata = lp;
tp->starget = dev->sdev_target;
+ tp->starget_ref... |
ea7b44c8e6baa1a4507f05ba2c0009ac21c3fe0b | Analyze and fix the following issue in the Linux kernel code: enable bus mastering on i915 at resume time | Problem Details:
On 9xx chips, bus mastering needs to be enabled at resume time for much of the
chip to function. With this patch, vblank interrupts will work as expected
on resume, along with other chip functions. Fixes kernel bugzilla #10844.
Signed-off-by: Jie Luo <clotho67@gmail.com>
Signed-off-by: Jesse Barnes... | ```diff
diff --git a/drivers/char/drm/i915_drv.c b/drivers/char/drm/i915_drv.c
index e8f3d682e3b1..93aed1c38bd2 100644
--- a/drivers/char/drm/i915_drv.c
+++ b/drivers/char/drm/i915_drv.c
@@ -389,6 +389,7 @@ static int i915_resume(struct drm_device *dev)
pci_restore_state(dev->pdev);
if (pci_enable_device(dev->pdev)... |
f6e16d5ad463d15f285666f588cfe49495c692d9 | Analyze and fix the following issue in the Linux kernel code: x86: KVM guest: Use the paravirt clocksource structs and functions | Problem Details:
This patch updates the kvm host code to use the pvclock structs
and functions, thereby making it compatible with Xen.
The patch also fixes an initialization bug: on SMP systems the
per-cpu has two different locations early at boot and after CPU
bringup. kvmclock must take that in account when registe... | ```diff
diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index f94bca6ff47f..e0edaaa6920a 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -383,6 +383,7 @@ config VMI
config KVM_CLOCK
bool "KVM paravirtualized clock"
select PARAVIRT
+ select PARAVIRT_CLOCK
depends on !(X86_VISWS || X86_VOYAGER)
help
... |
5af4e7a0bea715f2dd7190859a43eb2258b1f388 | Analyze and fix the following issue in the Linux kernel code: [GFS2] fix gfs2 block allocation (cleaned up) | Problem Details:
This patch fixes bz 450641.
This patch changes the computation for zero_metapath_length(), which it
renames to metapath_branch_start(). When you are extending the metadata
tree, The indirect blocks that point to the new data block must either
diverge from the existing tree either at the inode, or at t... | ```diff
diff --git a/fs/gfs2/bmap.c b/fs/gfs2/bmap.c
index c19184f2e70e..bec76b1c2bb0 100644
--- a/fs/gfs2/bmap.c
+++ b/fs/gfs2/bmap.c
@@ -246,15 +246,11 @@ static void find_metapath(const struct gfs2_sbd *sdp, u64 block,
}
-static inline unsigned int zero_metapath_length(const struct metapath *mp,
- unsigned... |
8097110d179b874d91c6495330c2b96c991e8c6e | Analyze and fix the following issue in the Linux kernel code: [IA64] Handle count==0 in sn2_ptc_proc_write() | Problem Details:
The fix applied in e0c6d97c65e0784aade7e97b9411f245a6c543e7
"security hole in sn2_ptc_proc_write" didn't take into account
the case where count==0 (which results in a buffer underrun
when adding the trailing '\0'). Thanks to Andi Kleen for
pointing this out.
Signed-off-by: Cliff Wickman <cpw@sgi.com>... | ```diff
diff --git a/arch/ia64/sn/kernel/sn2/sn2_smp.c b/arch/ia64/sn/kernel/sn2/sn2_smp.c
index 6dd886c5d860..e585f9a2afb9 100644
--- a/arch/ia64/sn/kernel/sn2/sn2_smp.c
+++ b/arch/ia64/sn/kernel/sn2/sn2_smp.c
@@ -512,7 +512,7 @@ static ssize_t sn2_ptc_proc_write(struct file *file, const char __user *user, si
int cp... |
2826f8c0f4c97b7db33e2a680f184d828eb7a785 | Analyze and fix the following issue in the Linux kernel code: [IA64] Fix boot failure on ia64/sn2 | Problem Details:
Call check_sal_cache_flush() after platform_setup() as
check_sal_cache_flush() now relies on being able to call platform
vector code.
Problem was introduced by: 3463a93def55c309f3c0d0a8aaf216be3be42d64
"Update check_sal_cache_flush to use platform_send_ipi()"
Signed-off-by: Jes Sorensen <jes@sgi.com>... | ```diff
diff --git a/arch/ia64/kernel/setup.c b/arch/ia64/kernel/setup.c
index f48a809c686d..4ae15c8c2488 100644
--- a/arch/ia64/kernel/setup.c
+++ b/arch/ia64/kernel/setup.c
@@ -578,8 +578,6 @@ setup_arch (char **cmdline_p)
cpu_init(); /* initialize the bootstrap CPU */
mmu_context_init(); /* initialize context_id... |
c95e62ce8905aab62fed224eaaa9b8558a0ef652 | Analyze and fix the following issue in the Linux kernel code: [SCSI] ses: Fix timeout | Problem Details:
Timeouts are measured in jiffies, not in seconds.
Signed-off-by: Matthew Wilcox <willy@linux.intel.com>
Cc: Stable Tree <stable@kernel.org>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> | ```diff
diff --git a/drivers/scsi/ses.c b/drivers/scsi/ses.c
index 45df83b9d847..0fe031f003e7 100644
--- a/drivers/scsi/ses.c
+++ b/drivers/scsi/ses.c
@@ -61,7 +61,7 @@ static int ses_probe(struct device *dev)
return err;
}
-#define SES_TIMEOUT 30
+#define SES_TIMEOUT (30 * HZ)
#define SES_RETRIES 3
static int... |
aabdc3b8c3b3d081f1532454e344208338478e29 | Analyze and fix the following issue in the Linux kernel code: kgdb: sparse fix | Problem Details:
- Fix warning reported by sparse
kernel/kgdb.c:1502:6: warning: symbol 'kgdb_console_write' was not declared.
Should it be static?
Signed-off-by: Jason Wessel <jason.wessel@windriver.com> | ```diff
diff --git a/kernel/kgdb.c b/kernel/kgdb.c
index 79e3c90113c2..3ec23c3ec97f 100644
--- a/kernel/kgdb.c
+++ b/kernel/kgdb.c
@@ -1499,7 +1499,8 @@ int kgdb_nmicallback(int cpu, void *regs)
return 1;
}
-void kgdb_console_write(struct console *co, const char *s, unsigned count)
+static void kgdb_console_write(... |
a606b5e24b7e2937604f4c85023d8d9c5ab0a28b | Analyze and fix the following issue in the Linux kernel code: kgdb: documentation update - remove kgdboe | Problem Details:
kgdboe is not presently included kgdb, and there should be no
references to it.
Also fix the tcp port terminal connection example.
Signed-off-by: Jason Wessel <jason.wessel@windriver.com> | ```diff
diff --git a/Documentation/DocBook/kgdb.tmpl b/Documentation/DocBook/kgdb.tmpl
index 028a8444d95e..e8acd1f03456 100644
--- a/Documentation/DocBook/kgdb.tmpl
+++ b/Documentation/DocBook/kgdb.tmpl
@@ -84,10 +84,9 @@
runs an instance of gdb against the vmlinux file which contains
the symbols (not boot im... |
4aeba0134f1e54cfd881e118b039ab6ed8b99126 | Analyze and fix the following issue in the Linux kernel code: pcmcia: (re)move {pcmcia,pccard}_get_status | Problem Details:
Except for one debug message in a driver marked BROKEN, pcmcia_get_status is
only used by the ioctl. Therefore, move it to pcmcia_ioctl.c and unexport it.
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net> | ```diff
diff --git a/drivers/mtd/maps/pcmciamtd.c b/drivers/mtd/maps/pcmciamtd.c
index 00530f9bf4a7..0cc31675aeb9 100644
--- a/drivers/mtd/maps/pcmciamtd.c
+++ b/drivers/mtd/maps/pcmciamtd.c
@@ -560,9 +560,7 @@ static int pcmciamtd_config(struct pcmcia_device *link)
DEBUG(1, "Allocated a window of %dKiB", dev->win_si... |
05f43d48ddbda0ce74941aff4711a1829116cc4f | Analyze and fix the following issue in the Linux kernel code: pcmcia: Fix ti12xx_2nd_slot_empty always failing | Problem Details:
For TI 1520 and others, ti12xx_2nd_slot_empty was reading card detect from
the wrong slot, and always failing.
Signed-off-by: Alex Harford <alex.harford@inmotiontechnology.com>
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net> | ```diff
diff --git a/drivers/pcmcia/ti113x.h b/drivers/pcmcia/ti113x.h
index 87a5fd5c2127..129db7bd06c3 100644
--- a/drivers/pcmcia/ti113x.h
+++ b/drivers/pcmcia/ti113x.h
@@ -692,7 +692,7 @@ static int ti12xx_2nd_slot_empty(struct yenta_socket *socket)
goto out;
/* check state */
- yenta_get_status(&socket->sock... |
c1ac02280d76de7aba8a9d43638d0f7d1fd0f820 | Analyze and fix the following issue in the Linux kernel code: pcmcia: check for pointer instead of pointer address | Problem Details:
Bug noted by Michael Buesch: checking for the pointer address is always true.
This didn't matter much, for the very first check in pcmcia_release_window()
was for the pointer pointing to something, and the return value is ignored
here. Nonetheless, fix it.
CC: Michael Buesch <mb@bu3sch.de>
Signed-off-... | ```diff
diff --git a/drivers/pcmcia/pcmcia_resource.c b/drivers/pcmcia/pcmcia_resource.c
index 1d128fbd1a92..c8f77b889d42 100644
--- a/drivers/pcmcia/pcmcia_resource.c
+++ b/drivers/pcmcia/pcmcia_resource.c
@@ -966,7 +966,7 @@ void pcmcia_disable_device(struct pcmcia_device *p_dev) {
pcmcia_release_configuration(p_de... |
785e821eb679c171f453722f15c6791de0c1abe1 | Analyze and fix the following issue in the Linux kernel code: pcmcia: add support CompactFlash PCMCIA support for Blackfin. | Problem Details:
A new host driver to add CompactFlash PCMCIA support for Blackfin.
[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Cc: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Andrew Morton <akpm@... | ```diff
diff --git a/drivers/pcmcia/Kconfig b/drivers/pcmcia/Kconfig
index 1b0eb5aaf650..e45402adac3f 100644
--- a/drivers/pcmcia/Kconfig
+++ b/drivers/pcmcia/Kconfig
@@ -263,6 +263,13 @@ config OMAP_CF
Say Y here to support the CompactFlash controller on OMAP.
Note that this doesn't support "True IDE" mode.
... |
b3363997a62d67f76f388c629673094935209d16 | Analyze and fix the following issue in the Linux kernel code: pcmcia: fix Alchemy warnings | Problem Details:
Fix the following warnings:
drivers/pcmcia/au1000_generic.c: In function `au1x00_pcmcia_socket_probe':
drivers/pcmcia/au1000_generic.c:405: warning: integer constant is too large for
"long" type
drivers/pcmcia/au1000_generic.c:413: warning: integer constant is too large for
"long" type
by properly po... | ```diff
diff --git a/drivers/pcmcia/au1000_generic.h b/drivers/pcmcia/au1000_generic.h
index 1e467bb54077..c62437df175e 100644
--- a/drivers/pcmcia/au1000_generic.h
+++ b/drivers/pcmcia/au1000_generic.h
@@ -34,9 +34,9 @@
#define AU1000_PCMCIA_IO_SPEED (255)
#define AU1000_PCMCIA_MEM_SPEED (300)
-#define ... |
17c15da00c0e7289375ad57e8fea0c7892b74aa0 | Analyze and fix the following issue in the Linux kernel code: [GFS2] BUG: unable to handle kernel paging request at ffff81002690e000 | Problem Details:
This patch fixes bugzilla bug bz448866: gfs2: BUG: unable to
handle kernel paging request at ffff81002690e000.
Signed-off-by: Bob Peterson <rpeterso@redhat.com>
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com> | ```diff
diff --git a/fs/gfs2/rgrp.c b/fs/gfs2/rgrp.c
index 6387523a3153..3401628d742b 100644
--- a/fs/gfs2/rgrp.c
+++ b/fs/gfs2/rgrp.c
@@ -195,7 +195,7 @@ ulong_aligned:
depending on architecture. I've experimented with several ways
of writing this section such as using an else before the goto
but this ... |
93e1ade5382206d597e9d6de2d1383e69f54d064 | Analyze and fix the following issue in the Linux kernel code: x86/oprofile: disable preemption in nmi_shutdown | Problem Details:
fix:
BUG: using smp_processor_id() in preemptible [00000000] code: oprofiled/27301
caller is nmi_shutdown+0x11/0x60
Pid: 27301, comm: oprofiled Not tainted 2.6.26-rc7 #25
[<c028a90d>] debug_smp_processor_id+0xbd/0xc0
[<c045fba1>] nmi_shutdown+0x11/0x60
[<c045dd4a>] oprofile_... | ```diff
diff --git a/arch/x86/oprofile/nmi_int.c b/arch/x86/oprofile/nmi_int.c
index cc48d3fde545..2b6ad5b9f9d5 100644
--- a/arch/x86/oprofile/nmi_int.c
+++ b/arch/x86/oprofile/nmi_int.c
@@ -269,12 +269,13 @@ static void nmi_cpu_shutdown(void *dummy)
static void nmi_shutdown(void)
{
- struct op_msrs *msrs = &__get_... |
3e9c83b309fd7cbf1d9b801d0d5877c040e30420 | Analyze and fix the following issue in the Linux kernel code: x86: pat.c consolidate error/debug messages in reserve_memtype | Problem Details:
... and move last debug message out of locked section.
Signed-off-by: Andreas Herrmann <andreas.herrmann3@amd.com>
Cc: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>
Cc: Suresh B Siddha <suresh.b.siddha@intel.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu> | ```diff
diff --git a/arch/x86/mm/pat.c b/arch/x86/mm/pat.c
index c996a3641200..1118288f8fe2 100644
--- a/arch/x86/mm/pat.c
+++ b/arch/x86/mm/pat.c
@@ -269,12 +269,6 @@ int reserve_memtype(u64 start, u64 end, unsigned long req_type,
}
if (actual_type != entry->type) {
- printk(
- KERN_INFO "%s:%d conflicti... |
69e26be9b1d0c83d3581475095ce2a1ccc578215 | Analyze and fix the following issue in the Linux kernel code: x86: pat.c more trivial changes | Problem Details:
- add BUG statement to catch invalid start and end parameters
- No need to track the actual type in both req_type and actual_type --
keep req_type unchanged.
- removed (IMHO) superfluous comments
Signed-off-by: Andreas Herrmann <andreas.herrmann3@amd.com>
Cc: Venkatesh Pallipadi <venkatesh.pallip... | ```diff
diff --git a/arch/x86/mm/pat.c b/arch/x86/mm/pat.c
index a6507bfb12a7..c996a3641200 100644
--- a/arch/x86/mm/pat.c
+++ b/arch/x86/mm/pat.c
@@ -200,7 +200,8 @@ int reserve_memtype(u64 start, u64 end, unsigned long req_type,
unsigned long actual_type;
int err = 0;
- /* Only track when pat_enabled */
+ BUG_... |
e8183c2452041326c95258ecc7865b6fcd91c730 | Analyze and fix the following issue in the Linux kernel code: udf: Fix regression in UDF anchor block detection | Problem Details:
In some cases it could happen that some block passed test in
udf_check_anchor_block() even though udf_read_tagged() refused to read it later
(e.g. because checksum was not correct). This patch makes
udf_check_anchor_block() use udf_read_tagged() so that the checking is
stricter.
This fixes the regres... | ```diff
diff --git a/fs/udf/super.c b/fs/udf/super.c
index 7a5f69be6ac2..44cc702f96cc 100644
--- a/fs/udf/super.c
+++ b/fs/udf/super.c
@@ -682,38 +682,26 @@ static int udf_vrs(struct super_block *sb, int silent)
/*
* Check whether there is an anchor block in the given block
*/
-static int udf_check_anchor_block(st... |
a9b21b622958afc3f3bc5a23d266dd9ed1171fd3 | Analyze and fix the following issue in the Linux kernel code: KVM: VMX: Fix host msr corruption with preemption enabled | Problem Details:
Switching msrs can occur either synchronously as a result of calls to
the msr management functions (usually in response to the guest touching
virtualized msrs), or asynchronously when preempting a kvm thread that has
guest state loaded. If we're unlucky enough to have the two at the same
time, host ms... | ```diff
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index 02efbe75f317..540e95179074 100644
--- a/arch/x86/kvm/vmx.c
+++ b/arch/x86/kvm/vmx.c
@@ -566,7 +566,7 @@ static void vmx_save_host_state(struct kvm_vcpu *vcpu)
load_transition_efer(vmx);
}
-static void vmx_load_host_state(struct vcpu_vmx *vmx)
+stat... |
4fa6b9c5dc4134bdeac341d731a87783cc11ca10 | Analyze and fix the following issue in the Linux kernel code: KVM: ioapic: fix lost interrupt when changing a device's irq | Problem Details:
The ioapic acknowledge path translates interrupt vectors to irqs. It
currently uses a first match algorithm, stopping when it finds the first
redirection table entry containing the vector. That fails however if the
guest changes the irq to a different line, leaving the old redirection table
entry in ... | ```diff
diff --git a/virt/kvm/ioapic.c b/virt/kvm/ioapic.c
index 98778cb69c6e..1dcf9f3d1107 100644
--- a/virt/kvm/ioapic.c
+++ b/virt/kvm/ioapic.c
@@ -269,28 +269,9 @@ void kvm_ioapic_set_irq(struct kvm_ioapic *ioapic, int irq, int level)
}
}
-static int get_eoi_gsi(struct kvm_ioapic *ioapic, int vector)
+static v... |
6bf6a9532fd03ad719f0c86654f16ef777b78fc6 | Analyze and fix the following issue in the Linux kernel code: KVM: MMU: Fix oops on guest userspace access to guest pagetable | Problem Details:
KVM has a heuristic to unshadow guest pagetables when userspace accesses
them, on the assumption that most guests do not allow userspace to access
pagetables directly. Unfortunately, in addition to unshadowing the pagetables,
it also oopses.
This never triggers on ordinary guests since sane OSes will ... | ```diff
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c
index baa6503894d3..7e7c3969f7a2 100644
--- a/arch/x86/kvm/mmu.c
+++ b/arch/x86/kvm/mmu.c
@@ -1083,10 +1083,6 @@ static void mmu_set_spte(struct kvm_vcpu *vcpu, u64 *shadow_pte,
struct kvm_mmu_page *shadow;
spte |= PT_WRITABLE_MASK;
- if (user_fault)... |
6597ca09e6c0e5aec7ffd2b8ab48c671d3c28414 | Analyze and fix the following issue in the Linux kernel code: KVM: MMU: Fix rmap_write_protect() hugepage iteration bug | Problem Details:
rmap_next() does not work correctly after rmap_remove(), as it expects
the rmap chains not to change during iteration. Fix (for now) by restarting
iteration from the beginning.
Signed-off-by: Avi Kivity <avi@qumranet.com> | ```diff
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c
index ee3f53098f0c..9628091c574d 100644
--- a/arch/x86/kvm/mmu.c
+++ b/arch/x86/kvm/mmu.c
@@ -640,6 +640,7 @@ static void rmap_write_protect(struct kvm *kvm, u64 gfn)
rmap_remove(kvm, spte);
--kvm->stat.lpages;
set_shadow_pte(spte, shadow_trap_non... |
d4acf7e7abe45457e751525a2a4d5b693dfdd597 | Analyze and fix the following issue in the Linux kernel code: KVM: Fix race between timer migration and vcpu migration | Problem Details:
A guest vcpu instance can be scheduled to a different physical CPU
between the test for KVM_REQ_MIGRATE_TIMER and local_irq_disable().
If that happens, the timer will only be migrated to the current pCPU on
the next exit, meaning that guest LAPIC timer event can be delayed until
a host interrupt is tr... | ```diff
diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
index 00acf1301a15..b90744a1dc3a 100644
--- a/arch/x86/kvm/x86.c
+++ b/arch/x86/kvm/x86.c
@@ -2759,6 +2759,8 @@ again:
if (vcpu->requests) {
if (test_and_clear_bit(KVM_REQ_MIGRATE_TIMER, &vcpu->requests))
__kvm_migrate_timers(vcpu);
+ if (test_and_c... |
6ff10de374cc68ff2024247793176dc8a1b317ea | Analyze and fix the following issue in the Linux kernel code: x86: fix "x86: use cpu_khz for loops_per_jiffy calculation" | Problem Details:
fix:
arch/x86/kernel/tsc_32.c: In function ‘tsc_init':
arch/x86/kernel/tsc_32.c:421: error: ‘lpj_tsc' undeclared (first use in this function)
arch/x86/kernel/tsc_32.c:421: error: (Each undeclared identifier is reported only once
arch/x86/kernel/tsc_32.c:421: error: for each function it appears in.)
S... | ```diff
diff --git a/arch/x86/kernel/tsc_32.c b/arch/x86/kernel/tsc_32.c
index be729035b30b..0af49fb533e1 100644
--- a/arch/x86/kernel/tsc_32.c
+++ b/arch/x86/kernel/tsc_32.c
@@ -1,6 +1,7 @@
#include <linux/sched.h>
#include <linux/clocksource.h>
#include <linux/workqueue.h>
+#include <linux/delay.h>
#include <linu... |
72c6e251ed84b3a9cdfde6711191155c47bb2b9c | Analyze and fix the following issue in the Linux kernel code: alpha: fix compile error in arch/alpha/mm/init.c | Problem Details:
Commit 9267b4b3880d00dc2dab90f1d817c856939114f7 ("alpha: fix module load
failures on smp (bug #10926)") causes a regression for my ev4
uniprocessor build:
CC arch/alpha/mm/init.o
/export/data/repositories/linux-2.6/arch/alpha/mm/init.c:34: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’... | ```diff
diff --git a/include/asm-alpha/percpu.h b/include/asm-alpha/percpu.h
index 82e8a94b4b2f..3495e8e00d70 100644
--- a/include/asm-alpha/percpu.h
+++ b/include/asm-alpha/percpu.h
@@ -69,6 +69,8 @@ extern unsigned long __per_cpu_offset[NR_CPUS];
#define __get_cpu_var(var) per_cpu_var(var)
#define __raw_get_cpu_va... |
cd1a28e8457e6ebf72c48d84d4e736307e86436e | Analyze and fix the following issue in the Linux kernel code: lockdep: add lock_class information to lock_chain and output it | Problem Details:
It is based on x86/master branch of git-x86 tree, and has been tested
on x86_64 platform.
ChangeLog:
v2:
- Enclosing proc file system related code into CONFIG_PROVE_LOCKING.
- Fix nr_chain_hlocks update code.
Signed-off-by: Huang Ying <ying.huang@intel.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.... | ```diff
diff --git a/kernel/lockdep.c b/kernel/lockdep.c
index a796f1f38ac5..7553a28b99cd 100644
--- a/kernel/lockdep.c
+++ b/kernel/lockdep.c
@@ -1459,7 +1459,7 @@ out_bug:
unsigned long nr_lock_chains;
struct lock_chain lock_chains[MAX_LOCKDEP_CHAINS];
-atomic_t nr_chain_hlocks;
+int nr_chain_hlocks;
static u16 ... |
b7e2445737ff69cef892b6fd9cd71cae2c9e9515 | Analyze and fix the following issue in the Linux kernel code: NFS: Fix filehandle size comparisons in the mount code | Problem Details:
Fix a sign issue in xdr_decode_fhstatus3()
Fix incorrect comparison in nfs_validate_mount_data()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com> | ```diff
diff --git a/fs/nfs/mount_clnt.c b/fs/nfs/mount_clnt.c
index 49c7cd0502cc..779d2eb649c5 100644
--- a/fs/nfs/mount_clnt.c
+++ b/fs/nfs/mount_clnt.c
@@ -130,10 +130,11 @@ static int xdr_decode_fhstatus3(struct rpc_rqst *req, __be32 *p,
struct mnt_fhstatus *res)
{
struct nfs_fh *fh = res->fh;
+ unsigned si... |
33852a1f2bb014e4047a844556c0d76a2f790c37 | Analyze and fix the following issue in the Linux kernel code: NFS: Reduce the NFS mount code stack usage. | Problem Details:
This appears to fix the Oops reported in
http://bugzilla.kernel.org/show_bug.cgi?id=10826
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com> | ```diff
diff --git a/fs/nfs/super.c b/fs/nfs/super.c
index 2a4a024a4e7b..dac663dc5611 100644
--- a/fs/nfs/super.c
+++ b/fs/nfs/super.c
@@ -1216,8 +1216,6 @@ static int nfs_validate_mount_data(void *options,
{
struct nfs_mount_data *data = (struct nfs_mount_data *)options;
- memset(args, 0, sizeof(*args));
-
if (... |
76fbc263ff7e42ce8b21b8aee176e3c74b45f81a | Analyze and fix the following issue in the Linux kernel code: pci: debug extra pci bus resources | Problem Details:
Signed-off-by: Ingo Molnar <mingo@elte.hu> | ```diff
diff --git a/drivers/pci/setup-bus.c b/drivers/pci/setup-bus.c
index 8ddb918f5f57..c74a2bce083d 100644
--- a/drivers/pci/setup-bus.c
+++ b/drivers/pci/setup-bus.c
@@ -537,6 +537,36 @@ void __ref pci_bus_assign_resources(struct pci_bus *bus)
}
EXPORT_SYMBOL(pci_bus_assign_resources);
+static void pci_bus_dum... |
9bf8a1a79d549a0cf3b26c88d1ac8cdf07deafee | Analyze and fix the following issue in the Linux kernel code: pci: debug extra pci resources range | Problem Details:
Signed-off-by: Ingo Molnar <mingo@elte.hu> | ```diff
diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
index 3706ce7972dd..27cdbb06c4dd 100644
--- a/drivers/pci/probe.c
+++ b/drivers/pci/probe.c
@@ -275,6 +275,7 @@ static void pci_read_bases(struct pci_dev *dev, unsigned int howmany, int rom)
}
res->start = l64 & PCI_BASE_ADDRESS_MEM_MASK;
res->e... |
945754a1754f9d4c2974a8241ad4f92fad7f3a6a | Analyze and fix the following issue in the Linux kernel code: mm: fix race in COW logic | Problem Details:
There is a race in the COW logic. It contains a shortcut to avoid the
COW and reuse the page if we have the sole reference on the page,
however it is possible to have two racing do_wp_page()ers with one
causing the other to mistakenly believe it is safe to take the shortcut
when it is not. This could... | ```diff
diff --git a/mm/memory.c b/mm/memory.c
index 423e0e7c2f73..d14b251a25a6 100644
--- a/mm/memory.c
+++ b/mm/memory.c
@@ -1785,7 +1785,6 @@ gotten:
page_table = pte_offset_map_lock(mm, pmd, address, &ptl);
if (likely(pte_same(*page_table, orig_pte))) {
if (old_page) {
- page_remove_rmap(old_page, vma);
... |
672ca28e300c17bf8d792a2a7a8631193e580c74 | Analyze and fix the following issue in the Linux kernel code: Fix ZERO_PAGE breakage with vmware | Problem Details:
Commit 89f5b7da2a6bad2e84670422ab8192382a5aeb9f ("Reinstate ZERO_PAGE
optimization in 'get_user_pages()' and fix XIP") broke vmware, as
reported by Jeff Chua:
"This broke vmware 6.0.4.
Jun 22 14:53:03.845: vmx| NOT_IMPLEMENTED
/build/mts/release/bora-93057/bora/vmx/main/vmmonPosix.c:774"
and ... | ```diff
diff --git a/mm/memory.c b/mm/memory.c
index 9aefaae46858..423e0e7c2f73 100644
--- a/mm/memory.c
+++ b/mm/memory.c
@@ -1045,6 +1045,26 @@ no_page_table:
return page;
}
+/* Can we do the FOLL_ANON optimization? */
+static inline int use_zero_page(struct vm_area_struct *vma)
+{
+ /*
+ * We don't want to opt... |
31f3e0b3a18c6d48196c40a82a3b8c01f4ff6b23 | Analyze and fix the following issue in the Linux kernel code: [patch 1/3] vfs: dcache sparse fixes | Problem Details:
Fix the following sparse warnings:
fs/dcache.c:2183:19: warning: symbol 'filp_cachep' was not declared. Should it be static?
fs/dcache.c:115:3: warning: context imbalance in 'dentry_iput' - unexpected unlock
fs/dcache.c:188:2: warning: context imbalance in 'dput' - different lock contexts for basic bl... | ```diff
diff --git a/fs/dcache.c b/fs/dcache.c
index 2b479de10a0a..e4b2b9436b32 100644
--- a/fs/dcache.c
+++ b/fs/dcache.c
@@ -17,6 +17,7 @@
#include <linux/syscalls.h>
#include <linux/string.h>
#include <linux/mm.h>
+#include <linux/fdtable.h>
#include <linux/fs.h>
#include <linux/fsnotify.h>
#include <linux/sla... |
be285c712bbbe5db43e503782fbef2bfeaa345f9 | Analyze and fix the following issue in the Linux kernel code: [patch 3/3] vfs: make d_path() consistent across mount operations | Problem Details:
The path that __d_path() computes can become slightly inconsistent when it
races with mount operations: it grabs the vfsmount_lock when traversing mount
points but immediately drops it again, only to re-grab it when it reaches the
next mount point. The result is that the filename computed is not alway... | ```diff
diff --git a/fs/dcache.c b/fs/dcache.c
index c4c9072d810c..2b479de10a0a 100644
--- a/fs/dcache.c
+++ b/fs/dcache.c
@@ -1782,6 +1782,7 @@ char *__d_path(const struct path *path, struct path *root,
char * end = buffer+buflen;
char * retval;
+ spin_lock(&vfsmount_lock);
prepend(&end, &buflen, "\0", 1);
i... |
c7d106c90ec40a0e35a6960157b40f238627246e | Analyze and fix the following issue in the Linux kernel code: nfsd: fix race in nfsd_nrthreads() | Problem Details:
We need the nfsd_mutex before accessing nfsd_serv->sv_nrthreads or we
can't even guarantee nfsd_serv will still be there.
Signed-off-by: Neil Brown <neilb@suse.de>
Acked-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> | ```diff
diff --git a/fs/nfsd/nfssvc.c b/fs/nfsd/nfssvc.c
index 26c81149d49a..96fdbcab8d95 100644
--- a/fs/nfsd/nfssvc.c
+++ b/fs/nfsd/nfssvc.c
@@ -165,10 +165,12 @@ int nfsd_vers(int vers, enum vers_op change)
int nfsd_nrthreads(void)
{
- if (nfsd_serv == NULL)
- return 0;
- else
- return nfsd_serv->sv_nrthreads;... |
3dd98a3bccb1bdd30b8a4a755e7bead1b64160ec | Analyze and fix the following issue in the Linux kernel code: knfsd: clean up nfsd filesystem interfaces | Problem Details:
Several of the nfsd filesystem interfaces allow changes to parameters
that don't have any effect on a running nfsd service. They are only ever
checked when nfsd is started. This patch fixes it so that changes to
those procfiles return -EBUSY if nfsd is already running to make it
clear that changes on t... | ```diff
diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c
index 5c97d47676ae..bf11d6879ab4 100644
--- a/fs/nfsd/nfs4state.c
+++ b/fs/nfsd/nfs4state.c
@@ -3249,12 +3249,14 @@ nfs4_state_shutdown(void)
nfs4_unlock_state();
}
+/*
+ * user_recovery_dirname is protected by the nfsd_mutex since it's only
+ * access... |
87afd448b186c885d67a08b7417cd46253b6a9d6 | Analyze and fix the following issue in the Linux kernel code: IB/mthca: Clear ICM pages before handing to FW | Problem Details:
Current memfree FW has a bug which in some cases, assumes that ICM
pages passed to it are cleared. This patch uses __GFP_ZERO to
allocate all ICM pages passed to the FW. Once firmware with a fix is
released, we can make the workaround conditional on firmware version.
This fixes the bug reported by A... | ```diff
diff --git a/drivers/infiniband/hw/mthca/mthca_memfree.c b/drivers/infiniband/hw/mthca/mthca_memfree.c
index b224079d4e1f..d5862e5d99a0 100644
--- a/drivers/infiniband/hw/mthca/mthca_memfree.c
+++ b/drivers/infiniband/hw/mthca/mthca_memfree.c
@@ -109,7 +109,11 @@ static int mthca_alloc_icm_pages(struct scatterl... |
694a1764d657e0f7a9b139bc7269c8d5f5a2534b | Analyze and fix the following issue in the Linux kernel code: [patch 3/4] vfs: fix ERR_PTR abuse in generic_readlink | Problem Details:
generic_readlink calls ERR_PTR for negative and positive values
(vfs_readlink returns length of "link"), but it should not
(not an errno) and does not need to.
Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com>
Cc: Al Viro <viro@ZenIV.linux.org.uk>
Cc: Christoph Hellwig <hch@lst.de>
Acked-by: Mi... | ```diff
diff --git a/fs/namei.c b/fs/namei.c
index ee1544696e83..01e67dddcc3d 100644
--- a/fs/namei.c
+++ b/fs/namei.c
@@ -2856,16 +2856,17 @@ int generic_readlink(struct dentry *dentry, char __user *buffer, int buflen)
{
struct nameidata nd;
void *cookie;
+ int res;
nd.depth = 0;
cookie = dentry->d_inode->i... |
c70f84417429f41519be0197a1092a53c2201f47 | Analyze and fix the following issue in the Linux kernel code: [patch for 2.6.26 4/4] vfs: utimensat(): fix write access check for futimens() | Problem Details:
The POSIX.1 draft spec for futimens()/utimensat() says:
Only a process with the effective user ID equal to the
user ID of the file, *or with write access to the file*,
or with appropriate privileges may use futimens() or
utimensat() with a null pointer as the times argu... | ```diff
diff --git a/fs/utimes.c b/fs/utimes.c
index 118d1c3241be..b6b664e7145e 100644
--- a/fs/utimes.c
+++ b/fs/utimes.c
@@ -148,14 +148,9 @@ long do_utimes(int dfd, char __user *filename, struct timespec *times, int flags
goto mnt_drop_write_and_out;
if (!is_owner_or_cap(inode)) {
- if (f) {
- if (!(f-... |
4cca92264e61a90b43fc4e076cd25b7f4e16dc61 | Analyze and fix the following issue in the Linux kernel code: [patch for 2.6.26 3/4] vfs: utimensat(): fix error checking for {UTIME_NOW,UTIME_OMIT} case | Problem Details:
The POSIX.1 draft spec for utimensat() says:
Only a process with the effective user ID equal to the
user ID of the file or with appropriate privileges may use
futimens() or utimensat() with a non-null times argument
that does not have both tv_nsec fields set to UTIME_NOW
and does n... | ```diff
diff --git a/fs/utimes.c b/fs/utimes.c
index d466bc587e6e..118d1c3241be 100644
--- a/fs/utimes.c
+++ b/fs/utimes.c
@@ -40,14 +40,9 @@ asmlinkage long sys_utime(char __user *filename, struct utimbuf __user *times)
#endif
-static bool nsec_special(long nsec)
-{
- return nsec == UTIME_OMIT || nsec == UTIME_NO... |
12fd0d3088d27867be68655bcab2b074f2835f60 | Analyze and fix the following issue in the Linux kernel code: [patch for 2.6.26 2/4] vfs: utimensat(): be consistent with utime() for immutable and append-only files | Problem Details:
This patch fixes utimensat() to make its behavior consistent
with that of utime()/utimes() when dealing with files marked
immutable and append-only.
The current utimensat() implementation also returns EPERM if
'times' is non-NULL and the tv_nsec fields are both UTIME_NOW.
For consistency, the
(times ... | ```diff
diff --git a/fs/utimes.c b/fs/utimes.c
index af059d5cb485..14d3edbb3d7c 100644
--- a/fs/utimes.c
+++ b/fs/utimes.c
@@ -102,6 +102,10 @@ long do_utimes(int dfd, char __user *filename, struct timespec *times, int flags
if (error)
goto dput_and_out;
+ if (times && times[0].tv_nsec == UTIME_NOW &&
+ ti... |
fe6e9c1f25ac01f848bd084ee0ee62a5a0966ff3 | Analyze and fix the following issue in the Linux kernel code: [PATCH] fix cgroup-inflicted breakage in block_dev.c | Problem Details:
devcgroup_inode_permission() expects MAY_FOO, not FMODE_FOO; kindly
keep your misdesign consistent if you positively have to inflict it
on the kernel.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> | ```diff
diff --git a/fs/block_dev.c b/fs/block_dev.c
index 470c10ceb0fb..10d8a0aa871a 100644
--- a/fs/block_dev.c
+++ b/fs/block_dev.c
@@ -931,8 +931,16 @@ static int do_open(struct block_device *bdev, struct file *file, int for_part)
struct gendisk *disk;
int ret;
int part;
+ int perm = 0;
- ret = devcgroup_in... |
1b7558e457ed0de61023cfc913d2c342c7c3d9f2 | Analyze and fix the following issue in the Linux kernel code: futexes: fix fault handling in futex_lock_pi | Problem Details:
This patch addresses a very sporadic pi-futex related failure in
highly threaded java apps on large SMP systems.
David Holmes reported that the pi_state consistency check in
lookup_pi_state triggered with his test application. This means that
the kernel internal pi_state and the user space futex varia... | ```diff
diff --git a/kernel/futex.c b/kernel/futex.c
index 449def8074fe..7d1136e97c14 100644
--- a/kernel/futex.c
+++ b/kernel/futex.c
@@ -1096,21 +1096,64 @@ static void unqueue_me_pi(struct futex_q *q)
* private futexes.
*/
static int fixup_pi_state_owner(u32 __user *uaddr, struct futex_q *q,
- struct task_st... |
3e14b50dd4a3178f4f635267a2706b5d4f8c61ee | Analyze and fix the following issue in the Linux kernel code: ALSA: sb - Fix wrong assertions | Problem Details:
snd_assert() in save_mixer() and restore_mixer() in sb_mixer.c is
just wrong. The debug code wasn't tested at all, obviously...
Signed-off-by: Takashi Iwai <tiwai@suse.de> | ```diff
diff --git a/sound/isa/sb/sb_mixer.c b/sound/isa/sb/sb_mixer.c
index 91d14224f6b3..73d4572d136b 100644
--- a/sound/isa/sb/sb_mixer.c
+++ b/sound/isa/sb/sb_mixer.c
@@ -925,7 +925,7 @@ static unsigned char als4000_saved_regs[] = {
static void save_mixer(struct snd_sb *chip, unsigned char *regs, int num_regs)
{
... |
44e051773da465f8c92127914bc784770e0e2a28 | Analyze and fix the following issue in the Linux kernel code: ALSA: aw2 - Fix Oops at initialization | Problem Details:
The irq handler may be called before the proper initialization of hardware.
Call snd_aw2_saa7146_setup() before the irq handler registration.
Signed-off-by: Takashi Iwai <tiwai@suse.de> | ```diff
diff --git a/sound/pci/aw2/aw2-alsa.c b/sound/pci/aw2/aw2-alsa.c
index 56f87cd33c19..3f00ddf450f8 100644
--- a/sound/pci/aw2/aw2-alsa.c
+++ b/sound/pci/aw2/aw2-alsa.c
@@ -316,6 +316,8 @@ static int __devinit snd_aw2_create(struct snd_card *card,
return -ENOMEM;
}
+ /* (2) initialization of the chip hardw... |
b206ed0462b7112d07bb9f245bf49f5e95ff174a | Analyze and fix the following issue in the Linux kernel code: [ARM] Orion: remove error printks in ->map_irq() implementations | Problem Details:
If all PCI devices are working as expected, the error printks in the
various implementations of ->map_irq() doesn't really provide any
useful info. And if something is not working as expected, turning
on pci=debug gives you more useful information than the printk calls
in ->map_irq(), since the former... | ```diff
diff --git a/arch/arm/mach-orion5x/dns323-setup.c b/arch/arm/mach-orion5x/dns323-setup.c
index 05ce66048741..ad810aa5fff5 100644
--- a/arch/arm/mach-orion5x/dns323-setup.c
+++ b/arch/arm/mach-orion5x/dns323-setup.c
@@ -53,8 +53,6 @@ static int __init dns323_pci_map_irq(struct pci_dev *dev, u8 slot, u8 pin)
if... |
e7068ad337a991fba627148a4a57939fdc1e6a2d | Analyze and fix the following issue in the Linux kernel code: [ARM] Orion: fix various whitespace and coding style issues | Problem Details:
More cosmetic cleanup:
- Replace 8-space indents by proper tab indents.
- In structure initialisers, use a trailing comma for every member.
- Collapse "},\n{" in structure initialiers to "}, {".
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Acked-by: Russell King <linux@arm.linux.org.uk> | ```diff
diff --git a/arch/arm/mach-orion5x/common.c b/arch/arm/mach-orion5x/common.c
index 4f13fd037f04..fa4be3cb1549 100644
--- a/arch/arm/mach-orion5x/common.c
+++ b/arch/arm/mach-orion5x/common.c
@@ -39,25 +39,22 @@ static struct map_desc orion5x_io_desc[] __initdata = {
.virtual = ORION5X_REGS_VIRT_BASE,
.pfn... |
4c4925c1f4ccd72002957c3e73b4f117f2bcf712 | Analyze and fix the following issue in the Linux kernel code: [ARM] fix cache alignment code in memset.S | Problem Details:
This code is currently disabled, which explains why no one was affected.
Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com> | ```diff
diff --git a/arch/arm/lib/memmove.S b/arch/arm/lib/memmove.S
index ef7fddc14ac9..018522c3ff26 100644
--- a/arch/arm/lib/memmove.S
+++ b/arch/arm/lib/memmove.S
@@ -60,6 +60,7 @@ ENTRY(memmove)
CALGN( bcs 2f )
CALGN( adr r4, 6f )
CALGN( subs r2, r2, ip ) @ C is set here
+ CALGN( rsb ip, ip, #32 )
C... |
55d8538498f62ec72b5ba67aa386c7726f630475 | Analyze and fix the following issue in the Linux kernel code: Fix performance regression on lmbench select benchmark | Problem Details:
Christian Borntraeger reported that reinstating cond_resched() with
CONFIG_PREEMPT caused a performance regression on lmbench:
For example select file 500:
23 microseconds
32 microseconds
and that's really because we totally unnecessarily do the cond_resched()
in the innermost loop of select(), wh... | ```diff
diff --git a/fs/select.c b/fs/select.c
index 8dda969614a9..da0e88201c3a 100644
--- a/fs/select.c
+++ b/fs/select.c
@@ -249,7 +249,6 @@ int do_select(int n, fd_set_bits *fds, s64 *timeout)
retval++;
}
}
- cond_resched();
}
if (res_in)
*rinp = res_in;
@@ -257,6 +256,7 @@ int do_s... |
ee98476bbc565f8fe42e198602e647288b6a258d | Analyze and fix the following issue in the Linux kernel code: [ARM] 5116/1: pxafb: cleanup and fix order of failure handling | Problem Details:
This issue was found by Krzysztof Helt and Eric Miao.
pxafb had issues in the order with which it cleaned up if errors occurred
during a probe. This patch reorders the failure handling sequence and also
frees the cmap and clk.
Signed-off-by: Jaya Kumar <jayakumar.lkml@gmail.com>
Acked-by: Krzysztof H... | ```diff
diff --git a/drivers/video/pxafb.c b/drivers/video/pxafb.c
index eb23d1923332..796e0d1d5b19 100644
--- a/drivers/video/pxafb.c
+++ b/drivers/video/pxafb.c
@@ -1685,14 +1685,14 @@ static int __init pxafb_probe(struct platform_device *dev)
if (r == NULL) {
dev_err(&dev->dev, "no I/O memory resource defined\n... |
f1edfc420ac7beb90b27bf822036cbbfa32483f1 | Analyze and fix the following issue in the Linux kernel code: [ARM] 5115/1: pxafb: fix ifdef for command line option handling | Problem Details:
This bug was found and fixed by Lothar Wassmann.
Previously, the use of ifndef CONFIG_MODULES made it such that pxafb command
line option parsing was dependent on whether the kernel was built with module
support. The ifndef should be MODULE so that parsing is dependent only on
whether the driver is bu... | ```diff
diff --git a/drivers/video/pxafb.c b/drivers/video/pxafb.c
index 7dcda187d9ba..eb23d1923332 100644
--- a/drivers/video/pxafb.c
+++ b/drivers/video/pxafb.c
@@ -1588,7 +1588,7 @@ static int __init pxafb_parse_options(struct device *dev, char *options)
static char g_options[256] __devinitdata = "";
-#ifndef C... |
481c5346d0981940ee63037eb53e4e37b0735c10 | Analyze and fix the following issue in the Linux kernel code: Slab: Fix memory leak in fallback_alloc() | Problem Details:
The zonelist patches caused the loop that checks for available
objects in permitted zones to not terminate immediately. One object
per zone per allocation may be allocated and then abandoned.
Break the loop when we have successfully allocated one object.
Signed-off-by: Christoph Lameter <clameter@sgi... | ```diff
diff --git a/mm/slab.c b/mm/slab.c
index 06236e4ddc1b..046607f05f3e 100644
--- a/mm/slab.c
+++ b/mm/slab.c
@@ -3263,9 +3263,12 @@ retry:
if (cpuset_zone_allowed_hardwall(zone, flags) &&
cache->nodelists[nid] &&
- cache->nodelists[nid]->free_objects)
+ cache->nodelists[nid]->free_objects) {
obj... |
71c2742f5e6348d76ee62085cf0a13e5eff0f00e | Analyze and fix the following issue in the Linux kernel code: Add return value to reserve_bootmem_node() | Problem Details:
This patch changes the function reserve_bootmem_node() from void to int,
returning -ENOMEM if the allocation fails.
This fixes a build problem on x86 with CONFIG_KEXEC=y and
CONFIG_NEED_MULTIPLE_NODES=y
Signed-off-by: Bernhard Walle <bwalle@suse.de>
Reported-by: Adrian Bunk <bunk@kernel.org>
Signed-o... | ```diff
diff --git a/include/linux/bootmem.h b/include/linux/bootmem.h
index 6a5dbdc8a7dc..686895bacd9d 100644
--- a/include/linux/bootmem.h
+++ b/include/linux/bootmem.h
@@ -94,7 +94,7 @@ extern unsigned long init_bootmem_node(pg_data_t *pgdat,
unsigned long freepfn,
unsigned long startpfn,
... |
8dc244f7deac4c0e95ce0ffd26f494bb6e1534c0 | Analyze and fix the following issue in the Linux kernel code: [WATCHDOG 48/57] txx9: Fix locking, switch to unlocked_ioctl | Problem Details:
Review and switch to unlocked_ioctl
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be> | ```diff
diff --git a/drivers/watchdog/txx9wdt.c b/drivers/watchdog/txx9wdt.c
index 57cefef27ce3..b729cc447df3 100644
--- a/drivers/watchdog/txx9wdt.c
+++ b/drivers/watchdog/txx9wdt.c
@@ -45,27 +45,34 @@ static unsigned long txx9wdt_alive;
static int expect_close;
static struct txx9_tmr_reg __iomem *txx9wdt_reg;
stat... |
d14bccaadaa49b651fabcd1298b6ea07db3af552 | Analyze and fix the following issue in the Linux kernel code: [WATCHDOG 42/57] sc1200_wdt: clean up, fix locking and use unlocked_ioctl | Problem Details:
Review and switch to unlocked_ioctl
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be> | ```diff
diff --git a/drivers/watchdog/sc1200wdt.c b/drivers/watchdog/sc1200wdt.c
index 35cddff7020f..7e5c9cc97dee 100644
--- a/drivers/watchdog/sc1200wdt.c
+++ b/drivers/watchdog/sc1200wdt.c
@@ -15,14 +15,18 @@
*
* Changelog:
* 20020220 Zwane Mwaikambo Code based on datasheet, no hardware.
- * 20020221 Zwane Mwai... |
437a0a54eea7b101e8a5b70688009956f6522ed0 | Analyze and fix the following issue in the Linux kernel code: x86, bitops: make constant-bit set/clear_bit ops faster, gcc workaround | Problem Details:
Jeremy Fitzhardinge reported this compiler bug:
Suggestion from Linus: add "r" to the input constraint of the
set_bit()/clear_bit()'s constant 'nr' branch:
Blows up on "gcc version 3.4.4 20050314 (prerelease) (Debian 3.4.3-13)":
CC init/main.o
include2/asm/bitops.h: In function `start_kernel':... | ```diff
diff --git a/include/asm-x86/bitops.h b/include/asm-x86/bitops.h
index 6c5054819719..96b1829cea15 100644
--- a/include/asm-x86/bitops.h
+++ b/include/asm-x86/bitops.h
@@ -58,7 +58,7 @@ static inline void set_bit(unsigned int nr, volatile unsigned long *addr)
if (IS_IMMEDIATE(nr)) {
asm volatile(LOCK_PREFIX... |
b9f75f45a6b46a0ab4eb0857d437a0845871f314 | Analyze and fix the following issue in the Linux kernel code: netns: Don't receive new packets in a dead network namespace. | Problem Details:
Alexey Dobriyan <adobriyan@gmail.com> writes:
> Subject: ICMP sockets destruction vs ICMP packets oops
> After icmp_sk_exit() nuked ICMP sockets, we get an interrupt.
> icmp_reply() wants ICMP socket.
>
> Steps to reproduce:
>
> launch shell in new netns
> move real NIC to netns
> setup routing
> ... | ```diff
diff --git a/include/net/net_namespace.h b/include/net/net_namespace.h
index aa540e6be502..d9dd0f707296 100644
--- a/include/net/net_namespace.h
+++ b/include/net/net_namespace.h
@@ -95,6 +95,11 @@ extern struct list_head net_namespace_list;
#ifdef CONFIG_NET_NS
extern void __put_net(struct net *net);
+stat... |
735ce972fbc8a65fb17788debd7bbe7b4383cc62 | Analyze and fix the following issue in the Linux kernel code: sctp: Make sure N * sizeof(union sctp_addr) does not overflow. | Problem Details:
As noticed by Gabriel Campana, the kmalloc() length arg
passed in by sctp_getsockopt_local_addrs_old() can overflow
if ->addr_num is large enough.
Therefore, enforce an appropriate limit.
Signed-off-by: David S. Miller <davem@davemloft.net> | ```diff
diff --git a/net/sctp/socket.c b/net/sctp/socket.c
index e7e3baf7009e..0dbcde6758ea 100644
--- a/net/sctp/socket.c
+++ b/net/sctp/socket.c
@@ -4401,7 +4401,9 @@ static int sctp_getsockopt_local_addrs_old(struct sock *sk, int len,
if (copy_from_user(&getaddrs, optval, len))
return -EFAULT;
- if (getaddrs.... |
2645a3c3761ac25498db2e627271016c849c68e1 | Analyze and fix the following issue in the Linux kernel code: pppoe: warning fix | Problem Details:
Fix warning:
drivers/net/pppoe.c: In function 'pppoe_recvmsg':
drivers/net/pppoe.c:945: warning: comparison of distinct pointer types lacks a cast
because skb->len is unsigned int and total_len is size_t
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@dav... | ```diff
diff --git a/drivers/net/pppoe.c b/drivers/net/pppoe.c
index bafb69b6f7cb..fc6f4b8c64b3 100644
--- a/drivers/net/pppoe.c
+++ b/drivers/net/pppoe.c
@@ -942,7 +942,7 @@ static int pppoe_recvmsg(struct kiocb *iocb, struct socket *sock,
m->msg_namelen = 0;
if (skb) {
- total_len = min(total_len, skb->len);
+... |
d559d4a24a3fed75bd890abcc1f95cd8d8dad6e1 | Analyze and fix the following issue in the Linux kernel code: alpha: fix compile failures with gcc-4.3 (bug #10438) | Problem Details:
Vast majority of these build failures are gcc-4.3 warnings
about static functions and objects being referenced from
non-static (read: "extern inline") functions, in conjunction
with our -Werror.
We cannot just convert "extern inline" to "static inline",
as people keep suggesting all the time, because ... | ```diff
diff --git a/arch/alpha/kernel/core_t2.c b/arch/alpha/kernel/core_t2.c
index c0750291b44a..d9980d47ab81 100644
--- a/arch/alpha/kernel/core_t2.c
+++ b/arch/alpha/kernel/core_t2.c
@@ -74,6 +74,8 @@
# define DBG(args)
#endif
+DEFINE_SPINLOCK(t2_hae_lock);
+
static volatile unsigned int t2_mcheck_any_expected... |
ede426923b25414f5ec9c00fefe6727d9721dd13 | Analyze and fix the following issue in the Linux kernel code: alpha: link failure fix | Problem Details:
With built-in scsi disk driver, the final link fails with a following
error:
`.exit.text' referenced in section `.rodata' of drivers/built-in.o:
defined in discarded section `.exit.text' of drivers/built-in.o
This happens with -Os (CONFIG_CC_OPTIMIZE_FOR_SIZE=y) with all gcc-4
versions, and also with ... | ```diff
diff --git a/arch/alpha/Makefile b/arch/alpha/Makefile
index 4e1a8e2c4541..4759fe751aa1 100644
--- a/arch/alpha/Makefile
+++ b/arch/alpha/Makefile
@@ -13,6 +13,7 @@ NM := $(NM) -B
LDFLAGS_vmlinux := -static -N #-relax
CHECKFLAGS += -D__alpha__ -m64
cflags-y := -pipe -mno-fp-regs -ffixed-8 -msmall-data
+cflag... |
9267b4b3880d00dc2dab90f1d817c856939114f7 | Analyze and fix the following issue in the Linux kernel code: alpha: fix module load failures on smp (bug #10926) | Problem Details:
To calculate addresses of locally defined variables, GCC uses 32-bit
displacement from the GP. Which doesn't work for per cpu variables in
modules, as an offset to the kernel per cpu area is way above 4G.
The workaround is to force allocation of a GOT entry for per cpu variable
using ldq instruction w... | ```diff
diff --git a/include/asm-alpha/percpu.h b/include/asm-alpha/percpu.h
index 48348fe34c19..82e8a94b4b2f 100644
--- a/include/asm-alpha/percpu.h
+++ b/include/asm-alpha/percpu.h
@@ -1,6 +1,76 @@
#ifndef __ALPHA_PERCPU_H
#define __ALPHA_PERCPU_H
+#include <linux/compiler.h>
+#include <linux/threads.h>
-#include... |
39d95b9d857ad9ed335dd1a2d6c6de1f1ee69ce1 | Analyze and fix the following issue in the Linux kernel code: tty: cdev lock_kernel() pushdown | Problem Details:
Parts of the serial code actually BUG() if we don't do this. | ```diff
diff --git a/drivers/char/tty_io.c b/drivers/char/tty_io.c
index e94bee032314..fd182f2e4a6c 100644
--- a/drivers/char/tty_io.c
+++ b/drivers/char/tty_io.c
@@ -2665,7 +2665,7 @@ static void release_dev(struct file *filp)
* ->siglock protects ->signal/->sighand
*/
-static int tty_open(struct inode *inode,... |
1f6ef2342972dc7fd623f360f84006e2304eb935 | Analyze and fix the following issue in the Linux kernel code: [watchdog] hpwdt: fix use of inline assembly | Problem Details:
The inline assembly in drivers/watchdog/hpwdt.c was incredibly broken,
and included all the function prologue and epilogue stuff, even though
it was itself then inside a C function where the compiler would add its
own prologue and epilogue on top of it all.
This then just _happened_ to work if you had... | ```diff
diff --git a/drivers/watchdog/hpwdt.c b/drivers/watchdog/hpwdt.c
index 2686f3eaeedf..eaa3f2a79ff5 100644
--- a/drivers/watchdog/hpwdt.c
+++ b/drivers/watchdog/hpwdt.c
@@ -140,49 +140,53 @@ static struct pci_device_id hpwdt_devices[] = {
};
MODULE_DEVICE_TABLE(pci, hpwdt_devices);
+extern asmlinkage void asm... |
a17bf220231a5061a29a27a99a273246eb3b156e | Analyze and fix the following issue in the Linux kernel code: pcmcia: add another pata/ide ID | Problem Details:
Addition of Transcend 1GB 45x id so that it is properly detected.
[bart: fix typo in ide-cs's ID spotted by Alan Cox]
Signed-off-by: William Peters <w1ll14@gmail.com>
Signed-off-by: Kristoffer Ericson <Kristoffer_e1@hotmail.com>
CC: Alan Cox <alan@lxorguk.ukuu.org.uk>
CC: linux-ide@vger.kernel.org
Si... | ```diff
diff --git a/drivers/ata/pata_pcmcia.c b/drivers/ata/pata_pcmcia.c
index c97bc0cd1e17..41b4361bbf6e 100644
--- a/drivers/ata/pata_pcmcia.c
+++ b/drivers/ata/pata_pcmcia.c
@@ -425,6 +425,7 @@ static struct pcmcia_device_id pcmcia_devices[] = {
PCMCIA_DEVICE_PROD_ID12("SMI VENDOR", "SMI PRODUCT", 0x30896c92, 0x... |
f54feafa6d47d0aa1a96adefdc763b708b02f94f | Analyze and fix the following issue in the Linux kernel code: ide: increase timeout in wait_drive_not_busy() | Problem Details:
Some ATAPI devices take longer than the current max timeout value to
become ready (i.e. TEAC DV-W28ECW takes 6 ms) so increase the timeout
value to 10 ms.
This fixes kernel.org bugzilla bug #10887:
http://bugzilla.kernel.org/show_bug.cgi?id=10887
Reported-by: Masanari Iida <standby24x7@gmail.com>
Sig... | ```diff
diff --git a/drivers/ide/ide-taskfile.c b/drivers/ide/ide-taskfile.c
index 0c908ca3ff79..ab545ffa1549 100644
--- a/drivers/ide/ide-taskfile.c
+++ b/drivers/ide/ide-taskfile.c
@@ -225,10 +225,10 @@ static u8 wait_drive_not_busy(ide_drive_t *drive)
u8 stat;
/*
- * Last sector was transfered, wait until dri... |
ce42a54946db338e43be9a89c0f7927e02aa3a16 | Analyze and fix the following issue in the Linux kernel code: palm_bk3710: fix resource management | Problem Details:
The driver expected a *virtual* address in the IDE platform device's memory
resource and didn't request the memory region for the register block. Fix this
taking into account the fact that DaVinci SoC devices are fixed-mapped to the
virtual memory early and we can get their virtual addresses using IO_A... | ```diff
diff --git a/drivers/ide/arm/palm_bk3710.c b/drivers/ide/arm/palm_bk3710.c
index d024ac8fad14..cc24803fadff 100644
--- a/drivers/ide/arm/palm_bk3710.c
+++ b/drivers/ide/arm/palm_bk3710.c
@@ -353,8 +353,8 @@ static int __devinit palm_bk3710_probe(struct platform_device *pdev)
struct clk *clkp;
struct resourc... |
89f5b7da2a6bad2e84670422ab8192382a5aeb9f | Analyze and fix the following issue in the Linux kernel code: Reinstate ZERO_PAGE optimization in 'get_user_pages()' and fix XIP | Problem Details:
KAMEZAWA Hiroyuki and Oleg Nesterov point out that since the commit
557ed1fa2620dc119adb86b34c614e152a629a80 ("remove ZERO_PAGE") removed
the ZERO_PAGE from the VM mappings, any users of get_user_pages() will
generally now populate the VM with real empty pages needlessly.
We used to get the ZERO_PAGE ... | ```diff
diff --git a/arch/powerpc/kernel/vdso.c b/arch/powerpc/kernel/vdso.c
index c21a626af676..ce245a850db2 100644
--- a/arch/powerpc/kernel/vdso.c
+++ b/arch/powerpc/kernel/vdso.c
@@ -142,7 +142,7 @@ static void dump_one_vdso_page(struct page *pg, struct page *upg)
printk("kpg: %p (c:%d,f:%08lx)", __va(page_to_pfn... |
2856922c158605514ec5974a03097eaec91f4c0d | Analyze and fix the following issue in the Linux kernel code: Ext4: Fix online resize block group descriptor corruption | Problem Details:
This is the patch for the group descriptor table corruption during
online resize pointed out by Theodore Tso. The problem was caused by
the fact that the ext4 group descriptor can be either 32 or 64 bytes
long. Only the 64 bytes structure was taken into account.
Signed-off-by: Frederic Bohe <frederi... | ```diff
diff --git a/fs/ext4/resize.c b/fs/ext4/resize.c
index 9ecb92f68543..9ff7b1c04239 100644
--- a/fs/ext4/resize.c
+++ b/fs/ext4/resize.c
@@ -855,7 +855,8 @@ int ext4_group_add(struct super_block *sb, struct ext4_new_group_data *input)
*/
/* Update group descriptor block for new group */
- gdp = (struct ext... |
ea71a546706dfdad72462624394e1e472c6bf34f | Analyze and fix the following issue in the Linux kernel code: sched: refactor wait_for_completion_timeout() | Problem Details:
Simplify the code and fix the boundary condition of
wait_for_completion_timeout(,0).
We can kill the first __remove_wait_queue() as well.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl> | ```diff
diff --git a/kernel/sched.c b/kernel/sched.c
index 577f160131bd..bebf9788f45e 100644
--- a/kernel/sched.c
+++ b/kernel/sched.c
@@ -4398,32 +4398,20 @@ do_wait_for_common(struct completion *x, long timeout, int state)
signal_pending(current)) ||
(state == TASK_KILLABLE &&
fatal_signal_p... |
0f476b6d91a1395bda6464e653ce66ea9bea7167 | Analyze and fix the following issue in the Linux kernel code: softirq: remove irqs_disabled warning from local_bh_enable | Problem Details:
There's no need to use local_irq_save() over local_irq_disable() in the
local_bh_enable code since it is a bug to call it with irqs disabled and
do_softirq will enable irqs if there is any pending work.
Consolidate the code from local_bh_enable and ..._ip to avoid having a
disconnect between them in t... | ```diff
diff --git a/kernel/softirq.c b/kernel/softirq.c
index 86775340ef1d..2cf2502b7c73 100644
--- a/kernel/softirq.c
+++ b/kernel/softirq.c
@@ -131,23 +131,17 @@ void _local_bh_enable(void)
EXPORT_SYMBOL(_local_bh_enable);
-void local_bh_enable(void)
+static inline void _local_bh_enable_ip(unsigned long ip)
{
... |
a1d5a8691f1b6c92491747bea3b778b184fa5837 | Analyze and fix the following issue in the Linux kernel code: x86: unify __set_fixmap, fix | Problem Details:
fix build failure:
arch/x86/mm/pgtable.c:280: warning: ‘enum fixed_addresses’ declared inside parameter list
arch/x86/mm/pgtable.c:280: warning: its scope is only this definition or declaration, which is probably not what you want
arch/x86/mm/pgtable.c:280: error: parameter 1 (‘idx’) has incomplete... | ```diff
diff --git a/arch/x86/mm/pgtable.c b/arch/x86/mm/pgtable.c
index e9fb66361fc8..892fd1892b8d 100644
--- a/arch/x86/mm/pgtable.c
+++ b/arch/x86/mm/pgtable.c
@@ -2,6 +2,7 @@
#include <asm/pgalloc.h>
#include <asm/pgtable.h>
#include <asm/tlb.h>
+#include <asm/fixmap.h>
pte_t *pte_alloc_one_kernel(struct mm_s... |
05345b0f006ac226d0d25d48fcb2d792ac44a071 | Analyze and fix the following issue in the Linux kernel code: xen: mask unwanted pte bits in __supported_pte_mask | Problem Details:
[ Stable: this isn't a bugfix in itself, but it's a pre-requiste
for "xen: don't drop NX bit" ]
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Cc: Stable Kernel <stable@kernel.org>
Cc: the arch/x86 maintainers <x86@kernel.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu> | ```diff
diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c
index c8a56e457d61..c048de34d6a1 100644
--- a/arch/x86/xen/enlighten.c
+++ b/arch/x86/xen/enlighten.c
@@ -1228,6 +1228,11 @@ asmlinkage void __init xen_start_kernel(void)
if (xen_feature(XENFEAT_supervisor_mode_kernel))
pv_info.kernel_rpl = 0... |
eb179e443deb0a5c81a62b4c157124a4b7ff1813 | Analyze and fix the following issue in the Linux kernel code: xen: mask unwanted pte bits in __supported_pte_mask | Problem Details:
[ Stable: this isn't a bugfix in itself, but it's a pre-requiste
for "xen: don't drop NX bit" ]
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Cc: Stable Kernel <stable@kernel.org>
Cc: the arch/x86 maintainers <x86@kernel.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu> | ```diff
diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c
index 8e6152e6ed88..73fb0c4c150a 100644
--- a/arch/x86/xen/enlighten.c
+++ b/arch/x86/xen/enlighten.c
@@ -1280,6 +1280,11 @@ asmlinkage void __init xen_start_kernel(void)
if (xen_feature(XENFEAT_supervisor_mode_kernel))
pv_info.kernel_rpl = 0... |
a1855d802fb62718192eb7e180161b08adff4e73 | Analyze and fix the following issue in the Linux kernel code: ALSA: hda - Fix digital converter proc output | Problem Details:
AC_VERB_GET_DIGI_CONVERT_2 isn't actually implemented but reserved.
The whole SIC bits are returned from DIGI_CONVERT_1.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz> | ```diff
diff --git a/sound/pci/hda/hda_codec.h b/sound/pci/hda/hda_codec.h
index dcd390b2bbaa..efc682888b31 100644
--- a/sound/pci/hda/hda_codec.h
+++ b/sound/pci/hda/hda_codec.h
@@ -78,7 +78,7 @@ enum {
#define AC_VERB_GET_BEEP_CONTROL 0x0f0a
#define AC_VERB_GET_EAPD_BTLENABLE 0x0f0c
#define AC_VERB_GET_DIGI_CONV... |
54481cf88bc59923ea30f2ca345a73c60155e901 | Analyze and fix the following issue in the Linux kernel code: x86: fix NULL pointer deref in __switch_to | Problem Details:
I am able to reproduce the oops reported by Simon in __switch_to() with
lguest.
My debug showed that there is at least one lguest specific
issue (which should be present in 2.6.25 and before aswell) and it got
exposed with a kernel oops with the recent fpu dynamic allocation patches.
In addition to t... | ```diff
diff --git a/drivers/lguest/x86/core.c b/drivers/lguest/x86/core.c
index 5126d5d9ea0e..2e554a4ab337 100644
--- a/drivers/lguest/x86/core.c
+++ b/drivers/lguest/x86/core.c
@@ -176,7 +176,7 @@ void lguest_arch_run_guest(struct lg_cpu *cpu)
* we set it now, so we can trap and pass that trap to the Guest if it
... |
bb10ed0994927d433f6dbdf274fdb26cfcf516b7 | Analyze and fix the following issue in the Linux kernel code: sched: fix wait_for_completion_timeout() spurious failure under heavy load | Problem Details:
It seems that the current implementaton of wait_for_completion_timeout()
has a small problem under very high load for the common pattern:
if (!wait_for_completion_timeout(&done, timeout))
/* handle failure */
because the implementation very roughly does (lots of code deleted to
show the basic flow... | ```diff
diff --git a/kernel/sched.c b/kernel/sched.c
index 4a3cb0614158..577f160131bd 100644
--- a/kernel/sched.c
+++ b/kernel/sched.c
@@ -4405,6 +4405,16 @@ do_wait_for_common(struct completion *x, long timeout, int state)
spin_unlock_irq(&x->wait.lock);
timeout = schedule_timeout(timeout);
spin_lock_irq(&... |
10b612f440a22a294e87ec7e8f03f9eea3338628 | Analyze and fix the following issue in the Linux kernel code: sched: rt: fix the bandwidth contraint computations | Problem Details:
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: "Daniel K." <dk@uw.no>
Signed-off-by: Ingo Molnar <mingo@elte.hu> | ```diff
diff --git a/kernel/sched.c b/kernel/sched.c
index 5b307da827ef..1f711a58a2b4 100644
--- a/kernel/sched.c
+++ b/kernel/sched.c
@@ -8419,7 +8419,7 @@ static unsigned long to_ratio(u64 period, u64 runtime)
#ifdef CONFIG_CGROUP_SCHED
static int __rt_schedulable(struct task_group *tg, u64 period, u64 runtime)
{
... |
b79f3833d81d54fc71d98c8064dc45f33a755a8a | Analyze and fix the following issue in the Linux kernel code: sched: rt: fix SMP bandwidth balancing for throttled groups | Problem Details:
Now we exceed the runtime and get throttled - the period rollover tick
will subtract the cpu quota from the runtime and check if we're below
quota. However with this cpu having a very small portion of the runtime
it will not refresh as fast as it should.
Therefore, also rebalance the runtime when we'r... | ```diff
diff --git a/kernel/sched_rt.c b/kernel/sched_rt.c
index 2e0ccdcf046a..87b2e3bf9472 100644
--- a/kernel/sched_rt.c
+++ b/kernel/sched_rt.c
@@ -228,6 +228,28 @@ static inline struct rt_bandwidth *sched_rt_bandwidth(struct rt_rq *rt_rq)
#endif
+#ifdef CONFIG_SMP
+static int do_balance_runtime(struct rt_rq *r... |
ada18de2eb76961a4d4847f63291744c9e7beec4 | Analyze and fix the following issue in the Linux kernel code: sched: debug: add some rt debug output | Problem Details:
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: "Daniel K." <dk@uw.no>
Signed-off-by: Ingo Molnar <mingo@elte.hu> | ```diff
diff --git a/kernel/sched_debug.c b/kernel/sched_debug.c
index 8bb713040ac9..8e077b9c91cb 100644
--- a/kernel/sched_debug.c
+++ b/kernel/sched_debug.c
@@ -119,9 +119,7 @@ void print_cfs_rq(struct seq_file *m, int cpu, struct cfs_rq *cfs_rq)
struct sched_entity *last;
unsigned long flags;
-#if !defined(CON... |
7dbceaf9bb68919651901b101f44edd5391ee489 | Analyze and fix the following issue in the Linux kernel code: x86, bitops: make constant-bit set/clear_bit ops faster, adapt, clean up | Problem Details:
fix integration bug introduced by "x86: bitops take an unsigned long *"
which turned "(void *) + x" into "(long *) + x".
small cleanups to make it more apparent which value get propagated where.
Signed-off-by: Ingo Molnar <mingo@elte.hu> | ```diff
diff --git a/include/asm-x86/bitops.h b/include/asm-x86/bitops.h
index ab7635a4acd9..6c5054819719 100644
--- a/include/asm-x86/bitops.h
+++ b/include/asm-x86/bitops.h
@@ -28,16 +28,15 @@
#define BITOP_ADDR(x) "+m" (*(volatile long *) (x))
#endif
-#define ADDR BITOP_ADDR(addr)
+#define ADDR BITOP_ADDR(add... |
f630e43a215a3129d0c1173cae0bce6ea4855cf7 | Analyze and fix the following issue in the Linux kernel code: ipv6: Drop packets for loopback address from outside of the box. | Problem Details:
[ Based upon original report and patch by Karsten Keil. Karsten
has verified that this fixes the TAHI test case "ICMPv6 test
v6LC.5.1.2 Part F". -DaveM ]
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: David S. Miller <davem@davemloft.net> | ```diff
diff --git a/include/net/ipv6.h b/include/net/ipv6.h
index e0a612bc9c4e..f422f7218e1c 100644
--- a/include/net/ipv6.h
+++ b/include/net/ipv6.h
@@ -367,6 +367,12 @@ static inline int ipv6_addr_any(const struct in6_addr *a)
a->s6_addr32[2] | a->s6_addr32[3] ) == 0);
}
+static inline int ipv6_addr_loopback... |
d4abc238c9f4df8b3216f3e883f5d0a07b7ac75a | Analyze and fix the following issue in the Linux kernel code: sched, delay accounting: fix incorrect delay time when constantly waiting on runqueue | Problem Details:
This patch corrects the incorrect value of per process run-queue wait
time reported by delay statistics. The anomaly was due to the following
reason. When a process leaves the CPU and immediately starts waiting for
CPU on the runqueue (which means it remains in the TASK_RUNNABLE state),
the time of re-... | ```diff
diff --git a/kernel/sched_stats.h b/kernel/sched_stats.h
index a38878e0e49d..80179ef7450e 100644
--- a/kernel/sched_stats.h
+++ b/kernel/sched_stats.h
@@ -198,6 +198,9 @@ static inline void sched_info_queued(struct task_struct *t)
/*
* Called when a process ceases being the active-running process, either
*... |
1a750e0cd7a30c478723ecfa1df685efcdd38a90 | Analyze and fix the following issue in the Linux kernel code: x86, bitops: make constant-bit set/clear_bit ops faster | Problem Details:
On Wed, 18 Jun 2008, Linus Torvalds wrote:
>
> And yes, the "lock andl" should be noticeably faster than the xchgl.
I dunno. Here's a untested (!!) patch that turns constant-bit
set/clear_bit ops into byte mask ops (lock orb/andb).
It's not exactly pretty. The reason for using the byte versions is th... | ```diff
diff --git a/include/asm-x86/bitops.h b/include/asm-x86/bitops.h
index 7d2494bdc660..ab7635a4acd9 100644
--- a/include/asm-x86/bitops.h
+++ b/include/asm-x86/bitops.h
@@ -23,11 +23,22 @@
#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 1)
/* Technically wrong, but this avoids compilation errors on some ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.