id
stringlengths
40
40
instruction
stringlengths
68
308
input
stringlengths
17
33.4k
output
stringlengths
100
30k
98aed9fd0104ef2d8e6b5154c9713e0e27e5f9c8
Analyze and fix the following issue in the Linux kernel code: mac80211: fix mesh TX coding style
Problem Details: Fix bad indentation & pointless if nesting. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
```diff diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c index da2447a7bade..82389adbe582 100644 --- a/net/mac80211/tx.c +++ b/net/mac80211/tx.c @@ -1467,12 +1467,12 @@ void ieee80211_xmit(struct ieee80211_sub_if_data *sdata, struct sk_buff *skb) if (ieee80211_vif_is_mesh(&sdata->vif) && ieee80211_is_data(h...
a75e2ad772b6c26efd702f04be1f9a6414d24f22
Analyze and fix the following issue in the Linux kernel code: rtlwifi: Add missing DMA buffer unmapping for PCI drivers
Problem Details: In https://bugzilla.kernel.org/show_bug.cgi?id=42976, a system with driver rtl8192se used as an AP suffers from "Out of SW-IOMMU space" errors. These are caused by the DMA buffers used for beacons never being unmapped. This bug was also reported at https://bugs.launchpad.net/ubuntu/+source/linux/+bug/...
```diff diff --git a/drivers/net/wireless/rtlwifi/pci.c b/drivers/net/wireless/rtlwifi/pci.c index 07dd38efe62a..288b035a3579 100644 --- a/drivers/net/wireless/rtlwifi/pci.c +++ b/drivers/net/wireless/rtlwifi/pci.c @@ -912,8 +912,13 @@ static void _rtl_pci_prepare_bcn_tasklet(struct ieee80211_hw *hw) memset(&tcb_desc...
69b8797fc4a926bf5b895a39b84daddc7eebcd09
Analyze and fix the following issue in the Linux kernel code: iwlwifi: Add pr_fmt
Problem Details: Prefix dmesg output with "iwlwifi: " by adding #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
```diff diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.c b/drivers/net/wireless/iwlwifi/iwl-agn.c index 94af564bb53f..22c953d65be5 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn.c @@ -26,6 +26,9 @@ * Intel Corporation, 5200 N.E. Elam Young Parkway, Hillsboro, OR 9712...
a855f7ee64fedbe831859d53b20650c2224afecc
Analyze and fix the following issue in the Linux kernel code: iwlwifi: fix unused variable warning
Problem Details: In the case of disabled CONFIG_IWLWIFI_DEBUGFS option the compiler complains about the unused variable 'img'. Fix this by moving the 'img' definition. Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net> Acked-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: John W. Linville <linville@tuxdriv...
```diff diff --git a/drivers/net/wireless/iwlwifi/iwl-mac80211.c b/drivers/net/wireless/iwlwifi/iwl-mac80211.c index 551db9eec884..f1c675a2a6f3 100644 --- a/drivers/net/wireless/iwlwifi/iwl-mac80211.c +++ b/drivers/net/wireless/iwlwifi/iwl-mac80211.c @@ -438,7 +438,6 @@ static int iwlagn_mac_resume(struct ieee80211_hw ...
18a223e0b9ec8979320ba364b47c9772391d6d05
Analyze and fix the following issue in the Linux kernel code: tcp: fix tcp_rcv_rtt_update() use of an unscaled RTT sample
Problem Details: Fix a code path in tcp_rcv_rtt_update() that was comparing scaled and unscaled RTT samples. The intent in the code was to only use the 'm' measurement if it was a new minimum. However, since 'm' had not yet been shifted left 3 bits but 'new_sample' had, this comparison would nearly always succeed, le...
```diff diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c index e886e2f7fa8d..e7b54d29690e 100644 --- a/net/ipv4/tcp_input.c +++ b/net/ipv4/tcp_input.c @@ -474,8 +474,11 @@ static void tcp_rcv_rtt_update(struct tcp_sock *tp, u32 sample, int win_dep) if (!win_dep) { m -= (new_sample >> 3); new_sample +...
004ac38859c5bbcc4ffccc37d33be5e467d61c28
Analyze and fix the following issue in the Linux kernel code: [media] [3.3.0] ir-raw: remove BUG_ON in ir_raw_event_thread
Problem Details: This patch removes BUG_ON in ir_raw_event_thread which IMO is a over-kill, and this kills the ir_raw_event_thread too. With a bit of additional logic in this patch, we nomore need to kill this thread. Other disadvantage of having a BUG-ON is, wake_up_process(dev->raw->thread) called on dead thread via ...
```diff diff --git a/drivers/media/rc/ir-raw.c b/drivers/media/rc/ir-raw.c index 95e630998aaf..a82025121345 100644 --- a/drivers/media/rc/ir-raw.c +++ b/drivers/media/rc/ir-raw.c @@ -46,9 +46,9 @@ static int ir_raw_event_thread(void *data) while (!kthread_should_stop()) { spin_lock_irq(&raw->lock); - retval = k...
5fb84b1428b271f8767e0eb3fcd7231896edfaa4
Analyze and fix the following issue in the Linux kernel code: tcp: restore correct limit
Problem Details: Commit c43b874d5d714f (tcp: properly initialize tcp memory limits) tried to fix a regression added in commits 4acb4190 & 3dc43e3, but still get it wrong. Result is machines with low amount of memory have too small tcp_rmem[2] value and slow tcp receives : Per socket limit being 1/1024 of memory instea...
```diff diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c index 5d54ed30e821..7758a83f98ff 100644 --- a/net/ipv4/tcp.c +++ b/net/ipv4/tcp.c @@ -3302,8 +3302,7 @@ void __init tcp_init(void) tcp_init_mem(&init_net); /* Set per-socket limits to no more than 1/128 the pressure threshold */ - limit = nr_free_buffer_pages()...
3e6be97ebbb0b45bb834670a45b343383d6de97f
Analyze and fix the following issue in the Linux kernel code: staging: comedi: amplc_pc263: separately configure ISA and PCI
Problem Details: The amplc_pc263 driver supports both ISA and PCI cards, but currently it is only possible to select the driver if PCI is configured. This patch splits the configuration to make the ISA and PCI parts seperately selectable, and changes the driver to only include the selected ISA and/or PCI board types. ...
```diff diff --git a/drivers/staging/comedi/Kconfig b/drivers/staging/comedi/Kconfig index df6eb2a9b94f..391a713ff2b5 100644 --- a/drivers/staging/comedi/Kconfig +++ b/drivers/staging/comedi/Kconfig @@ -233,6 +233,16 @@ config COMEDI_AMPLC_PC236_ISA To compile this driver as a module, choose M here: the module will...
011afa1ed8c408d694957d2474d89dc81a60b70c
Analyze and fix the following issue in the Linux kernel code: Revert "ath9k: fix going to full-sleep on PS idle"
Problem Details: This reverts commit c1afdaff90538ef085b756454f12b29575411214. Users have reported connection failures in 3.3.1 and suspend/resume failures in 3.4-rcX. Revert this commit for now - PS IDLE can be fixed in a clean manner later on. Cc: stable@vger.kernel.org Signed-off-by: Sujith Manoharan <c_manoha@qca...
```diff diff --git a/drivers/net/wireless/ath/ath9k/main.c b/drivers/net/wireless/ath/ath9k/main.c index 215eb2536b1e..2504ab005589 100644 --- a/drivers/net/wireless/ath/ath9k/main.c +++ b/drivers/net/wireless/ath/ath9k/main.c @@ -118,15 +118,13 @@ void ath9k_ps_restore(struct ath_softc *sc) if (--sc->ps_usecount != ...
e2bc7c5f3cb8756865aa0ab140d2288f61599dda
Analyze and fix the following issue in the Linux kernel code: rt2x00: Fix rfkill_polling register function.
Problem Details: Move rt2x00rfkill_register(rt2x00dev) to rt2x00lib_probe_dev function. It fixes of starting rfkill_poll function at the right time if sets hard rfkill block and reboot. rt2x00mac_rfkill_poll should be starting before bringing up the wireless interface. Signed-off-by: Chen, Chien-Chia <machen@sus...
```diff diff --git a/drivers/net/wireless/rt2x00/rt2x00dev.c b/drivers/net/wireless/rt2x00/rt2x00dev.c index fc9901e027c1..90cc5e772650 100644 --- a/drivers/net/wireless/rt2x00/rt2x00dev.c +++ b/drivers/net/wireless/rt2x00/rt2x00dev.c @@ -1062,11 +1062,6 @@ static int rt2x00lib_initialize(struct rt2x00_dev *rt2x00dev) ...
58f743ee06d400a887a3e30353c69c3151eb64df
Analyze and fix the following issue in the Linux kernel code: bcma: fix build error on MIPS; implicit pcibios_enable_device
Problem Details: The following is seen during allmodconfig builds for MIPS: drivers/bcma/driver_pci_host.c:518:2: error: implicit declaration of function 'pcibios_enable_device' [-Werror=implicit-function-declaration] cc1: some warnings being treated as errors make[3]: *** [drivers/bcma/driver_pci_host.o] Error 1 Mos...
```diff diff --git a/drivers/bcma/Kconfig b/drivers/bcma/Kconfig index c1172dafdffa..fb7c80fb721e 100644 --- a/drivers/bcma/Kconfig +++ b/drivers/bcma/Kconfig @@ -29,7 +29,7 @@ config BCMA_HOST_PCI config BCMA_DRIVER_PCI_HOSTMODE bool "Driver for PCI core working in hostmode" - depends on BCMA && MIPS + depends on...
c5a766ceb497078459115fcbd1412917083aa4a5
Analyze and fix the following issue in the Linux kernel code: [media] v4l: vdev_to_v4l2_subdev() should have return type "struct v4l2_subdev *"
Problem Details: vdev_to_v4l2_subdev() should return struct v4l2_subdev *, not void *. Fix this. Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/include/media/v4l2-subdev.h b/include/media/v4l2-subdev.h index feab950bc8ab..bcaf6b80bb20 100644 --- a/include/media/v4l2-subdev.h +++ b/include/media/v4l2-subdev.h @@ -545,7 +545,7 @@ struct v4l2_subdev { #define media_entity_to_v4l2_subdev(ent) \ container_of(ent, struct v4l2_subdev, entity) ...
59b2bbb614ca1bd934bb0e5c615a0849d11d8858
Analyze and fix the following issue in the Linux kernel code: Staging: bcm: IPv6Protocol.c: coding style fix
Problem Details: Eighth patch in a series to fix coding style in IPv6Protocol.c This patch removes some uneeded braces around single line if/for statements Signed-off-by: Max Tottenham <mtottenh@gmail.com> Acked-by: Kevin McKinney <klmckinney1@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/bcm/IPv6Protocol.c b/drivers/staging/bcm/IPv6Protocol.c index d9c9cef2d172..1da21642c18e 100644 --- a/drivers/staging/bcm/IPv6Protocol.c +++ b/drivers/staging/bcm/IPv6Protocol.c @@ -149,9 +149,8 @@ static UCHAR GetIpv6ProtocolPorts(UCHAR *pucPayload, USHORT *pusSrcPort, UCHAR *puc...
6704fc83cb0db017d840eb5a6ca6326a44399eb2
Analyze and fix the following issue in the Linux kernel code: Staging: bcm: IPv6Protocol.c: coding style fix
Problem Details: Seventh patch in a series of patches to fix coding style in IPv6Protocol.c this patch makes the file mostly conform to the 80 char line limit there are some exceptions to this rule I have left in to aid readability Signed-off-by: Max Tottenham <mtottenh@gmail.com> Acked-by: Kevin McKinney <klmckinney1...
```diff diff --git a/drivers/staging/bcm/IPv6Protocol.c b/drivers/staging/bcm/IPv6Protocol.c index 0f87119b452a..d9c9cef2d172 100644 --- a/drivers/staging/bcm/IPv6Protocol.c +++ b/drivers/staging/bcm/IPv6Protocol.c @@ -1,10 +1,13 @@ #include "headers.h" -static BOOLEAN MatchSrcIpv6Address(S_CLASSIFIER_RULE *pstClass...
6d147069346f99482bd9c417dec7fd4ce50d266a
Analyze and fix the following issue in the Linux kernel code: Staging: bcm: IPv6Protocol.c coding style fix
Problem Details: Sixth in a series of patche to fix coding style in IPv6Protocol.c This patch changes the format of if statments from: if (#VALUE == variable) to: if (variable == #VALUE) Signed-off-by: Max Tottenham <mtottenh@gmail.com> Acked-by: Kevin McKinney <klmckinney1@gmail.com> Signed-off-by: Greg Kroah-Hartm...
```diff diff --git a/drivers/staging/bcm/IPv6Protocol.c b/drivers/staging/bcm/IPv6Protocol.c index 80173e7a5716..0f87119b452a 100644 --- a/drivers/staging/bcm/IPv6Protocol.c +++ b/drivers/staging/bcm/IPv6Protocol.c @@ -11,7 +11,7 @@ static UCHAR *GetNextIPV6ChainedHeader(UCHAR **ppucPayload, UCHAR *pucNextHeader USHO...
aadb4ec271ee73b39031acb8a201f96e56d1cbf1
Analyze and fix the following issue in the Linux kernel code: Staging: bcm: IPv6Protocol.c coding style fix
Problem Details: Fith in a series of patche to fi coding syle in IPv6Protocol.c Fixed trailing whitespaces and replaced spaces with tabs in code indents Signed-off-by: Max Tottenham <mtottenh@gmail.com> Acked-by: Kevin McKinney <klmckinney1@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/bcm/IPv6Protocol.c b/drivers/staging/bcm/IPv6Protocol.c index 7bc1dc29e8ed..80173e7a5716 100644 --- a/drivers/staging/bcm/IPv6Protocol.c +++ b/drivers/staging/bcm/IPv6Protocol.c @@ -4,7 +4,7 @@ static BOOLEAN MatchSrcIpv6Address(S_CLASSIFIER_RULE *pstClassifierRule, IPV6Hea static ...
fac290a11694efff330c96041a7a88579c5cf8f2
Analyze and fix the following issue in the Linux kernel code: Staging: bcm: IPv6Protocol.c coding style fix
Problem Details: Fourth patch in a series of patches to fix coding style in IPv6Protocol.c Continuation of fixing spacing arount ',' Signed-off-by: Max Tottenham <mtottenh@gmail.com> Acked-by: Kevin McKinney <klmckinney1@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/bcm/IPv6Protocol.c b/drivers/staging/bcm/IPv6Protocol.c index 6bb949c68b39..7bc1dc29e8ed 100644 --- a/drivers/staging/bcm/IPv6Protocol.c +++ b/drivers/staging/bcm/IPv6Protocol.c @@ -34,7 +34,7 @@ static UCHAR * GetNextIPV6ChainedHeader(UCHAR **ppucPayload, UCHAR *pucNextHeade { ...
07ed6b7f0e574bcc5e77f247044727234e9eb092
Analyze and fix the following issue in the Linux kernel code: Staging: bcm: IPv6Protocol.c fix coding style
Problem Details: Third in a series of patches to fix coding style in Ipv6Protocol.c This patch fixes the spacing around ',' in function calls. Signed-off-by: Max Tottenham <mtottenh@gmail.com> Acked-by: Kevin McKinney <klmckinney1@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/bcm/IPv6Protocol.c b/drivers/staging/bcm/IPv6Protocol.c index de513bcab6b2..6bb949c68b39 100644 --- a/drivers/staging/bcm/IPv6Protocol.c +++ b/drivers/staging/bcm/IPv6Protocol.c @@ -1,10 +1,10 @@ #include "headers.h" -static BOOLEAN MatchSrcIpv6Address(S_CLASSIFIER_RULE *pstClass...
ac8c1003fb74d41c7181304d12515bb7104b7772
Analyze and fix the following issue in the Linux kernel code: Staging: bcm: IPv6Protocol.c coding style fix
Problem Details: Second in a set of patches to fix coding style in IPv6Protocol.c This patch changes the commenting style Signed-off-by: Max Tottenham <mtottenh@gmail.com> Acked-by: Kevin McKinney <klmckinney1@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/bcm/IPv6Protocol.c b/drivers/staging/bcm/IPv6Protocol.c index cd5f1c35ae4b..de513bcab6b2 100644 --- a/drivers/staging/bcm/IPv6Protocol.c +++ b/drivers/staging/bcm/IPv6Protocol.c @@ -25,7 +25,7 @@ static UCHAR * GetNextIPV6ChainedHeader(UCHAR **ppucPayload,UCHAR *pucNextHeader ret...
26908c9be1386f01a12852cc6bea78bd237f226e
Analyze and fix the following issue in the Linux kernel code: Staging: bcm: IPv6Protocol.c: Fix coding style
Problem Details: The first in a series of 8 patches to fix IPv6Protocol.c This first patch fixes formatting issues for braced statements (e.g. if/for/while) Signed-off-by: Max Tottenham <mtottenh@gmail.com> Acked-by: Kevin McKinney <klmckinney1@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/bcm/IPv6Protocol.c b/drivers/staging/bcm/IPv6Protocol.c index 5b4fd372ec36..cd5f1c35ae4b 100644 --- a/drivers/staging/bcm/IPv6Protocol.c +++ b/drivers/staging/bcm/IPv6Protocol.c @@ -9,20 +9,18 @@ static UCHAR * GetNextIPV6ChainedHeader(UCHAR **ppucPayload,UCHAR *pucNextHeader UCHA...
d740e889d2a49b48a4527b5192dea9278e691d6f
Analyze and fix the following issue in the Linux kernel code: staging:ramster Fix typos in staging:ramster
Problem Details: The below patch fixes some typos that I found while reading. Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/ramster/cluster/tcp.c b/drivers/staging/ramster/cluster/tcp.c index 3af1b2c51b78..3490192f8ca2 100644 --- a/drivers/staging/ramster/cluster/tcp.c +++ b/drivers/staging/ramster/cluster/tcp.c @@ -111,7 +111,7 @@ static struct socket *r2net_listen_sock; * r2net_wq. teardown detaches...
6354eb81fe8cc32899959d2dac23aa1c9a12c9fa
Analyze and fix the following issue in the Linux kernel code: staging:omapdrm Fix typos in drivers:omapdrm
Problem Details: The below patch fixes some typos that I found while reading. Note: I was told to hold off sending anything until *rc1 so hopefully now its alright.(wasnt sure what kernel *rc*) Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Reviewed-by: Rob Clark <rob@ti.com> Signed-off-by: Greg Kroah-Har...
```diff diff --git a/drivers/staging/omapdrm/omap_fb.c b/drivers/staging/omapdrm/omap_fb.c index 04b235b6724a..0c53a3c313ff 100644 --- a/drivers/staging/omapdrm/omap_fb.c +++ b/drivers/staging/omapdrm/omap_fb.c @@ -167,7 +167,7 @@ void omap_framebuffer_update_scanout(struct drm_framebuffer *fb, int x, int y, } /* C...
73e2918990c0d0ba7866696d492a8090e4f9f396
Analyze and fix the following issue in the Linux kernel code: staging: Fix typo in multiple files
Problem Details: Collect spelling typo in multiple files within staging directory. Signed-off-by: Masanari Iida <standby24x7@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/bcm/Misc.c b/drivers/staging/bcm/Misc.c index c7725e141fd5..8223a6913fc5 100644 --- a/drivers/staging/bcm/Misc.c +++ b/drivers/staging/bcm/Misc.c @@ -835,7 +835,7 @@ int reset_card_proc(PMINI_ADAPTER ps_adapter) Bcm_kill_all_URBs(psIntfAdapter); /* Reset the UMA-B Device */ if...
73e18893ddf8d2c8cf319ff3d11a5aa75db5d5f8
Analyze and fix the following issue in the Linux kernel code: staging: Fix typo in wlags49_h2
Problem Details: Correct spellings within wlags49_h2 Signed-off-by: Masanari Iida <standby24x7@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/wlags49_h2/README.ubuntu b/drivers/staging/wlags49_h2/README.ubuntu index edee8b9385be..5f1cfb8fd427 100644 --- a/drivers/staging/wlags49_h2/README.ubuntu +++ b/drivers/staging/wlags49_h2/README.ubuntu @@ -87,7 +87,7 @@ The linux driver files (wl_xxxx.c) are changed in the following...
f56d711bc9cc25b17643a76ead98caff24507ba9
Analyze and fix the following issue in the Linux kernel code: staging: fix android persistent_ram printk formats
Problem Details: Fix printk format warnings in android/persistent_ram.c: drivers/staging/android/persistent_ram.c:426:4: warning: format '%ld' expects type 'long int', but argument 2 has type 'size_t' drivers/staging/android/persistent_ram.c:426:4: warning: format '%ld' expects type 'long int', but argument 3 has type...
```diff diff --git a/drivers/staging/android/persistent_ram.c b/drivers/staging/android/persistent_ram.c index e08f2574e30a..ce710f9989df 100644 --- a/drivers/staging/android/persistent_ram.c +++ b/drivers/staging/android/persistent_ram.c @@ -424,11 +424,11 @@ struct persistent_ram_zone *__persistent_ram_init(struct de...
2471ec5895b2e3eeb55f4386a793123c8a5bf88a
Analyze and fix the following issue in the Linux kernel code: Staging: rts5139: a couple off by one fixes
Problem Details: Inside the array we check ms_start_idx[seg_no + 1] so on the last round through we end up going past the end of the array. Also if we don't break out of the loop early then we are beyond the end of the array there as well. With this change, if we don't find what we are looking for, we end on the last...
```diff diff --git a/drivers/staging/rts5139/ms.c b/drivers/staging/rts5139/ms.c index b0e9071c8e52..02aad2d242cb 100644 --- a/drivers/staging/rts5139/ms.c +++ b/drivers/staging/rts5139/ms.c @@ -3864,7 +3864,7 @@ static int ms_rw_multi_sector(struct scsi_cmnd *srb, struct rts51x_chip *chip, log_blk = (u16) (start_sec...
c4867936474183332db4c19791a65fdad6474fd5
Analyze and fix the following issue in the Linux kernel code: drm/i915: properly compute dp dithering for user-created modes
Problem Details: We've only computed whether we need to fall back to 6bpc due to dp link bandwidth constrains in mode_valid, but not mode_fixup. Under various circumstances X likes to create new modes which then lack proper 6bpc flags (if required), resulting in mode_fixup failures and ultimately black screens. Chris ...
```diff diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c index 110552ff302c..4b637919f74f 100644 --- a/drivers/gpu/drm/i915/intel_dp.c +++ b/drivers/gpu/drm/i915/intel_dp.c @@ -219,14 +219,38 @@ intel_dp_max_data_rate(int max_link_clock, int max_lanes) return (max_link_clock * max_lanes ...
f650caaa49c774df0bf15a9f99168db93c7a92e8
Analyze and fix the following issue in the Linux kernel code: staging/xgifb: fix addressing issues on platform with long physical addressing
Problem Details: Some platforms (e.g. ppc460ex) have 36-bit physical addressing, while sizeof(unsigned long) == 4. Adapt xgifb driver to use phys_addr_t for physical address variables instead of unsigned long. Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linux...
```diff diff --git a/drivers/staging/xgifb/XGI_main_26.c b/drivers/staging/xgifb/XGI_main_26.c index c55240b1608d..1c93a0300a02 100644 --- a/drivers/staging/xgifb/XGI_main_26.c +++ b/drivers/staging/xgifb/XGI_main_26.c @@ -1910,8 +1910,8 @@ static int __devinit xgifb_probe(struct pci_dev *pdev, xgifb_info->mmio_base ...
6490311f423b0d77969d6fa2ab6354b87e373bf9
Analyze and fix the following issue in the Linux kernel code: staging/xgifb: fix display on XGI Volari Z11m cards
Problem Details: Image on Z11m cards was totally garbled due to wrong memory being selected. Add a special handling for Z11m cards. Tested on PCIe Z11 and Z11m cards. Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/xgifb/vb_init.c b/drivers/staging/xgifb/vb_init.c index 94d5c35e22fb..3650bbff7686 100644 --- a/drivers/staging/xgifb/vb_init.c +++ b/drivers/staging/xgifb/vb_init.c @@ -61,7 +61,7 @@ XGINew_GetXG20DRAMType(struct xgi_hw_device_info *HwDeviceExtension, } temp = xgifb_reg_get(p...
5d92f71e687e4e1a0bed489707d1ec58fe1100de
Analyze and fix the following issue in the Linux kernel code: Staging: android: timed_gpio: Fix resource leak in timed_gpio_probe error paths
Problem Details: If gpio_request fails, we need to free all allocated resources. Current code uses wrong array index to access gpio_data array. So current code actually frees gpio_data[i].gpio by j times. This patch moves the error handling code to err_out and thus improves readability. Signed-off-by: Axel Lin <axel....
```diff diff --git a/drivers/staging/android/timed_gpio.c b/drivers/staging/android/timed_gpio.c index bc723eff11af..45c522cbe784 100644 --- a/drivers/staging/android/timed_gpio.c +++ b/drivers/staging/android/timed_gpio.c @@ -85,7 +85,7 @@ static int timed_gpio_probe(struct platform_device *pdev) struct timed_gpio_p...
3567f97965aa58b6acdfaf1ac86eed62905369ea
Analyze and fix the following issue in the Linux kernel code: staging: usbip: Fix typo in printed text
Problem Details: Signed-off-by: Christopher Harvey <charvey@matrox.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/usbip/vhci_rx.c b/drivers/staging/usbip/vhci_rx.c index f5fba7320c5a..f0eaf04fa25b 100644 --- a/drivers/staging/usbip/vhci_rx.c +++ b/drivers/staging/usbip/vhci_rx.c @@ -162,7 +162,7 @@ static void vhci_recv_ret_unlink(struct vhci_device *vdev, * already received the result of i...
2f5c638ced00fff2356ce0a02f16c8e928259750
Analyze and fix the following issue in the Linux kernel code: staging: usbip: fix potential segfault because of unchecked return value of strchr.
Problem Details: This doesn't happen with the usbip virtual hci module, but another module wanting to interface with this user space code could cause a seg-fault by sending data without newlines. Signed-off-by: Christopher Harvey <charvey@matrox.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/usbip/userspace/libsrc/vhci_driver.c b/drivers/staging/usbip/userspace/libsrc/vhci_driver.c index 269787751b20..0958ba53e94a 100644 --- a/drivers/staging/usbip/userspace/libsrc/vhci_driver.c +++ b/drivers/staging/usbip/userspace/libsrc/vhci_driver.c @@ -59,7 +59,10 @@ static int par...
277ac73720628f032c34c1e8b157a6ae2077766f
Analyze and fix the following issue in the Linux kernel code: Staging:rts_pstor: fix coding style issue in rtsx_transport.c
Problem Details: This patch changes the space of the indent to the tab that warning found by the checkpatch.pl tool. Signed-off-by: Hitoshi NAKAMORI<hitoshi.nakamori@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/rts_pstor/rtsx_transport.c b/drivers/staging/rts_pstor/rtsx_transport.c index 4e3d2c106af0..488f9500bf1f 100644 --- a/drivers/staging/rts_pstor/rtsx_transport.c +++ b/drivers/staging/rts_pstor/rtsx_transport.c @@ -130,7 +130,7 @@ unsigned int rtsx_stor_access_xfer_buf(unsigned char ...
215c47c931d2e22f05bbff31ebf9325f7479fcf5
Analyze and fix the following issue in the Linux kernel code: staging:octeon Fix typos in staging:octeon
Problem Details: The below patch is a resend to fix some typos and comments that I have found while reading. Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Acked-by: David Daney <david.daney@cavium.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/octeon/ethernet-rx.c b/drivers/staging/octeon/ethernet-rx.c index 400df8cbee53..5699e6f1b5ba 100644 --- a/drivers/staging/octeon/ethernet-rx.c +++ b/drivers/staging/octeon/ethernet-rx.c @@ -162,7 +162,7 @@ static inline int cvm_oct_check_rcv_error(cvmx_wqe_t *work) /* * We re...
e06d9b3e6c0f5617fe14e137a6121c5e59edf497
Analyze and fix the following issue in the Linux kernel code: staging:rts_pstor:Fix unbalanced parentheses
Problem Details: Signed-off-by: wwang <wei_wang@realsil.com.cn> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/rts_pstor/ms.c b/drivers/staging/rts_pstor/ms.c index 66341dff8c99..e098a90e4642 100644 --- a/drivers/staging/rts_pstor/ms.c +++ b/drivers/staging/rts_pstor/ms.c @@ -4135,7 +4135,7 @@ int mg_set_ICV(struct scsi_cmnd *srb, struct rtsx_chip *chip) #else retval = ms_transfer_data(ch...
13c398aa5c9a7eae7792726f6229d961e2915b12
Analyze and fix the following issue in the Linux kernel code: staging/mei: wd.c normalize debug and error messages
Problem Details: 1. use wd: prefix for all messages 2. fix strings 3. change from dev_dbg to dev_err where appropriate Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/mei/wd.c b/drivers/staging/mei/wd.c index 032cf6766de5..1e6285127e95 100644 --- a/drivers/staging/mei/wd.c +++ b/drivers/staging/mei/wd.c @@ -47,7 +47,7 @@ const uuid_le mei_wd_guid = UUID_LE(0x05B79A6F, 0x4628, 0x4D7F, 0x89, static void mei_wd_set_start_timeout(struct mei_device...
9487eb0a1588b8d759f7231c7aa44893525769b2
Analyze and fix the following issue in the Linux kernel code: staging/mei: refactor mei_wd_host_init function
Problem Details: The function has returned false in both error and success cases. 1. change return value to int and return appropriate errno 2. use typical Linux kernel error handling. 3. normalize debug messages Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfou...
```diff diff --git a/drivers/staging/mei/interface.h b/drivers/staging/mei/interface.h index f934b094085a..0d0043575a2a 100644 --- a/drivers/staging/mei/interface.h +++ b/drivers/staging/mei/interface.h @@ -51,7 +51,7 @@ int mei_flow_ctrl_creds(struct mei_device *dev, struct mei_cl *cl); int mei_wd_send(struct mei_d...
68d923d5369e7e8f72dbc75015829b7fc83512fc
Analyze and fix the following issue in the Linux kernel code: staging/mei: struct amt_wd_dev' should it be static
Problem Details: fix sparse warning: 'amt_wd_dev' was not declared. Should it be static Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/mei/wd.c b/drivers/staging/mei/wd.c index d7f40dbce6b0..57a1642b964b 100644 --- a/drivers/staging/mei/wd.c +++ b/drivers/staging/mei/wd.c @@ -345,7 +345,7 @@ static const struct watchdog_info wd_info = { .options = WDIOF_KEEPALIVEPING, }; -struct watchdog_device amt_wd_dev = {...
2f3d2b499b73b3aa05feba35a9b04c6eec1a50ec
Analyze and fix the following issue in the Linux kernel code: staging/mei: define pr_fmt prefix for pr_ macros
Problem Details: define pr_fmt macro and remove mei: from the messages Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/mei/main.c b/drivers/staging/mei/main.c index 7c9321fa7bb1..4f46738617a2 100644 --- a/drivers/staging/mei/main.c +++ b/drivers/staging/mei/main.c @@ -14,6 +14,8 @@ * */ +#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt + #include <linux/module.h> #include <linux/moduleparam.h> #...
4e24764017ee5dd9d7062e9c10af2c3c557f9c5a
Analyze and fix the following issue in the Linux kernel code: staging:quatech_usb2:quatech_usb2.c Fix typo in staging:quatech_usb2
Problem Details: The below patch fixes a typo that I found while reading. Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/quatech_usb2/quatech_usb2.c b/drivers/staging/quatech_usb2/quatech_usb2.c index bb977e00cc86..cb7d9065538b 100644 --- a/drivers/staging/quatech_usb2/quatech_usb2.c +++ b/drivers/staging/quatech_usb2/quatech_usb2.c @@ -732,7 +732,7 @@ static int qt2_write(struct tty_struct *tty, stru...
6975e183bb59dd6cc281247925092ca42ab7e1d5
Analyze and fix the following issue in the Linux kernel code: staging:panel:panel.c Fix typo in staging:panel
Problem Details: The below patch fixes a typo I found while reading. Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Cc: Willy Tarreau <willy@meta-x.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/panel/panel.c b/drivers/staging/panel/panel.c index 6183573f112f..7365089a33e8 100644 --- a/drivers/staging/panel/panel.c +++ b/drivers/staging/panel/panel.c @@ -754,7 +754,7 @@ static void lcd_backlight(int on) if (lcd_bl_pin == PIN_NONE) return; - /* The backlight is activa...
5d25287f9b11e2395a1f6679f43aa544977b3e54
Analyze and fix the following issue in the Linux kernel code: staging:olpc_dcon:olpc_dcon_xo_1.c Fix typo in staging:olpc_dcon
Problem Details: The below patch fixes a typo I found while reading. Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Cc: Andres Salomon <dilinger@queued.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/olpc_dcon/olpc_dcon_xo_1.c b/drivers/staging/olpc_dcon/olpc_dcon_xo_1.c index cb6ce0cf92a0..c87fdfac4855 100644 --- a/drivers/staging/olpc_dcon/olpc_dcon_xo_1.c +++ b/drivers/staging/olpc_dcon/olpc_dcon_xo_1.c @@ -116,7 +116,7 @@ static int dcon_init_xo_1(struct dcon_priv *dcon) c...
595914fea321fdd6c3664ce6b6a33c12930c24c7
Analyze and fix the following issue in the Linux kernel code: staging:ozwpan:ozhcd.c Fix typos in staging:ozwpan
Problem Details: The below patch fixes a typo that I found while reading. Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Acked-by: Chris Kelly <ckelly@ozmodevices.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/ozwpan/ozhcd.c b/drivers/staging/ozwpan/ozhcd.c index 750b14eb505e..cfa25e846ca6 100644 --- a/drivers/staging/ozwpan/ozhcd.c +++ b/drivers/staging/ozwpan/ozhcd.c @@ -1463,7 +1463,7 @@ static void oz_process_ep0_urb(struct oz_hcd *ozhcd, struct urb *urb, rc = -ENOMEM; } else {...
535f2a5ffa5b11bd6824cbab6027d5092b5517c2
Analyze and fix the following issue in the Linux kernel code: staging:nvec:nvec.h Fix typos in staging:nvec
Problem Details: The below patch fixes a typo I found while reading. Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Cc: Julian Andres Klode <jak@jak-linux.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/nvec/nvec.h b/drivers/staging/nvec/nvec.h index a4c17b0e10cf..ba6ed8f4e8a3 100644 --- a/drivers/staging/nvec/nvec.h +++ b/drivers/staging/nvec/nvec.h @@ -42,7 +42,7 @@ * enum nvec_event_size - The size of an event message * @NVEC_2BYTES: The message has one command byte and one ...
0cb2f1239dd7acf72fb60adb53c1fdaa65b719a2
Analyze and fix the following issue in the Linux kernel code: regulator: twl-regulator: Fix off-by-one vsel setting in twl6030smps_set_voltage
Problem Details: commit 268a1 "regulator: twl-regulator: Use DIV_ROUND_UP at appropriate places" introduced an off-by-one bug for setting vsel. The linear calculation code in twl6030smps_list_voltage() does subtract index by 1 so we need the vsel++ after DIV_ROUND_UP. The original code use this trick to differentiate...
```diff diff --git a/drivers/regulator/twl-regulator.c b/drivers/regulator/twl-regulator.c index 7384d277ef40..68d9a7b6e1f7 100644 --- a/drivers/regulator/twl-regulator.c +++ b/drivers/regulator/twl-regulator.c @@ -788,6 +788,7 @@ twl6030smps_set_voltage(struct regulator_dev *rdev, int min_uV, int max_uV, else if ((...
ba46ce30f13a13bb24d05e21df2571ad724f1a1e
Analyze and fix the following issue in the Linux kernel code: staging: usbip: fix the usage of kthread_stop()
Problem Details: stub_shutdown_connection() and vhci_shutdown_connection() use task_is_dead() before kthread_stop(). This buys nothing and wrong. kthread_stop() is fine even if this thread is dead. However, if it is dead nothing protects this task_struct, we shouldn't touch this memory. Change the code to do the neces...
```diff diff --git a/drivers/staging/usbip/stub_dev.c b/drivers/staging/usbip/stub_dev.c index fa870e3f7f6a..92ced35e6b7f 100644 --- a/drivers/staging/usbip/stub_dev.c +++ b/drivers/staging/usbip/stub_dev.c @@ -113,8 +113,8 @@ static ssize_t store_sockfd(struct device *dev, struct device_attribute *attr, spin_unlo...
96ddcd439871658b797289dde8fcead8bde73b68
Analyze and fix the following issue in the Linux kernel code: staging/rtl8192e - fix typo in printk message
Problem Details: In drivers/staging/rtl8192e/rtl8192e/rtl_core.c the follwing printk-message can be found: printk(KERN_ERR "rtl8193e: Unable to allocate space " This is quite obviously just a typo, all other similar messages use "rtl8192e" and the string "rtl8193e" does not occur anywhere else in the source of the dr...
```diff diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_core.c b/drivers/staging/rtl8192e/rtl8192e/rtl_core.c index 71adb6b3344d..7c676c2cba41 100644 --- a/drivers/staging/rtl8192e/rtl8192e/rtl_core.c +++ b/drivers/staging/rtl8192e/rtl8192e/rtl_core.c @@ -1211,7 +1211,7 @@ static void rtl8192_init_priv_variable(stru...
4d36bf61929d5edea8968ae4ec4c45dfb6077489
Analyze and fix the following issue in the Linux kernel code: Staging: rtl8187se: r8185b_init.c: Fix comment blocks
Problem Details: Reformated comment blocks to meet Coding Style Signed-off-by: Andrew Miller <amiller@amilx.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/rtl8187se/r8185b_init.c b/drivers/staging/rtl8187se/r8185b_init.c index d90cf10a0eb0..af9be964dbf0 100644 --- a/drivers/staging/rtl8187se/r8185b_init.c +++ b/drivers/staging/rtl8187se/r8185b_init.c @@ -1,22 +1,22 @@ -/*++ -Copyright (c) Realtek Semiconductor Corp. All rights reserve...
f9c73f9b56efd3ed020e6a3b19d1dcdf84d93bbe
Analyze and fix the following issue in the Linux kernel code: Staging: rtl8187se: r8185b_init.c: Fix some spacing issues
Problem Details: Fix some more spacing issues I missed before Signed-off-by: Andrew Miller <amiller@amilx.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/rtl8187se/r8185b_init.c b/drivers/staging/rtl8187se/r8185b_init.c index 5650ef11fcb0..3f9be9bcf6a3 100644 --- a/drivers/staging/rtl8187se/r8185b_init.c +++ b/drivers/staging/rtl8187se/r8185b_init.c @@ -71,10 +71,10 @@ static u8 MAC_REG_TABLE[][2] = { /* PAGA 0: */ {0x5e, 0x00}...
3d2ec48ee4934bc046da1ce0ac65ef98b2b8516c
Analyze and fix the following issue in the Linux kernel code: Staging: rtl8187se: r8185b_init.c: Fix function declarations
Problem Details: Reformated the function declarations Signed-off-by: Andrew Miller <amiller@amilx.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/rtl8187se/r8185b_init.c b/drivers/staging/rtl8187se/r8185b_init.c index 3c1ca69ac95a..5650ef11fcb0 100644 --- a/drivers/staging/rtl8187se/r8185b_init.c +++ b/drivers/staging/rtl8187se/r8185b_init.c @@ -117,24 +117,14 @@ static u8 OFDM_CONFIG[] = { * the code is ported from Windows...
f4477e90b3ea4c40466e8f418cf41a17aef09192
Analyze and fix the following issue in the Linux kernel code: staging: zsmalloc: fix memory leak
Problem Details: This patch fixes a memory leak in zsmalloc where the first subpage of each zspage is leaked when the zspage is freed. Signed-off-by: Nitin Gupta <ngupta@vflare.org> Acked-by: Seth Jennings <sjenning@linux.vnet.ibm.com> Acked-by: Dan Magenheimer <dan.magenheimer@oracle.com> Signed-off-by: Greg Kroah-Ha...
```diff diff --git a/drivers/staging/zsmalloc/zsmalloc-main.c b/drivers/staging/zsmalloc/zsmalloc-main.c index 09caa4f2687e..917461c66014 100644 --- a/drivers/staging/zsmalloc/zsmalloc-main.c +++ b/drivers/staging/zsmalloc/zsmalloc-main.c @@ -267,33 +267,39 @@ static unsigned long obj_idx_to_offset(struct page *page, ...
3fd654c22c7b002e8681accaed50a6d46656d815
Analyze and fix the following issue in the Linux kernel code: Staging: rts_pstor: off by one in for loop
Problem Details: I already fixed the other similar for loop in this file. I'm not sure how I missed this one. We use seg_no+1 inside the loop so we can't go right up to the end of the loop. Also if we don't break out of the loop then we end up past the end of the array, but with this fix we end up on the last elemen...
```diff diff --git a/drivers/staging/rts_pstor/ms.c b/drivers/staging/rts_pstor/ms.c index 66341dff8c99..f9a4498984cc 100644 --- a/drivers/staging/rts_pstor/ms.c +++ b/drivers/staging/rts_pstor/ms.c @@ -3498,7 +3498,8 @@ static int ms_rw_multi_sector(struct scsi_cmnd *srb, struct rtsx_chip *chip, u32 log_blk++; ...
0d05568ac79bfc595f1eadc3e0fd7a20a45f7b69
Analyze and fix the following issue in the Linux kernel code: staging:rts_pstor:Fix possible panic by NULL pointer dereference
Problem Details: rtsx_transport.c (rtsx_transfer_sglist_adma_partial): pointer struct scatterlist *sg, which is mapped in dma_map_sg, is used as an iterator in later transfer operation. It is corrupted and passed to dma_unmap_sg, thus causing fatal unmap of some erroneous address. Fix it by duplicating *sg_ptr for iter...
```diff diff --git a/drivers/staging/rts_pstor/rtsx_transport.c b/drivers/staging/rts_pstor/rtsx_transport.c index 4e3d2c106af0..9b2e5c99870f 100644 --- a/drivers/staging/rts_pstor/rtsx_transport.c +++ b/drivers/staging/rts_pstor/rtsx_transport.c @@ -335,6 +335,7 @@ static int rtsx_transfer_sglist_adma_partial(struct r...
401c90e56c48b1c642507a8bec91b7ae21f1156e
Analyze and fix the following issue in the Linux kernel code: staging/media/as102: Don't call release_firmware() on uninitialized variable
Problem Details: If, in drivers/staging/media/as102/as102_fw.c::as102_fw_upload(), the call cmd_buf = kzalloc(MAX_FW_PKT_SIZE, GFP_KERNEL); should fail and return NULL so that we jump to the 'error:' label, then we'll end up calling 'release_firmware(firmware);' with 'firmware' still uninitialized - not good. The eas...
```diff diff --git a/drivers/staging/media/as102/as102_fw.c b/drivers/staging/media/as102/as102_fw.c index 43ebc43e6b9a..1075fb1df0d9 100644 --- a/drivers/staging/media/as102/as102_fw.c +++ b/drivers/staging/media/as102/as102_fw.c @@ -165,7 +165,7 @@ error: int as102_fw_upload(struct as10x_bus_adapter_t *bus_adap) { ...
eaa004a4ba3264d17d7e6882948a7980e14e9d20
Analyze and fix the following issue in the Linux kernel code: staging/vme: Fix module parameters
Problem Details: loopback should be declared bool, and variant probably shouldn't be const. Signed-off-by: Gerard Snitselaar <dev@snitselaar.org> Acked-by: Martyn Welch <martyn.welch@ge.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/staging/vme/devices/vme_pio2_core.c b/drivers/staging/vme/devices/vme_pio2_core.c index 9fedc442a779..573c80003f0c 100644 --- a/drivers/staging/vme/devices/vme_pio2_core.c +++ b/drivers/staging/vme/devices/vme_pio2_core.c @@ -35,10 +35,10 @@ static int vector[PIO2_CARDS_MAX]; static int ve...
fcff311c938c95c90573c060d37648df00e45017
Analyze and fix the following issue in the Linux kernel code: staging: sep: Fix sign of error
Problem Details: One of our errors wasn't negative as intended. Fix this. (Found by Hillf Danton) While we are at it turn user causable messages down to dev_dbg level in the ioctl paths. Signed-off-by: Alan Cox <alan@linux.intel.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxf...
```diff diff --git a/drivers/staging/sep/sep_main.c b/drivers/staging/sep/sep_main.c index ad54c2e5c932..f1701bc6e312 100644 --- a/drivers/staging/sep/sep_main.c +++ b/drivers/staging/sep/sep_main.c @@ -3114,7 +3114,7 @@ static long sep_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) current->pid); ...
92b0abf80c5c5f0e0d71d1309688a330fd74731b
Analyze and fix the following issue in the Linux kernel code: usb: gadget: eliminate NULL pointer dereference (bugfix)
Problem Details: usb: gadget: eliminate NULL pointer dereference (bugfix) This patch fixes a bug which causes NULL pointer dereference in ffs_ep0_ioctl. The bug happens when the FunctionFS is not bound (either has not been bound yet or has been bound and then unbound) and can be reproduced with running the following c...
```diff diff --git a/drivers/usb/gadget/f_fs.c b/drivers/usb/gadget/f_fs.c index d187ae73262b..f52cb1ae45d9 100644 --- a/drivers/usb/gadget/f_fs.c +++ b/drivers/usb/gadget/f_fs.c @@ -712,7 +712,7 @@ static long ffs_ep0_ioctl(struct file *file, unsigned code, unsigned long value) if (code == FUNCTIONFS_INTERFACE_REVMA...
f135617224b4a1113b26b8ee5877e94f38e40d1e
Analyze and fix the following issue in the Linux kernel code: usb: gadget: rndis: fix Missing req->context assignment
Problem Details: It is crucial to assign each req->context value to struct rndis. The problem happens for multi function gadget (g_multi) when multiple functions are calling common usb_composite_dev control request. It might happen that *_setup method from one usb function will alter some fields of this common reques...
```diff diff --git a/drivers/usb/gadget/f_rndis.c b/drivers/usb/gadget/f_rndis.c index 7b1cf18df5e3..52343654f5df 100644 --- a/drivers/usb/gadget/f_rndis.c +++ b/drivers/usb/gadget/f_rndis.c @@ -500,6 +500,7 @@ rndis_setup(struct usb_function *f, const struct usb_ctrlrequest *ctrl) if (buf) { memcpy(req->buf, ...
ad579699c4f0274bf522a9252ff9b20c72197e48
Analyze and fix the following issue in the Linux kernel code: usb: musb: omap: fix the error check for pm_runtime_get_sync
Problem Details: pm_runtime_get_sync returns a signed integer. In case of errors it returns a negative value. This patch fixes the error check by making it signed instead of unsigned thus preventing register access if get_sync_fails. Also passes the error cause to the debug message. Cc: stable@vger.kernel.org Cc: Kis...
```diff diff --git a/drivers/usb/musb/omap2430.c b/drivers/usb/musb/omap2430.c index 0fb4ce84d17e..c7785e81254c 100644 --- a/drivers/usb/musb/omap2430.c +++ b/drivers/usb/musb/omap2430.c @@ -282,7 +282,8 @@ static void musb_otg_notifier_work(struct work_struct *data_notifier_work) static int omap2430_musb_init(struc...
8ae8090c82eb407267001f75b3d256b3bd4ae691
Analyze and fix the following issue in the Linux kernel code: usb: gadget: udc-core: fix asymmetric calls in remove_driver
Problem Details: During modprobe of gadget driver, pullup is called after udc_start. In order to make the exit path symmetric when removing a gadget driver, call pullup before ->udc_stop. This is needed to avoid issues with PM where udc_stop disables the module completely (put IP in reset state, cut functional and int...
```diff diff --git a/drivers/usb/gadget/udc-core.c b/drivers/usb/gadget/udc-core.c index c261887e05ae..2fa9865babed 100644 --- a/drivers/usb/gadget/udc-core.c +++ b/drivers/usb/gadget/udc-core.c @@ -264,8 +264,8 @@ static void usb_gadget_remove_driver(struct usb_udc *udc) if (udc_is_newstyle(udc)) { udc->driver->d...
3006dc8c627d738693e910c159630e4368c9e86c
Analyze and fix the following issue in the Linux kernel code: usb: musb: omap: fix crash when musb glue (omap) gets initialized
Problem Details: pm_runtime_enable is being called after omap2430_musb_init. Hence pm_runtime_get_sync in omap2430_musb_init does not have any effect (does not enable clocks) resulting in a crash during register access. It is fixed here. Cc: stable@vger.kernel.org # v3.0, v3.1, v3.2, v3.3 Signed-off-by: Kishon Vijay A...
```diff diff --git a/drivers/usb/musb/omap2430.c b/drivers/usb/musb/omap2430.c index 3dfd122266f4..0fb4ce84d17e 100644 --- a/drivers/usb/musb/omap2430.c +++ b/drivers/usb/musb/omap2430.c @@ -453,14 +453,14 @@ static int __devinit omap2430_probe(struct platform_device *pdev) goto err2; } + pm_runtime_enable(&pdev...
692933b2ccfce02400dc8360a97acde2846e8541
Analyze and fix the following issue in the Linux kernel code: usb: musb: fix bug in musb_cleanup_urb
Problem Details: Control transfers with data expected from device to host will use usb_rcvctrlpipe() for urb->pipe so for such urbs 'is_in' will be set causing control urb to fall into the first "if" condition in musb_cleanup_urb(). Fixed by adding logic to check for non control endpoints. Signed-off-by: Ajay Kumar G...
```diff diff --git a/drivers/usb/musb/musb_host.c b/drivers/usb/musb/musb_host.c index 79cb0af779fa..ef8d744800ac 100644 --- a/drivers/usb/musb/musb_host.c +++ b/drivers/usb/musb/musb_host.c @@ -2098,7 +2098,7 @@ static int musb_cleanup_urb(struct urb *urb, struct musb_qh *qh) } /* turn off DMA requests, discard ...
e2190a97c6d493eef1f180b9dadfd5ffd4706051
Analyze and fix the following issue in the Linux kernel code: usb: gadget: FunctionFS: clear FFS_FL_BOUND flag on unbind (bugfix)
Problem Details: clear FFS_FL_BOUND flag on unbind (bugfix) Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Acked-by: Michal Nazarewicz <mina86@mina86.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
```diff diff --git a/drivers/usb/gadget/f_fs.c b/drivers/usb/gadget/f_fs.c index 1cbba70836bc..d187ae73262b 100644 --- a/drivers/usb/gadget/f_fs.c +++ b/drivers/usb/gadget/f_fs.c @@ -1382,6 +1382,7 @@ static void functionfs_unbind(struct ffs_data *ffs) ffs->ep0req = NULL; ffs->gadget = NULL; ffs_data_put(ffs);...
db1d8ba36551bf55222c7961d9e9a1195a612fde
Analyze and fix the following issue in the Linux kernel code: usb: s3c-hsotg: Fix big buffers transfer in DMA mode
Problem Details: DMA address register shouldn't be updated manually if transfer size requires multiple packets. Signed-off-by: Anton Tikhomirov <av.tikhomirov@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
```diff diff --git a/drivers/usb/gadget/s3c-hsotg.c b/drivers/usb/gadget/s3c-hsotg.c index 8db23660b5e2..105b206cd844 100644 --- a/drivers/usb/gadget/s3c-hsotg.c +++ b/drivers/usb/gadget/s3c-hsotg.c @@ -741,7 +741,7 @@ static void s3c_hsotg_start_req(struct s3c_hsotg *hsotg, /* write size / packets */ writel(epsize...
659ad60cb9128345d0a6b9093dda9b0e366b7937
Analyze and fix the following issue in the Linux kernel code: usb: s3c-hsotg: Fix maximum patcket size setting for EP0
Problem Details: MPS field of DOEPCTL0 is read only. Signed-off-by: Anton Tikhomirov <av.tikhomirov@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
```diff diff --git a/drivers/usb/gadget/s3c-hsotg.c b/drivers/usb/gadget/s3c-hsotg.c index e3fe5fd795f0..03de169ab365 100644 --- a/drivers/usb/gadget/s3c-hsotg.c +++ b/drivers/usb/gadget/s3c-hsotg.c @@ -1696,10 +1696,12 @@ static void s3c_hsotg_set_ep_maxpacket(struct s3c_hsotg *hsotg, reg |= mpsval; writel(reg, re...
f7a83fe19336125d7eb26488788dc66c03f2c08e
Analyze and fix the following issue in the Linux kernel code: usb: s3c-hsotg: Fix TX FIFOs allocation
Problem Details: According to documentation, TX FIFO_number index starts from 1. For IN endpoint FIFO 0 we use GNPTXFSIZ register for programming the size and memory start address. Signed-off-by: Anton Tikhomirov <av.tikhomirov@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
```diff diff --git a/drivers/usb/gadget/s3c-hsotg.c b/drivers/usb/gadget/s3c-hsotg.c index 69295ba9d99a..e3fe5fd795f0 100644 --- a/drivers/usb/gadget/s3c-hsotg.c +++ b/drivers/usb/gadget/s3c-hsotg.c @@ -340,7 +340,7 @@ static void s3c_hsotg_init_fifo(struct s3c_hsotg *hsotg) /* currently we allocate TX FIFOs for all ...
c04352a590538123f8c93bd87ef1d4bb9e3a64c7
Analyze and fix the following issue in the Linux kernel code: usb: musb: fix some runtime_pm issues
Problem Details: When runtime_pm was originally added, it was done in rather confusing way: omap2430_musb_init() (called from musb_init_controller) would do runtime_pm_get_sync() and musb_init_controller() itself would do runtime_pm_put to balance it out. This is not only confusing but also wrong if non-omap2430 glue l...
```diff diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.c index 0f8b82918a40..239214626ec5 100644 --- a/drivers/usb/musb/musb_core.c +++ b/drivers/usb/musb/musb_core.c @@ -1904,7 +1904,7 @@ musb_init_controller(struct device *dev, int nIrq, void __iomem *ctrl) if (!musb->isr) { status = -E...
afb76df140823c57738598a876cd1d6568cd57c7
Analyze and fix the following issue in the Linux kernel code: usb: musb: fix oops on omap2430 module unload
Problem Details: This change prevents runtime suspend and resume actual execution, if omap2430 controller driver is loaded after musb-hdrc, and therefore the controller isn't initialized properly. The problem is reproducible with 3.1.y and 3.2 kernels. Kernel configuration of musb: % cat .config | egrep 'MUSB|GADG...
```diff diff --git a/drivers/usb/musb/omap2430.c b/drivers/usb/musb/omap2430.c index 2ae0bb309994..11b571ec22f2 100644 --- a/drivers/usb/musb/omap2430.c +++ b/drivers/usb/musb/omap2430.c @@ -491,11 +491,13 @@ static int omap2430_runtime_suspend(struct device *dev) struct omap2430_glue *glue = dev_get_drvdata(dev); ...
6e7beb7ec8b8c3a1927d4d02c33a0e2a8e72eec3
Analyze and fix the following issue in the Linux kernel code: ARM: S5PV210: Fix compiler warning in dma.c file
Problem Details: Fixes the following warning: warning: 'dma_dmamask' defined but not used [-Wunused-variable] Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
```diff diff --git a/arch/arm/mach-s5pv210/dma.c b/arch/arm/mach-s5pv210/dma.c index 86ce62f66190..b8337e248b09 100644 --- a/arch/arm/mach-s5pv210/dma.c +++ b/arch/arm/mach-s5pv210/dma.c @@ -33,8 +33,6 @@ #include <mach/irqs.h> #include <mach/dma.h> -static u64 dma_dmamask = DMA_BIT_MASK(32); - static u8 pdma0_per...
32ed53b83ea5ec26a4dba90e18f5e0ff6c71eb48
Analyze and fix the following issue in the Linux kernel code: wiznet: Fix Kconfig dependencies.
Problem Details: Both drivers need to depend upon HAS_IOMEM, otherwise we get a build failure on platforms like S390. All the driver specific config options need to depend upon the drivers themselves. Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: David S. Miller <davem@davemloft.net>
```diff diff --git a/drivers/net/ethernet/wiznet/Kconfig b/drivers/net/ethernet/wiznet/Kconfig index 2bb383caf2d8..c8291bf905a7 100644 --- a/drivers/net/ethernet/wiznet/Kconfig +++ b/drivers/net/ethernet/wiznet/Kconfig @@ -19,6 +19,7 @@ if NET_VENDOR_WIZNET config WIZNET_W5100 tristate "WIZnet W5100 Ethernet suppo...
83b0c6ba999643ee8ad6329f26e1cdc870e1a920
Analyze and fix the following issue in the Linux kernel code: ALSA: hda - Fix oops caused by recent commit "Fix internal mic for Lenovo Ideapad U300s"
Problem Details: Make sure we don't dereference the "quirk" pointer when it is null. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> 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_conexant.c b/sound/pci/hda/patch_conexant.c index cbe115b6c80c..abb59f472d48 100644 --- a/sound/pci/hda/patch_conexant.c +++ b/sound/pci/hda/patch_conexant.c @@ -4441,7 +4441,9 @@ static void apply_fixup(struct hda_codec *codec, struct conexant_spec *spec = codec->spec; qu...
fae3d88a5c56c3f836e95c4516da883a48612437
Analyze and fix the following issue in the Linux kernel code: ALSA: hda - hide HDMI/ELD printks unless snd.debug=2
Problem Details: Also remove two warnings when CONFIG_SND_DEBUG is not set: sound/pci/hda/patch_hdmi.c: In function ‘hdmi_intrinsic_event’: sound/pci/hda/patch_hdmi.c:761:6: warning: unused variable ‘eldv’ [-Wunused-variable] sound/pci/hda/patch_hdmi.c:760:6: warning: unused variable ‘pd’ [-Wunused-variable] Signed-o...
```diff diff --git a/include/sound/core.h b/include/sound/core.h index b6e0f57d451d..bc056687f647 100644 --- a/include/sound/core.h +++ b/include/sound/core.h @@ -325,6 +325,13 @@ void release_and_free_resource(struct resource *res); /* --- */ +/* sound printk debug levels */ +enum { + SND_PR_ALWAYS, + SND_PR_DEBU...
6ba900676bec8baaf61aa2f85b7345c0e65774d9
Analyze and fix the following issue in the Linux kernel code: netfilter: nf_conntrack: fix incorrect logic in nf_conntrack_init_net
Problem Details: in function nf_conntrack_init_net,when nf_conntrack_timeout_init falied, we should call nf_conntrack_ecache_fini to do rollback. but the current code calls nf_conntrack_timeout_fini. Signed-off-by: Gao feng <gaofeng@cn.fujitsu.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
```diff diff --git a/net/netfilter/nf_conntrack_core.c b/net/netfilter/nf_conntrack_core.c index 3cc4487ac349..729f157a0efa 100644 --- a/net/netfilter/nf_conntrack_core.c +++ b/net/netfilter/nf_conntrack_core.c @@ -1592,7 +1592,7 @@ static int nf_conntrack_init_net(struct net *net) return 0; err_timeout: - nf_conn...
07153c6ec074257ade76a461429b567cff2b3a1e
Analyze and fix the following issue in the Linux kernel code: netfilter: nf_ct_ipv4: packets with wrong ihl are invalid
Problem Details: It was reported that the Linux kernel sometimes logs: klogd: [2629147.402413] kernel BUG at net / netfilter / nf_conntrack_proto_tcp.c: 447! klogd: [1072212.887368] kernel BUG at net / netfilter / nf_conntrack_proto_tcp.c: 392 ipv4_get_l4proto() in nf_conntrack_l3proto_ipv4.c and tcp_error() in nf_co...
```diff diff --git a/net/ipv4/netfilter/nf_conntrack_l3proto_ipv4.c b/net/ipv4/netfilter/nf_conntrack_l3proto_ipv4.c index 750b06afd20e..cf73cc70ed2d 100644 --- a/net/ipv4/netfilter/nf_conntrack_l3proto_ipv4.c +++ b/net/ipv4/netfilter/nf_conntrack_l3proto_ipv4.c @@ -84,6 +84,14 @@ static int ipv4_get_l4proto(const stru...
6f407e5bc7af4e125e20e4f9c893f3df8fadb202
Analyze and fix the following issue in the Linux kernel code: wl12xx: adaptive sched scan dwell times
Problem Details: Set the dwell times for sched scan according to the number of probe requests which are going to be transmitted. This should fix the too short dwell time problem which prevented some of the probe requests from being transmitted in cases of high number of SSIDs (10+) to be actively sched scanned. However...
```diff diff --git a/drivers/net/wireless/wl12xx/conf.h b/drivers/net/wireless/wl12xx/conf.h index 3e581e19424c..5d2a9e004c72 100644 --- a/drivers/net/wireless/wl12xx/conf.h +++ b/drivers/net/wireless/wl12xx/conf.h @@ -1096,16 +1096,31 @@ struct conf_scan_settings { }; struct conf_sched_scan_settings { - /* minimum...
3eba4a0e6db9ca225bc0f3042d60fcfc86a30bc8
Analyze and fix the following issue in the Linux kernel code: wl12xx: fix a memory leak of probereq template upon recovery
Problem Details: wlvif->probereq is zeroed when adding an interface but the skb pointed to isn't freed when the interface is removed. This would lead to a mem leak on every recovery. Fix it by freeing the skb when removing the interface. Signed-off-by: Eyal Shapira <eyal@wizery.com> Signed-off-by: Luciano Coelho <coel...
```diff diff --git a/drivers/net/wireless/wl12xx/main.c b/drivers/net/wireless/wl12xx/main.c index e21d21d7de8e..b560f2d2837b 100644 --- a/drivers/net/wireless/wl12xx/main.c +++ b/drivers/net/wireless/wl12xx/main.c @@ -2358,6 +2358,8 @@ deinit: wl1271_free_ap_keys(wl, wlvif); } + dev_kfree_skb(wlvif->probereq); ...
fa4da365bc7772c2cd6d5405bdf151612455f957
Analyze and fix the following issue in the Linux kernel code: clockevents: tTack broadcast device mode change in tick_broadcast_switch_to_oneshot()
Problem Details: In the commit 77b0d60c5adf39c74039e2142a1d3cd1e4d53799, "clockevents: Leave the broadcast device in shutdown mode when not needed", we were bailing out too quickly in tick_broadcast_switch_to_oneshot(), with out tracking the broadcast device mode change to 'TICKDEV_MODE_ONESHOT'. This breaks the platf...
```diff diff --git a/kernel/time/tick-broadcast.c b/kernel/time/tick-broadcast.c index e883f57a3cd3..bf57abdc7bd0 100644 --- a/kernel/time/tick-broadcast.c +++ b/kernel/time/tick-broadcast.c @@ -575,10 +575,12 @@ void tick_broadcast_switch_to_oneshot(void) unsigned long flags; raw_spin_lock_irqsave(&tick_broadcas...
abec95adefaeb2229cb28de65f3d32cd149b9dd9
Analyze and fix the following issue in the Linux kernel code: regmap: fix compilation when !CONFIG_DEBUG_FS
Problem Details: Commit 79c64d5 "regmap: allow regmap instances to be named" changed the prototype of regmap_debugfs_init, but didn't update the dummy inline used when !CONFIG_DEBUGFS. Fix this. Signed-off-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
```diff diff --git a/drivers/base/regmap/internal.h b/drivers/base/regmap/internal.h index 6beef6691c47..8461ca7711ed 100644 --- a/drivers/base/regmap/internal.h +++ b/drivers/base/regmap/internal.h @@ -106,7 +106,7 @@ extern void regmap_debugfs_init(struct regmap *map, const char *name); extern void regmap_debugfs_ex...
afceb9319f21b18ee3bc15ee9a5f92e18ef8a8c9
Analyze and fix the following issue in the Linux kernel code: drm/radeon/kms: fix DVO setup on some r4xx chips
Problem Details: Some r4xx chips have the wrong frev in the DVOEncoderControl table. It should always be 1 on r4xx. Fixes modesetting on DVO on r4xx chips with the bad frev. Reported by twied on #radeon. Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org Signed-off-by: Dave Airlie <a...
```diff diff --git a/drivers/gpu/drm/radeon/atombios_encoders.c b/drivers/gpu/drm/radeon/atombios_encoders.c index e607c4d7dd98..2d39f9977e00 100644 --- a/drivers/gpu/drm/radeon/atombios_encoders.c +++ b/drivers/gpu/drm/radeon/atombios_encoders.c @@ -230,6 +230,10 @@ atombios_dvo_setup(struct drm_encoder *encoder, int ...
6587eb82617f7913c13e750e73e13fa9c829863c
Analyze and fix the following issue in the Linux kernel code: drm/savage: fix integer overflows in savage_bci_cmdbuf()
Problem Details: Since cmdbuf->size and cmdbuf->nbox are from userspace, a large value would overflow the allocation size, leading to out-of-bounds access. Signed-off-by: Xi Wang <xi.wang@gmail.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
```diff diff --git a/drivers/gpu/drm/savage/savage_state.c b/drivers/gpu/drm/savage/savage_state.c index 031aaaf79ac2..b6d8608375cd 100644 --- a/drivers/gpu/drm/savage/savage_state.c +++ b/drivers/gpu/drm/savage/savage_state.c @@ -988,7 +988,7 @@ int savage_bci_cmdbuf(struct drm_device *dev, void *data, struct drm_file...
cd423dd3634a5232a3019eb372b144619a61cd16
Analyze and fix the following issue in the Linux kernel code: usb: dwc3: ep0: increment "actual" on bounced ep0 case
Problem Details: due to a HW limitation we have a bounce buffer for ep0 out transfers which are not aligned with MaxPacketSize. On such case we were not increment r->actual as we should. This patch fixes that mistake. Cc: stable@vger.kernel.org Signed-off-by: Felipe Balbi <balbi@ti.com>
```diff diff --git a/drivers/usb/dwc3/ep0.c b/drivers/usb/dwc3/ep0.c index a40d3bb0f1c2..da43131be0e7 100644 --- a/drivers/usb/dwc3/ep0.c +++ b/drivers/usb/dwc3/ep0.c @@ -569,9 +569,10 @@ static void dwc3_ep0_complete_data(struct dwc3 *dwc, dwc->ep0_bounced = false; } else { transferred = ur->length - length; -...
690142e9882679fac4993bbb01582dd1b9440605
Analyze and fix the following issue in the Linux kernel code: wl12xx: fix DMA-API-related warnings
Problem Details: On the PandaBoard (omap_hsmmc + wl12xx_sdio) with DMA_API_DEBUG: WARNING: at lib/dma-debug.c:930 check_for_stack.part.8+0x7c/0xe0() omap_hsmmc omap_hsmmc.4: DMA-API: device driver maps memory fromstack Signed-off-by: Mircea Gherzan <mgherzan@gmail.com> Signed-off-by: Luciano Coelho <coelho@ti.com>
```diff diff --git a/drivers/net/wireless/wl12xx/boot.c b/drivers/net/wireless/wl12xx/boot.c index 954101d03f06..88d60c40b7e3 100644 --- a/drivers/net/wireless/wl12xx/boot.c +++ b/drivers/net/wireless/wl12xx/boot.c @@ -83,14 +83,22 @@ static void wl1271_parse_fw_ver(struct wl1271 *wl) static void wl1271_boot_fw_vers...
c56dbd57f3627203f2384ae1a5e71cf41904370e
Analyze and fix the following issue in the Linux kernel code: wl12xx: fix race between suspend/resume and recovery
Problem Details: The iteration on the wlvif list in wl1271_op_resume/suspend was perfomed before locking wl->mutex which would lead to a kernel panic in case a recovery was queued at the same time and would delete the wlvifs from the list. Signed-off-by: Eyal Shapira <eyal@wizery.com> Signed-off-by: Luciano Coelho <co...
```diff diff --git a/drivers/net/wireless/wl12xx/main.c b/drivers/net/wireless/wl12xx/main.c index a1ede7b48270..13820437806e 100644 --- a/drivers/net/wireless/wl12xx/main.c +++ b/drivers/net/wireless/wl12xx/main.c @@ -1652,14 +1652,12 @@ static int wl1271_configure_suspend_sta(struct wl1271 *wl, { int ret = 0; - ...
ec414c7c78d6d81c31d77a892fed0b5f691a6d4e
Analyze and fix the following issue in the Linux kernel code: wl12xx: fix station channel switch
Problem Details: Channel switch complete event wasn't handled properly in station mode, as we checked wrong CS flag. Signed-off-by: Victor Goldenshtein <victorg@ti.com> Signed-off-by: Luciano Coelho <coelho@ti.com>
```diff diff --git a/drivers/net/wireless/wl12xx/event.c b/drivers/net/wireless/wl12xx/event.c index c953717f38eb..60e6f27566aa 100644 --- a/drivers/net/wireless/wl12xx/event.c +++ b/drivers/net/wireless/wl12xx/event.c @@ -196,7 +196,7 @@ static int wl1271_event_process(struct wl1271 *wl, struct event_mailbox *mbox) ...
446f5ca19aef28fcc3f42e08b0ad8da7cd59114b
Analyze and fix the following issue in the Linux kernel code: wl12xx: set do_join on BSS_CHANGED_ASSOC
Problem Details: wl12xx sets the do_join flag (which later starts the sta role) when the bssid was changed and the sta is associated. However, this no longer happens after the "mac80211: remove spurious BSSID change flag" patch. Fix it by setting the do_join flag on BSS_CHANGED_ASSOC (for IBSS, do_join is already set ...
```diff diff --git a/drivers/net/wireless/wl12xx/main.c b/drivers/net/wireless/wl12xx/main.c index b1555fb5815b..a1ede7b48270 100644 --- a/drivers/net/wireless/wl12xx/main.c +++ b/drivers/net/wireless/wl12xx/main.c @@ -3791,8 +3791,7 @@ static void wl1271_bss_info_changed_sta(struct wl1271 *wl, wlvif->rssi_thold = b...
a9d5801041eecc7baceff49a28e82f91f207a961
Analyze and fix the following issue in the Linux kernel code: regulator: Fix build error for mc13783 and mc13892
Problem Details: Convert mc13783 and mc13892 to use a struct to pass in regulator runtime configuration. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
```diff diff --git a/drivers/regulator/mc13783-regulator.c b/drivers/regulator/mc13783-regulator.c index 6c0face87ffe..7dcdfa283e93 100644 --- a/drivers/regulator/mc13783-regulator.c +++ b/drivers/regulator/mc13783-regulator.c @@ -340,6 +340,7 @@ static int __devinit mc13783_regulator_probe(struct platform_device *pdev...
fe53d18def245f11fe501d403dd08639927c16f3
Analyze and fix the following issue in the Linux kernel code: regulator: Fix a typo in da903x.c
Problem Details: Fix below build errors which is introduced by commit c172708 "regulator: core: Use a struct to pass in regulator runtime configuration". CC drivers/regulator/da903x.o drivers/regulator/da903x.c: In function 'da903x_regulator_probe': drivers/regulator/da903x.c:541: error: 'conifg' undeclared (fi...
```diff diff --git a/drivers/regulator/da903x.c b/drivers/regulator/da903x.c index 4630b1ee9966..682bdb391abd 100644 --- a/drivers/regulator/da903x.c +++ b/drivers/regulator/da903x.c @@ -538,7 +538,7 @@ static int __devinit da903x_regulator_probe(struct platform_device *pdev) ri->desc.ops = &da9030_regulator_ldo1_15...
b3aa1584e9f3449b0669ab2beb9b9bf99874e1d6
Analyze and fix the following issue in the Linux kernel code: workqueue: Fix workqueue_execute_end() comment
Problem Details: workqueue_execute_end() is called after the callback function, not before. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Acked-by: Tejun Heo <tj@kernel.org> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
```diff diff --git a/include/trace/events/workqueue.h b/include/trace/events/workqueue.h index 7d497291c85d..4018f5058f27 100644 --- a/include/trace/events/workqueue.h +++ b/include/trace/events/workqueue.h @@ -103,7 +103,7 @@ TRACE_EVENT(workqueue_execute_start, ); /** - * workqueue_execute_end - called immediatel...
ac97c62071e469a67e9019998ccef68a5356ed7f
Analyze and fix the following issue in the Linux kernel code: regulator: Fix build of ab8500
Problem Details: Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
```diff diff --git a/drivers/regulator/ab8500.c b/drivers/regulator/ab8500.c index 93feadaf40c0..d1563907d3c8 100644 --- a/drivers/regulator/ab8500.c +++ b/drivers/regulator/ab8500.c @@ -780,9 +780,9 @@ static __devinit int ab8500_regulator_probe(struct platform_device *pdev) info = &ab8500_regulator_info[i]; inf...
08f1ec8a594c60bf3856e3c45b6d15fd691d90bb
Analyze and fix the following issue in the Linux kernel code: powerpc: Fix page fault with lockdep regression
Problem Details: commit a546498f3bf9aac311c66f965186373aee2ca0b0 introduced a regression on 32-bit when irq tracing is enabled by exposing an old bug in our irq tracing code for exception entry. The code would save and restore some GPRs around the calls to the C lockdep code, however, it tries to be too smart for its ...
```diff diff --git a/arch/powerpc/kernel/entry_32.S b/arch/powerpc/kernel/entry_32.S index 3e57a00b8cba..ba3aeb4bc06a 100644 --- a/arch/powerpc/kernel/entry_32.S +++ b/arch/powerpc/kernel/entry_32.S @@ -206,40 +206,43 @@ reenable_mmu: /* re-enable mmu so we can */ andi. r10,r10,MSR_EE /* Did EE change? */ beq 1...
507230c9997ef47147818508108b97b3e189826f
Analyze and fix the following issue in the Linux kernel code: ALSA: riptide: remove redundant NULL test before release_firmware()
Problem Details: release_firmware() deals gracefully with NULL pointers, no need to check first. Signed-off-by: Jesper Juhl <jj@chaosbits.net> Signed-off-by: Takashi Iwai <tiwai@suse.de>
```diff diff --git a/sound/pci/riptide/riptide.c b/sound/pci/riptide/riptide.c index 0481d94aac9b..cbeb3f77350c 100644 --- a/sound/pci/riptide/riptide.c +++ b/sound/pci/riptide/riptide.c @@ -1837,8 +1837,7 @@ static int snd_riptide_free(struct snd_riptide *chip) } if (chip->irq >= 0) free_irq(chip->irq, chip); -...
fd34ef9bc44b87d746b7178e9c4ba51163b46884
Analyze and fix the following issue in the Linux kernel code: sh: kgdb: Fix up NULL pointer deref by kgdb_nmicallback.
Problem Details: kgdb_nmicallback expects valid register state, so just fetch the register state with get_irq_regs() as on other platforms. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
```diff diff --git a/arch/sh/kernel/kgdb.c b/arch/sh/kernel/kgdb.c index ba8e76325d12..38b313909ac9 100644 --- a/arch/sh/kernel/kgdb.c +++ b/arch/sh/kernel/kgdb.c @@ -313,7 +313,7 @@ BUILD_TRAP_HANDLER(singlestep) static void kgdb_call_nmi_hook(void *ignored) { - kgdb_nmicallback(raw_smp_processor_id(), NULL); + kg...
258f742635360175564e9470eb060ff4d4b984e7
Analyze and fix the following issue in the Linux kernel code: modpost: Fix modpost license checking of vmlinux.o
Problem Details: Commit f02e8a6596b7 ("module: Sort exported symbols") sorts symbols placing each of them in its own elf section. This sorting and merging into the canonical sections are done by the linker. Unfortunately modpost to generate Module.symvers file parses vmlinux.o (which is not linked yet) and all module...
```diff diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c index 3f01fd908730..c4e7d1510f9d 100644 --- a/scripts/mod/modpost.c +++ b/scripts/mod/modpost.c @@ -132,8 +132,10 @@ static struct module *new_module(char *modname) /* strip trailing .o */ s = strrchr(p, '.'); if (s != NULL) - if (strcmp(s, ".o")...
14f087d839d9bd3f90ad69d4b3fde7d236c156b1
Analyze and fix the following issue in the Linux kernel code: sh: kgdb: Fix up basic SMP support.
Problem Details: kgdb needs a kgdb_roundup_cpus() definition in the architecture backend, so just copy over the MIPS version, which already does what we want. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
```diff diff --git a/arch/sh/kernel/kgdb.c b/arch/sh/kernel/kgdb.c index b117781bfea2..93458880acad 100644 --- a/arch/sh/kernel/kgdb.c +++ b/arch/sh/kernel/kgdb.c @@ -264,6 +264,18 @@ BUILD_TRAP_HANDLER(singlestep) local_irq_restore(flags); } +static void kgdb_call_nmi_hook(void *ignored) +{ + kgdb_nmicallback(raw...
879d38e6bc36d73b0ac40ec9b0d839fda9fa8b1a
Analyze and fix the following issue in the Linux kernel code: USB: fix race between root-hub suspend and remote wakeup
Problem Details: This patch (as1533) fixes a race between root-hub suspend and remote wakeup. If a wakeup event occurs while a root hub is suspending, it might not cause the suspend to fail. Although the host controller drivers check for pending wakeup events at the start of their bus_suspend routines, they generally...
```diff diff --git a/drivers/usb/core/hcd.c b/drivers/usb/core/hcd.c index 9d7fc9a39933..140d3e11f212 100644 --- a/drivers/usb/core/hcd.c +++ b/drivers/usb/core/hcd.c @@ -1978,6 +1978,18 @@ int hcd_bus_suspend(struct usb_device *rhdev, pm_message_t msg) if (status == 0) { usb_set_device_state(rhdev, USB_STATE_SUSP...
876ae50d94b02f3f523aa451b45ec5fb9c25d221
Analyze and fix the following issue in the Linux kernel code: USB: ftdi_sio: fix race condition in TIOCMIWAIT, and abort of TIOCMIWAIT when the device is removed
Problem Details: There are two issues here, one is that the device is generating spurious very fast modem status line changes somewhere: CTS becomes high then low 18µs later: [121226.924373] ftdi_process_packet: prev rng=0 dsr=10 dcd=0 cts=6 [121226.924378] ftdi_process_packet: status=10 prev=00 diff=10 [121226.924382...
```diff diff --git a/drivers/usb/serial/ftdi_sio.c b/drivers/usb/serial/ftdi_sio.c index c02e4602d90a..02e7f2d32d52 100644 --- a/drivers/usb/serial/ftdi_sio.c +++ b/drivers/usb/serial/ftdi_sio.c @@ -76,6 +76,7 @@ struct ftdi_private { struct async_icount icount; wait_queue_head_t delta_msr_wait; /* Used for TIOCMIW...
fca5430d48d53eaf103498c33fd0d1984b9f448b
Analyze and fix the following issue in the Linux kernel code: USB: ftdi_sio: fix status line change handling for TIOCMIWAIT and TIOCGICOUNT
Problem Details: Handling of TIOCMIWAIT was changed by commit 1d749f9afa657f6ee9336b2bc1fcd750a647d157 USB: ftdi_sio.c: Use ftdi async_icount structure for TIOCMIWAIT, as in other drivers FTDI_STATUS_B0_MASK does not indicate the changed modem status lines, it indicates the value of the current modem status lines. An...
```diff diff --git a/drivers/usb/serial/ftdi_sio.c b/drivers/usb/serial/ftdi_sio.c index ff8605b4b4be..c02e4602d90a 100644 --- a/drivers/usb/serial/ftdi_sio.c +++ b/drivers/usb/serial/ftdi_sio.c @@ -75,7 +75,7 @@ struct ftdi_private { unsigned long last_dtr_rts; /* saved modem control outputs */ struct async_icount...
cd4376e23a59a2adf3084cb5f4a523e6d5fd4e49
Analyze and fix the following issue in the Linux kernel code: USB: don't ignore suspend errors for root hubs
Problem Details: This patch (as1532) fixes a mistake in the USB suspend code. When the system is going to sleep, we should ignore errors in powering down USB devices, because they don't really matter. The devices will go to low power anyway when the entire USB bus gets suspended (except for SuperSpeed devices; maybe ...
```diff diff --git a/drivers/usb/core/driver.c b/drivers/usb/core/driver.c index f8e2d6d52e5c..9a56635dc19c 100644 --- a/drivers/usb/core/driver.c +++ b/drivers/usb/core/driver.c @@ -1189,8 +1189,13 @@ static int usb_suspend_both(struct usb_device *udev, pm_message_t msg) if (status == 0) { status = usb_suspend_de...
891a3b1fddb24b4b53426685bd0390bb74c9b5b3
Analyze and fix the following issue in the Linux kernel code: USB: fix bug in serial driver unregistration
Problem Details: This patch (as1536) fixes a bug in the USB serial core. Unloading and reloading a serial driver while a serial device is plugged in causes errors because of the code in usb_serial_disconnect() that tries to make sure the port_remove method is called. With the new order of driver registration introduc...
```diff diff --git a/drivers/usb/serial/bus.c b/drivers/usb/serial/bus.c index 7f547dc3a590..ed8adb052ca7 100644 --- a/drivers/usb/serial/bus.c +++ b/drivers/usb/serial/bus.c @@ -60,8 +60,6 @@ static int usb_serial_device_probe(struct device *dev) retval = -ENODEV; goto exit; } - if (port->dev_state != PORT_REG...
3a450850e2bb0f92cacb12da90fe98eccd105468
Analyze and fix the following issue in the Linux kernel code: USB: serial: metro-usb: Fix idProduct for Uni-Directional mode.
Problem Details: The right idProduct for Metrologic Bar Code Scanner in Uni-Directional Serial Emulation mode is 0x0700. Also rename idProduct for Bi-Directional mode to be a bit more informative. Signed-off-by: Aleksey Babahin <tamerlan311@gmail.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hart...
```diff diff --git a/drivers/usb/serial/metro-usb.c b/drivers/usb/serial/metro-usb.c index 6e1622f2a297..08d16e8c002d 100644 --- a/drivers/usb/serial/metro-usb.c +++ b/drivers/usb/serial/metro-usb.c @@ -27,8 +27,8 @@ /* Product information. */ #define FOCUS_VENDOR_ID 0x0C2E -#define FOCUS_PRODUCT_ID 0x0720 -#def...