id
stringlengths
40
40
instruction
stringlengths
68
308
input
stringlengths
17
33.4k
output
stringlengths
100
30k
3ddeb7c5c61d0d6bfd837487d3454ffdb788bb91
Analyze and fix the following issue in the Linux kernel code: NFSv4: Propagate the error NFS4ERR_BADOWNER to nfs4_do_setattr
Problem Details: This will be required in order to switch uid/gid mapping back on if the admin has tried to disable it. Note that we also propagate NFS4ERR_BADNAME at the same time, in order to work around a Linux server bug. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
```diff diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index 7b4b9f3e9842..8f3ada04ea19 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c @@ -85,6 +85,9 @@ static int nfs4_map_errors(int err) switch (err) { case -NFS4ERR_RESOURCE: return -EREMOTEIO; + case -NFS4ERR_BADOWNER: + case -NFS4ERR_BADNAME: + ...
f49f9baac8f63de9cbc17a0a84e04060496e8e76
Analyze and fix the following issue in the Linux kernel code: pnfs: fix pnfs lock inversion of i_lock and cl_lock
Problem Details: The pnfs code was using throughout the lock order i_lock, cl_lock. This conflicts with the nfs delegation code. Rework the pnfs code to avoid taking both locks simultaneously. Currently the code takes the double lock to add/remove the layout to a nfs_client list, while atomically checking that the li...
```diff diff --git a/fs/nfs/callback_proc.c b/fs/nfs/callback_proc.c index 89587573fe50..2f41dccea18e 100644 --- a/fs/nfs/callback_proc.c +++ b/fs/nfs/callback_proc.c @@ -188,10 +188,10 @@ static u32 initiate_bulk_draining(struct nfs_client *clp, rv = NFS4ERR_DELAY; list_del_init(&lo->plh_bulk_recall); spin_u...
38511722446993d926861696194c39ef135d85a4
Analyze and fix the following issue in the Linux kernel code: pnfs: avoid incorrect use of layout stateid
Problem Details: The code could violate the following from RFC5661, section 12.5.3: "Once a client has no more layouts on a file, the layout stateid is no longer valid and MUST NOT be used." This can occur when a layout already has a lseg, starts another non-everlapping LAYOUTGET, and a CB_LAYOUTRECALL for the existin...
```diff diff --git a/fs/nfs/pnfs.c b/fs/nfs/pnfs.c index 1b1bc1a0fb0a..c8d9b2148cb1 100644 --- a/fs/nfs/pnfs.c +++ b/fs/nfs/pnfs.c @@ -255,6 +255,9 @@ put_lseg_locked(struct pnfs_layout_segment *lseg, list_del_init(&lseg->pls_layout->plh_layouts); spin_unlock(&clp->cl_lock); clear_bit(NFS_LAYOUT_BULK_RECALL...
ecac799a5ecc364006f0db6f2db15e77ed4d63e2
Analyze and fix the following issue in the Linux kernel code: NFSv4: Fix the setlk error handler
Problem Details: Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
```diff diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index b0b1a5568529..bf4e6d4b5bf5 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c @@ -4173,23 +4173,18 @@ static const struct rpc_call_ops nfs4_recover_lock_ops = { static void nfs4_handle_setlk_error(struct nfs_server *server, struct nfs4_lock_state *...
b4410c2f7f775b03da31566c05bb8d2383c7dc27
Analyze and fix the following issue in the Linux kernel code: NFSv4.1: Fix the handling of the SEQUENCE status bits
Problem Details: We want SEQUENCE status bits to be handled by the state manager in order to avoid threading issues. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
```diff diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index 411dc80d0656..b0b1a5568529 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c @@ -436,8 +436,8 @@ static int nfs41_sequence_done(struct rpc_task *task, struct nfs4_sequence_res * clp = res->sr_session->clp; do_renew_lease(clp, timestamp); /* ...
0400a6b0cb756f976bae32ae8db47bfa9853897c
Analyze and fix the following issue in the Linux kernel code: NFSv4/4.1: Fix nfs4_schedule_state_recovery abuses
Problem Details: nfs4_schedule_state_recovery() should only be used when we need to force the state manager to check the lease. If we just want to start the state manager in order to handle a state recovery situation, we should be using nfs4_schedule_state_manager(). This patch fixes the abuses of nfs4_schedule_state_...
```diff diff --git a/fs/nfs/nfs4_fs.h b/fs/nfs/nfs4_fs.h index 7a7474073148..54ff900cb8f0 100644 --- a/fs/nfs/nfs4_fs.h +++ b/fs/nfs/nfs4_fs.h @@ -298,6 +298,11 @@ struct rpc_cred *nfs4_get_renew_cred_locked(struct nfs_client *clp); #if defined(CONFIG_NFS_V4_1) struct rpc_cred *nfs4_get_machine_cred_locked(struct nfs...
017f2b239dabb2740b91df162e004371b861f371
Analyze and fix the following issue in the Linux kernel code: futex,plist: Remove debug lock assignment from plist_node
Problem Details: The original code uses &plist_node->plist as the fake head of the priority list for plist_del(), these debug locks in the fake head are needed for CONFIG_DEBUG_PI_LIST. But now we always pass the real head to plist_del(), the debug locks in plist_node will not be used, so we remove these assignments. ...
```diff diff --git a/kernel/futex.c b/kernel/futex.c index 6feeea4f8f15..9fe913141ec9 100644 --- a/kernel/futex.c +++ b/kernel/futex.c @@ -1089,9 +1089,6 @@ void requeue_futex(struct futex_q *q, struct futex_hash_bucket *hb1, plist_del(&q->list, &hb1->chain); plist_add(&q->list, &hb2->chain); q->lock_ptr = &hb...
2e12978a9f7a7abd54e8eb9ce70a7718767b8b2c
Analyze and fix the following issue in the Linux kernel code: futex,plist: Pass the real head of the priority list to plist_del()
Problem Details: Some plist_del()s in kernel/futex.c are passed a faked head of the priority list. It does not fail because the current code does not require the real head in plist_del(). The current code of plist_del() just uses the head for checking, so it will not cause a bad result even when we use a faked head. ...
```diff diff --git a/kernel/futex.c b/kernel/futex.c index b766d28accd6..6feeea4f8f15 100644 --- a/kernel/futex.c +++ b/kernel/futex.c @@ -775,6 +775,24 @@ retry: return ret; } +/** + * __unqueue_futex() - Remove the futex_q from its futex_hash_bucket + * @q: The futex_q to unqueue + * + * The q->lock_ptr must not...
c7ecea24e26037fdfe9cbe83c9821689336f70d5
Analyze and fix the following issue in the Linux kernel code: omap2+: mux: Fix compile when CONFIG_OMAP_MUX is not selected
Problem Details: Fix compile when CONFIG_OMAP_MUX is not selected Signed-off-by: Tony Lindgren <tony@atomide.com>
```diff diff --git a/arch/arm/mach-omap2/board-cm-t35.c b/arch/arm/mach-omap2/board-cm-t35.c index 27bea540ccbb..71545c95238c 100644 --- a/arch/arm/mach-omap2/board-cm-t35.c +++ b/arch/arm/mach-omap2/board-cm-t35.c @@ -675,6 +675,7 @@ static void __init cm_t35_init_early(void) mt46h32m32lf6_sdrc_params); } ...
86c79bf45f380c6efd907e95f993146b2b975232
Analyze and fix the following issue in the Linux kernel code: omap2+: mux: Remove the use of IDLE flag
Problem Details: Currently OMAP_DEVICE_PAD_IDLE flag is used to mux pins dynamically. This can be simplified by using the enabled state variable of each pad. This also fixes the issue of the static pads not getting muxed after idling and disable/enable state transitions. Signed-off-by: sricharan <r.sricharan@ti.com> S...
```diff diff --git a/arch/arm/mach-omap2/mux.c b/arch/arm/mach-omap2/mux.c index 8717370c91b1..bb043cbb3886 100644 --- a/arch/arm/mach-omap2/mux.c +++ b/arch/arm/mach-omap2/mux.c @@ -359,7 +359,6 @@ void omap_hwmod_mux(struct omap_hwmod_mux_info *hmux, u8 state) struct omap_device_pad *pad = hmux->pads_dynamic[i]; ...
1f940bdfc0d03265d178d9dfd840d854819f797d
Analyze and fix the following issue in the Linux kernel code: block: fixup plugging stubs for !CONFIG_BLOCK
Problem Details: They used an older prototype, fix it up. Reported-by: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
```diff diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h index 91fa428fa2c1..16a902f099ac 100644 --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h @@ -1297,15 +1297,18 @@ static inline long nr_blockdev_pages(void) return 0; } -static inline void blk_start_plug(struct list_head *list) +struct bl...
808118cb41dfe12a1ac0e35515ac4d91b170bdf9
Analyze and fix the following issue in the Linux kernel code: mac80211: do not enable ps if 802.1x controlled port is unblocked
Problem Details: If dynamic_ps is disabled, enabling power save before the 4-way handshake completes may delay the station from being authorized to send/receive traffic, i.e. increase roaming times. It also may result in a failed 4-way handshake depending on the AP's timing requirements and beacon interval, and the sta...
```diff diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c index 7b701dcddb50..11866b42f1ed 100644 --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c @@ -834,6 +834,10 @@ static int ieee80211_change_station(struct wiphy *wiphy, rcu_read_unlock(); + if (sdata->vif.type == NL80211_IFTYPE_STATION && + params->s...
d89dba7a275f40757d27ba16c8bc6aa424656bbe
Analyze and fix the following issue in the Linux kernel code: libertas: fix write past end of array in mesh_id_get()
Problem Details: defs.meshie.val.mesh_id is 32 chars long. It's not supposed to be NUL terminated. This code puts a terminator on the end to make it easier to print to sysfs. The problem is that if the mesh_id fills the entire buffer the original code puts the terminator one spot past the end. The way the original ...
```diff diff --git a/drivers/net/wireless/libertas/mesh.c b/drivers/net/wireless/libertas/mesh.c index acf3bf63ee33..9d097b9c8005 100644 --- a/drivers/net/wireless/libertas/mesh.c +++ b/drivers/net/wireless/libertas/mesh.c @@ -918,7 +918,6 @@ static ssize_t mesh_id_get(struct device *dev, struct device_attribute *attr,...
75e03512455827eb2c09e057578ae23178a93cf8
Analyze and fix the following issue in the Linux kernel code: ath9k_hw: Fix PLL initialization for AR9485.
Problem Details: Increase the delay to make sure the initialization of pll passes. Signed-off-by: Vivek Natarajan <vnatarajan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
```diff diff --git a/drivers/net/wireless/ath/ath9k/hw.c b/drivers/net/wireless/ath/ath9k/hw.c index 9a3438174f86..338b07502f1a 100644 --- a/drivers/net/wireless/ath/ath9k/hw.c +++ b/drivers/net/wireless/ath/ath9k/hw.c @@ -701,7 +701,7 @@ static void ath9k_hw_init_pll(struct ath_hw *ah, AR_CH0_DPLL3_PHASE_SHI...
5f6722ee63a45d4ad3412743d161ec54d6c32ccc
Analyze and fix the following issue in the Linux kernel code: wl1251: fix elp_work race condition
Problem Details: While working on PS I've noticed elp_work is kicking rather often, and sometimes the chip is put to sleep before 5ms delay expires. This seems to happen because by the time wl1251_ps_elp_wakeup is called elp_work might still be pending. After wakeup is done, the processing may take some time, during wh...
```diff diff --git a/drivers/net/wireless/wl1251/ps.c b/drivers/net/wireless/wl1251/ps.c index 842155e65a80..9cc514703d2a 100644 --- a/drivers/net/wireless/wl1251/ps.c +++ b/drivers/net/wireless/wl1251/ps.c @@ -58,7 +58,6 @@ void wl1251_ps_elp_sleep(struct wl1251 *wl) unsigned long delay; if (wl->psm) { - cancel...
4918b40dc8b0e3addf3178f2dded99e149f5ad31
Analyze and fix the following issue in the Linux kernel code: davinci: da830: fix driver name for spi clocks
Problem Details: The spi driver name called out for the da830 spi clock list is not correct, fix it. Signed-off-by: Michael Williamson <michael.williamson@criticallink.com> Acked-by: Sekhar Nori <nsekhar@ti.com> Signed-off-by: Kevin Hilman <khilman@ti.com>
```diff diff --git a/arch/arm/mach-davinci/da830.c b/arch/arm/mach-davinci/da830.c index ec23ab473620..826118e13678 100644 --- a/arch/arm/mach-davinci/da830.c +++ b/arch/arm/mach-davinci/da830.c @@ -397,8 +397,8 @@ static struct clk_lookup da830_clks[] = { CLK(NULL, "uart0", &uart0_clk), CLK(NULL, "uart1", &uart1...
883ae7992c09435927dda642b61f1455fceb5b85
Analyze and fix the following issue in the Linux kernel code: ideapad: read brightness setting on brightness key notify
Problem Details: BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=25922 On ideapad Y530, the brightness key notify will be blocked if the last notify is not responsed by getting the brightness value. Read value when we get the notify shall fix the problem and will not have any difference on other ideapads. Signed...
```diff diff --git a/drivers/platform/x86/ideapad-laptop.c b/drivers/platform/x86/ideapad-laptop.c index 114d95247cdf..21b101899bae 100644 --- a/drivers/platform/x86/ideapad-laptop.c +++ b/drivers/platform/x86/ideapad-laptop.c @@ -459,6 +459,8 @@ static void ideapad_acpi_notify(struct acpi_device *adevice, u32 event) ...
86b32122fd54addc9af01f8b919c65d3f49090a3
Analyze and fix the following issue in the Linux kernel code: xen/e820: Don't mark balloon memory as E820_UNUSABLE when running as guest and fix overflow.
Problem Details: If we have a guest that asked for: memory=1024 maxmem=2048 Which means we want 1GB now, and create pagetables so that we can expand up to 2GB, we would have this E820 layout: [ 0.000000] BIOS-provided physical RAM map: [ 0.000000] Xen: 0000000000000000 - 00000000000a0000 (usable) [ 0.00000...
```diff diff --git a/arch/x86/xen/setup.c b/arch/x86/xen/setup.c index 2a4add9634ce..010ba2e62de5 100644 --- a/arch/x86/xen/setup.c +++ b/arch/x86/xen/setup.c @@ -200,7 +200,8 @@ char * __init xen_memory_setup(void) * used as potential resource for I/O address (happens * when 'allocate_resource' is called). ...
89d8d32060de17c23f761df74799c7c07b79dd01
Analyze and fix the following issue in the Linux kernel code: mtd: fix printf format warnings, mostly lack of %zd for size_t, in mtdswap
Problem Details: Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
```diff diff --git a/drivers/mtd/mtdswap.c b/drivers/mtd/mtdswap.c index 57e6cc30bc42..a65594fee4a3 100644 --- a/drivers/mtd/mtdswap.c +++ b/drivers/mtd/mtdswap.c @@ -331,7 +331,7 @@ static int mtdswap_read_oob(struct mtdswap_dev *d, loff_t from, if (ops->oobretlen < ops->ooblen) { dev_warn(d->dev, "Read OOB ret...
7e79443ce250776b8477426127acdac15c567f22
Analyze and fix the following issue in the Linux kernel code: ALSA: atiixp - Fix wrong time-out checks during ac-link reset
Problem Details: The time-out in snd_atiixp_aclink_reset() is wrongly checked, and it resulted in exiting from the loop at the first iteration. Reported-by: Amir Shamsuddin <AmirS2+alsa@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
```diff diff --git a/sound/pci/atiixp.c b/sound/pci/atiixp.c index 49d572a7b235..3119cd97a217 100644 --- a/sound/pci/atiixp.c +++ b/sound/pci/atiixp.c @@ -522,7 +522,7 @@ static int snd_atiixp_aclink_reset(struct atiixp *chip) atiixp_read(chip, CMD); mdelay(1); atiixp_update(chip, CMD, ATI_REG_CMD_AC_RESET, AT...
0aeea18964173715a1037034ef6838198f319319
Analyze and fix the following issue in the Linux kernel code: block: fix mis-synchronisation in blkdev_issue_zeroout()
Problem Details: BZ29402 https://bugzilla.kernel.org/show_bug.cgi?id=29402 We can hit serious mis-synchronization in bio completion path of blkdev_issue_zeroout() leading to a panic. The problem is that when we are going to wait_for_completion() in blkdev_issue_zeroout() we check if the bb.done equals issued (number ...
```diff diff --git a/block/blk-lib.c b/block/blk-lib.c index eec78becb355..bd3e8df4d5e2 100644 --- a/block/blk-lib.c +++ b/block/blk-lib.c @@ -109,7 +109,6 @@ struct bio_batch atomic_t done; unsigned long flags; struct completion *wait; - bio_end_io_t *end_io; }; static void bio_batch_end_io(struct bio ...
2c1c5f199482356c00f70b6f2f368c3455d1230c
Analyze and fix the following issue in the Linux kernel code: mtd: mxc_nand: fix OOB corruption when page size > 2KiB
Problem Details: When page size is 4KiB, ecc.total is set to 8*9, and this causes nand_write_page_hwecc() to read past the initialized part of the eccpos array, which corrupts chip->oob_poi with bogus values from ecc_calc. Fix this by creating a proper nand_ecclayout for 4KiB flashes. Signed-off-by: Baruch Siach <bar...
```diff diff --git a/drivers/mtd/nand/mxc_nand.c b/drivers/mtd/nand/mxc_nand.c index 6cd78ed439a7..b7d5a5b9a543 100644 --- a/drivers/mtd/nand/mxc_nand.c +++ b/drivers/mtd/nand/mxc_nand.c @@ -211,6 +211,31 @@ static struct nand_ecclayout nandv2_hw_eccoob_largepage = { } }; +/* OOB description for 4096 byte pages wi...
4eb2da8994042d68e84e31138788429a102da2ea
Analyze and fix the following issue in the Linux kernel code: mtd: pxa3xx_nand: unify prepare command
Problem Details: Make the interface simpler which could make both debug and enhancement easier. Signed-off-by: Lei Wen <leiwen@marvell.com> Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
```diff diff --git a/drivers/mtd/nand/pxa3xx_nand.c b/drivers/mtd/nand/pxa3xx_nand.c index be0aa44ada42..de0a2a25eb01 100644 --- a/drivers/mtd/nand/pxa3xx_nand.c +++ b/drivers/mtd/nand/pxa3xx_nand.c @@ -28,6 +28,7 @@ #define CHIP_DELAY_TIMEOUT (2 * HZ/10) #define NAND_STOP_DELAY (2 * HZ/50) +#define PAGE_CHUNK_SIZ...
e70727e442eb61581f836a9a0ca0c3b70d8a3ff2
Analyze and fix the following issue in the Linux kernel code: mtd: speedtest: fix integer overflow
Problem Details: 32-bit integers used in 'calc_speed()' may overflow and lead to incorrect results. Use 64-bit integers instead. Signed-off-by: David Lambert <dave@lambsys.com> Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
```diff diff --git a/drivers/mtd/tests/mtd_speedtest.c b/drivers/mtd/tests/mtd_speedtest.c index 3ce6fce75e07..627d4e2466a3 100644 --- a/drivers/mtd/tests/mtd_speedtest.c +++ b/drivers/mtd/tests/mtd_speedtest.c @@ -314,16 +314,16 @@ static inline void stop_timing(void) static long calc_speed(void) { - long ms, k, s...
5d9d9936209e589569a97985285b3282310cf2db
Analyze and fix the following issue in the Linux kernel code: mtd: mxc_nand: fix read past buffer end
Problem Details: Signed-off-by: Baruch Siach <baruch@tkos.co.il> Acked-by: Sascha hauer <s.hauer@pengutronix.de> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
```diff diff --git a/drivers/mtd/nand/mxc_nand.c b/drivers/mtd/nand/mxc_nand.c index ef932ba55a0b..6cd78ed439a7 100644 --- a/drivers/mtd/nand/mxc_nand.c +++ b/drivers/mtd/nand/mxc_nand.c @@ -641,9 +641,9 @@ static void mxc_nand_read_buf(struct mtd_info *mtd, u_char *buf, int len) n = min(n, len); - memcpy(buf, ho...
775adc3d44c8076d3e475fabebb61c08421c4421
Analyze and fix the following issue in the Linux kernel code: mtd: nand: fix a typo in a commentary
Problem Details: Signed-off-by: Jason Liu <r64343@freescale.com> Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
```diff diff --git a/drivers/mtd/nand/nand_base.c b/drivers/mtd/nand/nand_base.c index a9c6ce745767..da7604050347 100644 --- a/drivers/mtd/nand/nand_base.c +++ b/drivers/mtd/nand/nand_base.c @@ -2377,7 +2377,7 @@ static int nand_do_write_oob(struct mtd_info *mtd, loff_t to, return -EINVAL; } - /* Do not allow re...
13ce77f46c79a3839e4c2ff9722c9416c165f498
Analyze and fix the following issue in the Linux kernel code: mtd: cfi: fix writebufsize initialization
Problem Details: When initializing mtd->writebufsize, we must take into account possible flash chip interleaving. Wrong writebufsize initialization caused UBIFS recovery issues resulting in unmountable UBIFS file system on NOR flash partitions. Signed-off-by: Anatolij Gustschin <agust@denx.de> Acked-by: Guillaume LECE...
```diff diff --git a/drivers/mtd/chips/cfi_cmdset_0001.c b/drivers/mtd/chips/cfi_cmdset_0001.c index 4aaa88f8ab5f..092aef11120c 100644 --- a/drivers/mtd/chips/cfi_cmdset_0001.c +++ b/drivers/mtd/chips/cfi_cmdset_0001.c @@ -455,7 +455,7 @@ struct mtd_info *cfi_cmdset_0001(struct map_info *map, int primary) mtd->flags ...
e6da85685b2dec1e69e58366c22d1f883d6da575
Analyze and fix the following issue in the Linux kernel code: mtd: onenand_base: onenand_verify bugfix for writepage non-aligned address
Problem Details: In onenand_verify function the address can be writepage non-aligned. When a page is read for comparing the right offset should be used for "this->verify_buf" to get the right matching with compared "buf" buffer. Signed-off-by: Roman Tereshonkov <roman.tereshonkov@nokia.com> Signed-off-by: Adrian Hunte...
```diff diff --git a/drivers/mtd/onenand/onenand_base.c b/drivers/mtd/onenand/onenand_base.c index 38e6d76bcc0e..4205b9423b89 100644 --- a/drivers/mtd/onenand/onenand_base.c +++ b/drivers/mtd/onenand/onenand_base.c @@ -1648,11 +1648,10 @@ static int onenand_verify(struct mtd_info *mtd, const u_char *buf, loff_t addr, ...
7912a5e7f37512d8d105785046137435b70347ce
Analyze and fix the following issue in the Linux kernel code: mtd: nand: fix pointer NULL pointer dereferencing
Problem Details: In 'verify_bbt_descr()', first check the "bd" pointer, then dereference it. Comments amended by Artem. Signed-off-by: Stanislav Fomichev <kernel@fomichev.me> Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
```diff diff --git a/drivers/mtd/nand/nand_bbt.c b/drivers/mtd/nand/nand_bbt.c index 6ebd869993aa..a1e8b30078d9 100644 --- a/drivers/mtd/nand/nand_bbt.c +++ b/drivers/mtd/nand/nand_bbt.c @@ -1101,12 +1101,16 @@ static void mark_bbt_region(struct mtd_info *mtd, struct nand_bbt_descr *td) static void verify_bbt_descr(st...
f17f12ce9dd6ec0a8e1f415ecdbaebfce0207464
Analyze and fix the following issue in the Linux kernel code: mtd: phram: fix memory leak
Problem Details: Commit 4f678a58 (mtd: fix memory leaks in phram_setup) missed two cases where the memory allocated for name would be leaked. This commit frees the memory when register_device() fails and on unregister_devices(). Signed-off-by: Mathias Krause <minipli@googlemail.com> Signed-off-by: Artem Bityutskiy <Ar...
```diff diff --git a/drivers/mtd/devices/phram.c b/drivers/mtd/devices/phram.c index 52393282eaf1..8d28fa02a5a2 100644 --- a/drivers/mtd/devices/phram.c +++ b/drivers/mtd/devices/phram.c @@ -117,6 +117,7 @@ static void unregister_devices(void) list_for_each_entry_safe(this, safe, &phram_list, list) { del_mtd_devic...
a6e8509f2172a6ac764a82763fce64836a108a14
Analyze and fix the following issue in the Linux kernel code: ALSA: intel8x0m: add 'm' as "suffix" to static functions
Problem Details: Adding an 'm' will distinguish them from identical names in intel8x0.c. Signed-off-by: Paul Bolle <pebolle@tiscali.nl> Signed-off-by: Takashi Iwai <tiwai@suse.de>
```diff diff --git a/sound/pci/intel8x0m.c b/sound/pci/intel8x0m.c index b1c926cd281b..8716b291cb7d 100644 --- a/sound/pci/intel8x0m.c +++ b/sound/pci/intel8x0m.c @@ -341,9 +341,9 @@ static int snd_intel8x0m_codec_semaphore(struct intel8x0m *chip, unsigned int co return -EBUSY; } -static void snd_intel8x0_codec_w...
5cd2ad81f912c8535491f541108b655f4552dff9
Analyze and fix the following issue in the Linux kernel code: ALSA: intel8x0m: wait a bit before warm reset check
Problem Details: At every resume a laptop I use prints this message (at KERN_ERR level): ALSA sound/pci/intel8x0m.c:904: AC'97 warm reset still in progress? [0x2] The thing to note here is that 0x2 corresponds to ICH_AC97COLD. Ie, what seems to be happening is that the register involved indicated a warm reset for ...
```diff diff --git a/sound/pci/intel8x0m.c b/sound/pci/intel8x0m.c index 13cec1e5ced9..b1c926cd281b 100644 --- a/sound/pci/intel8x0m.c +++ b/sound/pci/intel8x0m.c @@ -894,7 +894,8 @@ static int snd_intel8x0m_ich_chip_init(struct intel8x0m *chip, int probing) /* finish cold or do warm reset */ cnt |= (cnt & ICH_AC97...
c804c733846572ca85c2bba60c7fe6fa024dff18
Analyze and fix the following issue in the Linux kernel code: mtd: add "platform:" prefix for platform modalias
Problem Details: Since 43cc71eed1250755986da4c0f9898f9a635cb3bf (platform: prefix MODALIAS with "platform:"), the platform modalias is prefixed with "platform:". Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com> Signed-off-by: David Woodhouse <David.Woodhouse@int...
```diff diff --git a/drivers/mtd/nand/omap2.c b/drivers/mtd/nand/omap2.c index 15682ec8530e..28af71c61834 100644 --- a/drivers/mtd/nand/omap2.c +++ b/drivers/mtd/nand/omap2.c @@ -968,6 +968,6 @@ static void __exit omap_nand_exit(void) module_init(omap_nand_init); module_exit(omap_nand_exit); -MODULE_ALIAS(DRIVER_NA...
bd637f6f22235b4613f9ab6555e8088a455c1ed4
Analyze and fix the following issue in the Linux kernel code: mtd: mtd_blkdevs: fix double free on error path
Problem Details: This one liner patch fixes double free that will occur if add_mtd_blktrans_dev fails. On failure it frees the input argument, but all its users also free it on error which is natural thing to do. Thus don't free it. All credit for finding that bug belongs to reporters of the bug in the android bugzill...
```diff diff --git a/drivers/mtd/mtd_blkdevs.c b/drivers/mtd/mtd_blkdevs.c index cb20c67995d8..e0a2373bf0e2 100644 --- a/drivers/mtd/mtd_blkdevs.c +++ b/drivers/mtd/mtd_blkdevs.c @@ -413,7 +413,6 @@ error3: error2: list_del(&new->list); error1: - kfree(new); return ret; } ```
82013d988fc03a1b908b2b0360a1e34f6152fda6
Analyze and fix the following issue in the Linux kernel code: mtd: amd76xrom: fix oops at boot when resources are not available
Problem Details: For some unknown reasons resources needed by amd76xrom driver can be unavailable. And instead of returning an error, the driver keeps going and crash the kernel. This patch fixes the problem by making the driver return -EBUSY if the resources are not available. Commit messages tweaked by Artem. Repor...
```diff diff --git a/drivers/mtd/maps/amd76xrom.c b/drivers/mtd/maps/amd76xrom.c index 77d64ce19e9f..92de7e3a49a5 100644 --- a/drivers/mtd/maps/amd76xrom.c +++ b/drivers/mtd/maps/amd76xrom.c @@ -151,6 +151,7 @@ static int __devinit amd76xrom_init_one (struct pci_dev *pdev, printk(KERN_ERR MOD_NAME " %s(): ...
edf7de31c25ce72f163bf7d1fc0d2711869d073c
Analyze and fix the following issue in the Linux kernel code: ALSA: usbaudio: fix suspend/resume
Problem Details: - ESHUTDOWN must be correctly handled - the optional interrupt endpoint's URB must be stopped and restarted Signed-off-by: Oliver Neukum <oneukum@suse.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
```diff diff --git a/sound/usb/card.c b/sound/usb/card.c index c0f8270bc199..7fa53d91e73b 100644 --- a/sound/usb/card.c +++ b/sound/usb/card.c @@ -586,6 +586,7 @@ static int usb_audio_suspend(struct usb_interface *intf, pm_message_t message) struct snd_usb_audio *chip = usb_get_intfdata(intf); struct list_head *p; ...
ea75159ee6f00bd809f57a58e5505dc362382cc8
Analyze and fix the following issue in the Linux kernel code: OMAP4: DSS2: Clock source changes for OMAP4
Problem Details: On OMAP3, the pixel clock for the LCD manager was derived through DISPC_FCLK as: Lcd Pixel clock = DISPC_FCLK / lcd / pcd Where lcd and pcd are divisors in the DISPC_DIVISOR register. On OMAP4, the pixel clocks for LCD1 and LCD2 managers are derived from 2 new clocks named LCD1_CLK and LCD2_CLK. The...
```diff diff --git a/drivers/video/omap2/dss/dispc.c b/drivers/video/omap2/dss/dispc.c index 28b690f2447f..b8c576a0bc02 100644 --- a/drivers/video/omap2/dss/dispc.c +++ b/drivers/video/omap2/dss/dispc.c @@ -2365,25 +2365,33 @@ unsigned long dispc_lclk_rate(enum omap_channel channel) lcd = FLD_GET(l, 23, 16); - r ...
b9cb0984a6e6a09a4bcdc11ebc9f0eb71e5b6c85
Analyze and fix the following issue in the Linux kernel code: OMAP: DSS2: fix omap_dispc_register_isr() fail path
Problem Details: Fix handling of error in omap_dispc_register_isr() in case there are no free isr slots available. Reported-by: Ben Tucker <btucker@mpcdata.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
```diff diff --git a/drivers/video/omap2/dss/dispc.c b/drivers/video/omap2/dss/dispc.c index dae9686fb437..4a368c47700e 100644 --- a/drivers/video/omap2/dss/dispc.c +++ b/drivers/video/omap2/dss/dispc.c @@ -2831,6 +2831,9 @@ int omap_dispc_register_isr(omap_dispc_isr_t isr, void *arg, u32 mask) break; } + if (re...
f2988ab9f4a2bf5e24f37d20eab1aad6862953d3
Analyze and fix the following issue in the Linux kernel code: HACK: OMAP: DSS2: Fix OMAP2_DSS_USE_DSI_PLL
Problem Details: When using OMAP2_DSS_USE_DSI_PLL, which selects DSI PLL as source clock for DISPC, the DSI needs the vdds_dsi regulator. Latest regulator changes broke this, causing the the code to not acquire the regulator when using OMAP2_DSS_USE_DSI_PLL. This patch acquires the vdds_dsi regulator in dsi_pll_init()...
```diff diff --git a/drivers/video/omap2/dss/dsi.c b/drivers/video/omap2/dss/dsi.c index 44b667b55ab8..be7694ff7ca7 100644 --- a/drivers/video/omap2/dss/dsi.c +++ b/drivers/video/omap2/dss/dsi.c @@ -1119,6 +1119,26 @@ int dsi_pll_init(struct omap_dss_device *dssdev, bool enable_hsclk, DSSDBG("PLL init\n"); +#ifde...
08a0a657949e723f0cbb6a33b1c706134d5a6d78
Analyze and fix the following issue in the Linux kernel code: omapfb: Fix linker error in drivers/video/omap/lcd_2430sdp.c
Problem Details: There is a linker error from lcd_2430sdp.c if CONFIG_TWL4030_CORE is not set. This can be triggered on OMAP2 builds when OMAP3 or OMAP4 are not set. drivers/built-in.o: In function `sdp2430_panel_disable': drivers/video/omap/lcd_2430sdp.c:123: undefined reference to `twl_i2c_write_u8' drivers/video/om...
```diff diff --git a/drivers/video/omap/Kconfig b/drivers/video/omap/Kconfig index ff7049b2cc8f..15e7f1912af9 100644 --- a/drivers/video/omap/Kconfig +++ b/drivers/video/omap/Kconfig @@ -5,6 +5,7 @@ config FB_OMAP select FB_CFB_FILLRECT select FB_CFB_COPYAREA select FB_CFB_IMAGEBLIT + select TWL4030_CORE if MACH_...
6ec549e50b192105ede7bb289a31da6f6e1a61e9
Analyze and fix the following issue in the Linux kernel code: OMAP: DSS2: Check for SDI HW before accessing SDI registers
Problem Details: Only OMAP 3430 hardware has SDI support. The availability of SDI HW can be found out by checking if the LCD channel supports SDI displays. This patch checks for SDI HW support before accessing SDI registers, which fixes a crash on OMAP4 when SDI SW support is compiled in. Signed-off-by: Tomi Valkeine...
```diff diff --git a/drivers/video/omap2/dss/dss.c b/drivers/video/omap2/dss/dss.c index dc57100cc43d..50c18677684d 100644 --- a/drivers/video/omap2/dss/dss.c +++ b/drivers/video/omap2/dss/dss.c @@ -32,6 +32,7 @@ #include <plat/display.h> #include <plat/clock.h> #include "dss.h" +#include "dss_features.h" #define...
ac425ed5fb0b6564d4eeee9fb13ef0c1f6da8e8f
Analyze and fix the following issue in the Linux kernel code: OMAP: DSS2: Fix def_disp module param description
Problem Details: MODULE_PARM_DESC() takes the name of the actual module parameter, not the name of the variable, as input. Fix the module parameter description for def_disp. Signed-off-by: Jani Nikula <jani@nikula.org> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
```diff diff --git a/drivers/video/omap2/dss/core.c b/drivers/video/omap2/dss/core.c index f56ee64f5b58..bcf69a462b5f 100644 --- a/drivers/video/omap2/dss/core.c +++ b/drivers/video/omap2/dss/core.c @@ -47,7 +47,7 @@ static struct { static char *def_disp_name; module_param_named(def_disp, def_disp_name, charp, 0); ...
a110f4ef810ee29d810876df725f41d66629733e
Analyze and fix the following issue in the Linux kernel code: ASoC: mini2440: Fix uda134x codec problem.
Problem Details: ASoC audio for mini2440 platform in current kenrel doesn't work. First problem is samsung_asoc_dma device is missing in initialization. Next problem is with codec. Codec is initialized but never probed because no platform_device exist for codec driver. It leads to errors during codec binding to asoc da...
```diff diff --git a/arch/arm/mach-s3c2440/mach-mini2440.c b/arch/arm/mach-s3c2440/mach-mini2440.c index f62bb4c793bd..7c3fb071ddd6 100644 --- a/arch/arm/mach-s3c2440/mach-mini2440.c +++ b/arch/arm/mach-s3c2440/mach-mini2440.c @@ -506,6 +506,11 @@ static struct i2c_board_info mini2440_i2c_devs[] __initdata = { }, };...
ecf3fde07c8dcb92a1bf3fbdfe70905d85cd00e1
Analyze and fix the following issue in the Linux kernel code: mtd: fix race in cfi_cmdset_0001 driver
Problem Details: As inval_cache_and_wait_for_operation() drop and reclaim the lock to invalidate the cache, some other thread may suspend the operation before reaching the for(;;) loop. Therefore the loop must start with checking the chip->state before reading status from the chip. Signed-off-by: Joakim Tjernlund <Joa...
```diff diff --git a/drivers/mtd/chips/cfi_cmdset_0001.c b/drivers/mtd/chips/cfi_cmdset_0001.c index a8c3e1c9b02a..4aaa88f8ab5f 100644 --- a/drivers/mtd/chips/cfi_cmdset_0001.c +++ b/drivers/mtd/chips/cfi_cmdset_0001.c @@ -1230,10 +1230,32 @@ static int inval_cache_and_wait_for_operation( sleep_time = chip_op_time / ...
27380fb83079bc7bd644e1115bb001dfdcec307f
Analyze and fix the following issue in the Linux kernel code: ASoC: Fix spacing in MAX8950
Problem Details: Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
```diff diff --git a/sound/soc/codecs/max9850.c b/sound/soc/codecs/max9850.c index 6d2c5a37550e..208d2ee61855 100644 --- a/sound/soc/codecs/max9850.c +++ b/sound/soc/codecs/max9850.c @@ -118,7 +118,7 @@ static int max9850_hw_params(struct snd_pcm_substream *substream, u64 lrclk_div; u8 sf, da; - if(!max9850->sysc...
efba2e313ea1b1bd69a7c4659263becf43bb1adc
Analyze and fix the following issue in the Linux kernel code: mtd: jedec_probe: Change variable name from cfi_p to cfi
Problem Details: In the following commit, we'll need to use the CMD() macro in order to fix the initialisation of the sector_erase_cmd field. That requires the local variable to be called 'cfi', so change it first in a simple patch. Signed-off-by: Antony Pavlov <antony@niisi.msk.ru> Acked-by: Guillaume LECERF <glecerf...
```diff diff --git a/drivers/mtd/chips/jedec_probe.c b/drivers/mtd/chips/jedec_probe.c index d72a5fb2d041..7bedbb96604d 100644 --- a/drivers/mtd/chips/jedec_probe.c +++ b/drivers/mtd/chips/jedec_probe.c @@ -1935,14 +1935,14 @@ static void jedec_reset(u32 base, struct map_info *map, struct cfi_private *cfi) } -stat...
64c25a92e865f06ad8782fbdaa1e2a97d50acf73
Analyze and fix the following issue in the Linux kernel code: ASoC: PXA: Z2: Fix codec pin name
Problem Details: MONO was renamed to MONO1. Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com> Acked-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: stable@kernel.org
```diff diff --git a/sound/soc/pxa/z2.c b/sound/soc/pxa/z2.c index b0b6c8d7c2f3..d69d9fc32233 100644 --- a/sound/soc/pxa/z2.c +++ b/sound/soc/pxa/z2.c @@ -152,7 +152,7 @@ static int z2_wm8750_init(struct snd_soc_pcm_runtime *rtd) snd_soc_dapm_disable_pin(dapm, "LINPUT3"); snd_soc_dapm_disable_pin(dapm, "RINPUT3"); ...
37a9d912b24f96a0591773e6e6c3642991ae5a70
Analyze and fix the following issue in the Linux kernel code: futex: Sanitize cmpxchg_futex_value_locked API
Problem Details: The cmpxchg_futex_value_locked API was funny in that it returned either the original, user-exposed futex value OR an error code such as -EFAULT. This was confusing at best, and could be a source of livelocks in places that retry the cmpxchg_futex_value_locked after trying to fix the issue by running fa...
```diff diff --git a/arch/alpha/include/asm/futex.h b/arch/alpha/include/asm/futex.h index 945de222ab91..c4e5c2850cce 100644 --- a/arch/alpha/include/asm/futex.h +++ b/arch/alpha/include/asm/futex.h @@ -81,21 +81,22 @@ static inline int futex_atomic_op_inuser (int encoded_op, int __user *uaddr) } static inline int ...
e4a7b7b0c98efcdcc4c1f6eb10925dec1fbc4016
Analyze and fix the following issue in the Linux kernel code: GFS2: fix block allocation check for fallocate
Problem Details: GFS2 fallocate wasn't properly checking if a blocks were already allocated. In write_empty_blocks(), if a page didn't have buffer_heads attached, GFS2 was always treating it as if there were no blocks allocated for that page. GFS2 now calls gfs2_block_map() to check if the blocks are allocated before w...
```diff diff --git a/fs/gfs2/file.c b/fs/gfs2/file.c index 2878481f72a9..4074b952b059 100644 --- a/fs/gfs2/file.c +++ b/fs/gfs2/file.c @@ -622,8 +622,7 @@ static void empty_write_end(struct page *page, unsigned from, { struct gfs2_inode *ip = GFS2_I(page->mapping->host); - page_zero_new_buffers(page, from, to); - ...
f91f9cd505f92e4227ffda7e5799a33d4f34bf36
Analyze and fix the following issue in the Linux kernel code: arm: tcc8k: Fix bus clock calculation
Problem Details: There are two dividers used to derive bus clock from system clock: system clock is divided by SCKDIV+1, then by BCKDIV+1. SCKDIV divider has been ignored up to now, which is no problem as long as it is 0. Take SCKDIV into account for bus clock calculation. Signed-off-by: Oskar Schirmer <oskar@linutro...
```diff diff --git a/arch/arm/mach-tcc8k/clock.c b/arch/arm/mach-tcc8k/clock.c index 8d8c99f89558..e7cdae5c77a4 100644 --- a/arch/arm/mach-tcc8k/clock.c +++ b/arch/arm/mach-tcc8k/clock.c @@ -308,10 +308,17 @@ static unsigned long get_rate_sys(struct clk *clk) static unsigned long get_rate_bus(struct clk *clk) { - u...
cfeeb2f99867c075f3a1a6ac59c0a42e1cd741b0
Analyze and fix the following issue in the Linux kernel code: arm: tcc8k: Fix indent, coding syle
Problem Details: Remove double definition of ACLKUSBH, change parameter name in root_clk_disable, as there is no reason to have a different name than in root_clk_enable. No functional change. Signed-off-by: Oskar Schirmer <oskar@linutronix.de> Cc: bigeasy@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix....
```diff diff --git a/arch/arm/mach-tcc8k/clock.c b/arch/arm/mach-tcc8k/clock.c index a25e3fcb716f..8d8c99f89558 100644 --- a/arch/arm/mach-tcc8k/clock.c +++ b/arch/arm/mach-tcc8k/clock.c @@ -45,7 +45,6 @@ #define ACLKGSB1 (CKC_BASE + ACLKGSB1_OFFS) #define ACLKGSB2 (CKC_BASE + ACLKGSB2_OFFS) #define ACLKGSB3 (CKC_BA...
fe03a9f7bb89e920e60fd1bb074adab2eed2bf48
Analyze and fix the following issue in the Linux kernel code: arm: tcc8k: Fix clock rate calculation
Problem Details: The calculation of the best divider value for a requested clock rate always returned a value that was slightly too large. It was also not protected against possible divisions by zero. Request for very low, but non zero rates would cause the ACLK divisor field to overflow. Catch this situation by using...
```diff diff --git a/arch/arm/mach-tcc8k/clock.c b/arch/arm/mach-tcc8k/clock.c index 3970a9cdce26..7ebcbff4652a 100644 --- a/arch/arm/mach-tcc8k/clock.c +++ b/arch/arm/mach-tcc8k/clock.c @@ -50,6 +50,8 @@ #define ACLKTCX (CKC_BASE + ACLKTCX_OFFS) #define ACLKTCZ (CKC_BASE + ACLKTCZ_OFFS) +#define ACLK_MAX_DIV (0x...
cce3f612fedcbeee61977497b99bbf68a4082b6b
Analyze and fix the following issue in the Linux kernel code: UBIFS: simplify UBIFS Kconfig menu
Problem Details: Remove debug message level and debug checks Kconfig options as they proved to be useless anyway. We have sysfs interface which we can use for fine-grained debugging messages and checks selection, see Documentation/filesystems/ubifs.txt for mode details. Signed-off-by: Artem Bityutskiy <Artem.Bityutski...
```diff diff --git a/fs/ubifs/Kconfig b/fs/ubifs/Kconfig index 830e3f76f442..1d1859dc3de5 100644 --- a/fs/ubifs/Kconfig +++ b/fs/ubifs/Kconfig @@ -44,23 +44,20 @@ config UBIFS_FS_ZLIB # Debugging-related stuff config UBIFS_FS_DEBUG - bool "Enable debugging" + bool "Enable debugging support" depends on UBIFS_FS ...
d882962f6af2b484b62a7fb05ef959e1bf355fc4
Analyze and fix the following issue in the Linux kernel code: UBIFS: handle allocation failures in UBIFS write path
Problem Details: Running kernel 2.6.37, my PPC-based device occasionally gets an order-2 allocation failure in UBIFS, which causes the root FS to become unwritable: kswapd0: page allocation failure. order:2, mode:0x4050 Call Trace: [c787dc30] [c00085b8] show_stack+0x7c/0x194 (unreliable) [c787dc70] [c0061aec] __alloc_...
```diff diff --git a/fs/ubifs/journal.c b/fs/ubifs/journal.c index 914f1bd89e57..aed25e864227 100644 --- a/fs/ubifs/journal.c +++ b/fs/ubifs/journal.c @@ -690,7 +690,7 @@ int ubifs_jnl_write_data(struct ubifs_info *c, const struct inode *inode, { struct ubifs_data_node *data; int err, lnum, offs, compr_type, out_l...
2f4dd595f6d60ec3ccbb68def73df457970cf671
Analyze and fix the following issue in the Linux kernel code: OMAP3: wdtimer: Fix CORE idle transition
Problem Details: The HW superwised smart idle for wdtimer in OMAP3 prevents CORE power domain idle transitions. Disable it by swithing to SW supervised transitions. This could be a hardware bug in the OMAP3 wdtimer2 block. Signed-off-by: Kalle Jokiniemi <kalle.jokiniemi@nokia.com> Signed-off-by: Paul Walmsley <paul@p...
```diff diff --git a/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c b/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c index c4ca005f8bb5..477ba543b227 100644 --- a/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c +++ b/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c @@ -1312,6 +1312,11 @@ static struct omap_hwmod omap3xxx_wd_timer2_hwmod ...
fdc315a19a2c33da29dd87d4ca88f4e4407bd42d
Analyze and fix the following issue in the Linux kernel code: drm/radeon: add pageflip hooks for fusion
Problem Details: Looks like these got passed over with both being merged at the same time but not quite meeting in the middle. should fix: https://bugs.freedesktop.org/show_bug.cgi?id=34137 along with Michael's phoronix article. Reported-by: Chi-Thanh Christopher Nguyen Article-written-by: Michael Larabel @ phoronix ...
```diff diff --git a/drivers/gpu/drm/radeon/radeon_asic.c b/drivers/gpu/drm/radeon/radeon_asic.c index e75d63b8e21d..793c5e6026ad 100644 --- a/drivers/gpu/drm/radeon/radeon_asic.c +++ b/drivers/gpu/drm/radeon/radeon_asic.c @@ -834,6 +834,9 @@ static struct radeon_asic sumo_asic = { .pm_finish = &evergreen_pm_finish, ...
dcbcdf22f500ac6e4ec06485341024739b9dc241
Analyze and fix the following issue in the Linux kernel code: net: bridge builtin vs. ipv6 modular
Problem Details: When configs BRIDGE=y and IPV6=m, this build error occurs: br_multicast.c:(.text+0xa3341): undefined reference to `ipv6_dev_get_saddr' BRIDGE_IGMP_SNOOPING is boolean; if it were tristate, then adding depends on IPV6 || IPV6=n to BRIDGE_IGMP_SNOOPING would be a good fix. As it is currently, making ...
```diff diff --git a/net/bridge/Kconfig b/net/bridge/Kconfig index 9190ae462cb4..6dee7bf648a9 100644 --- a/net/bridge/Kconfig +++ b/net/bridge/Kconfig @@ -6,6 +6,7 @@ config BRIDGE tristate "802.1d Ethernet Bridging" select LLC select STP + depends on IPV6 || IPV6=n ---help--- If you say Y here, then your L...
4c418ba9695a24917a1fcfa48f7db3fd76337eb7
Analyze and fix the following issue in the Linux kernel code: ipmi: Fix IPMI errors due to timing problems
Problem Details: This patch fixes an issue in OpenIPMI module where sometimes an ABORT command is sent after sending an IPMI request to BMC causing the IPMI request to fail. Signed-off-by: YiCheng Doe <yicheng.doe@hp.com> Signed-off-by: Corey Minyard <cminyard@mvista.com> Acked-by: Tom Mingarelli <thomas.mingarelli@hp...
```diff diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_intf.c index 7855f9f45b8e..62787e30d508 100644 --- a/drivers/char/ipmi/ipmi_si_intf.c +++ b/drivers/char/ipmi/ipmi_si_intf.c @@ -900,6 +900,14 @@ static void sender(void *send_info, printk("**Enqueue: %d.%9.9d\n", t.tv_se...
3c5ead52ed68406c0ee789024c4ae581be8bcee4
Analyze and fix the following issue in the Linux kernel code: arch/tile: fix deadlock bugs in rwlock implementation
Problem Details: The first issue fixed in this patch is that pending rwlock write locks could lock out new readers; this could cause a deadlock if a read lock was held on cpu 1, a write lock was then attempted on cpu 2 and was pending, and cpu 1 was interrupted and attempted to re-acquire a read lock. The write lock co...
```diff diff --git a/arch/tile/include/asm/spinlock_32.h b/arch/tile/include/asm/spinlock_32.h index 88efdde8dd2b..a8f2c6e31a87 100644 --- a/arch/tile/include/asm/spinlock_32.h +++ b/arch/tile/include/asm/spinlock_32.h @@ -78,13 +78,6 @@ void arch_spin_unlock_wait(arch_spinlock_t *lock); #define _RD_COUNT_SHIFT 24 #d...
ba3820ade317ee36e496b9b40d2ec3987dd4aef0
Analyze and fix the following issue in the Linux kernel code: drm/i915: Revive combination mode for backlight control
Problem Details: This reverts commit 951f3512dba5bd44cda3e5ee22b4b522e4bb09fb drm/i915: Do not handle backlight combination mode specially since this commit introduced other regressions due to untouched LBPC register, e.g. the backlight dimmed after resume. In addition to the revert, this patch includes a fix fo...
```diff diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h index 3e6f486f4605..2abe240dae58 100644 --- a/drivers/gpu/drm/i915/i915_reg.h +++ b/drivers/gpu/drm/i915/i915_reg.h @@ -1553,7 +1553,17 @@ /* Backlight control */ #define BLC_PWM_CTL 0x61254 +#define BACKLIGHT_MODULATION_FREQ_...
c9749a352383d4d2d25eb28062afd1a7eee115b7
Analyze and fix the following issue in the Linux kernel code: OMAP3: PM: Allow the cache clean when L1 is lost.
Problem Details: When L1 cache is suppose to be lost, it needs to be cleaned before entrering to the low power mode. While at this, also fix few comments and remove un-necessary clean_l2 lable. Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com> Signed-off-by: Kevin Hilman <khilman@ti.com>
```diff diff --git a/arch/arm/mach-omap2/sleep34xx.S b/arch/arm/mach-omap2/sleep34xx.S index a31845a201e9..f75a166f0a21 100644 --- a/arch/arm/mach-omap2/sleep34xx.S +++ b/arch/arm/mach-omap2/sleep34xx.S @@ -188,12 +188,12 @@ ENTRY(omap34xx_cpu_suspend) stmfd sp!, {r0-r12, lr} @ save registers on stack /* - * r0 ...
8409d57bc342536ffe96acc7cd6c7575d98d3edb
Analyze and fix the following issue in the Linux kernel code: OMAP3: PM: Fix the MMU on sequence in the asm code
Problem Details: Add necessary barriers after enabling MMU. Also use the sane way to load pc and jump to it instead of executing ldma first up. Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com> Signed-off-by: Kevin Hilman <khilman@ti.com>
```diff diff --git a/arch/arm/mach-omap2/sleep34xx.S b/arch/arm/mach-omap2/sleep34xx.S index 1c17ee81cb12..a31845a201e9 100644 --- a/arch/arm/mach-omap2/sleep34xx.S +++ b/arch/arm/mach-omap2/sleep34xx.S @@ -617,12 +617,17 @@ usettbr0: ldr r2, cache_pred_disable_mask and r4, r2 mcr p15, 0, r4, c1, c0, 0 + dsb + is...
c34c32ea97718bb24fc06158733580003ba89211
Analyze and fix the following issue in the Linux kernel code: NFSv4.1 reclaim complete must wait for completion
Problem Details: Signed-off-by: Andy Adamson <andros@netapp.com> [Trond: fix whitespace errors] Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
```diff diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index d3c705aa71f6..0a13ae720dd0 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c @@ -5359,6 +5359,9 @@ static int nfs41_proc_reclaim_complete(struct nfs_client *clp) status = PTR_ERR(task); goto out; } + status = nfs4_wait_for_completion_rpc_task...
7d6d63d6427090cbb1d282364b65b12634ca59bd
Analyze and fix the following issue in the Linux kernel code: NFSv4.1: Retry CREATE_SESSION on NFS4ERR_DELAY
Problem Details: Fix bug where we currently retry the EXCHANGEID call again, eventhough we already have a valid clientid. Instead, delay and retry the CREATE_SESSION call. Signed-off-by: Ricardo Labiaga <Ricardo.Labiaga@netapp.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
```diff diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index b07d4e23b876..d3c705aa71f6 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c @@ -5028,10 +5028,20 @@ int nfs4_proc_create_session(struct nfs_client *clp) int status; unsigned *ptr; struct nfs4_session *session = clp->cl_session; + long timeout ...
3fa0b4e201d254b52a251fa348bd53e53000cff6
Analyze and fix the following issue in the Linux kernel code: (try3-resend) Fix nfs_compat_user_ino64 so it doesn't cause problems if bit 31 or 63 are set in fileid
Problem Details: The problem was use of an int32, which when converted to a uint64 is sign extended resulting in a fileid that doesn't fit in 32 bits even though the intent of the function is to fit the fileid into 32 bits. Signed-off-by: Frank Filz <ffilzlnx@us.ibm.com> Reviewed-by: Jeff Layton <jlayton@redhat.com> [...
```diff diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c index 1cc600e77bb4..2f8e61816d75 100644 --- a/fs/nfs/inode.c +++ b/fs/nfs/inode.c @@ -37,6 +37,7 @@ #include <linux/inet.h> #include <linux/nfs_xdr.h> #include <linux/slab.h> +#include <linux/compat.h> #include <asm/system.h> #include <asm/uaccess.h> @@ -89,7 ...
43b7c3f051dea504afccc39bcb56d8e26c2e0b77
Analyze and fix the following issue in the Linux kernel code: nfs: fix compilation warning
Problem Details: this commit fix compilation warning as following: linux-2.6/fs/nfs/nfs4proc.c:3265: warning: comparison of distinct pointer types lacks a cast Signed-off-by: Jovi Zhang <bookjovi@gmail.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
```diff diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index d1ed67145cf3..b07d4e23b876 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c @@ -3262,7 +3262,7 @@ static int buf_to_pages_noslab(const void *buf, size_t buflen, spages = pages; do { - len = min(PAGE_CACHE_SIZE, buflen); + len = min_t(size_t,...
d2224e7afbf2a6556f4f8f25bc0e96d99ec4d2bd
Analyze and fix the following issue in the Linux kernel code: nfs: close NFSv4 COMMIT vs. CLOSE race
Problem Details: I've been adding in more artificial delays in the NFSv4 commit and close codepaths to uncover races. The kernel I'm testing has the patch to close the race in __rpc_wait_for_completion_task that's in Trond's cthon2011 branch. The reproducer I've been using does this in a loop: mkdir("DIR"); fd = ope...
```diff diff --git a/fs/nfs/write.c b/fs/nfs/write.c index c8278f4046cb..42b92d7a9cc4 100644 --- a/fs/nfs/write.c +++ b/fs/nfs/write.c @@ -1292,6 +1292,8 @@ static int nfs_commit_rpcsetup(struct list_head *head, task = rpc_run_task(&task_setup_data); if (IS_ERR(task)) return PTR_ERR(task); + if (how & FLUSH_SYNC...
bf294b41cefcb22fc3139e0f42c5b3f06728bd5e
Analyze and fix the following issue in the Linux kernel code: SUNRPC: Close a race in __rpc_wait_for_completion_task()
Problem Details: Although they run as rpciod background tasks, under normal operation (i.e. no SIGKILL), functions like nfs_sillyrename(), nfs4_proc_unlck() and nfs4_do_close() want to be fully synchronous. This means that when we exit, we want all references to the rpc_task to be gone, and we want any dentry reference...
```diff diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index 1ff76acc7e98..d1ed67145cf3 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c @@ -4150,7 +4150,7 @@ static void nfs4_lock_release(void *calldata) task = nfs4_do_unlck(&data->fl, data->ctx, data->lsp, data->arg.lock_seqid); if (!IS_ERR(task)...
8e76a80960bf06c245160a484d5a363ca6b520bb
Analyze and fix the following issue in the Linux kernel code: msm: scm: Check for interruption immediately
Problem Details: When we're interrupted on the secure side, we should just issue another smc instruction again instead of replaying the arguments to smc. Fix it. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: David Brown <davidb@codeaurora.org>
```diff diff --git a/arch/arm/mach-msm/scm.c b/arch/arm/mach-msm/scm.c index 5eddf549717a..cfa808dd4897 100644 --- a/arch/arm/mach-msm/scm.c +++ b/arch/arm/mach-msm/scm.c @@ -174,15 +174,18 @@ static u32 smc(u32 cmd_addr) register u32 r0 asm("r0") = 1; register u32 r1 asm("r1") = (u32)&context_id; register u32 r2...
98d4ded60bda17a9ffecd902b03deac52922b788
Analyze and fix the following issue in the Linux kernel code: msm: scm: Fix improper register assignment
Problem Details: Assign the registers used in the inline assembly immediately before the inline assembly block. This ensures the compiler doesn't optimize away dead register assignments when it shouldn't. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Acked-by: Nicolas Pitre <nico@fluxnic.net> Signed-off-by: David...
```diff diff --git a/arch/arm/mach-msm/scm.c b/arch/arm/mach-msm/scm.c index ba57b5adf873..5eddf549717a 100644 --- a/arch/arm/mach-msm/scm.c +++ b/arch/arm/mach-msm/scm.c @@ -264,13 +264,16 @@ u32 scm_get_version(void) { int context_id; static u32 version = -1; - register u32 r0 asm("r0") = 0x1 << 8; - register u3...
a0e181167ee4254988c8c89d26ffd8ef4cb7deb0
Analyze and fix the following issue in the Linux kernel code: xen: events: fix xen_map_pirq_gsi error return
Problem Details: Fix initial value of irq so that first goto out (if pirq or gsi arguments are too large) actually returns an error. Signed-off-by: Ian Campbell <ian.campbell@citrix.com> Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
```diff diff --git a/drivers/xen/events.c b/drivers/xen/events.c index 0b27080b1918..a9c154d1d2ff 100644 --- a/drivers/xen/events.c +++ b/drivers/xen/events.c @@ -592,7 +592,7 @@ int xen_allocate_pirq(unsigned gsi, int shareable, char *name) */ int xen_map_pirq_gsi(unsigned pirq, unsigned gsi, int shareable, char *n...
ada6814c878c4d95fc8ca1402e49effbf3cc319a
Analyze and fix the following issue in the Linux kernel code: xen: events: Clean up round-robin evtchn scan.
Problem Details: Also fixes a couple of boundary cases. Signed-off-by: Keir Fraser <keir.fraser@citrix.com> Signed-off-by: Ian Campbell <ian.campbell@citrix.com> [ijc: forward ported from linux-2.6.18-xen.hg 988:c88a02a22a05] Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
```diff diff --git a/drivers/xen/events.c b/drivers/xen/events.c index 1fc3192468ef..c49cb6d6b838 100644 --- a/drivers/xen/events.c +++ b/drivers/xen/events.c @@ -1026,8 +1026,8 @@ irqreturn_t xen_debug_interrupt(int irq, void *dev_id) } static DEFINE_PER_CPU(unsigned, xed_nesting_count); -static DEFINE_PER_CPU(uns...
ab7f863e4183057dc494f3180199934a9637d401
Analyze and fix the following issue in the Linux kernel code: xen: events: Process event channels notifications in round-robin order.
Problem Details: Avoids fairness issue resulting from domain 0 processing lowest numbered event channel first. Fixes bug #1115 "Event channel port scanning unfair". Bugzilla: http://bugzilla.xensource.com/bugzilla/show_bug.cgi?id=1115 Signed-off-by: Ian Campbell <ian.campbell@citrix.com> [ijc: forward ported from lin...
```diff diff --git a/drivers/xen/events.c b/drivers/xen/events.c index 6befe6227159..75cc6f50bd29 100644 --- a/drivers/xen/events.c +++ b/drivers/xen/events.c @@ -1027,6 +1027,11 @@ irqreturn_t xen_debug_interrupt(int irq, void *dev_id) static DEFINE_PER_CPU(unsigned, xed_nesting_count); +/* + * Mask out the i lea...
260a7d4cfd26d8bad8ac3a7fce11de47491d7e00
Analyze and fix the following issue in the Linux kernel code: xen: pci: only define xen_initdom_setup_msi_irqs if CONFIG_XEN_DOM0
Problem Details: Fixes: CC arch/x86/pci/xen.o arch/x86/pci/xen.c:183: warning: 'xen_initdom_setup_msi_irqs' defined but not used Signed-off-by: Ian Campbell <ian.campbell@citrix.com> Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
```diff diff --git a/arch/x86/pci/xen.c b/arch/x86/pci/xen.c index 8634e1b49c03..47c4688dcd48 100644 --- a/arch/x86/pci/xen.c +++ b/arch/x86/pci/xen.c @@ -203,6 +203,7 @@ static void xen_teardown_msi_irq(unsigned int irq) xen_destroy_irq(irq); } +#ifdef CONFIG_XEN_DOM0 static int xen_initdom_setup_msi_irqs(struct...
76c567fbba50c3da2f4d40e2e551bab26cfd4381
Analyze and fix the following issue in the Linux kernel code: arch/tile: support 4KB page size as well as 64KB
Problem Details: The Tilera architecture traditionally supports 64KB page sizes to improve TLB utilization and improve performance when the hardware is being used primarily to run a single application. For more generic server scenarios, it can be beneficial to run with 4KB page sizes, so this commit allows that to be ...
```diff diff --git a/arch/tile/Kconfig b/arch/tile/Kconfig index eed0fc5dfe67..f3b78701c219 100644 --- a/arch/tile/Kconfig +++ b/arch/tile/Kconfig @@ -202,12 +202,6 @@ config NODES_SHIFT By default, 2, i.e. 2^2 == 4 DDR2 controllers. In a system with more controllers, this value should be raised. -# Need 16MB...
5fb682b0644cd20015d9b0e3ca6921ad5533f4ba
Analyze and fix the following issue in the Linux kernel code: arch/tile: fix some comments and whitespace
Problem Details: This is a grab bag of changes with no actual change to generated code. This includes whitespace and comment typos, plus a couple of stale comments being removed. Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
```diff diff --git a/arch/tile/Kconfig b/arch/tile/Kconfig index 9e4eb51b673f..92f7ea070b62 100644 --- a/arch/tile/Kconfig +++ b/arch/tile/Kconfig @@ -1,5 +1,5 @@ # For a description of the syntax of this configuration file, -# see Documentation/kbuild/config-language.txt. +# see Documentation/kbuild/kconfig-language....
42924355204bd83d799bd151211ae6e014982849
Analyze and fix the following issue in the Linux kernel code: omap: Fix H4 init_irq to not call h4_init_flash
Problem Details: There should be no reason to call h4_init_flash this early. It causes problems as things are not yet initialized. Tested-by: Tarun Kanti DebBarma <tarun.kanti@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
```diff diff --git a/arch/arm/mach-omap2/board-h4.c b/arch/arm/mach-omap2/board-h4.c index 7e6bf4fa1535..bac7933b8cbb 100644 --- a/arch/arm/mach-omap2/board-h4.c +++ b/arch/arm/mach-omap2/board-h4.c @@ -299,7 +299,6 @@ static void __init omap_h4_init_early(void) static void __init omap_h4_init_irq(void) { omap_init...
6f685c5cdd29649cf8cc8f57c72791159f936e07
Analyze and fix the following issue in the Linux kernel code: ARM: 6781/1: Thumb-2: Work around buggy Thumb-2 short branch relocations in gas
Problem Details: Various binutils versions can resolve Thumb-2 branches to locally-defined, preemptible global symbols as short-range "b.n" branch instructions. This is a problem, because there's no guarantee the final destination of the symbol, or any candidate locations for a trampoline, are within range of the bran...
```diff diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 2fec7073f687..f871f2e1dd7c 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -1379,6 +1379,37 @@ config THUMB2_KERNEL If unsure, say N. +config THUMB2_AVOID_R_ARM_THM_JUMP11 + bool "Work around buggy Thumb-2 short branch relocations in gas" + ...
ebbeb3d6aa22433c218da6f29fd7b3ebc89b87ea
Analyze and fix the following issue in the Linux kernel code: ALSA: HDA: Fix volume control naming for surround speakers on Realtek auto-parser
Problem Details: When more than one pair of internal speakers is present, allow names according to their channels. Tested-by: Bartłomiej Żogała <nusch88@gmail.com> Cc: <stable@kernel.org> Signed-off-by: David Henningsson <david.henningsson@canonical.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
```diff diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index b4a22dd775a2..6f59bccb104c 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c @@ -5080,7 +5080,9 @@ static const char *alc_get_line_out_pfx(const struct auto_pin_cfg *cfg, switch (cfg->line_out_type)...
32eea3884debb65ec1da633bc5df5aee23879865
Analyze and fix the following issue in the Linux kernel code: ALSA: HDA: Enable surround and subwoofer on Lenovo Ideapad Y530
Problem Details: The pin config values would change the association instead of the sequence, this commit fixes that up. Tested-by: Bartłomiej Żogała <nusch88@gmail.com> Cc: <stable@kernel.org> Signed-off-by: David Henningsson <david.henningsson@canonical.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
```diff diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index f6c344126b83..b4a22dd775a2 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c @@ -10677,6 +10677,7 @@ static struct alc_config_preset alc882_presets[] = { */ enum { PINFIX_ABIT_AW9D_MAX, + PINFIX_LE...
7e6b6465e6efbca3985258996be9c189da96c8bf
Analyze and fix the following issue in the Linux kernel code: btrfs: fix not enough reserved space
Problem Details: btrfs_link() will insert 3 items(inode ref, dir name item and dir index item) into the b+ tree and update 2 items(its inode, and parent's inode) in the b+ tree. So we should reserve space for these 5 items, not 3 items. Reported-by: Tsutomu Itoh <t-itoh@jp.fujitsu.com> Signed-off-by: Miao Xie <miaox@c...
```diff diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c index e7a8303328b2..db67821ccac2 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c @@ -4823,10 +4823,11 @@ static int btrfs_link(struct dentry *old_dentry, struct inode *dir, goto fail; /* - * 1 item for inode ref + * 2 items for inode and inode ref ...
b4966b7770349deb05e3dd2bd2c65d2d044abbbb
Analyze and fix the following issue in the Linux kernel code: btrfs: fix dip leak
Problem Details: The btrfs DIO code leaks dip structs when dip->csums allocation fails; bio->bi_end_io isn't set at the point where the free_ordered branch is consequently taken, thus bio_endio doesn't call the function which would free it in the normal case. Fix. Signed-off-by: Daniel J Blueman <daniel.blueman@gmail....
```diff diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c index 44b926646e33..e7a8303328b2 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c @@ -6058,6 +6058,7 @@ static void btrfs_submit_direct(int rw, struct bio *bio, struct inode *inode, if (!skip_sum) { dip->csums = kmalloc(sizeof(u32) * bio->bi_vcnt, GFP_NO...
bc3a8a01def4fb0ec0ef8a20d097277b9c6b2a1f
Analyze and fix the following issue in the Linux kernel code: ALSA: usb-audio - Add "cval->res = 384" quirk for Logitech Webcam C600
Problem Details: One more affected devices: Logitech Webcam C600 (046d:0808) Volume range before quirk is 6400, after (also real) is 16. Signed-off-by: Alexey Fisher <bug-track@fisher-privat.net> Signed-off-by: Takashi Iwai <tiwai@suse.de>
```diff diff --git a/sound/usb/mixer.c b/sound/usb/mixer.c index 3e3116c5bc52..844cf786e81c 100644 --- a/sound/usb/mixer.c +++ b/sound/usb/mixer.c @@ -1122,6 +1122,7 @@ static void build_feature_ctl(struct mixer_build *state, void *raw_desc, } break; + case USB_ID(0x046d, 0x0808): case USB_ID(0x046d, 0x0809):...
80acefff3bc7bd53d46c16c683ab66c0ece20810
Analyze and fix the following issue in the Linux kernel code: ALSA: usb-audio - Add volume range check and warn if it too big
Problem Details: Signed-off-by: Alexey Fisher <bug-track@fisher-privat.net> Signed-off-by: Takashi Iwai <tiwai@suse.de>
```diff diff --git a/sound/usb/mixer.c b/sound/usb/mixer.c index 7df89b3d7ded..3e3116c5bc52 100644 --- a/sound/usb/mixer.c +++ b/sound/usb/mixer.c @@ -987,6 +987,7 @@ static void build_feature_ctl(struct mixer_build *state, void *raw_desc, struct snd_kcontrol *kctl; struct usb_mixer_elem_info *cval; const struct ...
4a0b1665db09cf2da9ad7d0f12da386373c10bfa
Analyze and fix the following issue in the Linux kernel code: tracing: Fix irqoff selftest expanding max buffer
Problem Details: If the kernel command line declares a tracer "ftrace=sometracer" and that tracer is either not defined or is enabled after irqsoff, then the irqs off selftest will fail with the following error: Testing tracer irqsoff: ------------[ cut here ]------------ WARNING: at /home/rostedt/work/autotest/noback...
```diff diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c index fd6e1b906b3c..9541c27c1cf2 100644 --- a/kernel/trace/trace.c +++ b/kernel/trace/trace.c @@ -779,6 +779,11 @@ __acquires(kernel_lock) tracing_reset_online_cpus(tr); current_trace = type; + + /* If we expanded the buffers, make sure the max i...
31274d72f01604f4b02d933b4f3cac84d2c201fd
Analyze and fix the following issue in the Linux kernel code: tracing: Explain about unstable clock on resume with ring buffer warning
Problem Details: The "Delta way too big" warning might appear on a system with a unstable shed clock right after the system is resumed and tracing was enabled at time of suspend. Since it's not realy a bug, and the unstable sched clock is working fast and reliable otherwise, Steven suggested to keep using the sched cl...
```diff diff --git a/kernel/trace/ring_buffer.c b/kernel/trace/ring_buffer.c index 3237d961d905..db7b439d23ee 100644 --- a/kernel/trace/ring_buffer.c +++ b/kernel/trace/ring_buffer.c @@ -2172,11 +2172,19 @@ rb_reserve_next_event(struct ring_buffer *buffer, if (likely(ts >= cpu_buffer->write_stamp)) { delta = diff;...
ca9da2dd63b0b32de1b693953dff66cadeb6400b
Analyze and fix the following issue in the Linux kernel code: tracing: Fix event alignment: skb:kfree_skb
Problem Details: Acked-by: Neil Horman <nhorman@tuxdriver.com> Signed-off-by: David Sharp <dhsharp@google.com> LKML-Reference: <1291421609-14665-10-git-send-email-dhsharp@google.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
```diff diff --git a/include/trace/events/skb.h b/include/trace/events/skb.h index f10293c41b1e..0c68ae22da22 100644 --- a/include/trace/events/skb.h +++ b/include/trace/events/skb.h @@ -19,14 +19,14 @@ TRACE_EVENT(kfree_skb, TP_STRUCT__entry( __field( void *, skbaddr ) - __field( unsigned short, protocol ) ...
ad440ad66f1617194738bf674dfe2d38978ac54d
Analyze and fix the following issue in the Linux kernel code: tracing: Fix event alignment: mce:mce_record
Problem Details: Signed-off-by: David Sharp <dhsharp@google.com> LKML-Reference: <1291421609-14665-9-git-send-email-dhsharp@google.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
```diff diff --git a/include/trace/events/mce.h b/include/trace/events/mce.h index 7eee77895cb3..4cbbcef6baa8 100644 --- a/include/trace/events/mce.h +++ b/include/trace/events/mce.h @@ -17,36 +17,36 @@ TRACE_EVENT(mce_record, TP_STRUCT__entry( __field( u64, mcgcap ) __field( u64, mcgstatus ) - __field( u8,...
d5bf2ff07230a4a1b73ecb22363f77c02e1d85ab
Analyze and fix the following issue in the Linux kernel code: tracing: Fix event alignment: kvm:kvm_hv_hypercall
Problem Details: Acked-by: Avi Kivity <avi@redhat.com> Signed-off-by: David Sharp <dhsharp@google.com> LKML-Reference: <1291421609-14665-8-git-send-email-dhsharp@google.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
```diff diff --git a/arch/x86/kvm/trace.h b/arch/x86/kvm/trace.h index 1357d7cf4ec8..db932760ea82 100644 --- a/arch/x86/kvm/trace.h +++ b/arch/x86/kvm/trace.h @@ -62,21 +62,21 @@ TRACE_EVENT(kvm_hv_hypercall, TP_ARGS(code, fast, rep_cnt, rep_idx, ingpa, outgpa), TP_STRUCT__entry( - __field( __u16, code ) - _...
b5e3008e489f5a00c6d5db914a4c4338c9ef5e8b
Analyze and fix the following issue in the Linux kernel code: tracing: Fix event alignment: module:module_request
Problem Details: Acked-by: Li Zefan <lizf@cn.fujitsu.com> Signed-off-by: David Sharp <dhsharp@google.com> LKML-Reference: <1291421609-14665-7-git-send-email-dhsharp@google.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
```diff diff --git a/include/trace/events/module.h b/include/trace/events/module.h index c6bae36547e5..21a546d27c0c 100644 --- a/include/trace/events/module.h +++ b/include/trace/events/module.h @@ -108,14 +108,14 @@ TRACE_EVENT(module_request, TP_ARGS(name, wait, ip), TP_STRUCT__entry( - __field( bool, wait )...
140e4f2d1cd816aed196705c036763313c0e4bd3
Analyze and fix the following issue in the Linux kernel code: tracing: Fix event alignment: ftrace:context_switch and ftrace:wakeup
Problem Details: Signed-off-by: David Sharp <dhsharp@google.com> LKML-Reference: <1291421609-14665-6-git-send-email-dhsharp@google.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
```diff diff --git a/kernel/trace/trace_entries.h b/kernel/trace/trace_entries.h index 6cf223764be8..1516cb3ec549 100644 --- a/kernel/trace/trace_entries.h +++ b/kernel/trace/trace_entries.h @@ -109,12 +109,12 @@ FTRACE_ENTRY(funcgraph_exit, ftrace_graph_ret_entry, */ #define FTRACE_CTX_FIELDS \ __field( unsig...
23bfdacf4eb525ff3404161429cedaa281c23e47
Analyze and fix the following issue in the Linux kernel code: ARM: 6798/1: aout-core: zero thread debug registers in a.out core dump
Problem Details: The removal of the single-step emulation from ptrace on ARM means that thread_struct no longer has software breakpoint fields in its debug member. This patch fixes the a.out core dump code so that the debug registers are zeroed rather than trying to copy from non-existent fields. Cc: Nicolas Pitre <n...
```diff diff --git a/arch/arm/include/asm/a.out-core.h b/arch/arm/include/asm/a.out-core.h index 93d04acaa31f..92f10cb5c70c 100644 --- a/arch/arm/include/asm/a.out-core.h +++ b/arch/arm/include/asm/a.out-core.h @@ -32,11 +32,7 @@ static inline void aout_dump_thread(struct pt_regs *regs, struct user *dump) dump->u_dsi...
b9a46bba88001504235459c8410f17e6a7e38008
Analyze and fix the following issue in the Linux kernel code: perf top: Fix events overflow in top command
Problem Details: The snprintf function returns number of printed characters even if it cross the size parameter. So passing enough events via '-e' parameter will cause segmentation fault. It's reproduced by following command: perf top -e `perf list | grep Tracepoint | awk -F'[' '\ {gsub(/[[:space:]]+/,"",$1);array[FN...
```diff diff --git a/tools/perf/util/top.c b/tools/perf/util/top.c index 70a9c13f4ad5..4f869da4e9c7 100644 --- a/tools/perf/util/top.c +++ b/tools/perf/util/top.c @@ -61,6 +61,12 @@ static void rb_insert_active_sym(struct rb_root *tree, struct sym_entry *se) rb_insert_color(&se->rb_node, tree); } +#define SNPRINTF...
bb0a80e394b512028ad6cf4c86157d4f9db5aab8
Analyze and fix the following issue in the Linux kernel code: mx51 enchance the sd/mmc HW timing compatibility on mx51 boards.
Problem Details: Some cards have the CRC errors in read on mx51 BBG board. Configure the eSDHC pad configurations to level up the compatibility to fix this issue. Signed-off-by: Richard Zhu <Hong-Xing.Zhu@freescale.com> Tested-by: Shawn Guo <shawn.guo@freescale.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
```diff diff --git a/arch/arm/plat-mxc/include/mach/iomux-mx51.h b/arch/arm/plat-mxc/include/mach/iomux-mx51.h index 6056cf2cd006..df6acc066fb1 100644 --- a/arch/arm/plat-mxc/include/mach/iomux-mx51.h +++ b/arch/arm/plat-mxc/include/mach/iomux-mx51.h @@ -985,11 +985,11 @@ #define MX51_PAD_NANDF_WE_B__GPIO3_3 (_MX51_P...
e636db5b956950b8b9bfbeb766a637f84bae1e3b
Analyze and fix the following issue in the Linux kernel code: drbd: fix potential imbalance of ap_in_flight
Problem Details: When we receive a barrier ack, we walk the ring list of drbd requests in the transfer log of the respective epoch, do some housekeeping, and free those objects. We tried to keep epochs of mirrored and unmirrored drbd requests separate, and assert that no local-only requests are present in a barrier_ac...
```diff diff --git a/drivers/block/drbd/drbd_main.c b/drivers/block/drbd/drbd_main.c index c3760f33d52c..9043772de400 100644 --- a/drivers/block/drbd/drbd_main.c +++ b/drivers/block/drbd/drbd_main.c @@ -337,23 +337,6 @@ bail: } -/* In C_AHEAD mode only out_of_sync packets are sent for requests. Detach - * those re...
725a97e43ee945cc813fffd9e628e50d703b973b
Analyze and fix the following issue in the Linux kernel code: drbd: fix potential access of on-stack wait_queue_head_t after return
Problem Details: I run into something declaring itself as "spinlock deadlock", BUG: spinlock lockup on CPU#1, kjournald/27816, ffff88000ad6bca0 Pid: 27816, comm: kjournald Tainted: G W 2.6.34.6 #2 Call Trace: <IRQ> [<ffffffff811ba0aa>] do_raw_spin_lock+0x11e/0x14d [<ffffffff81340fde>] _raw_spin_lock_irqs...
```diff diff --git a/drivers/block/drbd/drbd_bitmap.c b/drivers/block/drbd/drbd_bitmap.c index 314a3632303b..25428bc28476 100644 --- a/drivers/block/drbd/drbd_bitmap.c +++ b/drivers/block/drbd/drbd_bitmap.c @@ -897,7 +897,7 @@ void drbd_bm_clear_all(struct drbd_conf *mdev) struct bm_aio_ctx { struct drbd_conf *mdev;...
418e0a927d520f9c8e875ea75abee35d93a0f1b3
Analyze and fix the following issue in the Linux kernel code: drbd: spelling fix in log message
Problem Details: Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com> Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
```diff diff --git a/drivers/block/drbd/drbd_main.c b/drivers/block/drbd/drbd_main.c index 2190064d59bd..f529c25e1ad5 100644 --- a/drivers/block/drbd/drbd_main.c +++ b/drivers/block/drbd/drbd_main.c @@ -1351,7 +1351,7 @@ static void after_state_ch(struct drbd_conf *mdev, union drbd_state os, if (ns.conn == C_CONNEC...
2265b473aecc1a6fe1f84a0ee272ba39806c2a8a
Analyze and fix the following issue in the Linux kernel code: drbd: fix potential dereference of NULL pointer
Problem Details: If drbd used to have crypto digest algorithms configured, then is being unconfigured (but not unloaded), it frees the algorithms, but does not reset the config. If it then is reconfigured to use the very same algorithm, it "forgot" to re-allocate the algorithms, thinking that the config has not change...
```diff diff --git a/drivers/block/drbd/drbd_main.c b/drivers/block/drbd/drbd_main.c index c6c7e3e6dc23..4da6f11cc82e 100644 --- a/drivers/block/drbd/drbd_main.c +++ b/drivers/block/drbd/drbd_main.c @@ -3020,6 +3020,8 @@ void drbd_mdev_cleanup(struct drbd_conf *mdev) D_ASSERT(list_empty(&mdev->resync_work.list)); D...
84e7c0f7d123d64d97e1f789ad2f23a72fe8981f
Analyze and fix the following issue in the Linux kernel code: drbd: Removed a reference to debug macros removed long time ago
Problem Details: Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com> Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
```diff diff --git a/drivers/block/drbd/drbd_bitmap.c b/drivers/block/drbd/drbd_bitmap.c index 09d208b858e7..423dede45844 100644 --- a/drivers/block/drbd/drbd_bitmap.c +++ b/drivers/block/drbd/drbd_bitmap.c @@ -596,9 +596,8 @@ static void bm_memset(struct drbd_bitmap *b, size_t offset, int c, size_t len) if (bm+do_n...
6850c4421481139dc2cf982358e79c833a50d73c
Analyze and fix the following issue in the Linux kernel code: drbd: get rid of unused debug code
Problem Details: Long time ago, we had paranoia code in the bitmap that allocated one extra word, assigned a magic value, and checked on every occasion that the magic value was still unchanged. That debug code is unused, the extra long word complicates code a bit. Get rid of it. Signed-off-by: Philipp Reisner <philip...
```diff diff --git a/drivers/block/drbd/drbd_bitmap.c b/drivers/block/drbd/drbd_bitmap.c index 0e31e573af72..09d208b858e7 100644 --- a/drivers/block/drbd/drbd_bitmap.c +++ b/drivers/block/drbd/drbd_bitmap.c @@ -488,10 +488,7 @@ static int bm_clear_surplus(struct drbd_bitmap *b) * on disk and in core memory alike */ ...