id
stringlengths
40
40
instruction
stringlengths
68
308
input
stringlengths
17
33.4k
output
stringlengths
100
30k
99eb44fe941b35b28914881774515005fa2ab7f6
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (4259): Pass an explicit log prefix to cx2341x_log_status
Problem Details: A card number is not unique enough. Instead, let the caller specify the prefix of the status messages. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
```diff diff --git a/drivers/media/video/cx2341x.c b/drivers/media/video/cx2341x.c index c98740979b60..65f00fc08fa9 100644 --- a/drivers/media/video/cx2341x.c +++ b/drivers/media/video/cx2341x.c @@ -847,22 +847,22 @@ invalid: return "<invalid>"; } -void cx2341x_log_status(struct cx2341x_mpeg_params *p, int card_id...
4d6b5aee9d19d1a982d9db0b5ffea20ee94816c6
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (4257): Fix 64-bit compile warnings.
Problem Details: Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
```diff diff --git a/drivers/media/video/cx2341x.c b/drivers/media/video/cx2341x.c index 01b22eab5725..c98740979b60 100644 --- a/drivers/media/video/cx2341x.c +++ b/drivers/media/video/cx2341x.c @@ -601,7 +601,7 @@ static void cx2341x_calc_audio_properties(struct cx2341x_mpeg_params *params) } int cx2341x_ext_ctrls...
1b58841aa7011670d8a32f53554e21b3fae9c047
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (4254): Remove obsoleted tuner_debug option.
Problem Details: Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
```diff diff --git a/drivers/media/video/tuner-core.c b/drivers/media/video/tuner-core.c index a26ded7d6fae..011413cf34a8 100644 --- a/drivers/media/video/tuner-core.c +++ b/drivers/media/video/tuner-core.c @@ -40,7 +40,6 @@ static unsigned int no_autodetect = 0; static unsigned int show_i2c = 0; /* insmod options ...
343f92c293af979ddf6070b167306e96c776187b
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (4252): Remove duplicate 'tda9887' in info messages.
Problem Details: Remove the duplicate '(tda9887)' in these messages: tda9887 8-0043 (tda9887): tda988[5/6/7] found @ 0x43 (tuner) The same string is already printed as the prefix in this line. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
```diff diff --git a/drivers/media/video/tda9887.c b/drivers/media/video/tda9887.c index b6ae969563b2..b1ea6aa33166 100644 --- a/drivers/media/video/tda9887.c +++ b/drivers/media/video/tda9887.c @@ -22,11 +22,11 @@ */ #define tda9887_info(fmt, arg...) do {\ - printk(KERN_INFO "%s %d-%04x (tda9887): " fmt, t->i2c.na...
eb8e0ee4f51a89d569c01d5b09a8cbc935c72a4c
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (4241): Fix faulty encoder error recovery in pvrusb2
Problem Details: Signed-off-by: Mike Isely <isely@pobox.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
```diff diff --git a/drivers/media/video/pvrusb2/pvrusb2-hdw.c b/drivers/media/video/pvrusb2/pvrusb2-hdw.c index f461830c64c9..1829029cc9b9 100644 --- a/drivers/media/video/pvrusb2/pvrusb2-hdw.c +++ b/drivers/media/video/pvrusb2/pvrusb2-hdw.c @@ -1098,12 +1098,13 @@ void pvr2_hdw_subsys_bit_chg_no_lock(struct pvr2_hdw ...
e2fdbc039aeac4ce614ee29f4b14bcef5ba000dd
Analyze and fix the following issue in the Linux kernel code: [PATCH] drivers/net/hamradio/dmascc.c: fix section mismatch
Problem Details: dev_setup() is using the __initdata variables ax25_broadcast and ax25_test. Since the only caller of dev_setup() (setup_adapter()) is already __init, the solution is to make dev_setup() __init, too. Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Jeff Garzik <jeff@garzik.org>
```diff diff --git a/drivers/net/hamradio/dmascc.c b/drivers/net/hamradio/dmascc.c index 0d5fccc984bb..c9a46b89942a 100644 --- a/drivers/net/hamradio/dmascc.c +++ b/drivers/net/hamradio/dmascc.c @@ -436,7 +436,7 @@ static int __init dmascc_init(void) module_init(dmascc_init); module_exit(dmascc_exit); -static void ...
600991b003039bd86d89aed0a88de89987ccbcd1
Analyze and fix the following issue in the Linux kernel code: [PATCH] Fix phy id for LXT971A/LXT972A
Problem Details: From: Uwe Zeisberger <Uwe_Zeisberger@digi.com> The phy ids used are taken from an driver that used a right shift of 4 to chop off the revision number. This driver does not shift, so the id and mask values are wrong and must be left shifted by 4 to actually detect the chips. Signed-off-by: Uwe Zeisbe...
```diff diff --git a/drivers/net/phy/lxt.c b/drivers/net/phy/lxt.c index bef79e454c33..3f702c503afe 100644 --- a/drivers/net/phy/lxt.c +++ b/drivers/net/phy/lxt.c @@ -123,9 +123,9 @@ static int lxt971_config_intr(struct phy_device *phydev) } static struct phy_driver lxt970_driver = { - .phy_id = 0x07810000, + .phy...
b4ed03ff12e4bf228aaf15b2a364134348ebe8a9
Analyze and fix the following issue in the Linux kernel code: [PATCH] DM9000 - better checks for platform resources
Problem Details: The current DM9000 driver cannot cope if it is given more than 3 resources (for example, if it is being passed an wake-up irq that it is not using yet). Check that we have been given at-least one IRQ resource. Also fix the minor type-casting for the case of 2 resources. Signed-off-by: Ben Dooks <ben...
```diff diff --git a/drivers/net/dm9000.c b/drivers/net/dm9000.c index 24996da4c1c4..631e0d9f2e40 100644 --- a/drivers/net/dm9000.c +++ b/drivers/net/dm9000.c @@ -410,10 +410,7 @@ dm9000_probe(struct platform_device *pdev) if (pdev->num_resources < 2) { ret = -ENODEV; goto out; - } - - switch (pdev->num_resourc...
d38b69689c349f35502b92e20dafb30c62d49d63
Analyze and fix the following issue in the Linux kernel code: Revert "kbuild: fix make -rR breakage"
Problem Details: This reverts commit e5c44fd88c146755da6941d047de4d97651404a9. Thanks to Daniel Ritz and Michal Piotrowski for noticing the problem. Daniel says: "[The] reason is a recent change that made modules always shows as module.mod. it breaks modprobe and probably many scripts..besides lsmod looking...
```diff diff --git a/scripts/Kbuild.include b/scripts/Kbuild.include index ac5f275b0283..b0d067be7390 100644 --- a/scripts/Kbuild.include +++ b/scripts/Kbuild.include @@ -12,11 +12,6 @@ space := $(empty) $(empty) # contain a comma depfile = $(subst $(comma),_,$(@D)/.$(@F).d) -### -# basetarget equals the filename...
ce2deca27acc761ab90a0e79bd31d6816df38960
Analyze and fix the following issue in the Linux kernel code: ARM: OMAP: Fix SRAM to use MT_MEMORY instead of MT_DEVICE
Problem Details: MT_MEMORY is needed in order to execute code in SRAM. Also need to use section mapping. Based on a patch by Richard Woodruff. Signed-off-by: Tony Lindgren <tony@atomide.com>
```diff diff --git a/arch/arm/plat-omap/sram.c b/arch/arm/plat-omap/sram.c index b7bf09b1b412..aebd06faf2cf 100644 --- a/arch/arm/plat-omap/sram.c +++ b/arch/arm/plat-omap/sram.c @@ -158,14 +158,12 @@ static struct map_desc omap_sram_io_desc[] __initdata = { { /* .length gets filled in at runtime */ .virtual = OMA...
2aab6468b7f88df60828f8e07cfdf8c87338ed8d
Analyze and fix the following issue in the Linux kernel code: ARM: OMAP: Fix GPMC compilation when DEBUG is defined
Problem Details: Signed-off-by: Juha Yrjola <juha.yrjola@solidboot.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
```diff diff --git a/arch/arm/mach-omap2/gpmc.c b/arch/arm/mach-omap2/gpmc.c index 4aeaa4e79585..c7a48f921fef 100644 --- a/arch/arm/mach-omap2/gpmc.c +++ b/arch/arm/mach-omap2/gpmc.c @@ -90,7 +90,7 @@ unsigned int gpmc_ns_to_ticks(unsigned int time_ns) #ifdef DEBUG static int set_gpmc_timing_reg(int cs, int reg, in...
7ff879dbcd2083c95933a56bce65ae45ecab3f35
Analyze and fix the following issue in the Linux kernel code: ARM: OMAP: Fix DMA channel irq handling for omap24xx
Problem Details: - DMA CSR register is cleared by reading on omap1, but on omap2 it is cleard by writing to it. - DMA TOUT interrupt does not exist on omap24xx, rename it - Add SECURE and MISALIGNED errors by default for omap24xx - Add defines for external DMA request lines Signed-off-by: Tony Lindgren <tony@atom...
```diff diff --git a/arch/arm/plat-omap/dma.c b/arch/arm/plat-omap/dma.c index 8e7c33656b52..c5d0214ef191 100644 --- a/arch/arm/plat-omap/dma.c +++ b/arch/arm/plat-omap/dma.c @@ -43,6 +43,7 @@ #define OMAP_DMA_ACTIVE 0x01 #define OMAP_DMA_CCR_EN (1 << 7) +#define OMAP2_DMA_CSR_CLEAR_MASK 0xffe #define OMAP_FUN...
e32f7ec2e8bf00756c74a5e6a80bc59e949dd81d
Analyze and fix the following issue in the Linux kernel code: ARM: OMAP: Fix 32 kHz timer and modify GP timer to use GPT1
Problem Details: The dmtimer framework update broke 32 kHz timer as udelay() does not work before system timer is started (and GPT1 should not be reset). This also makes the GP timer use GPT1. This requires a fix in clock framework. Signed-off-by: Timo Teras <timo.teras@solidboot.com> Signed-off-by: Juha Yrjola <juha....
```diff diff --git a/arch/arm/mach-omap2/clock.c b/arch/arm/mach-omap2/clock.c index 242d8f925e9e..6789dd4029a1 100644 --- a/arch/arm/mach-omap2/clock.c +++ b/arch/arm/mach-omap2/clock.c @@ -753,7 +753,7 @@ static u32 omap2_get_src_field(u32 *type_to_addr, u32 reg_offset, val = 0x2; break; case CM_WKUP_SEL1: -...
99c477074de4a91a388aff863646dc3e2eb783e2
Analyze and fix the following issue in the Linux kernel code: ARM: OMAP: Fix GPIO IRQ mask handling
Problem Details: The GPIO IRQ mask was retrieved incorrectly in cases where we have a mask register instead of an enable register. Also we should only return the valid bits depending on the bank size. This fixes a bug on 1510/1610 based OMAPs where GPIO IRQs are not delivered. Signed-off-by: Imre Deak <imre.deak@noki...
```diff diff --git a/arch/arm/plat-omap/gpio.c b/arch/arm/plat-omap/gpio.c index cd1e508f90c1..e75a2ca70ba1 100644 --- a/arch/arm/plat-omap/gpio.c +++ b/arch/arm/plat-omap/gpio.c @@ -540,29 +540,44 @@ static inline void _clear_gpio_irqstatus(struct gpio_bank *bank, int gpio) static u32 _get_gpio_irqbank_mask(struct gp...
eca9e56eb8dfcf2b8b966c1c49e4622196f0586d
Analyze and fix the following issue in the Linux kernel code: ARM: OMAP: DMA transfer parameter configuration fix
Problem Details: Fix for re-using OMAP DMA channel with different transfer parameters. Bits in the CCR register need to be cleaned as well in some cases. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
```diff diff --git a/arch/arm/plat-omap/dma.c b/arch/arm/plat-omap/dma.c index 5dac4230360d..aa1cf79f9543 100644 --- a/arch/arm/plat-omap/dma.c +++ b/arch/arm/plat-omap/dma.c @@ -166,18 +166,24 @@ void omap_set_dma_transfer_params(int lch, int data_type, int elem_count, if (cpu_is_omap24xx() && dma_trigger) { u32 ...
ffb7a80f932550590ef54791b60db7e6ffce63f3
Analyze and fix the following issue in the Linux kernel code: ARM: OMAP: Fix gpt2_ick clock bit
Problem Details: CM_ICLKEN1_CORE bit should be 4, not 0 as noted by Richard Woodruff. Signed-off-by: Tony Lindgren <tony@atomide.com>
```diff diff --git a/arch/arm/mach-omap2/clock.h b/arch/arm/mach-omap2/clock.h index 6c78d471fab7..2781dfbc5164 100644 --- a/arch/arm/mach-omap2/clock.h +++ b/arch/arm/mach-omap2/clock.h @@ -1062,7 +1062,7 @@ static struct clk gpt2_ick = { .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, .enabl...
ea6dedd7fbd0f760ebf37eb0bcc8c64856475a13
Analyze and fix the following issue in the Linux kernel code: ARM: OMAP: GPIO IRQ lazy IRQ disable fix
Problem Details: - The current OMAP GPIO IRQ framework doesn't use the do_edge_IRQ, do_level_IRQ handlers, but instead calls do_simple_IRQ. This doesn't handle disabled interrupts properly, so drivers will still get interrupts after calling disable_irq. The patch solves this by respecting the irq_desc.disable_d...
```diff diff --git a/arch/arm/plat-omap/gpio.c b/arch/arm/plat-omap/gpio.c index d3c8ea7eecfd..cd1e508f90c1 100644 --- a/arch/arm/plat-omap/gpio.c +++ b/arch/arm/plat-omap/gpio.c @@ -537,6 +537,34 @@ static inline void _clear_gpio_irqstatus(struct gpio_bank *bank, int gpio) _clear_gpio_irqbank(bank, 1 << get_gpio_ind...
3fb5a9891dbb553dda96783dbc0dc4e77cbb2529
Analyze and fix the following issue in the Linux kernel code: [PATCH] fs/ocfs2/dlm/: cleanups
Problem Details: This patch #if 0's the no longer used dlm_dump_lock_resources(). Since this makes dlmdebug.h empty, this patch also removes this header. Additionally, the needlessly global dlm_is_node_recovered() is made static. Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Mark Fasheh <mark.fasheh@ora...
```diff diff --git a/fs/ocfs2/dlm/dlmdebug.c b/fs/ocfs2/dlm/dlmdebug.c index e119e4ddf93f..3f6c8d88f7af 100644 --- a/fs/ocfs2/dlm/dlmdebug.c +++ b/fs/ocfs2/dlm/dlmdebug.c @@ -37,10 +37,8 @@ #include "dlmapi.h" #include "dlmcommon.h" -#include "dlmdebug.h" #include "dlmdomain.h" -#include "dlmdebug.h" #define ...
43dee336c903fae15783b90983dfdedd2c7ffefc
Analyze and fix the following issue in the Linux kernel code: ocfs2: fix compiler warnings in dlm_convert_lock_handler()
Problem Details: We need to cast to unsigned long long. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
```diff diff --git a/fs/ocfs2/dlm/dlmconvert.c b/fs/ocfs2/dlm/dlmconvert.c index b24fa537a767..c764dc8e40a2 100644 --- a/fs/ocfs2/dlm/dlmconvert.c +++ b/fs/ocfs2/dlm/dlmconvert.c @@ -487,7 +487,8 @@ int dlm_convert_lock_handler(struct o2net_msg *msg, u32 len, void *data) mlog(ML_ERROR, "There is something here " ...
8a9343fa24d8d3fcb189bed2b7afcf4b8a8c1c8d
Analyze and fix the following issue in the Linux kernel code: ocfs2: dlm_print_one_mle() needs to be defined
Problem Details: Fixes compile breakage. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
```diff diff --git a/fs/ocfs2/dlm/dlmmaster.c b/fs/ocfs2/dlm/dlmmaster.c index 733d9a528873..1b38c558f2ad 100644 --- a/fs/ocfs2/dlm/dlmmaster.c +++ b/fs/ocfs2/dlm/dlmmaster.c @@ -128,11 +128,8 @@ static inline int dlm_mle_equal(struct dlm_ctxt *dlm, return 1; } -#if 0 -/* Code here is included but defined out as i...
495ac96e638cb0ad33baa7113531d742bfb328d4
Analyze and fix the following issue in the Linux kernel code: ocfs2: fix incorrect error returns
Problem Details: Use DLM_REJECTED instead of DLM_RECOVERING. Signed-off-by: Kurt Hackel <kurt.hackel@oracle.com> Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
```diff diff --git a/fs/ocfs2/dlm/dlmlock.c b/fs/ocfs2/dlm/dlmlock.c index e3cab0e48503..d6f89577e25f 100644 --- a/fs/ocfs2/dlm/dlmlock.c +++ b/fs/ocfs2/dlm/dlmlock.c @@ -299,7 +299,7 @@ static enum dlm_status dlm_send_remote_lock_request(struct dlm_ctxt *dlm, if (tmpret >= 0) { // successfully sent and received ...
343e26a4007d14c2154c1d13d1209797dce5c535
Analyze and fix the following issue in the Linux kernel code: ocfs2: dump mismatching migrated lvbs before BUG()
Problem Details: Signed-off-by: Kurt Hackel <kurt.hackel@oracle.com> Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
```diff diff --git a/fs/ocfs2/dlm/dlmrecovery.c b/fs/ocfs2/dlm/dlmrecovery.c index 19123ce8b306..de68e498bfad 100644 --- a/fs/ocfs2/dlm/dlmrecovery.c +++ b/fs/ocfs2/dlm/dlmrecovery.c @@ -1689,8 +1689,19 @@ static int dlm_process_recovery_data(struct dlm_ctxt *dlm, if (!dlm_lvb_is_empty(res->lvb) && (ml->t...
69d72b066cc5971318d9e29e34289b74cf8a9d22
Analyze and fix the following issue in the Linux kernel code: ocfs2: dlm recovery / lockres reference count fix
Problem Details: Take a reference on lockres structures while they are on the recovery list. Signed-off-by: Kurt Hackel <kurt.hackel@oracle.com> Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
```diff diff --git a/fs/ocfs2/dlm/dlmcommon.h b/fs/ocfs2/dlm/dlmcommon.h index bf873919b009..9e052445b0b5 100644 --- a/fs/ocfs2/dlm/dlmcommon.h +++ b/fs/ocfs2/dlm/dlmcommon.h @@ -849,6 +849,7 @@ void dlm_clean_master_list(struct dlm_ctxt *dlm, u8 dead_node); int dlm_lock_basts_flushed(struct dlm_ctxt *dlm, stru...
a7f90d83ea8dc8b0999ab7c1c0539af9a6ed69d2
Analyze and fix the following issue in the Linux kernel code: ocfs2: dump lockres info before we BUG() on a bad reference
Problem Details: Signed-off-by: Kurt Hackel <kurt.hackel@oracle.com> Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
```diff diff --git a/fs/ocfs2/dlm/dlmmaster.c b/fs/ocfs2/dlm/dlmmaster.c index 9c5ef405bb39..427c0af0d219 100644 --- a/fs/ocfs2/dlm/dlmmaster.c +++ b/fs/ocfs2/dlm/dlmmaster.c @@ -619,6 +619,28 @@ static void dlm_lockres_release(struct kref *kref) mlog(0, "destroying lockres %.*s\n", res->lockname.len, res->loc...
a2bf04774bf4aa0a75036c1e92e3d2fd1cce2aff
Analyze and fix the following issue in the Linux kernel code: ocfs2: mle ref counting fixes
Problem Details: Signed-off-by: Kurt Hackel <kurt.hackel@oracle.com> Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
```diff diff --git a/fs/ocfs2/dlm/dlmmaster.c b/fs/ocfs2/dlm/dlmmaster.c index d1c85f10c634..19399446aa8e 100644 --- a/fs/ocfs2/dlm/dlmmaster.c +++ b/fs/ocfs2/dlm/dlmmaster.c @@ -74,6 +74,7 @@ struct dlm_master_list_entry wait_queue_head_t wq; atomic_t woken; struct kref mle_refs; + int inuse; unsigned long may...
8bc674cb4834fb25206b7f7f5e37fe571aa76b34
Analyze and fix the following issue in the Linux kernel code: ocfs2: Fix empty lvb check
Problem Details: The check for an empty lvb should check the entire buffer not just the first byte. Signed-off-by: Kurt Hackel <kurt.hackel@oracle.com> Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
```diff diff --git a/fs/ocfs2/dlm/dlmcommon.h b/fs/ocfs2/dlm/dlmcommon.h index 4fc1be3a3fa2..bf873919b009 100644 --- a/fs/ocfs2/dlm/dlmcommon.h +++ b/fs/ocfs2/dlm/dlmcommon.h @@ -315,6 +315,15 @@ enum dlm_lockres_list { DLM_BLOCKED_LIST }; +static inline int dlm_lvb_is_empty(char *lvb) +{ + int i; + for (i=0; i<DL...
aba9aac78817d88aa2b223f1aedf1e9815ae97b8
Analyze and fix the following issue in the Linux kernel code: ocfs2: fix inverted logic in dlm_is_node_dead
Problem Details: Signed-off-by: Kurt Hackel <kurt.hackel@oracle.com> Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
```diff diff --git a/fs/ocfs2/dlm/dlmrecovery.c b/fs/ocfs2/dlm/dlmrecovery.c index bf2a02eca62e..b568bb6617d8 100644 --- a/fs/ocfs2/dlm/dlmrecovery.c +++ b/fs/ocfs2/dlm/dlmrecovery.c @@ -267,7 +267,7 @@ int dlm_is_node_dead(struct dlm_ctxt *dlm, u8 node) { int dead; spin_lock(&dlm->spinlock); - dead = test_bit(nod...
c8f33b6e86af74ee7b800f57cac7b3c8559318fe
Analyze and fix the following issue in the Linux kernel code: [PATCH] ocfs2: Alloc at least a page for the DLM hash
Problem Details: The OCFS2 DLM allocates a number of pages for a hash to lookup locks. There was a bug where a PAGE_SIZE bigger than the hash size (eg, 64K pages) would result in zero pages allocated. Signed-off-by: Joel Becker <joel.becker@oracle.com> Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
```diff diff --git a/fs/ocfs2/dlm/dlmcommon.h b/fs/ocfs2/dlm/dlmcommon.h index 0378ddbc8a8c..4fc1be3a3fa2 100644 --- a/fs/ocfs2/dlm/dlmcommon.h +++ b/fs/ocfs2/dlm/dlmcommon.h @@ -37,8 +37,12 @@ #define DLM_THREAD_SHUFFLE_INTERVAL 5 // flush everything every 5 passes #define DLM_THREAD_MS 200 ...
a3d3329159ea76bae0b3b8680691a1c3ecf5801f
Analyze and fix the following issue in the Linux kernel code: ocfs2: calculate lockid hash values outside of the spinlock
Problem Details: Fixes a performance bug - pointed out by Andrew. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
```diff diff --git a/fs/ocfs2/dlm/dlmcommon.h b/fs/ocfs2/dlm/dlmcommon.h index 1c05d485e019..3b675368762e 100644 --- a/fs/ocfs2/dlm/dlmcommon.h +++ b/fs/ocfs2/dlm/dlmcommon.h @@ -39,6 +39,9 @@ #define DLM_HASH_BUCKETS (PAGE_SIZE / sizeof(struct hlist_head)) +/* Intended to make it easier for us to switch out h...
041976fb6ae851cd18d96584a5d6361b564c9974
Analyze and fix the following issue in the Linux kernel code: [SCSI] lpfc: sparse NULL warnings
Problem Details: From: Randy Dunlap <rdunlap@xenotime.net> Fix sparse warnings: use NULL instead of 0 for pointers: drivers/scsi/lpfc/lpfc_els.c:827:56: warning: Using plain integer as NULL pointer drivers/scsi/lpfc/lpfc_els.c:2781:18: warning: Using plain integer as NULL pointer drivers/scsi/lpfc/lpfc_els.c:2782:18: ...
```diff diff --git a/drivers/scsi/lpfc/lpfc_els.c b/drivers/scsi/lpfc/lpfc_els.c index 283b7d824c34..4126fd87956f 100644 --- a/drivers/scsi/lpfc/lpfc_els.c +++ b/drivers/scsi/lpfc/lpfc_els.c @@ -821,7 +821,7 @@ lpfc_issue_els_plogi(struct lpfc_hba * phba, uint32_t did, uint8_t retry) pring = &psli->ring[LPFC_ELS_RING...
a09ab7e2fcd22f0490a270bb310536c651d53cb9
Analyze and fix the following issue in the Linux kernel code: [PATCH] type-oh bug in tlclk.c
Problem Details: Mark Bellon found a bug in my tlclk driver. Thanks! I botch the register mask for store_received_ref_clk3a. See http://download.intel.com/design/network/manuals/30412001.pdf tables 124 and 136 for details. Signed-off-by: Mark Gross <mark.gross@intel.com> Signed-off-by: Linus Torvalds <torvalds@osdl...
```diff diff --git a/drivers/char/tlclk.c b/drivers/char/tlclk.c index f58ad7f68267..ef68d152d3e4 100644 --- a/drivers/char/tlclk.c +++ b/drivers/char/tlclk.c @@ -343,7 +343,7 @@ static ssize_t store_received_ref_clk3b(struct device *d, val = (unsigned char)tmp; spin_lock_irqsave(&event_lock, flags); - SET_PORT_B...
916d15445f4ad2a9018e5451760734f36083be77
Analyze and fix the following issue in the Linux kernel code: [PATCH] fix processing of the last byte in isdn_readbchan_tty()
Problem Details: The changes in the tty handling contain a bug while accessing the last byte in the skb. Since special sequence for control of DTMF and FAX via ttyI* devices handled via this path, these services do not work anymore. Signed-off-by: Karsten Keil <kkeil@suse.de> Signed-off-by: Linus Torvalds <torvalds@os...
```diff diff --git a/drivers/isdn/i4l/isdn_common.c b/drivers/isdn/i4l/isdn_common.c index 81accdf35168..b26e509ec759 100644 --- a/drivers/isdn/i4l/isdn_common.c +++ b/drivers/isdn/i4l/isdn_common.c @@ -933,7 +933,7 @@ isdn_readbchan_tty(int di, int channel, struct tty_struct *tty, int cisco_hack) count_put = count...
890fbae2818a045350b8d1e3bda61ceb88ff1d17
Analyze and fix the following issue in the Linux kernel code: [PATCH] devfs: Last little devfs cleanups throughout the kernel tree.
Problem Details: Just removes a few unused #defines and fixes some comments due to devfs now being gone. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
```diff diff --git a/Documentation/Changes b/Documentation/Changes index b02f476c2973..488272074c36 100644 --- a/Documentation/Changes +++ b/Documentation/Changes @@ -181,8 +181,8 @@ Intel IA32 microcode -------------------- A driver has been added to allow updating of Intel IA32 microcode, -accessible as both a de...
331b831983f9d706f4a40d08a996d5c2c7a6ea7b
Analyze and fix the following issue in the Linux kernel code: [PATCH] devfs: Rename TTY_DRIVER_NO_DEVFS to TTY_DRIVER_DYNAMIC_DEV
Problem Details: I've always found this flag confusing. Now that devfs is no longer around, it has been renamed, and the documentation for when this flag should be used has been updated. Also fixes all drivers that use this flag. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
```diff diff --git a/arch/cris/arch-v10/kernel/debugport.c b/arch/cris/arch-v10/kernel/debugport.c index f3a85b77c17e..dde813e16294 100644 --- a/arch/cris/arch-v10/kernel/debugport.c +++ b/arch/cris/arch-v10/kernel/debugport.c @@ -541,7 +541,7 @@ init_dummy_console(void) dummy_driver.init_termios = tty_std_termios; ...
f4eaa37017a5a68f67ef86729508022c13fb8e6d
Analyze and fix the following issue in the Linux kernel code: [PATCH] devfs: Remove the tty_driver devfs_name field as it's no longer needed
Problem Details: Also fixes all drivers that set this field. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
```diff diff --git a/drivers/char/cyclades.c b/drivers/char/cyclades.c index 122e7a72a4e1..2657eeba7da6 100644 --- a/drivers/char/cyclades.c +++ b/drivers/char/cyclades.c @@ -5250,7 +5250,6 @@ cy_init(void) cy_serial_driver->owner = THIS_MODULE; cy_serial_driver->driver_name = "cyclades"; cy_serial_drive...
264f48646e6829b4d00a0e058452578318e6fb15
Analyze and fix the following issue in the Linux kernel code: [PATCH] devfs: Remove the line_driver devfs_name field as it's no longer needed
Problem Details: Also fixes all drivers that set this field. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
```diff diff --git a/arch/um/drivers/line.c b/arch/um/drivers/line.c index ee1fe6a24905..5ca57ca33713 100644 --- a/arch/um/drivers/line.c +++ b/arch/um/drivers/line.c @@ -654,7 +654,6 @@ struct tty_driver *line_register_devfs(struct lines *set, driver->driver_name = line_driver->name; driver->name = line_driver->...
5e483075a1f9862a65af648d1d939499969c7b5d
Analyze and fix the following issue in the Linux kernel code: [PATCH] devfs: Remove the videodevice devfs_name field as it's no longer needed
Problem Details: Also fixes all drivers that set this field. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
```diff diff --git a/drivers/media/video/videodev.c b/drivers/media/video/videodev.c index a802a7e0df79..b26ebaff226f 100644 --- a/drivers/media/video/videodev.c +++ b/drivers/media/video/videodev.c @@ -1570,8 +1570,7 @@ int video_register_device(struct video_device *vfd, int type, int nr) vfd->class_dev.dev = vfd->...
ce7b0f46bbf4bff8daab2dd3d878b9e72a623d09
Analyze and fix the following issue in the Linux kernel code: [PATCH] devfs: Remove the gendisk devfs_name field as it's no longer needed
Problem Details: And remove the now unneeded number field. Also fixes all drivers that set these fields. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
```diff diff --git a/arch/um/drivers/ubd_kern.c b/arch/um/drivers/ubd_kern.c index 5856a02fff58..c3e205b6a4c9 100644 --- a/arch/um/drivers/ubd_kern.c +++ b/arch/um/drivers/ubd_kern.c @@ -637,14 +637,10 @@ static int ubd_new_disk(int major, u64 size, int unit, disk->first_minor = unit << UBD_SHIFT; disk->fops = &ubd...
96192ff1a9d0c6ef365d21667080259d83ea2f5b
Analyze and fix the following issue in the Linux kernel code: [PATCH] devfs: Remove the miscdevice devfs_name field as it's no longer needed
Problem Details: Also fixes all drivers that set this field. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
```diff diff --git a/arch/i386/kernel/microcode.c b/arch/i386/kernel/microcode.c index 0a865889b2a9..40b44cc0d14b 100644 --- a/arch/i386/kernel/microcode.c +++ b/arch/i386/kernel/microcode.c @@ -493,7 +493,6 @@ static struct file_operations microcode_fops = { static struct miscdevice microcode_dev = { .minor = MICR...
ff23eca3e8f613034e0d20ff86f6a89b62f5a14e
Analyze and fix the following issue in the Linux kernel code: [PATCH] devfs: Remove the devfs_fs_kernel.h file from the tree
Problem Details: Also fixes up all files that #include it. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
```diff diff --git a/arch/sparc64/solaris/socksys.c b/arch/sparc64/solaris/socksys.c index 09664ab124ec..bc3df95bc057 100644 --- a/arch/sparc64/solaris/socksys.c +++ b/arch/sparc64/solaris/socksys.c @@ -26,7 +26,6 @@ #include <linux/slab.h> #include <linux/syscalls.h> #include <linux/in.h> -#include <linux/devfs_fs_...
aa4148cfc7b3b93eeaf755a7d14f10afaffe9a96
Analyze and fix the following issue in the Linux kernel code: [PATCH] devfs: Remove devfs support from the serial subsystem
Problem Details: Also fixes all serial drivers. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
```diff diff --git a/drivers/serial/21285.c b/drivers/serial/21285.c index 7572665a8855..9fd0de4b7afd 100644 --- a/drivers/serial/21285.c +++ b/drivers/serial/21285.c @@ -479,7 +479,6 @@ static struct uart_driver serial21285_reg = { .owner = THIS_MODULE, .driver_name = "ttyFB", .dev_name = "ttyFB", - .devfs_n...
8501a2fbe762b21d2504ed3aca3b52be61b5e6e4
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: x86_64 stack usage debugging
Problem Details: Applies to git & 2.6.17-rc6 after CONFIG_DEBUG_STACKOVERFLOW patch uses same stack-zeroing mechanism as on i386 to discover maximum stack excursions. Signed-off-by: Eric Sandeen <sandeen@sgi.com> Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
```diff diff --git a/arch/x86_64/Kconfig.debug b/arch/x86_64/Kconfig.debug index 087a04868b25..1d92ab56c0f9 100644 --- a/arch/x86_64/Kconfig.debug +++ b/arch/x86_64/Kconfig.debug @@ -42,6 +42,15 @@ config DEBUG_STACKOVERFLOW This option will cause messages to be printed if free stack space drops below a certain...
4961f10e2205d0ededa291e12ec634efc58aa93c
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: (resend) x86_64 stack overflow debugging
Problem Details: Take two, now without spurious whitespace :( Applies to git & 2.6.17-rc6 CONFIG_DEBUG_STACKOVERFLOW existed for x86_64 in 2.4, but seems to have gone AWOL in 2.6. I've pretty much just copied this over from the 2.4 code, with appropriate tweaks for the 2.6 kernel, plus a bugfix. I'd personally rath...
```diff diff --git a/arch/x86_64/Kconfig.debug b/arch/x86_64/Kconfig.debug index 0226f08be874..087a04868b25 100644 --- a/arch/x86_64/Kconfig.debug +++ b/arch/x86_64/Kconfig.debug @@ -35,6 +35,13 @@ config IOMMU_LEAK Add a simple leak tracer to the IOMMU code. This is useful when you are debugging a buggy d...
a4cffb6444c327677f901323ecf1a13d6bd2df3f
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: msi_apic.c build fix
Problem Details: CC drivers/pci/msi-apic.o In file included from include/asm/msi.h:11, from drivers/pci/msi.h:71, from drivers/pci/msi-apic.c:8: include/asm/smp.h:103: error: syntax error before '->' token akpm: nasty. It appears to be static inline unsigned int cpu_mask_to...
```diff diff --git a/drivers/pci/msi-apic.c b/drivers/pci/msi-apic.c index 0eb5fe9003a2..5ed798b319c7 100644 --- a/drivers/pci/msi-apic.c +++ b/drivers/pci/msi-apic.c @@ -4,6 +4,7 @@ #include <linux/pci.h> #include <linux/irq.h> +#include <asm/smp.h> #include "msi.h" ```
e77deacb7b078156fcadf27b838a4ce1a65eda04
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: Avoid broadcasting NMI IPIs
Problem Details: On some i386/x86_64 systems, sending an NMI IPI as a broadcast will reset the system. This seems to be a BIOS bug which affects machines where one or more cpus are not under OS control. It occurs on HT systems with a version of the OS that is not compiled without HT support. It also occurs when a sy...
```diff diff --git a/arch/x86_64/kernel/genapic_flat.c b/arch/x86_64/kernel/genapic_flat.c index c66ca7b1d31a..21c7066e236a 100644 --- a/arch/x86_64/kernel/genapic_flat.c +++ b/arch/x86_64/kernel/genapic_flat.c @@ -78,22 +78,29 @@ static void flat_send_IPI_mask(cpumask_t cpumask, int vector) static void flat_send_IP...
704fc59e1d056de80beaf30174bc8e0b1682efbb
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: fix apic error on bootup
Problem Details: Appended patch fixes the "APIC error on CPUX: 00(40)" observed during bootup. From SDM Vol-3A "Valid Interrupt Vectors" section: "When an illegal vector value (0-15) is written to an LVT entry and the delivery mode is Fixed, the APIC may signal an illegal vector error, with out regard to whether th...
```diff diff --git a/arch/i386/kernel/apic.c b/arch/i386/kernel/apic.c index 5f197e197c55..7ce09492fc0c 100644 --- a/arch/i386/kernel/apic.c +++ b/arch/i386/kernel/apic.c @@ -157,7 +157,7 @@ void clear_local_APIC(void) maxlvt = get_maxlvt(); /* - * Masking an LVT entry on a P6 can trigger a local APIC error + *...
03fdc2c277afdbd217eccd1ce0cfeff77ebd8b77
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: enlarge window for stack growth
Problem Details: Allow stack growth so the 'enter' instruction works. Also fixes problem in compat_sys_kexec_load() which could allocate more than 128 bytes using compat_alloc_user_space(). Signed-off-by: Chuck Ebbert <76306.1226@compuserve.com> Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Linus Torvalds <to...
```diff diff --git a/arch/x86_64/mm/fault.c b/arch/x86_64/mm/fault.c index 64728898f869..4968a71df4aa 100644 --- a/arch/x86_64/mm/fault.c +++ b/arch/x86_64/mm/fault.c @@ -410,8 +410,10 @@ asmlinkage void __kprobes do_page_fault(struct pt_regs *regs, if (!(vma->vm_flags & VM_GROWSDOWN)) goto bad_area; if (error_c...
45486f81c9aa07218b73a38cbcf62ffa66e99088
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: Standardize i386/x86_64 handling of NMI_VECTOR
Problem Details: x86_64 and i386 behave inconsistently when sending an IPI on vector 2 (NMI_VECTOR). Make both behave the same, so IPI 2 is sent as NMI. The crash code was abusing send_IPI_allbutself() by passing a code instead of a vector, it only worked because crash knew about the internal code of send_IPI_allbuts...
```diff diff --git a/arch/i386/kernel/crash.c b/arch/i386/kernel/crash.c index 21dc1bbb8067..0c88d3ec8c18 100644 --- a/arch/i386/kernel/crash.c +++ b/arch/i386/kernel/crash.c @@ -120,14 +120,9 @@ static int crash_nmi_callback(struct pt_regs *regs, int cpu) return 1; } -/* - * By using the NMI code instead of a vec...
9c63f8738734eb7e6d3f76ca03186f16ef88edf5
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: Fix modular pc speaker
Problem Details: It turned out that the following change is needed when the speaker is compiled as a module. Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
```diff diff --git a/arch/x86_64/kernel/setup.c b/arch/x86_64/kernel/setup.c index 8ade23d7ae76..0d2d4f67aa73 100644 --- a/arch/x86_64/kernel/setup.c +++ b/arch/x86_64/kernel/setup.c @@ -1361,7 +1361,7 @@ struct seq_operations cpuinfo_op = { .show = show_cpuinfo, }; -#ifdef CONFIG_INPUT_PCSPKR +#if defined(CONFIG_...
da5311258d2afb96fc592c8b11e818facfa46dc3
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: Fix race in cpu_local_* on preemptible kernels
Problem Details: When a process changes CPUs while doing the non atomic cpu_local_* operations it might operate on the local_t of a different CPUs. Fix that by disabling preemption. Pointed out by Christopher Lameter Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
```diff diff --git a/include/asm-i386/local.h b/include/asm-i386/local.h index e67fa08260fe..3b4998c51d08 100644 --- a/include/asm-i386/local.h +++ b/include/asm-i386/local.h @@ -55,12 +55,26 @@ static __inline__ void local_sub(long i, local_t *v) * much more efficient than these naive implementations. Note they tak...
75bd665cc9f4d0f67164d9145e446ae554d4ed3f
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: Fix fast check in safe_smp_processor_id
Problem Details: The APIC ID returned by hard_smp_processor_id can be beyond NR_CPUS and then overflow the x86_cpu_to_apic[] array. Add a check for overflow. If it happens then the slow loop below will catch. Bug pointed out by Doug Thompson Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Linus Torvalds <torva...
```diff diff --git a/arch/x86_64/kernel/smp.c b/arch/x86_64/kernel/smp.c index fe906ba1cf45..5885b8f044b2 100644 --- a/arch/x86_64/kernel/smp.c +++ b/arch/x86_64/kernel/smp.c @@ -520,13 +520,13 @@ asmlinkage void smp_call_function_interrupt(void) int safe_smp_processor_id(void) { - int apicid, i; + unsigned apicid,...
495ab9c045e1b0e5c82951b762257fe1c9d81564
Analyze and fix the following issue in the Linux kernel code: [PATCH] i386/x86-64/ia64: Move polling flag into thread_info_status
Problem Details: During some profiling I noticed that default_idle causes a lot of memory traffic. I think that is caused by the atomic operations to clear/set the polling flag in thread_info. There is actually no reason to make this atomic - only the idle thread does it to itself, other CPUs only read it. So I moved i...
```diff diff --git a/arch/i386/kernel/apm.c b/arch/i386/kernel/apm.c index 9e819eb68229..7c5729d1fd06 100644 --- a/arch/i386/kernel/apm.c +++ b/arch/i386/kernel/apm.c @@ -764,9 +764,9 @@ static int apm_do_idle(void) int idled = 0; int polling; - polling = test_thread_flag(TIF_POLLING_NRFLAG); + polling = !!(curre...
5f51e139d8b29116779044f26f84cceae34c31a4
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: miscellaneous mm/init.c fixes
Problem Details: - fix an off-by-one error in phys_pmd_init() - prevent phys_pmd_init() from removing mappings established earlier - fix the direct mapping early printk to in fact show the end of the range - remove an apparently orphan comment Signed-off-by: Jan Beulich <jbeulich@novell.com> Signed-off-by: Andi Kle...
```diff diff --git a/arch/x86_64/mm/init.c b/arch/x86_64/mm/init.c index 2f5f5b11e9d0..02add1d1dfa8 100644 --- a/arch/x86_64/mm/init.c +++ b/arch/x86_64/mm/init.c @@ -88,8 +88,6 @@ void show_mem(void) printk(KERN_INFO "%lu pages swap cached\n",cached); } -/* References to section boundaries */ - int after_bootmem...
bf660254e0d430e5d991e432d5dad8d6714828f6
Analyze and fix the following issue in the Linux kernel code: [PATCH] i386/x86-64: Fix isoimage when syslinux is in /usr/share
Problem Details: It's like this on SUSE systems. Cc: hpa@zytor.com Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
```diff diff --git a/arch/i386/boot/Makefile b/arch/i386/boot/Makefile index 33e55476381b..e97946626064 100644 --- a/arch/i386/boot/Makefile +++ b/arch/i386/boot/Makefile @@ -109,8 +109,13 @@ fdimage288: $(BOOTIMAGE) $(obj)/mtools.conf isoimage: $(BOOTIMAGE) -rm -rf $(obj)/isoimage mkdir $(obj)/isoimage - cp `echo...
7b0e85012581a9a8b12a8191d365716bf3ca3d3c
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: Add X86_FEATURE_RDTSCP, fix rdtscp in /proc/cpuinfo
Problem Details: This patch adds the X86_FEATURE_RDTSCP #define, so that kernel code can check for the feature easily and also fixes the location of the "rdtscp" string in the cpuinfo tables. Signed-off-by: Vojtech Pavlik <vojtech@suse.cz> Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Linus Torvalds <torvalds@...
```diff diff --git a/arch/x86_64/kernel/setup.c b/arch/x86_64/kernel/setup.c index 24aa25ee0d7d..923b76fb0aa6 100644 --- a/arch/x86_64/kernel/setup.c +++ b/arch/x86_64/kernel/setup.c @@ -1206,7 +1206,7 @@ static int show_cpuinfo(struct seq_file *m, void *v) NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NU...
a813ce432f27c4f5011c7b5ac9d2bbbfeb41d9a7
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: Rename IOMMU option, fix help and mark option embedded.
Problem Details: - Rename the GART_IOMMU option to IOMMU to make clear it's not just for AMD - Rewrite the help text to better emphatise this fact - Make it an embedded option because too many people get it wrong. To my astonishment I discovered the aacraid driver tests this symbol directly. This looks quite brok...
```diff diff --git a/arch/x86_64/Kconfig b/arch/x86_64/Kconfig index fc75275d8c72..e8c52a1eec06 100644 --- a/arch/x86_64/Kconfig +++ b/arch/x86_64/Kconfig @@ -386,24 +386,26 @@ config HPET_EMULATE_RTC bool "Provide RTC interrupt" depends on HPET_TIMER && RTC=y -config GART_IOMMU - bool "K8 GART IOMMU support" +# ...
26a3c49cec96ffb9cfcc30dfa0cd05ccc25dcb3a
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: fix vector_lock deadlock in io_apic.c
Problem Details: Fix a potential deadlock scenario introduced by io_apic.c's new vector_lock on i386 and x86_64. Found by the locking correctness validator. The patch was boot-tested on x86. For details of the deadlock scenario, see the validator output: ====================================================== [ BU...
```diff diff --git a/arch/i386/kernel/io_apic.c b/arch/i386/kernel/io_apic.c index 61317f4be444..72ae414e4d49 100644 --- a/arch/i386/kernel/io_apic.c +++ b/arch/i386/kernel/io_apic.c @@ -1163,14 +1163,15 @@ u8 irq_vector[NR_IRQ_VECTORS] __read_mostly = { FIRST_DEVICE_VECTOR , 0 }; int assign_irq_vector(int irq) { s...
14118c3cdd46d72e503ee2f727b11d881f72f755
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: fix unlikely profiling & vsyscalls on x86_64
Problem Details: fix unlikely profiling in vsyscalls ... Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
```diff diff --git a/arch/x86_64/kernel/vsyscall.c b/arch/x86_64/kernel/vsyscall.c index 9468fb20b0bc..f603037df162 100644 --- a/arch/x86_64/kernel/vsyscall.c +++ b/arch/x86_64/kernel/vsyscall.c @@ -107,7 +107,7 @@ static __always_inline long time_syscall(long *t) int __vsyscall(0) vgettimeofday(struct timeval * tv,...
f201611fcecdfa825471dc425ee007997228fae4
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: Use -ENODEV in IOMMU initialization
Problem Details: Fix initcall at 0xffffffff806c5b89: pci_iommu_init+0x0/0x53c(): returned with error code -1 Return -ENODEV instead when the IOMMU is not used. Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
```diff diff --git a/arch/x86_64/kernel/pci-gart.c b/arch/x86_64/kernel/pci-gart.c index ded3af3bceec..82a346e6e2e4 100644 --- a/arch/x86_64/kernel/pci-gart.c +++ b/arch/x86_64/kernel/pci-gart.c @@ -581,7 +581,7 @@ static int __init pci_iommu_init(void) if (cache_k8_northbridges() < 0 || num_k8_northbridges == 0) {...
a32073bffc656ca4bde6002b6cf7c1a8e0e22712
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: Clean and enhance up K8 northbridge access code
Problem Details: - Factor out the duplicated access/cache code into a single file * Shared between i386/x86-64. - Share flush code between AGP and IOMMU * Fix a bug: AGP didn't wait for end of flush before - Drop 8 northbridges limit and allocate dynamically - Add lock to serialize AGP and IOMMU GART flushes ...
```diff diff --git a/arch/i386/Kconfig b/arch/i386/Kconfig index 1596101cfaf8..2206bf6637de 100644 --- a/arch/i386/Kconfig +++ b/arch/i386/Kconfig @@ -1054,6 +1054,10 @@ config SCx200 This support is also available as a module. If compiled as a module, it will be called scx200. +config K8_NB + def_bool y + d...
3c5846470c30580bbcb4d5f2339f75a2c88cfe6e
Analyze and fix the following issue in the Linux kernel code: [PATCH] x86_64: x86_64-enable-large-bzImage.patch
Problem Details: enable large bzImages on x86_64. (fix is from x86's build.c) Using this patch i have successfully built and booted an allyesconfig 13MB+ bzImage on x86_64 too: $ size64 vmlinux text data bss dec hex filename 23444831 8202642 3439360 35086833 21761f1 vmlinux -rw-rw-...
```diff diff --git a/arch/x86_64/boot/tools/build.c b/arch/x86_64/boot/tools/build.c index c44f5e2ec100..eae86691709a 100644 --- a/arch/x86_64/boot/tools/build.c +++ b/arch/x86_64/boot/tools/build.c @@ -149,10 +149,8 @@ int main(int argc, char ** argv) sz = sb.st_size; fprintf (stderr, "System is %d kB\n", sz/1024)...
2e2d0dcc1bd7ca7c26ea5e29efb7f34bbd564f1c
Analyze and fix the following issue in the Linux kernel code: typo fixes
Problem Details: Signed-off-by: Adrian Bunk <bunk@stusta.de>
```diff diff --git a/Documentation/DocBook/kernel-locking.tmpl b/Documentation/DocBook/kernel-locking.tmpl index 158ffe9bfade..644c3884fab9 100644 --- a/Documentation/DocBook/kernel-locking.tmpl +++ b/Documentation/DocBook/kernel-locking.tmpl @@ -1590,7 +1590,7 @@ the amount of locking which needs to be done. <par...
b78709cfd4387c15a9894748bcada8a4ca75c561
Analyze and fix the following issue in the Linux kernel code: [PATCH] sched: fix SCHED_FIFO bug in sys_sched_rr_get_interval()
Problem Details: The introduction of SCHED_BATCH scheduling class with a value of 3 means that the expression (p->policy & SCHED_FIFO) will return true if policy is SCHED_BATCH or SCHED_FIFO. Unfortunately, this expression is used in sys_sched_rr_get_interval() and in the absence of a comment to say that this is inten...
```diff diff --git a/kernel/sched.c b/kernel/sched.c index f06d059edef5..cfaf3fabeecd 100644 --- a/kernel/sched.c +++ b/kernel/sched.c @@ -4247,7 +4247,7 @@ long sys_sched_rr_get_interval(pid_t pid, struct timespec __user *interval) if (retval) goto out_unlock; - jiffies_to_timespec(p->policy & SCHED_FIFO ? + ji...
2139a7fbf3effd8cad505871e3a3c308780ada32
Analyze and fix the following issue in the Linux kernel code: [PATCH] initramfs overwrite fix
Problem Details: This patch ensures that initramfs overwrites work correctly, even when dealing with device nodes of different types. Furthermore, when replacing a file which already exists, we must make very certain that we truncate the existing file. Signed-off-by: H. Peter Anvin <hpa@zytor.com> Cc: Michael Neuling...
```diff diff --git a/init/initramfs.c b/init/initramfs.c index f81cfa40a719..d28c1094d7e5 100644 --- a/init/initramfs.c +++ b/init/initramfs.c @@ -30,6 +30,7 @@ static void __init free(void *where) static __initdata struct hash { int ino, minor, major; + mode_t mode; struct hash *next; char name[N_ALIGN(PATH_M...
3285edf152cefff482f95ceb90b1bd46ac169df1
Analyze and fix the following issue in the Linux kernel code: [PATCH] md: Fix bug that stops raid5 resync from happening
Problem Details: As data_disks is *less* than raid_disks, the current test here is obviously wrong. And as the difference is already available in conf->max_degraded, it makes much more sense to use that. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torval...
```diff diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c index 6d3a2a09cd90..f920e50ea124 100644 --- a/drivers/md/raid5.c +++ b/drivers/md/raid5.c @@ -2858,7 +2858,7 @@ static inline sector_t sync_request(mddev_t *mddev, sector_t sector_nr, int *ski * to resync, then assert that we are finished, because there is...
b3cc9ec76ba44d010f4c820c4608b91aaf28a0b9
Analyze and fix the following issue in the Linux kernel code: [PATCH] md: Fix Kconfig error
Problem Details: RAID5 recently changed to RAID456 Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
```diff diff --git a/drivers/md/Kconfig b/drivers/md/Kconfig index 0fa55e408554..bf869ed03eed 100644 --- a/drivers/md/Kconfig +++ b/drivers/md/Kconfig @@ -137,7 +137,7 @@ config MD_RAID456 config MD_RAID5_RESHAPE bool "Support adding drives to a raid-5 array (experimental)" - depends on MD_RAID5 && EXPERIMENTAL + ...
ce25c31bdd3b39266debd86a7732007e05983a67
Analyze and fix the following issue in the Linux kernel code: [PATCH] md: Change md/bitmap file handling to use bmap to file blocks-fix
Problem Details: Fix problems with new bmap based access to bitmap files. 1/ When not using a file based bitmap, attach a NULL list of buffers to each page so the common free_buffer routine can cope. 2/ Use submit_bh to read as well as write, rather than vfs_read. This makes read and write more symetric. 3/ sync...
```diff diff --git a/drivers/md/bitmap.c b/drivers/md/bitmap.c index bedd66e9e8ac..ebbd2d856256 100644 --- a/drivers/md/bitmap.c +++ b/drivers/md/bitmap.c @@ -247,6 +247,8 @@ static struct page *read_sb_page(mddev_t *mddev, long offset, unsigned long inde if (sync_page_io(rdev->bdev, target, PAGE_SIZE, page, READ)...
a647e4bc5ce697e25ff50d2e22de68a581b1ed38
Analyze and fix the following issue in the Linux kernel code: [PATCH] md/bitmap: remove unnecessary page reference manipulations from md/bitmap code
Problem Details: md/bitmap gets a collection of pages representing the bitmap when it initialises the bitmap, and puts all the references when discarding the bitmap. It also occasionally takes extra references without any good reason, and sometimes drops them ... though it doesn't always drop them, which can result i...
```diff diff --git a/drivers/md/bitmap.c b/drivers/md/bitmap.c index 2e257d5998bc..609e68d3e1bc 100644 --- a/drivers/md/bitmap.c +++ b/drivers/md/bitmap.c @@ -332,7 +332,6 @@ static int write_page(struct bitmap *bitmap, struct page *page, int wait) /* add to list to be waited for */ struct page_list *item = mempo...
d7375ab324971e7acbea9f02a0269ae7348f4147
Analyze and fix the following issue in the Linux kernel code: [PATCH] md/bitmap: fix online removal of file-backed bitmaps
Problem Details: When "mdadm --grow /dev/mdX --bitmap=none" is used to remove a filebacked bitmap, the bitmap was disconnected from the array, but the file wasn't closed (until the array was stopped). The file also wasn't closed if adding the bitmap file failed. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by...
```diff diff --git a/drivers/md/md.c b/drivers/md/md.c index 8c1e1900893d..ea6837d45fc8 100644 --- a/drivers/md/md.c +++ b/drivers/md/md.c @@ -3601,10 +3601,13 @@ static int set_bitmap_file(mddev_t *mddev, int fd) mddev->pers->quiesce(mddev, 1); if (fd >= 0) err = bitmap_create(mddev); - if (fd < 0 || err) +...
5c6bd75d06db512515a3781aa97e42df2faf0815
Analyze and fix the following issue in the Linux kernel code: [PATCH] dm: prevent removal if open
Problem Details: If you misuse the device-mapper interface (or there's a bug in your userspace tools) it's possible to end up with 'unlinked' mapped devices that cannot be removed until you reboot (along with uninterruptible processes). This patch prevents you from removing a device that is still open. It introduces ...
```diff diff --git a/drivers/md/dm-ioctl.c b/drivers/md/dm-ioctl.c index c826b3e1799a..c6ce13b18747 100644 --- a/drivers/md/dm-ioctl.c +++ b/drivers/md/dm-ioctl.c @@ -48,7 +48,7 @@ struct vers_iter { static struct list_head _name_buckets[NUM_BUCKETS]; static struct list_head _uuid_buckets[NUM_BUCKETS]; -static void...
ce503f59ae899c3e75a8a1cf46f2d44c0c5b5c7c
Analyze and fix the following issue in the Linux kernel code: [PATCH] dm kcopyd: error accumulation fix
Problem Details: kcopyd should accumulate errors - otherwise I/O failures may be ignored unintentionally. And invert 'success' (used in a future patch), using a more intuitive !(read_err || write_err). Signed-off-by: Jonathan Brassow <jbrassow@redhat.com> Signed-off-by: Alasdair G Kergon <agk@redhat.com> Signed-off-b...
```diff diff --git a/drivers/md/dm-raid1.c b/drivers/md/dm-raid1.c index 84f2ed6d9c5b..6ae42f1d76ae 100644 --- a/drivers/md/dm-raid1.c +++ b/drivers/md/dm-raid1.c @@ -602,7 +602,7 @@ static void recovery_complete(int read_err, unsigned int write_err, struct region *reg = (struct region *) context; /* FIXME: bette...
8a835f11bce68ed990533e49b5dedb00bee46d71
Analyze and fix the following issue in the Linux kernel code: [PATCH] dm mirror log: sync_count fix
Problem Details: When a mirror is reduced in size, clear the part of the bitmap that is no longer used. Signed-off-by: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
```diff diff --git a/drivers/md/dm-log.c b/drivers/md/dm-log.c index 33d80721667c..ba98bf57c7c0 100644 --- a/drivers/md/dm-log.c +++ b/drivers/md/dm-log.c @@ -447,7 +447,7 @@ static int disk_resume(struct dirty_log *log) if (r) return r; - /* set or clear any new bits */ + /* set or clear any new bits -- device ...
29121bd0b00ebb9524971a583fea4a2f7afe8041
Analyze and fix the following issue in the Linux kernel code: [PATCH] dm mirror log: bitset_size fix
Problem Details: Fix the 'sizeof' in the region log bitmap size calculation: it's uint32_t, not unsigned long - this breaks on some archs. Signed-off-by: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
```diff diff --git a/drivers/md/dm-log.c b/drivers/md/dm-log.c index f52a78fc82bb..33d80721667c 100644 --- a/drivers/md/dm-log.c +++ b/drivers/md/dm-log.c @@ -295,10 +295,10 @@ static int create_log_context(struct dirty_log *log, struct dm_target *ti, * Work out how many "unsigned long"s we need to hold the bitset. ...
702ca6f0be9ef95087ee2c9f31e6517492554483
Analyze and fix the following issue in the Linux kernel code: [PATCH] dm mirror log: sector size fix
Problem Details: On-disk logs for dm-mirror devices are currently hard-coded to use 512 byte hard-sector-sizes. This patch fixes dm-log so it will work with devices with non-512-byte hard-sector-sizes. To maintain full compatibility, instead of moving the clean-bits bitset to a bitset, and enlarges the disk-header bu...
```diff diff --git a/drivers/md/dm-log.c b/drivers/md/dm-log.c index d73779a42417..ae41628b75c0 100644 --- a/drivers/md/dm-log.c +++ b/drivers/md/dm-log.c @@ -155,8 +155,6 @@ struct log_c { struct io_region header_location; struct log_header *disk_header; - - struct io_region bits_location; }; /* @@ -240,29 +...
143535396c7ebd9395a931a000b3963f457712b8
Analyze and fix the following issue in the Linux kernel code: [PATCH] dm table: get_target: fix last index
Problem Details: The table is indexed from 0, so an index equal to t->num_targets should be rejected. (There is no code in the current tree that would exercise this bug.) Signed-off-by: Milan Broz <mbroz@redhat.com> Signed-off-by: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-...
```diff diff --git a/drivers/md/dm-table.c b/drivers/md/dm-table.c index 8f56a54cf0ce..b6183eda8106 100644 --- a/drivers/md/dm-table.c +++ b/drivers/md/dm-table.c @@ -802,7 +802,7 @@ sector_t dm_table_get_size(struct dm_table *t) struct dm_target *dm_table_get_target(struct dm_table *t, unsigned int index) { - if (...
e4c8b3ba34cc1aeab451c7a5cc843c5fd62cbe3d
Analyze and fix the following issue in the Linux kernel code: [PATCH] dm: mirror sector offset fix
Problem Details: The device-mapper core does not perform any remapping of bios before passing them to the targets. If a particular mapping begins part-way into a device, targets obtain the sector relative to the start of the mapping by subtracting ti->begin. The dm-raid1 target didn't do this everywhere: this patch f...
```diff diff --git a/drivers/md/dm-raid1.c b/drivers/md/dm-raid1.c index 4ad269e66525..346f3a59e776 100644 --- a/drivers/md/dm-raid1.c +++ b/drivers/md/dm-raid1.c @@ -106,12 +106,42 @@ struct region { struct bio_list delayed_bios; }; + +/*----------------------------------------------------------------- + * Mirror...
f0b04115368ff383654a3bd26baf8f4be5e81132
Analyze and fix the following issue in the Linux kernel code: [PATCH] dm: fix block device initialisation
Problem Details: In alloc_dev(), we register the device with the block layer and then continue to initialize the device. But register_disk() makes the device available to be opened before we have completed initialising it. This patch moves the final bits of the initialization above the disk registration. [akpm: too ...
```diff diff --git a/drivers/md/dm.c b/drivers/md/dm.c index 29af584ae838..dfd037858902 100644 --- a/drivers/md/dm.c +++ b/drivers/md/dm.c @@ -891,6 +891,10 @@ static struct mapped_device *alloc_dev(unsigned int minor, int persistent) if (!md->disk) goto bad4; + atomic_set(&md->pending, 0); + init_waitqueue_head...
7ec75f254742766eb729f1d1024a5b4e6692fc5f
Analyze and fix the following issue in the Linux kernel code: [PATCH] dm: fix mapped device ref counting
Problem Details: To avoid races, _minor_lock must be held while changing mapped device reference counts. There are a few paths where a mapped_device pointer is returned before a reference is taken. This patch fixes them. [akpm: too late for 2.6.17 - suitable for 2.6.17.x after it has settled] Signed-off-by: Jeff Ma...
```diff diff --git a/drivers/md/dm-ioctl.c b/drivers/md/dm-ioctl.c index 8edd6435414d..f7e743691aa8 100644 --- a/drivers/md/dm-ioctl.c +++ b/drivers/md/dm-ioctl.c @@ -102,8 +102,10 @@ static struct hash_cell *__get_name_cell(const char *str) unsigned int h = hash_str(str); list_for_each_entry (hc, _name_buckets +...
ba61fdd17d73ddb5c892a9f12383c6c560a20d56
Analyze and fix the following issue in the Linux kernel code: [PATCH] dm: fix idr minor allocation
Problem Details: One part of the system can attempt to use a mapped device before another has finished initialising it or while it is being freed. This patch introduces a place holder value, MINOR_ALLOCED, to mark the minor as allocated but in a state where it can't be used, such as mid-allocation or mid-free. At the...
```diff diff --git a/drivers/md/dm.c b/drivers/md/dm.c index 4d710b7a133b..87d8ca1121e2 100644 --- a/drivers/md/dm.c +++ b/drivers/md/dm.c @@ -54,6 +54,8 @@ union map_info *dm_get_mapinfo(struct bio *bio) return NULL; } +#define MINOR_ALLOCED ((void *)-1) + /* * Bits for the md->flags field. */ @@ -777...
6db4063c5b72b46e9793b0f141a7a3984ac6facf
Analyze and fix the following issue in the Linux kernel code: [PATCH] VT binding: Add sysfs control to the VT layer
Problem Details: Add sysfs control to the VT layer. A new sysfs class, 'vtconsole', and class devices 'vtcon[n]' are added. Each class device file has the following attributes: /sys/class/vtconsole/vtcon[n]/name - read-only attribute showing the name of the current backend /sys/...
```diff diff --git a/drivers/char/vt.c b/drivers/char/vt.c index d788a0eaf26a..037d8a3f5882 100644 --- a/drivers/char/vt.c +++ b/drivers/char/vt.c @@ -100,12 +100,14 @@ #define MAX_NR_CON_DRIVER 16 -#define CON_DRIVER_FLAG_BIND 1 +#define CON_DRIVER_FLAG_MODULE 1 #define CON_DRIVER_FLAG_INIT 2 struct con_drive...
1c8ce271fe707d26b7bca4e490067fe65694b363
Analyze and fix the following issue in the Linux kernel code: [PATCH] Detaching fbcon: fix give_up_console()
Problem Details: To allow for detaching fbcon, it must be able to give up the console. However, the function give_up_console() is plain broken. It just sets the entries in the console driver map to NULL, it leaves the vt layer without a console driver, and does not decrement the module reference count. Calling give_u...
```diff diff --git a/drivers/char/vt.c b/drivers/char/vt.c index eb27eed48a86..d7ff7fdb6fe3 100644 --- a/drivers/char/vt.c +++ b/drivers/char/vt.c @@ -100,6 +100,7 @@ const struct consw *conswitchp; +static struct consw *defcsw; /* default console */ /* A bitmap for codes <32. A bit of 1 indicates that the code...
50ec42edd9784fad6a37b05be03064ea24098db6
Analyze and fix the following issue in the Linux kernel code: [PATCH] Detaching fbcon: fix vgacon to allow retaking of the console
Problem Details: One of the limitations of the framebuffer console system is its inablity to unload or detach itself from the console layer. And once it loads, it also locks in framebuffer drivers preventing their unload. Although the con2fbmap utility does provide a means to unload individual drivers, it requires tha...
```diff diff --git a/drivers/video/console/vgacon.c b/drivers/video/console/vgacon.c index e64d42e2449e..f32b590730f2 100644 --- a/drivers/video/console/vgacon.c +++ b/drivers/video/console/vgacon.c @@ -114,6 +114,7 @@ static int vga_512_chars; static int vga_video_font_height; static int vga_scan_lines; stati...
1a8c9795290361cef232fd54f425a57d143108a8
Analyze and fix the following issue in the Linux kernel code: [PATCH] atyfb: Fix section warnings
Problem Details: Fix the following warning: WARNING: drivers/video/aty/atyfb.o - Section mismatch: reference to .init.text:aty_init_cursor from .text between 'aty_init' (at offset 0x241d) and 'atyfb_blank' Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Lin...
```diff diff --git a/drivers/video/aty/atyfb_base.c b/drivers/video/aty/atyfb_base.c index ef1379d116b4..22e720611bf6 100644 --- a/drivers/video/aty/atyfb_base.c +++ b/drivers/video/aty/atyfb_base.c @@ -316,12 +316,12 @@ static int vram; static int pll; static int mclk; static int xclk; -static int comp_sync __initd...
9b27915b6aa33b5fbc17beb8c7d5d0b662419018
Analyze and fix the following issue in the Linux kernel code: [PATCH] macmodes: Fix section warning
Problem Details: Fix the following warning: WARNING: drivers/video/macmodes.o - Section mismatch: reference to .init.text:mac_find_mode from __ksymtab after '__ksymtab_mac_find_mode' (at offset 0x10) Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Tor...
```diff diff --git a/drivers/video/aty/aty128fb.c b/drivers/video/aty/aty128fb.c index db878fd55fb2..11cf7fcb1d55 100644 --- a/drivers/video/aty/aty128fb.c +++ b/drivers/video/aty/aty128fb.c @@ -100,7 +100,7 @@ #ifndef CONFIG_PPC_PMAC /* default mode */ -static struct fb_var_screeninfo default_var __initdata = { +s...
f837e6f73fe3f04594dad9829df6c7baa5b64a85
Analyze and fix the following issue in the Linux kernel code: [PATCH] fbdev: Fix logo rotation if width != height
Problem Details: Logo drawing crashes or produces a corrupt display if the logo width and height are not equal. The dimensions are transposed prior to the actual rotation and the width is used instead of the height in the actual rotation code. These produce a corrupt image. Signed-off-by: Antonino Daplas <adaplas@po...
```diff diff --git a/drivers/video/fbmem.c b/drivers/video/fbmem.c index 2279d14fe556..e9af5e61018d 100644 --- a/drivers/video/fbmem.c +++ b/drivers/video/fbmem.c @@ -334,11 +334,11 @@ static void fb_rotate_logo_ud(const u8 *in, u8 *out, u32 width, u32 height) static void fb_rotate_logo_cw(const u8 *in, u8 *out, u32...
4efefd1d8ea4eaf71bacc4f71fa017c202fa67ec
Analyze and fix the following issue in the Linux kernel code: [PATCH] neofb: fix unblank logic interfering with lid toggled backlight
Problem Details: This is a fix for the most annoying problem that remained with neofb: After "setterm -powersave powerdown" the console blanker will disable the backlight after the given timeout expires. If this happens after the lid has been shut, we read "LCD off" from the register and store that in the driver. On...
```diff diff --git a/drivers/video/neofb.c b/drivers/video/neofb.c index 24b12f71d5a8..2f156b724d1c 100644 --- a/drivers/video/neofb.c +++ b/drivers/video/neofb.c @@ -1333,17 +1333,22 @@ static int neofb_blank(int blank_mode, struct fb_info *info) * run "setterm -powersave powerdown" to take advantage */ struc...
137a8899b1dba82b54463811844995a33b21ca39
Analyze and fix the following issue in the Linux kernel code: [PATCH] backlight: Fix Kconfig dependency
Problem Details: CONFIG_FB = m and CONFIG_{BACKLIGHT:LCD}_CLASS_DEVICE = y is possible resulting in link errors. Fix by making backlight and lcd class also depend on FB Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
```diff diff --git a/drivers/video/backlight/Kconfig b/drivers/video/backlight/Kconfig index 02f15297a021..022f9d3473f5 100644 --- a/drivers/video/backlight/Kconfig +++ b/drivers/video/backlight/Kconfig @@ -10,7 +10,7 @@ menuconfig BACKLIGHT_LCD_SUPPORT config BACKLIGHT_CLASS_DEVICE tristate "Lowlevel Backl...
6931a764e1cff26c59be23fbde94cd51fe96bf42
Analyze and fix the following issue in the Linux kernel code: [PATCH] s3c2410fb: Fix resume
Problem Details: regs.lcdcon1 was not updated on suspend. The result was a garbaged display on resume. This bug was first noticed by Christer Weinigel. This patch is a modified version of the one he sent to me. Signed-off-by: Arnaud Patard <arnaud.patard@rtp-net.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Sig...
```diff diff --git a/drivers/video/s3c2410fb.c b/drivers/video/s3c2410fb.c index 9451932fbaf2..fbc411850686 100644 --- a/drivers/video/s3c2410fb.c +++ b/drivers/video/s3c2410fb.c @@ -641,6 +641,7 @@ static int __init s3c2410fb_probe(struct platform_device *pdev) int ret; int irq; int i; + u32 lcdcon1; mach_in...
17cc6281c12b26425209c58e3d8825a9568db3cc
Analyze and fix the following issue in the Linux kernel code: [PATCH] fbdev: Coverity Bug 90
Problem Details: It's a false positive, but let's suppress it anyway. Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
```diff diff --git a/drivers/video/modedb.c b/drivers/video/modedb.c index 1aa36d302a51..7e539b69a9a2 100644 --- a/drivers/video/modedb.c +++ b/drivers/video/modedb.c @@ -791,8 +791,9 @@ struct fb_videomode *fb_find_best_mode(struct fb_var_screeninfo *var, if (diff > d) { diff = d; best = mode; - } else...
8126a044f9e686f4ecf95e32fd89ad1dd48b4183
Analyze and fix the following issue in the Linux kernel code: [PATCH] fbdev: Coverity Bug 85
Problem Details: It's a false positive, but let's suppress it anyway. Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
```diff diff --git a/drivers/video/cfbimgblt.c b/drivers/video/cfbimgblt.c index 8ba6152db2fd..ad8a89bf8eae 100644 --- a/drivers/video/cfbimgblt.c +++ b/drivers/video/cfbimgblt.c @@ -230,6 +230,7 @@ static inline void fast_imageblit(const struct fb_image *image, struct fb_info * tab = cfb_tab16; break; case 32:...
0fa67f84f445e8c567f8a189f2262dd9f8334bc1
Analyze and fix the following issue in the Linux kernel code: [PATCH] atyfb: Fix dead code
Problem Details: Coverity Bug 68: Fix dead code Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
```diff diff --git a/drivers/video/aty/atyfb_base.c b/drivers/video/aty/atyfb_base.c index 54ebc5a808ef..ef1379d116b4 100644 --- a/drivers/video/aty/atyfb_base.c +++ b/drivers/video/aty/atyfb_base.c @@ -2402,12 +2402,15 @@ static int __init aty_init(struct fb_info *info, const char *name) break; } switch (clk...
313ca22f0bfab792adeb447146d9cb86536c64d3
Analyze and fix the following issue in the Linux kernel code: [PATCH] vesafb: Fix return code of vesafb_setcolreg
Problem Details: If the hardware palette cannot be accessed, make vesafb_setcolreg return a nonzero value. Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
```diff diff --git a/drivers/video/vesafb.c b/drivers/video/vesafb.c index 2fbaa8484f8a..eff2ebcf1f7c 100644 --- a/drivers/video/vesafb.c +++ b/drivers/video/vesafb.c @@ -80,10 +80,11 @@ static int vesafb_pan_display(struct fb_var_screeninfo *var, return 0; } -static void vesa_setpalette(int regno, unsigned red, u...
ba70710e59c701734aad524bc441b3400700e94b
Analyze and fix the following issue in the Linux kernel code: [PATCH] fbdev: Firmware EDID fixes
Problem Details: - make firmware edid independent from framebuffer (No need to choose framebuffer just to disable this option - enable this option in X86_64 - check if VBE/DDC function is implemented before calling actual function Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@...
```diff diff --git a/arch/i386/boot/video.S b/arch/i386/boot/video.S index c9343c3a8082..8c2a6faeeae5 100644 --- a/arch/i386/boot/video.S +++ b/arch/i386/boot/video.S @@ -1929,7 +1929,7 @@ skip10: movb %ah, %al ret store_edid: -#ifdef CONFIG_FB_FIRMWARE_EDID +#ifdef CONFIG_FIRMWARE_EDID pushw %es # just save ...
72c24cc51aef31219f2e258b4dcb68e09399e040
Analyze and fix the following issue in the Linux kernel code: [PATCH] atyfb: Fix hardware cursor handling
Problem Details: Fix image and color handling in atyfb_cursor() - In the 2-bit scheme of the cursor image, just set the first bit to be always zero (turn off transparency and/or XOR), and just do the masking manually - The cursor color is converted into 32-bit RGBA8888 using struct fb_cmap. Each component in th...
```diff diff --git a/drivers/video/aty/mach64_cursor.c b/drivers/video/aty/mach64_cursor.c index ad8b7496f853..27bf0137e3bb 100644 --- a/drivers/video/aty/mach64_cursor.c +++ b/drivers/video/aty/mach64_cursor.c @@ -66,11 +66,6 @@ static const u8 cursor_bits_lookup[16] = { 0x01, 0x41, 0x11, 0x51, 0x05, 0x45, 0x15, 0x5...
f8020dc560fde089becc05de1d0ada1f7f46dc51
Analyze and fix the following issue in the Linux kernel code: [PATCH] savagefb: Add state save and_restore hooks
Problem Details: Reported by: Rich (Bugzilla Bug 6417) "if savage driver is used in x.org together with savagefb, it results in seriously garbled and distorted screen - coupled with severe slowdowns." This bug is the result of Xorg unable to handle savagefb altering the hardware which results in X failing to start pr...
```diff diff --git a/drivers/video/savage/savagefb_driver.c b/drivers/video/savage/savagefb_driver.c index 267d4e5c9991..3bd0a573d755 100644 --- a/drivers/video/savage/savagefb_driver.c +++ b/drivers/video/savage/savagefb_driver.c @@ -305,7 +305,7 @@ savage2000_waitidle(struct savagefb_par *par) while ((savage_in32(0...
3d1c1cc962cebaae6a70fd89a0adb29ad10a2a12
Analyze and fix the following issue in the Linux kernel code: [PATCH] fix IDE deadlock in error reporting code
Problem Details: Michal Piotrowski reported the following validator assert: hdd: set_drive_speed_status: status=0x51 { DriveReady SeekComplete Error } hdd: set_drive_speed_status: error=0xb4 { AbortedCommand LastFailedSense=0x0b } ============================ [ BUG: illegal lock usage! ] ------------------------...
```diff diff --git a/drivers/ide/ide-lib.c b/drivers/ide/ide-lib.c index 16a143133f93..7ddb11828731 100644 --- a/drivers/ide/ide-lib.c +++ b/drivers/ide/ide-lib.c @@ -485,7 +485,7 @@ static u8 ide_dump_ata_status(ide_drive_t *drive, const char *msg, u8 stat) unsigned long flags; u8 err = 0; - local_irq_set(flags)...
178184b60979992508130741f16499c360bc9c9a
Analyze and fix the following issue in the Linux kernel code: [PATCH] ide-io: increase timeout value to allow for slave wakeup
Problem Details: During an STR resume cycle, the ide master disk times-out when there is also a slave present (especially CD). Increasing the timeout in ide-io from 10,000 to 100,000 fixes this problem. Acked-by: Alan Cox <alan@lxorguk.ukuu.org.uk> Cc: Bartlomiej Zolnierkiewicz <B.Zolnierkiewicz@elka.pw.edu.pl> Cc: <...
```diff diff --git a/drivers/ide/ide-io.c b/drivers/ide/ide-io.c index 622a55c72f03..d2428cef1598 100644 --- a/drivers/ide/ide-io.c +++ b/drivers/ide/ide-io.c @@ -959,7 +959,7 @@ static void ide_check_pm_state(ide_drive_t *drive, struct request *rq) printk(KERN_WARNING "%s: bus not ready on wakeup\n", drive->name);...
4fb0f76d8cf4f7a3ffc36dd5e1bc8ca977b68824
Analyze and fix the following issue in the Linux kernel code: [PATCH] Fix IDE locking error
Problem Details: This bit us a few kernels ago, and for some reason never made it's way upstream. https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=144743 Kernel panic - not syncing: drivers/ide/pci/piix.c:231: spin_lock(drivers/ide/ide.c:c03cef28) already locked by driver/ide/ide-iops.c/1153. Signed-off-by: Dave ...
```diff diff --git a/drivers/ide/pci/piix.c b/drivers/ide/pci/piix.c index e9b83e1a3028..7fac6f57b5d6 100644 --- a/drivers/ide/pci/piix.c +++ b/drivers/ide/pci/piix.c @@ -222,6 +222,8 @@ static void piix_tune_drive (ide_drive_t *drive, u8 pio) unsigned long flags; u16 master_data; u8 slave_data; + static DEFINE_S...
2ceb8693ef63ae3d154ce1a05d275f2bb20a5e4c
Analyze and fix the following issue in the Linux kernel code: [PATCH] de_thread: fix lockless do_each_thread
Problem Details: We should keep the value of old_leader->tasks.next in de_thread, otherwise we can't do for_each_process/do_each_thread without tasklist_lock held. Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru> Cc: "Eric W. Biederman" <ebiederm@xmission.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: ...
```diff diff --git a/fs/exec.c b/fs/exec.c index 8c5196087f31..fffea1eef8dc 100644 --- a/fs/exec.c +++ b/fs/exec.c @@ -707,7 +707,7 @@ static int de_thread(struct task_struct *tsk) attach_pid(current, PIDTYPE_PID, current->pid); attach_pid(current, PIDTYPE_PGID, current->signal->pgrp); attach_pid(current, PID...
a872ff0cb2218dc9688b990c5ccda064dc40946b
Analyze and fix the following issue in the Linux kernel code: [PATCH] simplify/fix first_tid()
Problem Details: first_tid: /* If nr exceeds the number of threads there is nothing todo */ if (nr) { if (nr >= get_nr_threads(leader)) goto done; } This is not reliable: sub-threads can exit after this check, so the 'for' loop below can overlap and proc_task_readdir() can return an already filldir'ed dirents...
```diff diff --git a/fs/proc/base.c b/fs/proc/base.c index 6092a6e2c5a9..5ee46d3a5cac 100644 --- a/fs/proc/base.c +++ b/fs/proc/base.c @@ -2227,38 +2227,34 @@ int proc_pid_readdir(struct file * filp, void * dirent, filldir_t filldir) static struct task_struct *first_tid(struct task_struct *leader, int tid, int n...