id
stringlengths
40
40
instruction
stringlengths
68
308
input
stringlengths
17
33.4k
output
stringlengths
100
30k
a83520f432a335ff12f260e9cf3602eabb64ee48
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12560): Fix a number of EXPORT_SYMBOL warnings
Problem Details: Make Checkpatch tool happy: -:2349: WARNING: EXPORT_SYMBOL(foo); should immediately follow its function/variable On all cases, it were just a blank line at the wrong place. Yet, fixing it is trivial Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/common/ir-keymaps.c b/drivers/media/common/ir-keymaps.c index 08024d214983..3e059684906d 100644 --- a/drivers/media/common/ir-keymaps.c +++ b/drivers/media/common/ir-keymaps.c @@ -28,7 +28,6 @@ IR_KEYTAB_TYPE ir_codes_empty[IR_KEYTAB_SIZE] = { [0x2a] = KEY_COFFEE, }; - EXPORT_SYM...
97fd4f7fb62b018ff7afc0aea8cfffa2d79e59cd
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12557): Use C99 comment CodingStyle
Problem Details: The ir-keymaps.c has frequent additions. As people tend to copy an old keyboard entry, a bad CodingStyle at an ancient entry may result on a freshly bad CodingStyle patch. So, better to fix the CodingStyle for the entire file. This patch is the first of a series of patches fixing it, generated by som...
```diff diff --git a/drivers/media/common/ir-keymaps.c b/drivers/media/common/ir-keymaps.c index c222b7f15184..13878b047a3d 100644 --- a/drivers/media/common/ir-keymaps.c +++ b/drivers/media/common/ir-keymaps.c @@ -64,41 +64,41 @@ IR_KEYTAB_TYPE ir_codes_proteus_2309[IR_KEYTAB_SIZE] = { EXPORT_SYMBOL_GPL(ir_codes_prot...
89dec01b7e251697720ac3d6a5310d72359eba69
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12489): pwc - fix few use-after-free and memory leaks
Problem Details: I just happen to peek inside the PWC driver and did not like what I saw there. Please consider applying the patch below. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/pwc/pwc-if.c b/drivers/media/video/pwc/pwc-if.c index 8d17cf613306..f976df452a34 100644 --- a/drivers/media/video/pwc/pwc-if.c +++ b/drivers/media/video/pwc/pwc-if.c @@ -1057,7 +1057,8 @@ static int pwc_create_sysfs_files(struct video_device *vdev) goto err; if (pdev->featu...
7ae26889635d0708bb2a0b5d21f99368abc2366c
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12487): Fix control AC-3 of the 6752HS
Problem Details: Fix error for AC-3 control of the 6752HS MPEG-2 coder. Signed-off-by: Beholder Intl. Ltd. Dmitry Belimov <d.belimov@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/saa7134/saa6752hs.c b/drivers/media/video/saa7134/saa6752hs.c index 63c4b8f1f541..1eabff6b2456 100644 --- a/drivers/media/video/saa7134/saa6752hs.c +++ b/drivers/media/video/saa7134/saa6752hs.c @@ -468,7 +468,7 @@ static int handle_ctrl(int has_ac3, struct saa6752hs_mpeg_params ...
ad5f74c0ad9afcc9a20f35850aa5170768c64a0c
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12486): cx88: fix TBS 8920 card support
Problem Details: It does matter to set explicitly gpio0 value in cx88_board structure for TBS 8920 card. Signed-off-by: Igor M. Liplianin <liplianin@me.by> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/cx88/cx88-cards.c b/drivers/media/video/cx88/cx88-cards.c index 43aa7e06e5bc..e5f07fbd5a35 100644 --- a/drivers/media/video/cx88/cx88-cards.c +++ b/drivers/media/video/cx88/cx88-cards.c @@ -1953,7 +1953,8 @@ static const struct cx88_board cx88_boards[] = { .radio_addr = A...
166987c6987a25a95cef6889d24088f0eb2daa36
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12482): firedtv: add PID filtering for SW zigzag retune
Problem Details: The AVC protocol uses the same command for tuning and PID filtering and since dvb-core uses a software zigzagging to do automatic retuning this could cause all PID filters to be cleared. PID filter information is now included in all DSD commands to the card. Background: There is a problem in the fir...
```diff diff --git a/drivers/media/dvb/firewire/firedtv-avc.c b/drivers/media/dvb/firewire/firedtv-avc.c index 32526f103b59..1a94c6bb601c 100644 --- a/drivers/media/dvb/firewire/firedtv-avc.c +++ b/drivers/media/dvb/firewire/firedtv-avc.c @@ -254,6 +254,26 @@ int avc_recv(struct firedtv *fdtv, void *data, size_t length...
114323ede9e84a64327b74ff6f7da5576c9ae361
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12481): Fix lowband tuning with tda8261
Problem Details: Attached is a patch which fixes tuning to low frequency channels with stb0899+tda8261 cards like the KNC TV-Station DVB-S2. The cause of the issue was a broken if construct, which should have been an if/else if, so that the setting for the lowest matching frequency is applied. Without this patch for e...
```diff diff --git a/drivers/media/dvb/frontends/tda8261.c b/drivers/media/dvb/frontends/tda8261.c index b6d177799104..320c3c36d8b2 100644 --- a/drivers/media/dvb/frontends/tda8261.c +++ b/drivers/media/dvb/frontends/tda8261.c @@ -136,9 +136,9 @@ static int tda8261_set_state(struct dvb_frontend *fe, if (frequency ...
d6f76b979c9f83aaf2fa3d51eb5b175690f7acbc
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12478): ARRAY_SIZE changes
Problem Details: These changes were a direct result of using a semantic patch More information can be found at http://www.emn.fr/x-info/coccinelle/ [mchehab@redhat.com: fix a merge conflict] Signed-off-by: Stoyan Gaydarov <sgayda2@uiuc.edu> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/gspca/conex.c b/drivers/media/video/gspca/conex.c index 8d48ea1742c2..eca003566ae3 100644 --- a/drivers/media/video/gspca/conex.c +++ b/drivers/media/video/gspca/conex.c @@ -820,7 +820,7 @@ static int sd_config(struct gspca_dev *gspca_dev, cam = &gspca_dev->cam; cam->cam_m...
1c2ca352944e1899e72a39cc640d874dfa008a1b
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12472): hdpvr-control: fix bad whitespaces
Problem Details: It were using 7 spaces instead of tab for indent. Cc: Janne Grunau <j@jannau.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/hdpvr/hdpvr-control.c b/drivers/media/video/hdpvr/hdpvr-control.c index 06791749d1a0..5a6b78b8d25d 100644 --- a/drivers/media/video/hdpvr/hdpvr-control.c +++ b/drivers/media/video/hdpvr/hdpvr-control.c @@ -178,24 +178,24 @@ error: int hdpvr_set_options(struct hdpvr_device *de...
272ece5e798b7ff0d9bc083fe7df2e960e8d5db8
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12471): stv06xx: fix bad whitespaces
Problem Details: It were using 7 spaces instead of tab for indent. Cc: Erik Andren <erik.andren@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/gspca/stv06xx/stv06xx.c b/drivers/media/video/gspca/stv06xx/stv06xx.c index 0da8e0de0456..7af511b5e9c2 100644 --- a/drivers/media/video/gspca/stv06xx/stv06xx.c +++ b/drivers/media/video/gspca/stv06xx/stv06xx.c @@ -130,8 +130,8 @@ int stv06xx_write_sensor_bytes(struct sd *sd, con...
8ccd4cd07e36bd8529010a520865fa275c3051f0
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12470): cx231xx/cx231xx-conf-reg.h: fix bad whitespaces
Problem Details: It were using 7 spaces instead of tab for indent. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/cx231xx/cx231xx-conf-reg.h b/drivers/media/video/cx231xx/cx231xx-conf-reg.h index a6f398a175c5..31a8759f6e54 100644 --- a/drivers/media/video/cx231xx/cx231xx-conf-reg.h +++ b/drivers/media/video/cx231xx/cx231xx-conf-reg.h @@ -60,10 +60,10 @@ #define PWR_RESETOUT_EN 0x10...
dfb4ba1e13061b655cb2d077f621fc87cf4e920f
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12468): saa7134: Fix bad whitespacing
Problem Details: The changeset 0b17d0ed that aded ASUSTeK P7131 Analog were using 7 spaces instead of tab, probably due to some bad cut-and-paste. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/saa7134/saa7134-cards.c b/drivers/media/video/saa7134/saa7134-cards.c index b15d696dff47..faf2e70a74f1 100644 --- a/drivers/media/video/saa7134/saa7134-cards.c +++ b/drivers/media/video/saa7134/saa7134-cards.c @@ -3663,8 +3663,8 @@ struct saa7134_board saa7134_boards[] = { ....
b24ed7b662351c8ea5c4b3dbc879c9971e721070
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12466): Kconfig files: Fix improper use of whitespaces
Problem Details: On VIDEO_M52790 and USB_GSPCA_SN9C20X, instead of tab, it were using 7 whitespaces at the beginning, probably due to some cut-and-paste trouble. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/Kconfig b/drivers/media/video/Kconfig index dcf9fa9264bb..1d758525d236 100644 --- a/drivers/media/video/Kconfig +++ b/drivers/media/video/Kconfig @@ -203,9 +203,9 @@ config VIDEO_CS53L32A module will be called cs53l32a. config VIDEO_M52790 - tristate "Mitsubishi M52...
3c1c48bbcf892e97c4e965b8528f4d735bf9a746
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12465): cx88: High resolution timer for Remote Controls
Problem Details: Patch solves problem of missed keystrokes on some remote controls, as reported on http://bugzilla.kernel.org/show_bug.cgi?id=9637 . Signed-off-by: Andrzej Hajda <andrzej.hajda@wp.pl> Signed-off-by: Jean Delvare <khali@linux-fr.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/Documentation/video4linux/CARDLIST.saa7134 b/Documentation/video4linux/CARDLIST.saa7134 index c913e5614195..dc0576afe5dd 100644 --- a/Documentation/video4linux/CARDLIST.saa7134 +++ b/Documentation/video4linux/CARDLIST.saa7134 @@ -167,3 +167,4 @@ 166 -> Beholder BeholdTV 607 RDS [5ac...
17d8dfe8c8a23dfadd714315465d992410bebd88
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12452): gspca/Kconfig: Fix bad identation for USB_GSPCA_SN9C20X_EVDEV
Problem Details: Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/gspca/Kconfig b/drivers/media/video/gspca/Kconfig index e994dcac43ff..f114dd1507c2 100644 --- a/drivers/media/video/gspca/Kconfig +++ b/drivers/media/video/gspca/Kconfig @@ -113,10 +113,10 @@ config USB_GSPCA_SN9C20X module will be called gspca_sn9c20x. config USB_GSPCA_SN...
a35c87c7084f3f4972f3ce5f23cfcb34f95341b1
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12434): em28xx: fix empire auto-detect
Problem Details: Fixed eeprom hash table Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/em28xx/em28xx-cards.c b/drivers/media/video/em28xx/em28xx-cards.c index 22a464f5007b..02e24411b134 100644 --- a/drivers/media/video/em28xx/em28xx-cards.c +++ b/drivers/media/video/em28xx/em28xx-cards.c @@ -1663,7 +1663,7 @@ static struct em28xx_hash_table em28xx_eeprom_hash[] = ...
eb2de30b318ae583fef113cac94150924ae1ed6b
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12427): cx24113: fix mips compiler warning
Problem Details: do_div requires an u64 as the first argument, not a s64. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Acked-by: Patrick Boettcher <pboettcher@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/dvb/frontends/cx24113.c b/drivers/media/dvb/frontends/cx24113.c index e4fd533a427c..075b2b57cf09 100644 --- a/drivers/media/dvb/frontends/cx24113.c +++ b/drivers/media/dvb/frontends/cx24113.c @@ -303,6 +303,7 @@ static void cx24113_calc_pll_nf(struct cx24113_state *state, u16 *n, s32 ...
f19b56a8eb54d758bff94ae6a1b4f79335155238
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12426): pvrusb2: fix compile warning
Problem Details: Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Acked-by: Mike Isely <isely@pobox.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/pvrusb2/pvrusb2-audio.c b/drivers/media/video/pvrusb2/pvrusb2-audio.c index 416933ca607d..cc06d5e4adcc 100644 --- a/drivers/media/video/pvrusb2/pvrusb2-audio.c +++ b/drivers/media/video/pvrusb2/pvrusb2-audio.c @@ -65,9 +65,10 @@ void pvr2_msp3400_subdev_update(struct pvr2_hdw *h...
46058128ff57db466ec132cb7de76cf9ecbd3dd3
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12420): saa7134: fix the radio on Avermedia GO 007 FM
Problem Details: We have support for radio on saa7133/35/31e cards with tda8290/8275(a) and 5.5MHz ceramic filter on the bridge chips since a while. It was previously not tested, if this card supports it too, but the old "ghost" radio with wrong filters doesn't work anymore. Thanks go to Pham Thanh Nam and Laszlo Kus...
```diff diff --git a/drivers/media/video/saa7134/saa7134-cards.c b/drivers/media/video/saa7134/saa7134-cards.c index 47dbbf555a12..e1d89b232392 100644 --- a/drivers/media/video/saa7134/saa7134-cards.c +++ b/drivers/media/video/saa7134/saa7134-cards.c @@ -1633,7 +1633,7 @@ struct saa7134_board saa7134_boards[] = { }}...
4786dd65fc354cae804635726c2768b8559a51bf
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12419): Fix incorrect type of tuner for the BeholdTV H6 card
Problem Details: Define correct tuner in config. Radio now works fine Signed-off-by: Beholder Intl. Ltd. Dmitry Belimov <d.belimov@gmail.com> Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/saa7134/saa7134-cards.c b/drivers/media/video/saa7134/saa7134-cards.c index 6eebe3ef97d3..47dbbf555a12 100644 --- a/drivers/media/video/saa7134/saa7134-cards.c +++ b/drivers/media/video/saa7134/saa7134-cards.c @@ -4861,7 +4861,7 @@ struct saa7134_board saa7134_boards[] = { /*...
0b0157398eb5c0786567b11fcf651147b0892c81
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12388): dvb-usb: fix tuning with Cinergy T2
Problem Details: cinergyInitialize param.flags. Signed-off-by: Eberhard Mattes <eberhard.mattes@web.de> Signed-off-by: Thierry MERLE <thierry.merle@free.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/dvb/dvb-usb/cinergyT2-fe.c b/drivers/media/dvb/dvb-usb/cinergyT2-fe.c index 649f25cca49e..9cd51ac12076 100644 --- a/drivers/media/dvb/dvb-usb/cinergyT2-fe.c +++ b/drivers/media/dvb/dvb-usb/cinergyT2-fe.c @@ -275,6 +275,7 @@ static int cinergyt2_fe_set_frontend(struct dvb_frontend *fe,...
6c428b578b15a1dbf40832d3aeed43761940b81f
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12376): em28xx: fix V4L2 API compliance: don't expose audio inputs for devices without it
Problem Details: V4L2 API (chapter 1.5) states that: Drivers must implement all input ioctls when the device has one or more inputs, all output ioctls when the device has one or more outputs. When the device has any audio inputs or outputs the driver must set the V4L2_CAP_AUDIO flag in the struct v4l2_capability r...
```diff diff --git a/drivers/media/video/em28xx/em28xx-video.c b/drivers/media/video/em28xx/em28xx-video.c index 477b9b67eaeb..f3ee001f21ca 100644 --- a/drivers/media/video/em28xx/em28xx-video.c +++ b/drivers/media/video/em28xx/em28xx-video.c @@ -1005,6 +1005,9 @@ static int vidioc_g_audio(struct file *file, void *priv...
00c1e2167e3163d2e193644b7d768f06d2a8c279
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12373): hdpvr: fix lock imbalances
Problem Details: There are many lock imbalances in this driver. Fix all found. Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/hdpvr/hdpvr-core.c b/drivers/media/video/hdpvr/hdpvr-core.c index 188bd5aea258..1c9bc94c905c 100644 --- a/drivers/media/video/hdpvr/hdpvr-core.c +++ b/drivers/media/video/hdpvr/hdpvr-core.c @@ -126,7 +126,7 @@ static int device_authorization(struct hdpvr_device *dev) char *pri...
b9ab3508efa57905ae037ddf48c97ea6ed74b799
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12372): saa7134: fix lock imbalance
Problem Details: There seems to be one superfluos unlock in a poll function. Remove it. Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/saa7134/saa7134-video.c b/drivers/media/video/saa7134/saa7134-video.c index 58854df5382b..da26f476a302 100644 --- a/drivers/media/video/saa7134/saa7134-video.c +++ b/drivers/media/video/saa7134/saa7134-video.c @@ -1444,7 +1444,6 @@ video_poll(struct file *file, struct poll_table...
575f9af89952c7e7703e48666d95609daaf99630
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12370): v4l doc: fix cqcam source code path
Problem Details: Fixed the c-qcam source code path in the linux kernel tree. Signed-off-by: Mhayk Whandson <eu@mhayk.com.br> Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/Documentation/video4linux/CQcam.txt b/Documentation/video4linux/CQcam.txt index 04986efb731c..d230878e473e 100644 --- a/Documentation/video4linux/CQcam.txt +++ b/Documentation/video4linux/CQcam.txt @@ -18,8 +18,8 @@ Table of Contents 1.0 Introduction - The file ../drivers/char/c-qcam.c is a d...
5376176199fdd55e6310738bfacb57bf606f16bf
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12360): au0828: fix typo: dvb uses bulk xfer, dont say isoc in debug
Problem Details: The au0828-dvb driver uses bulk usb transfers for digital transport, but the debug reports, "iso xfer already running!\n". Fix this to report bulk instead of isoc. Signed-off-by: Michael Krufky <mkrufky@kernellabs.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/au0828/au0828-dvb.c b/drivers/media/video/au0828/au0828-dvb.c index 14baffc22192..b8a4b52e8d47 100644 --- a/drivers/media/video/au0828/au0828-dvb.c +++ b/drivers/media/video/au0828/au0828-dvb.c @@ -151,7 +151,7 @@ static int start_urb_transfer(struct au0828_dev *dev) dprintk(2...
4041f6b3b4deaa3c67fbe71b67c3c18ac9ce0207
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12352): gspca - vc032x: Fix mi1310_soc preview and LED
Problem Details: The patches gspca - vc032x: Add resolution 1280x1024 for sensor mi1310_soc. gspca - vc032x: Webcam 041e:405b added and mi1310_soc updated. will make the preview function not work, so I disable the 1280x1024 resolution and revert back to the origin mi1310_soc settings. And, using USB snoop tool on Win...
```diff diff --git a/drivers/media/video/gspca/vc032x.c b/drivers/media/video/gspca/vc032x.c index 5b6f717d3fe4..cda14583bc35 100644 --- a/drivers/media/video/gspca/vc032x.c +++ b/drivers/media/video/gspca/vc032x.c @@ -425,208 +425,92 @@ static const __u8 mi0360_initQVGA_JPG[][4] = { static const __u8 mi1310_socinitVG...
00b581ef0d31db9c28215254b64f3890c7c9f939
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12351): gspca - sn9c20x: Misc fixes
Problem Details: * use i2c_w instead of reg_w * return error on failure * read the correct number of bytes Signed-off-by: Brian Johnson <brijohn@gmail.com> Signed-off-by: Jean-Francois Moine <moinejf@free.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/gspca/sn9c20x.c b/drivers/media/video/gspca/sn9c20x.c index fcfbbd329b4c..52a7f8edf7ac 100644 --- a/drivers/media/video/gspca/sn9c20x.c +++ b/drivers/media/video/gspca/sn9c20x.c @@ -1096,12 +1096,12 @@ int i2c_w(struct gspca_dev *gspca_dev, const u8 *buffer) reg_r(gspca_dev, ...
f3d6f63302bfcd7462d46bd1fe44146c971634d4
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12347): cx25840: Bugfix for no DVB-T on the Hauppauge HVR-1700
Problem Details: After the i2c subdev changes the ordering of initialization changed, causing a total loss of previous GPIO settings and a loss of DTV. The generic firmware loading routine has now changed to preserve GPIO values if the device is cx23885 based (safety) and I've moved the GPIO configuration from probe() ...
```diff diff --git a/drivers/media/video/cx25840/cx25840-core.c b/drivers/media/video/cx25840/cx25840-core.c index 0be51b65f098..1aeaf18a9bea 100644 --- a/drivers/media/video/cx25840/cx25840-core.c +++ b/drivers/media/video/cx25840/cx25840-core.c @@ -321,6 +321,15 @@ static void cx23885_initialize(struct i2c_client *cl...
73c6f462d1d07f276e279467f311a96a2a43d9c5
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12345): em28xx: fix audio VIDIOC_S_CTRL adjustments on devices without ac97
Problem Details: Even devices without ac97 needs to call analog audio setup function, to properly set xclk and mute/unmute. Thanks to Angelo Cano <acano@fastmail.fm> for reporting and testing it. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/em28xx/em28xx-video.c b/drivers/media/video/em28xx/em28xx-video.c index 7ed3051554c1..477b9b67eaeb 100644 --- a/drivers/media/video/em28xx/em28xx-video.c +++ b/drivers/media/video/em28xx/em28xx-video.c @@ -1146,11 +1146,25 @@ static int vidioc_s_ctrl(struct file *file, void *pri...
43f8de7ac6d504dea159d7842724857e9e020964
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12342): af9015: avoid magically sized temporary buffer in eeprom_dump
Problem Details: Replace printing to magically sized temporary buffer with use of KERN_CONT for continual printing of eeprom registers dump. Since deb_info is defined as dprintk, which is conditionally defined to printk without additional parameters, meaning that deb_info is equivalent to direct printk (without adding...
```diff diff --git a/drivers/media/dvb/dvb-usb/af9015.c b/drivers/media/dvb/dvb-usb/af9015.c index 26690dfb3260..00fbaf56c61b 100644 --- a/drivers/media/dvb/dvb-usb/af9015.c +++ b/drivers/media/dvb/dvb-usb/af9015.c @@ -538,24 +538,22 @@ exit: /* dump eeprom */ static int af9015_eeprom_dump(struct dvb_usb_device *d) ...
1420d498fd8890bbd878d261f317f9d64544ce0b
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12336): ivtv: Fix improper GPIO audio mux input switch on video standard change
Problem Details: Remove the subdev_s_std() method from the GPIO subdev. It appears it was used in the past to effect the switch back from radio mode to tuner mode, but it had a side effect that is improper and against the V4L2 spec, when you were not in radio mode. Whenever the video stanadrd was changed, the GPIO au...
```diff diff --git a/drivers/media/video/ivtv/ivtv-gpio.c b/drivers/media/video/ivtv/ivtv-gpio.c index 85ac707228e7..aede061cae5d 100644 --- a/drivers/media/video/ivtv/ivtv-gpio.c +++ b/drivers/media/video/ivtv/ivtv-gpio.c @@ -236,18 +236,6 @@ static int subdev_s_radio(struct v4l2_subdev *sd) return 0; } -static i...
d31b67d81b1b724d0610e9f0cfeac494d62ffca4
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12335): ivtv: Fix errors in AVerTV M113 card definitions and add a new M113 card
Problem Details: Tested-by: Ravi A. <asvravi@gmail.com> Signed-off-by: Andy Walls <awalls@radix.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/ivtv/ivtv-cards.c b/drivers/media/video/ivtv/ivtv-cards.c index 40c29032f292..4873b6ca5801 100644 --- a/drivers/media/video/ivtv/ivtv-cards.c +++ b/drivers/media/video/ivtv/ivtv-cards.c @@ -977,26 +977,27 @@ static const struct ivtv_card ivtv_card_avertv_mce116 = { /* -------...
76594c5315d843fb1d3bffe7a8e2559086755f72
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12326): zr364xx: error message when buffer is too small and code cleanup
Problem Details: . added code to print an error message when buffer is too small to hold frame data, that is better than just a hard crash. Tested using MAX_FRAME_SIZE = 50000, lots of error messages appeared in /var/log/messages but no crash. . removed line "f->type = V4L2_BUF_TYPE_VIDEO_CAPTURE;" in zr364xx_vidioc_t...
```diff diff --git a/drivers/media/video/zr364xx.c b/drivers/media/video/zr364xx.c index 009f8733cb16..9aae011d92ab 100644 --- a/drivers/media/video/zr364xx.c +++ b/drivers/media/video/zr364xx.c @@ -66,6 +66,13 @@ } \ } while (0) +/*#define FULL_DEBUG 1*/ +#ifdef FULL_DEBUG +#define _DBG DBG +#else +#define _DBG...
fc7e4a3e7201ee8a9a6359fdbcb6677231f353b5
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12312): stv0900: fix i2c repeater configuration must be set to manual
Problem Details: In automatic mode every stop event on SDA line ends repetition. However, in NetUP Dual card on the same i2c bus we have several devices. If someone using both adapters to lock simultaneously or working with CAM interface during lock procedure, it lead to end repetition prematurely quite often. Set stv...
```diff diff --git a/drivers/media/dvb/frontends/stv0900_core.c b/drivers/media/dvb/frontends/stv0900_core.c index 1da045fbb4ef..3bde3324a032 100644 --- a/drivers/media/dvb/frontends/stv0900_core.c +++ b/drivers/media/dvb/frontends/stv0900_core.c @@ -230,8 +230,8 @@ enum fe_stv0900_error stv0900_initialize(struct stv09...
7a6fbd83378dd0a6127b5d59a51d35688bcd6d9d
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12294): b2c2: Use dvb-pll for Cablestar2
Problem Details: The dvb-pll code should do the same thing that alps_tdee4_stv0297_tuner_set_params() was doing. Except the dvb-pll code will check for tuner presence when attaching, while the old code didn't. This tuner appears to not be behind the stv0297's I2C gate but is instead on a different I2C adapter provide...
```diff diff --git a/drivers/media/dvb/b2c2/flexcop-fe-tuner.c b/drivers/media/dvb/b2c2/flexcop-fe-tuner.c index 5bf9049c6c00..850a6c606750 100644 --- a/drivers/media/dvb/b2c2/flexcop-fe-tuner.c +++ b/drivers/media/dvb/b2c2/flexcop-fe-tuner.c @@ -511,54 +511,7 @@ static int airstar_atsc3_attach(struct flexcop_device *f...
3bd10fc9f53fffe5913619733d7b1707a06899cf
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12210): ivtv: Fix automatic detection of AVerMedia UltraTV 1500MCE.
Problem Details: My initial change left the AVerMedia UtlraTV 1500MCE card entry out of the list of cards to check during the probe. This change adds it to the ivtv_card_list[]. Signed-off-by: Andy Walls <awalls@radix.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/ivtv/ivtv-cards.c b/drivers/media/video/ivtv/ivtv-cards.c index 553a314fa436..40c29032f292 100644 --- a/drivers/media/video/ivtv/ivtv-cards.c +++ b/drivers/media/video/ivtv/ivtv-cards.c @@ -1224,6 +1224,7 @@ static const struct ivtv_card *ivtv_card_list[] = { &ivtv_card_aver_e...
0389b34e7c5c2dcdef61ed1741db674b47e4dc00
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12200): mt312: Fix checkpatch warnings
Problem Details: This patch fixes some checkpatch warnings in mt312-driver. Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/dvb/frontends/mt312.c b/drivers/media/dvb/frontends/mt312.c index f69daaac78c9..472907d43460 100644 --- a/drivers/media/dvb/frontends/mt312.c +++ b/drivers/media/dvb/frontends/mt312.c @@ -85,7 +85,7 @@ static int mt312_read(struct mt312_state *state, const enum mt312_reg_addr reg, ...
d33fbcbb21ba53358ba8a83765cfd1401e06d883
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12168): v4l2-ioctl: avoid flooding log with unasked debug messages
Problem Details: Thanks to Hans Verkuil <hverkuil@xs4all.nl> for pointing this issue on my last patch. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/v4l2-ioctl.c b/drivers/media/video/v4l2-ioctl.c index aa8f66c63364..c32e67608ad4 100644 --- a/drivers/media/video/v4l2-ioctl.c +++ b/drivers/media/video/v4l2-ioctl.c @@ -42,6 +42,12 @@ printk(KERN_DEBUG "%s: " fmt, vfd->name, ## arg);\ } while (0) +#define dbgarg3(fmt, ...
d1afe4250a0aecf7ee92fa3d563a2f2aabf6cc0b
Analyze and fix the following issue in the Linux kernel code: V4L/DVB (12124): v4l2-ioctl: better output debug messages for VIDIOC_ENUM_FRAMESIZES
Problem Details: Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/video/v4l2-ioctl.c b/drivers/media/video/v4l2-ioctl.c index f2afc4e08379..aa8f66c63364 100644 --- a/drivers/media/video/v4l2-ioctl.c +++ b/drivers/media/video/v4l2-ioctl.c @@ -1726,24 +1726,29 @@ static long __video_do_ioctl(struct file *file, ret = ops->vidioc_enum_framesizes(fi...
ea038f63ac52439e7816295fa6064fe95e6c1f51
Analyze and fix the following issue in the Linux kernel code: [SCSI] fix oops during scsi scanning
Problem Details: Chris Webb reported: p0# uname -a Linux f7ea8425-d45b-490f-a738-d181d0df6963.host.elastichosts.com 2.6.30.4-elastic-lon-p #2 SMP PREEMPT Thu Aug 20 14:30:50 BST 2009 x86_64 Intel(R) Xeon(R) CPU E5420 @ 2.50GHz GenuineIntel GNU/Linux p0# zgrep SCAN_ASYNC /proc/config.gz # CONFIG_SCSI_SCAN_ASYNC ...
```diff diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c index b7b9fec67a98..a89c421dab51 100644 --- a/drivers/scsi/sd.c +++ b/drivers/scsi/sd.c @@ -2021,6 +2021,7 @@ static void sd_probe_async(void *data, async_cookie_t cookie) sd_printk(KERN_NOTICE, sdkp, "Attached SCSI %sdisk\n", sdp->removable ? "removab...
afffd3dabe5209882c8cc59a373a4d33b5db304a
Analyze and fix the following issue in the Linux kernel code: [SCSI] libsrp: fix memory leak in srp_ring_free()
Problem Details: This patch fixes a memory leak in the libsrp function srp_ring_free(). It is not documented whether or not this function should free the ring pointer itself. But the source code of the callers of this function (srp_target_alloc() and srp_target_free()) makes it clear that srp_ring_free() should dealloc...
```diff diff --git a/drivers/scsi/libsrp.c b/drivers/scsi/libsrp.c index 2742ae8a3d09..9ad38e81e343 100644 --- a/drivers/scsi/libsrp.c +++ b/drivers/scsi/libsrp.c @@ -124,6 +124,7 @@ static void srp_ring_free(struct device *dev, struct srp_buf **ring, size_t max, dma_free_coherent(dev, size, ring[i]->buf, ring[i]->d...
dd784edcfc080fb4c83f1f3d10d905c5ab61616f
Analyze and fix the following issue in the Linux kernel code: [SCSI] scsi_dh_rdac: changes for rdac debug logging
Problem Details: Patch to add debugging stuff for rdac device handler. - Added a bit mask "module parameter" rdac_logging with 2 bits for each type of logging. - currently defined only two types of logging(failover and sense logging). Can be enhanced later if required. - By default only failover logging is enabled ...
```diff diff --git a/drivers/scsi/device_handler/scsi_dh_rdac.c b/drivers/scsi/device_handler/scsi_dh_rdac.c index 9f1c4c2df924..11c89311427e 100644 --- a/drivers/scsi/device_handler/scsi_dh_rdac.c +++ b/drivers/scsi/device_handler/scsi_dh_rdac.c @@ -201,6 +201,31 @@ static const char *lun_state[] = static LIST_HEAD(c...
1527666e6af977cc287e0f7088356c8be29b3f75
Analyze and fix the following issue in the Linux kernel code: [SCSI] scsi_dh_rdac: changes to collect the rdac debug information during the initialization
Problem Details: Adding the code to read the debug information during initialization. This patch collects the information about storage and controllers during rdac_activate. Signed-off-by: Babu Moger <babu.moger@lsi.com> Reviewed-by: Vijay Chauhan <vijay.chauhan@lsi.com> Reviewed-by: Bob Stankey <Robert.stankey@lsi.co...
```diff diff --git a/drivers/scsi/device_handler/scsi_dh_rdac.c b/drivers/scsi/device_handler/scsi_dh_rdac.c index c5e4476e912b..9f1c4c2df924 100644 --- a/drivers/scsi/device_handler/scsi_dh_rdac.c +++ b/drivers/scsi/device_handler/scsi_dh_rdac.c @@ -112,6 +112,7 @@ struct c9_inquiry { #define SUBSYS_ID_LEN 16 #def...
e71044ee2efa4792e21d243b03d49006db66aec9
Analyze and fix the following issue in the Linux kernel code: [SCSI] sg: fix oops in the error path in sg_build_indirect()
Problem Details: When the allocation fails in sg_build_indirect(), an oops happens in the error path. It's caused by an obvious typo. Signed-off-by: Michal Schmidt <mschmidt@redhat.com> Reported-by: Bob Tracy <rct@gherkin.frus.com> Acked-by: Douglas Gilbert <dgilbert@interlog.com> Cc: Stable Tree <stable@kernel.org> S...
```diff diff --git a/drivers/scsi/sg.c b/drivers/scsi/sg.c index 9230402c45af..4968c4ced385 100644 --- a/drivers/scsi/sg.c +++ b/drivers/scsi/sg.c @@ -1811,7 +1811,7 @@ retry: return 0; out: for (i = 0; i < k; i++) - __free_pages(schp->pages[k], order); + __free_pages(schp->pages[i], order); if (--order >= 0...
9766096d331c82e71d3c9df61f1c88eff6ad916b
Analyze and fix the following issue in the Linux kernel code: [SCSI] mptsas : FW event thread and scsi mid layer deadlock in SYNCHRONIZE CACHE command
Problem Details: Normally In HBA reset path MPT driver will flush existing work in current work queue (mpt/0) . This is just a dummy activity for MPT driver point of view, since HBA reset will turn off Work queue events. It means we will simply returns from work queue without doing anything. But for the case where Wor...
```diff diff --git a/drivers/message/fusion/mptsas.c b/drivers/message/fusion/mptsas.c index 02a18dfcd52a..83873e3d0ce7 100644 --- a/drivers/message/fusion/mptsas.c +++ b/drivers/message/fusion/mptsas.c @@ -325,7 +325,6 @@ mptsas_cleanup_fw_event_q(MPT_ADAPTER *ioc) { struct fw_event_work *fw_event, *next; struct ...
f44fd18198eb26b62ba86b17016e9441ce95fc71
Analyze and fix the following issue in the Linux kernel code: [SCSI] mptsas : NULL pointer on big endian systems causing Expander not to tear off
Problem Details: On Big endian system kernel will crash due to address translation is not handle properly. Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
```diff diff --git a/drivers/message/fusion/mptsas.c b/drivers/message/fusion/mptsas.c index f744f0fc9491..02a18dfcd52a 100644 --- a/drivers/message/fusion/mptsas.c +++ b/drivers/message/fusion/mptsas.c @@ -3314,6 +3314,7 @@ mptsas_send_expander_event(struct fw_event_work *fw_event) expander_data = (MpiEventDataSasEx...
094614fc14966bc6a6259ade55f051fe17f36122
Analyze and fix the following issue in the Linux kernel code: firewire: sbp2: fix status reception
Problem Details: Per SBP-2 clause 5.3, a target shall store 8...32 bytes of status information. Trailing zeros after the first 8 bytes don't need to be stored, they are implicit. Fix the status write handler to clear all unwritten status data. Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
```diff diff --git a/drivers/firewire/sbp2.c b/drivers/firewire/sbp2.c index e5df822a8130..8f83bffb43e7 100644 --- a/drivers/firewire/sbp2.c +++ b/drivers/firewire/sbp2.c @@ -425,19 +425,20 @@ static void sbp2_status_write(struct fw_card *card, struct fw_request *request, struct sbp2_logical_unit *lu = callback_data;...
85cb9b68640cf467a99d4b6d518f1293222dbc9e
Analyze and fix the following issue in the Linux kernel code: firewire: core: fix topology map response handler
Problem Details: This register is 1 kBytes large. Adjust topology_map.length to prevent registration of other response handlers in this region and to make sure that we respond to requests to the upper half of the register. Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
```diff diff --git a/drivers/firewire/core-transaction.c b/drivers/firewire/core-transaction.c index 479b22f5a1eb..da628c72a462 100644 --- a/drivers/firewire/core-transaction.c +++ b/drivers/firewire/core-transaction.c @@ -834,7 +834,7 @@ static void handle_topology_map(struct fw_card *card, struct fw_request *request ...
b171e204b32b69e241af994d6e9be559e33535c1
Analyze and fix the following issue in the Linux kernel code: firewire: core: fix race with parallel PCI device probe
Problem Details: The config ROM buffer received from generate_config_rom is a globally shared static buffer. Extend the card_mutex protection in fw_add_card until after the config ROM was copied into the card driver's buffer. Otherwise, parallelized card driver probes may end up with ROM contents that were meant for a...
```diff diff --git a/drivers/firewire/core-card.c b/drivers/firewire/core-card.c index f74edae5cb4c..e4864e894e4f 100644 --- a/drivers/firewire/core-card.c +++ b/drivers/firewire/core-card.c @@ -444,16 +444,13 @@ int fw_card_add(struct fw_card *card, card->guid = guid; mutex_lock(&card_mutex); - config_rom = gene...
928ec5f148e729076e9202e7c78babede628a50c
Analyze and fix the following issue in the Linux kernel code: firewire: ohci: fix Self ID Count register mask (safeguard against buffer overflow)
Problem Details: The selfIDSize field of Self ID Count is 9 bits wide, and we are only interested in the high 8 bits. Fix the mask accordingly. The previously too large mask didn't do damage though because the next few bits in the register are reserved and therefore zero with presently existing hardware. Also, check...
```diff diff --git a/drivers/firewire/ohci.c b/drivers/firewire/ohci.c index 76b321bb73f9..5d524254499e 100644 --- a/drivers/firewire/ohci.c +++ b/drivers/firewire/ohci.c @@ -1279,8 +1279,8 @@ static void bus_reset_tasklet(unsigned long data) * the inverted quadlets and a header quadlet, we shift one * bit extra ...
64549e9357e5222a73e41aa87372b37abb047720
Analyze and fix the following issue in the Linux kernel code: ieee1394: raw1394: Do not leak memory on failed trylock.
Problem Details: Do not leak the allocated memory in case the mutex_trylock() failed to acquire the lock. Signed-off-by: Michael Buesch <mb@bu3sch.de> This bug does not happen in practice: All raw1394 clients use libraw1394, and accesses to a libraw1394 handle need to be serialized by the client. This is documented...
```diff diff --git a/drivers/ieee1394/raw1394.c b/drivers/ieee1394/raw1394.c index da5f8829b503..0bc3d78ce7b1 100644 --- a/drivers/ieee1394/raw1394.c +++ b/drivers/ieee1394/raw1394.c @@ -2272,8 +2272,10 @@ static ssize_t raw1394_write(struct file *file, const char __user * buffer, return -EFAULT; } - if (!mutex_...
b7cfda9fc3d7aa60cffab5367f2a72a4a70060cd
Analyze and fix the following issue in the Linux kernel code: ARM: Fix pfn_valid() for sparse memory
Problem Details: On OMAP platforms, some people want to declare to segment up the memory between the kernel and a separate application such that there is a hole in the middle of the memory as far as Linux is concerned. However, they want to be able to mmap() the hole. This currently causes problems, because update_mm...
```diff diff --git a/arch/arm/include/asm/memory.h b/arch/arm/include/asm/memory.h index 85763db87449..b3b54c6216a4 100644 --- a/arch/arm/include/asm/memory.h +++ b/arch/arm/include/asm/memory.h @@ -212,7 +212,6 @@ static inline __deprecated void *bus_to_virt(unsigned long x) * * page_to_pfn(page) convert a struct...
74c520da5414d15b0ab2839d67efab2e7227be75
Analyze and fix the following issue in the Linux kernel code: netxen: fix tx timeout recovery
Problem Details: Redesign tx timeout handling in line with new firmware reset design that co-ordinates with other PCI function drivers. o For NX3031, first try to reset PCI function's own context before requesting firmware reset. o For NX2031, since firmware heartbit is not supported directly request firmware res...
```diff diff --git a/drivers/net/netxen/netxen_nic.h b/drivers/net/netxen/netxen_nic.h index 7e3d2b932790..1ae46e8c2dc7 100644 --- a/drivers/net/netxen/netxen_nic.h +++ b/drivers/net/netxen/netxen_nic.h @@ -178,6 +178,7 @@ #define MAX_BUFFERS_PER_CMD 32 #define TX_STOP_THRESH ((MAX_SKB_FRAGS >> 2) + 4) +#define NX...
ec5c50cb93c446a4686863df74e4b7a547628115
Analyze and fix the following issue in the Linux kernel code: netxen: fix file firmware leak
Problem Details: Release file firmware when no firmware reset is required. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: David S. Miller <davem@davemloft.net>
```diff diff --git a/drivers/net/netxen/netxen_nic_main.c b/drivers/net/netxen/netxen_nic_main.c index 557e76c4c589..e8574eeae58f 100644 --- a/drivers/net/netxen/netxen_nic_main.c +++ b/drivers/net/netxen/netxen_nic_main.c @@ -817,7 +817,7 @@ netxen_start_firmware(struct netxen_adapter *adapter) if (err < 0) goto ...
5ea1c50662d447de344812054175d7151783ea25
Analyze and fix the following issue in the Linux kernel code: tg3: Fix return ring size breakage
Problem Details: Commit f6eb9b1fc1411d22c073f5264e5630a541d0f7df, "tg3: Add 5717 asic rev" changed how the rx return ring size operations are done. It effectively inverts the sense of the previous test, but it failed to also invert the resulting sizes. This patch corrects that error. Signed-off-by: Matt Carlson <mca...
```diff diff --git a/drivers/net/tg3.c b/drivers/net/tg3.c index 7cf80006eafa..f09bc5dfe8b2 100644 --- a/drivers/net/tg3.c +++ b/drivers/net/tg3.c @@ -112,7 +112,7 @@ */ #define TG3_RX_RCB_RING_SIZE(tp) \ (((tp->tg3_flags & TG3_FLAG_JUMBO_CAPABLE) && \ - !(tp->tg3_flags2 & TG3_FLG2_5780_CLASS)) ? 512 : 1024) + ...
9feae56c0de65fdd8b1f64f376bb6578417d2b79
Analyze and fix the following issue in the Linux kernel code: netxen: build fix for INET=n
Problem Details: When CONFIG_INET is disabled, netxen has a build failure: netxen_nic_main.c:(.text+0x118fd1): undefined reference to `netxen_config_indev_addr' so make that function just an empty stub when CONFIG_INET=n. (not "inline" since that conflicts with other declarations of it) Signed-off-by: Randy Dunlap <...
```diff diff --git a/drivers/net/netxen/netxen_nic_main.c b/drivers/net/netxen/netxen_nic_main.c index 81c24a7effcf..1399102fa4bd 100644 --- a/drivers/net/netxen/netxen_nic_main.c +++ b/drivers/net/netxen/netxen_nic_main.c @@ -2450,6 +2450,10 @@ static struct notifier_block netxen_netdev_cb = { static struct notifier_...
d42571efe33552cd519b7f3800a788b5f2d51798
Analyze and fix the following issue in the Linux kernel code: drm/radeon/kms: fix typo in quirks
Problem Details: Signed-off-by: Alex Deucher <alexdeucher@gmail.com> Signed-off-by: Dave Airlie <airlied@linux.ie>
```diff diff --git a/drivers/gpu/drm/radeon/radeon_atombios.c b/drivers/gpu/drm/radeon/radeon_atombios.c index 4dff85b450ea..aa756dec8959 100644 --- a/drivers/gpu/drm/radeon/radeon_atombios.c +++ b/drivers/gpu/drm/radeon/radeon_atombios.c @@ -148,7 +148,7 @@ static bool radeon_atom_apply_quirks(struct drm_device *dev, ...
1be340563cf40210487afe332c0d7c9a523dba5f
Analyze and fix the following issue in the Linux kernel code: drm/radeon/kms/r600: fix blit dword count for non r6xx
Problem Details: rv6xx emits two extra dwords in the render target setup. Signed-off-by: Alex Deucher <alexdeucher@gmail.com> Signed-off-by: Dave Airlie <airlied@linux.ie>
```diff diff --git a/drivers/gpu/drm/radeon/r600_blit_kms.c b/drivers/gpu/drm/radeon/r600_blit_kms.c index bbb0d615ac1c..1ebfd5a6dfec 100644 --- a/drivers/gpu/drm/radeon/r600_blit_kms.c +++ b/drivers/gpu/drm/radeon/r600_blit_kms.c @@ -550,6 +550,12 @@ int r600_blit_prepare_copy(struct radeon_device *rdev, int size_byte...
7ad9bb651fc2036ea94bed94da76a4b08959a911
Analyze and fix the following issue in the Linux kernel code: ext4: Fix initalization of s_flex_groups
Problem Details: The s_flex_groups array should have been initialized using atomic_add to sum up the free counts from the block groups that make up a flex_bg. By using atomic_set, the value of the s_flex_groups array was set to the values of the last block group in the flex_bg. The impact of this bug is that the bl...
```diff diff --git a/fs/ext4/super.c b/fs/ext4/super.c index 9f6fa3f74629..04c693357336 100644 --- a/fs/ext4/super.c +++ b/fs/ext4/super.c @@ -1694,12 +1694,12 @@ static int ext4_fill_flex_info(struct super_block *sb) gdp = ext4_get_group_desc(sb, i, NULL); flex_group = ext4_flex_group(sbi, i); - atomic_set(&s...
998ec759ef2fc9c60319815c72b2b699ab939733
Analyze and fix the following issue in the Linux kernel code: Phonet: fix netlink address dump error handling
Problem Details: Signed-off-by: Rémi Denis-Courmont <remi.denis-courmont@nokia.com> Signed-off-by: David S. Miller <davem@davemloft.net>
```diff diff --git a/net/phonet/pn_netlink.c b/net/phonet/pn_netlink.c index f8b4cee434c2..d21fd3576610 100644 --- a/net/phonet/pn_netlink.c +++ b/net/phonet/pn_netlink.c @@ -147,7 +147,7 @@ static int getaddr_dumpit(struct sk_buff *skb, struct netlink_callback *cb) if (fill_addr(skb, pnd->netdev, addr << 2, ...
f510c35de0e63e1066db83d2fdce99e6dbde0c80
Analyze and fix the following issue in the Linux kernel code: mv643xx_eth.c: remove unused txq_set_wrr()
Problem Details: The txq_set_wrr() function in drivers/net/mv643xx_eth.c is unused, not even referenced under #if 0 or something like that, which results in a compile-time warning: drivers/net/mv643xx_eth.c:1070: warning: 'txq_set_wrr' defined but not used Fix: remove it. Signed-off-by: Mikael Pettersson <mikpe@it.u...
```diff diff --git a/drivers/net/mv643xx_eth.c b/drivers/net/mv643xx_eth.c index 0f32db3e92ad..b62e61d4ca3e 100644 --- a/drivers/net/mv643xx_eth.c +++ b/drivers/net/mv643xx_eth.c @@ -1066,40 +1066,6 @@ static void txq_set_fixed_prio_mode(struct tx_queue *txq) } } -static void txq_set_wrr(struct tx_queue *txq, int ...
864fdf884e82bacbe8ca5e93bd43393a61d2e2b4
Analyze and fix the following issue in the Linux kernel code: ucc_geth: Fix hangs after switching from full to half duplex
Problem Details: MPC8360 QE UCC ethernet controllers hang when changing link duplex under a load (a bit of NFS activity is enough). PHY: mdio@e0102120:00 - Link is Up - 1000/Full sh-3.00# ethtool -s eth0 speed 100 duplex half autoneg off PHY: mdio@e0102120:00 - Link is Down PHY: mdio@e0102120:00 - Link is Up -...
```diff diff --git a/drivers/net/ucc_geth.c b/drivers/net/ucc_geth.c index a39368a46352..4469f2451a6f 100644 --- a/drivers/net/ucc_geth.c +++ b/drivers/net/ucc_geth.c @@ -1561,6 +1561,25 @@ static int ugeth_disable(struct ucc_geth_private *ugeth, enum comm_dir mode) return 0; } +static void ugeth_quiesce(struct uc...
ffcfb8db540ff879c2a85bf7e404954281443414
Analyze and fix the following issue in the Linux kernel code: Subject: [PATCH] appletalk: Fix skb leak when ipddp interface is not loaded
Problem Details: And also do a better job of returning proper NET_{RX,XMIT}_ values. Based on a patch and suggestions by Mark Smith. This fixes CVE-2009-2903 Reported-by: Mark Smith <lk-netdev@lk-netdev.nosense.org> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: David S. Miller <davem@davem...
```diff diff --git a/drivers/net/appletalk/ipddp.c b/drivers/net/appletalk/ipddp.c index bea87da97e34..aaf14d306a4a 100644 --- a/drivers/net/appletalk/ipddp.c +++ b/drivers/net/appletalk/ipddp.c @@ -177,8 +177,7 @@ static netdev_tx_t ipddp_xmit(struct sk_buff *skb, struct net_device *dev) dev->stats.tx_packets++; d...
689fd8b65d669b96d612ccc37d6fb87bf7ed6907
Analyze and fix the following issue in the Linux kernel code: tracing: trace parser support for function and graph
Problem Details: Convert the writing to 'set_graph_function', 'set_ftrace_filter' and 'set_ftrace_notrace' to use the generic trace_parser 'trace_get_user' function. Removed FTRACE_ITER_CONT flag, since it's not needed after this change. Minor fix in set_graph_function display - g_show function. Signed-off-by: Jiri ...
```diff diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c index 8c804e24f96f..8b23d5670088 100644 --- a/kernel/trace/ftrace.c +++ b/kernel/trace/ftrace.c @@ -1323,11 +1323,10 @@ static int __init ftrace_dyn_table_alloc(unsigned long num_to_init) enum { FTRACE_ITER_FILTER = (1 << 0), - FTRACE_ITER_CONT = (...
7e61615857c6fb3afbcb43f5c4e97511a923f5a8
Analyze and fix the following issue in the Linux kernel code: drm/i915: Only destroy a constructed mmap offset
Problem Details: drm_ht_remove_item() does not handle removing an absent item and the hlist in particular is incorrectly initialised. The easy remedy is simply skip calling i915_gem_free_mmap_offset() unless we have actually created the offset and associated ht entry. This also fixes the mishandling of a partially con...
```diff diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c index 30ea4b6b0219..e0da98602eed 100644 --- a/drivers/gpu/drm/i915/i915_gem.c +++ b/drivers/gpu/drm/i915/i915_gem.c @@ -3834,7 +3834,8 @@ void i915_gem_free_object(struct drm_gem_object *obj) i915_gem_object_unbind(obj); - i915...
e517a5e97080bbe52857bd0d7df9b66602d53c4d
Analyze and fix the following issue in the Linux kernel code: agp/intel: Fix the pre-9xx chipset flush.
Problem Details: Ever since we enabled GEM, the pre-9xx chipsets (particularly 865) have had serious stability issues. Back in May a wbinvd was added to the DRM to work around much of the problem. Some failure remained -- easily visible by dragging a window around on an X -retro desktop, or by looking at bugzilla. T...
```diff diff --git a/arch/x86/mm/pageattr.c b/arch/x86/mm/pageattr.c index 7e600c1962db..5866b28eede1 100644 --- a/arch/x86/mm/pageattr.c +++ b/arch/x86/mm/pageattr.c @@ -143,6 +143,7 @@ void clflush_cache_range(void *vaddr, unsigned int size) mb(); } +EXPORT_SYMBOL_GPL(clflush_cache_range); static void __cpa_f...
8ba69ba6a324b13e1190fc31e41954d190fd4f1d
Analyze and fix the following issue in the Linux kernel code: net: unix: fix sending fds in multiple buffers
Problem Details: Kalle Olavi Niemitalo reported that: "..., when one process calls sendmsg once to send 43804 bytes of data and one file descriptor, and another process then calls recvmsg three times to receive the 16032+16032+11740 bytes, each of those recvmsg calls returns the file descriptor in the ancillar...
```diff diff --git a/net/unix/af_unix.c b/net/unix/af_unix.c index fc3ebb906911..51ab497115eb 100644 --- a/net/unix/af_unix.c +++ b/net/unix/af_unix.c @@ -1501,6 +1501,7 @@ static int unix_stream_sendmsg(struct kiocb *kiocb, struct socket *sock, struct sk_buff *skb; int sent = 0; struct scm_cookie tmp_scm; + bool...
f79e0258ea1f04d63db499479b5fb855dff6dbc5
Analyze and fix the following issue in the Linux kernel code: clocksource: Resolve cpu hotplug dead lock with TSC unstable, fix crash
Problem Details: The watchdog timer is started after the watchdog clocksource and at least one watched clocksource have been registered. The clocksource work element watchdog_work is initialized just before the clocksource timer is started. This is too late for the clocksource_mark_unstable call from native_cpu_up. To ...
```diff diff --git a/kernel/time/clocksource.c b/kernel/time/clocksource.c index a0af4ffcb6e5..5697155f1868 100644 --- a/kernel/time/clocksource.c +++ b/kernel/time/clocksource.c @@ -123,10 +123,12 @@ static DEFINE_MUTEX(clocksource_mutex); static char override_name[32]; #ifdef CONFIG_CLOCKSOURCE_WATCHDOG +static v...
50a9b214bc6c052caa05a210ebfc1bdf0d7085b2
Analyze and fix the following issue in the Linux kernel code: Btrfs: fix btrfs page_mkwrite to return locked page
Problem Details: This closes a whole where the page may be written before the page_mkwrite caller has a chance to dirty it (thanks to Nick Piggin) Signed-off-by: Chris Mason <chris.mason@oracle.com>
```diff diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c index 233fe6f26120..c846482e7985 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c @@ -4552,11 +4552,14 @@ again: } ClearPageChecked(page); set_page_dirty(page); + SetPageUptodate(page); BTRFS_I(inode)->last_trans = root->fs_info->generation + 1; u...
a1ed835e1ab5795f91b198d08c43e2f56848dcf3
Analyze and fix the following issue in the Linux kernel code: Btrfs: Fix extent replacment race
Problem Details: Data COW means that whenever we write to a file, we replace any old extent pointers with new ones. There was a window where a readpage might find the old extent pointers on disk and cache them in the extent_map tree in ram in the middle of a given write replacing them. Even though both the readpage a...
```diff diff --git a/fs/btrfs/ctree.h b/fs/btrfs/ctree.h index 38eeb6c49c8a..1ceab8b4d6dc 100644 --- a/fs/btrfs/ctree.h +++ b/fs/btrfs/ctree.h @@ -2292,7 +2292,7 @@ extern struct file_operations btrfs_file_operations; int btrfs_drop_extents(struct btrfs_trans_handle *trans, struct btrfs_root *root, struct in...
e48c465bb366c0169f7908bfe62ae7080874ee7d
Analyze and fix the following issue in the Linux kernel code: Btrfs: Fix new state initialization order
Problem Details: As the extent state tree is manipulated, there are call backs that are used to take extra actions when different state bits are set or cleared. One example of this is a counter for the total number of delayed allocation bytes in a single inode and in the whole FS. When new states are inserted, this c...
```diff diff --git a/fs/btrfs/extent_io.c b/fs/btrfs/extent_io.c index 41cf1b451b41..8e168a457a37 100644 --- a/fs/btrfs/extent_io.c +++ b/fs/btrfs/extent_io.c @@ -367,10 +367,10 @@ static int insert_state(struct extent_io_tree *tree, } if (bits & EXTENT_DIRTY) tree->dirty_bytes += end - start + 1; - set_state_cb...
074835f0143b83845af5044af2739c52c9f53808
Analyze and fix the following issue in the Linux kernel code: intel-iommu: Fix kernel hang if interrupt remapping disabled in BIOS
Problem Details: BIOS clear DMAR table INTR_REMAP flag to disable interrupt remapping. Current kernel only check interrupt remapping(IR) flag in DRHD's extended capability register to decide interrupt remapping support or not. But IR flag will not change when BIOS disable/enable interrupt remapping. When user disable ...
```diff diff --git a/drivers/pci/dmar.c b/drivers/pci/dmar.c index fba4f6891680..270ed222a075 100644 --- a/drivers/pci/dmar.c +++ b/drivers/pci/dmar.c @@ -1316,3 +1316,13 @@ int dmar_reenable_qi(struct intel_iommu *iommu) return 0; } + +/* + * Check interrupt remapping support in DMAR table description. + */ +int ...
b217a903ab6581cba04f88c44284dcdd2a752561
Analyze and fix the following issue in the Linux kernel code: cfq: fix the log message after dispatched a request
Problem Details: The blktrace tools can show process id when cfq dispatched a request, using cfq_log_cfqq() instead of cfq_log(). Signed-off-by: Shan Wei <shanwei@cn.fujitsu.com> Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
```diff diff --git a/block/cfq-iosched.c b/block/cfq-iosched.c index f75a54bfc547..a34686f091db 100644 --- a/block/cfq-iosched.c +++ b/block/cfq-iosched.c @@ -1349,7 +1349,7 @@ static int cfq_dispatch_requests(struct request_queue *q, int force) cfq_slice_expired(cfqd, 0); } - cfq_log(cfqd, "dispatched a request...
212a502676c308ead964a024e081529ad3f8d94c
Analyze and fix the following issue in the Linux kernel code: cciss: memory leak in cciss_init_one()
Problem Details: commit 22bece00dc1f28dd3374c55e464c9f02eb642876 (cciss: fix regression firmware not displayed in procfs) added a small memory leak in cciss_init_one() Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
```diff diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c index a52cc7fe45ea..0589dfbbd7db 100644 --- a/drivers/block/cciss.c +++ b/drivers/block/cciss.c @@ -3889,7 +3889,7 @@ static int __devinit cciss_init_one(struct pci_dev *pdev, int j = 0; int rc; int dac, return_code; - InquiryData_struct *inq_buff...
723590ed52d244b025f10a8e2f54c2f57ed02b4d
Analyze and fix the following issue in the Linux kernel code: splice: update mtime and atime on files
Problem Details: Splice should update the modification and access times on regular files just like read and write. Not updating mtime will confuse backup tools, etc... This patch only adds the time updates for regular files. For pipes and other special files that splice touches the need for updating the times is less...
```diff diff --git a/fs/splice.c b/fs/splice.c index 73766d24f97b..aec4014291be 100644 --- a/fs/splice.c +++ b/fs/splice.c @@ -502,8 +502,10 @@ ssize_t generic_file_splice_read(struct file *in, loff_t *ppos, len = left; ret = __generic_file_splice_read(in, ppos, pipe, len, flags); - if (ret > 0) + if (ret > 0) {...
fca51d64c5baf64604bc1edc5c5f0e7ed176322f
Analyze and fix the following issue in the Linux kernel code: block: fix comment in blk-iopoll.c
Problem Details: Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
```diff diff --git a/block/blk-iopoll.c b/block/blk-iopoll.c index 0671d4614b08..b9b32652292c 100644 --- a/block/blk-iopoll.c +++ b/block/blk-iopoll.c @@ -115,9 +115,12 @@ static void blk_iopoll_softirq(struct softirq_action *h) local_irq_disable(); - /* Drivers must not modify the NAPI state if they - * cons...
1badcfbd7febd33f71fc02bda9112bd25e9c294b
Analyze and fix the following issue in the Linux kernel code: block: fix long lines in block/blk-iopoll.c
Problem Details: Note sure why they happened in the first place, probably some bad terminal setting. Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
```diff diff --git a/block/blk-iopoll.c b/block/blk-iopoll.c index 566db1e7c1c7..df6f192c9f67 100644 --- a/block/blk-iopoll.c +++ b/block/blk-iopoll.c @@ -24,9 +24,9 @@ static DEFINE_PER_CPU(struct list_head, blk_cpu_iopoll); * @iop: The parent iopoll structure * * Description: - * Add this blk_iopoll st...
59e36927ee08f3bf06d8d14597e57389bf1b41dc
Analyze and fix the following issue in the Linux kernel code: [S390] tape: Use pr_xxx instead of dev_xxx in shared driver code
Problem Details: For messages from the tape core that is shared between the 3590 and 34xx tape disciplines, we want to have the "tape" prefix instead of "tape_3590" or "tape_34xx". In order to fix this, we now use the pr_xxx printk macros. Signed-off-by: Michael Holzheu <holzheu@linux.vnet.ibm.com> Signed-off-by: Mart...
```diff diff --git a/drivers/s390/char/tape_34xx.c b/drivers/s390/char/tape_34xx.c index 5a519fac37b7..2fe45ff77b75 100644 --- a/drivers/s390/char/tape_34xx.c +++ b/drivers/s390/char/tape_34xx.c @@ -8,7 +8,7 @@ * Martin Schwidefsky <schwidefsky@de.ibm.com> */ -#define KMSG_COMPONENT "tape" +#define KMSG_COMPONE...
53f8c573ea3b54b7e1b81d2cd403373b08103736
Analyze and fix the following issue in the Linux kernel code: [S390] tape: Fix device online messages
Problem Details: Currently, when a tape device is set online and no cartridge is loaded, we get the messages "The tape cartridge has been successfully unloaded" and "Determining the size of the recorded area". These messages are not correct. To fix this, we now print the "cartridge loaded/unloaded" messages only, when ...
```diff diff --git a/drivers/s390/char/tape_block.c b/drivers/s390/char/tape_block.c index 47ff695255ea..1c2a582e626c 100644 --- a/drivers/s390/char/tape_block.c +++ b/drivers/s390/char/tape_block.c @@ -302,8 +302,6 @@ tapeblock_revalidate_disk(struct gendisk *disk) if (!device->blk_data.medium_changed) return 0; ...
f64d04c042193183c6dad98944ae2861b998e8b7
Analyze and fix the following issue in the Linux kernel code: [S390] s390dbf: Add description for usage of "%s" in sprintf events
Problem Details: Using "%s" in sprintf event functions is dangerous. This patch adds a short description for this issue to the s390 debug feature documentation. Signed-off-by: Michael Holzheu <holzheu@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
```diff diff --git a/Documentation/s390/s390dbf.txt b/Documentation/s390/s390dbf.txt index 2d10053dd97e..ae66f9b90a25 100644 --- a/Documentation/s390/s390dbf.txt +++ b/Documentation/s390/s390dbf.txt @@ -495,6 +495,13 @@ and for each vararg a long value. So e.g. for a debug entry with a format string plus two varargs o...
0c88ee5b7523e76e290d558c28cd0be48ffad597
Analyze and fix the following issue in the Linux kernel code: [S390] Initialize __LC_THREAD_INFO early.
Problem Details: "lockdep: Fix backtraces" reveales a bug in early setup code: when lockdep tries to save a stack backtrace before setup_arch has been called the lowcore pointer for the current thread info pointer isn't initialized yet. However our save stack backtrace code relies on it. If the pointer isn't initialize...
```diff diff --git a/arch/s390/kernel/head31.S b/arch/s390/kernel/head31.S index 2ced846065b7..602b508cd4c4 100644 --- a/arch/s390/kernel/head31.S +++ b/arch/s390/kernel/head31.S @@ -24,6 +24,7 @@ startup_continue: # Setup stack # l %r15,.Linittu-.LPG1(%r13) + st %r15,__LC_THREAD_INFO # cache thread info in lowcore...
50aa98bad056a17655864a4d71ebc32d95c629a7
Analyze and fix the following issue in the Linux kernel code: [S390] fix recursive locking on page_table_lock
Problem Details: Suzuki Poulose reported the following recursive locking bug on s390: Here is the stack trace : (see Appendix I for more info) [<0000000000406ed6>] _spin_lock+0x52/0x94 [<0000000000103bde>] crst_table_free+0x14e/0x1a4 [<00000000001ba684>] __pmd_alloc+0x114/0x1ec [<00000000001be8d0>] handle_mm_...
```diff diff --git a/arch/s390/include/asm/mmu.h b/arch/s390/include/asm/mmu.h index 3b59216e6284..03be99919d62 100644 --- a/arch/s390/include/asm/mmu.h +++ b/arch/s390/include/asm/mmu.h @@ -2,6 +2,7 @@ #define __MMU_H typedef struct { + spinlock_t list_lock; struct list_head crst_list; struct list_head pgtable...
68d36bdbf6377d36129b2c6bcbe9d24c5fb1739a
Analyze and fix the following issue in the Linux kernel code: [S390] tape: reversed order of labels
Problem Details: Fix the order of goto labels in tape_generic_online. Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
```diff diff --git a/drivers/s390/char/tape_core.c b/drivers/s390/char/tape_core.c index 1d420d947596..7424d648e81f 100644 --- a/drivers/s390/char/tape_core.c +++ b/drivers/s390/char/tape_core.c @@ -358,11 +358,11 @@ tape_generic_online(struct tape_device *device, out_char: tapechar_cleanup_device(device); +out_mi...
95f1556c35529a162cef50296f3dc7f978852048
Analyze and fix the following issue in the Linux kernel code: [S390] zcrypt: Use spin_lock_bh in suspend callback
Problem Details: Fix lock dependency warning. inconsistent {IN-SOFTIRQ-W} -> {SOFTIRQ-ON-W} usage. bash/1442 [HC0[0]:SC0[0]:HE1:SE1] takes: (&ap_dev->lock){+.?...}, at: [<000003e001280404>] __ap_poll_device+0x40/0x3e8 [ap] {IN-SOFTIRQ-W} state was registered at: [<000000000017f094>] __lock_acquire+0xb78/0x182c [<...
```diff diff --git a/drivers/s390/crypto/ap_bus.c b/drivers/s390/crypto/ap_bus.c index ae9ab240c7f1..85785807acbc 100644 --- a/drivers/s390/crypto/ap_bus.c +++ b/drivers/s390/crypto/ap_bus.c @@ -648,7 +648,9 @@ static int ap_bus_suspend(struct device *dev, pm_message_t state) /* Poll on the device until all requests ...
3f7cb51fac60618aa543058a90e668956d5fb518
Analyze and fix the following issue in the Linux kernel code: [S390] vmur: Invalid allocation sequence for vmur class
Problem Details: The vmur class is allocated after the CCW driver is registered and it is destroyed before the CCW driver is unregistered. This is not the correct sequence, because the vmur class can be used via driver core callbacks that are triggered during the CCW driver deregistration. For Example: 1. vmur device ...
```diff diff --git a/drivers/s390/char/vmur.c b/drivers/s390/char/vmur.c index 31b902e94f7b..77571b68539a 100644 --- a/drivers/s390/char/vmur.c +++ b/drivers/s390/char/vmur.c @@ -1026,9 +1026,15 @@ static int __init ur_init(void) debug_set_level(vmur_dbf, 6); + vmur_class = class_create(THIS_MODULE, "vmur"); + if...
6292b9ef5a4e85d6b782412a85725dd38df24b85
Analyze and fix the following issue in the Linux kernel code: [S390] tape: use init_timer_on_stack() rather than init_timer()
Problem Details: With CONFIG_DEBUG_OBJECTS_TIMERS=y "chccwdev --online" for a tape device will fail with message "ODEBUG: object is on stack, but not annotated". We now use init_timer_on_stack. Signed-off-by: Frank Munzert <munzert@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
```diff diff --git a/drivers/s390/char/tape_std.c b/drivers/s390/char/tape_std.c index 1a9420ba518d..750354ad16e5 100644 --- a/drivers/s390/char/tape_std.c +++ b/drivers/s390/char/tape_std.c @@ -68,7 +68,7 @@ tape_std_assign(struct tape_device *device) * to another host (actually this shouldn't happen but it does). ...
bfe3349b516df011dcf6462b0fd748a6f5c2e8af
Analyze and fix the following issue in the Linux kernel code: [S390] atomic ops: small cleanups
Problem Details: Couple of coding style fixes, replace __inline__ with inline and remove #ifdef __KERNEL_- since the header file isn't exported. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
```diff diff --git a/arch/s390/include/asm/atomic.h b/arch/s390/include/asm/atomic.h index b491d5e963cf..ae7c8f9f94a5 100644 --- a/arch/s390/include/asm/atomic.h +++ b/arch/s390/include/asm/atomic.h @@ -18,8 +18,6 @@ #define ATOMIC_INIT(i) { (i) } -#ifdef __KERNEL__ - #if __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC...
ca99dab01dd63dcc413395bd3e75b0be152dfefc
Analyze and fix the following issue in the Linux kernel code: [S390] dasd: fix message naming
Problem Details: This patch fixes message naming so that generic dasd messages do not contain the device discipline. For this purpose the dev_ makros are replaced by pr_ makros for generic dasd messages. Signed-off-by: Stefan Haberland <stefan.haberland@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm...
```diff diff --git a/drivers/s390/block/dasd_3990_erp.c b/drivers/s390/block/dasd_3990_erp.c index 27991b692056..e8ff7b0c961d 100644 --- a/drivers/s390/block/dasd_3990_erp.c +++ b/drivers/s390/block/dasd_3990_erp.c @@ -7,7 +7,7 @@ * */ -#define KMSG_COMPONENT "dasd" +#define KMSG_COMPONENT "dasd-eckd" #include...
3b554a14f4bdf754ba9d2f64c2b6edf8dafe93b9
Analyze and fix the following issue in the Linux kernel code: [S390] cio: move final put_device to ccw_device_unregister
Problem Details: We use a test_and_clear_bit to prevent a device from being unregistered twice. Unfortunately in this cases the "final" put_device (from device_initialize) was issued more than once, resulting in an use after free error. Fix this by moving this put_device to ccw_device_unregister. Signed-off-by: Sebast...
```diff diff --git a/drivers/s390/cio/device.c b/drivers/s390/cio/device.c index 6b770f8c0a89..345a61f45a5a 100644 --- a/drivers/s390/cio/device.c +++ b/drivers/s390/cio/device.c @@ -307,8 +307,11 @@ int ccw_device_is_orphan(struct ccw_device *cdev) static void ccw_device_unregister(struct ccw_device *cdev) { - if ...
6ee4fec6be06f7d138860b37cba58982cc3ccb16
Analyze and fix the following issue in the Linux kernel code: [S390] cio: remove subchannel init_name
Problem Details: We used the init_name to set the console subchannels name early at the boot stage. With the patch cio: fix memleak in subchannel validation we moved the name setting to the point where we actually register the console subchannel. At this time we can do dynamic allocations and therefore use dev_set_name...
```diff diff --git a/drivers/s390/cio/cio.c b/drivers/s390/cio/cio.c index fe18ef691bb7..138124fcfcad 100644 --- a/drivers/s390/cio/cio.c +++ b/drivers/s390/cio/cio.c @@ -667,7 +667,6 @@ void __irq_entry do_IRQ(struct pt_regs *regs) #ifdef CONFIG_CCW_CONSOLE static struct subchannel console_subchannel; -static char...
ab6aae09024be1b039df441fa1b64dbe092d0acb
Analyze and fix the following issue in the Linux kernel code: [S390] cio: fix memleak in subchannel validation
Problem Details: When scanning for new subchannels we have a code path where we allocate memory for a struct subchannel, set the device name (which is dynamically allocated now) and do a check if the underlying device is blacklisted - if so we free the subchannel structure. Since we have not set up refcounting at this ...
```diff diff --git a/drivers/s390/cio/cio.c b/drivers/s390/cio/cio.c index 390b4e96fd0d..fe18ef691bb7 100644 --- a/drivers/s390/cio/cio.c +++ b/drivers/s390/cio/cio.c @@ -564,11 +564,6 @@ int cio_validate_subchannel(struct subchannel *sch, struct subchannel_id schid) goto out; } mutex_init(&sch->reg_mutex); - /...
f014824ee72e66292c3b1172dc142f959b42e61b
Analyze and fix the following issue in the Linux kernel code: [S390] cio: fix use after free in s390 debug feature
Problem Details: When using s390dbf with "%s" in sprintf format strings the string itself is not copied to the dbf buffer. Since in this case only pointers are stored in the s390dbf, we should not use dev_name - which is bound to the lifetime of the device. Reading this entry from s390dbf after the device was released ...
```diff diff --git a/drivers/s390/cio/device.c b/drivers/s390/cio/device.c index a50cfa51aa3c..6b770f8c0a89 100644 --- a/drivers/s390/cio/device.c +++ b/drivers/s390/cio/device.c @@ -2038,7 +2038,9 @@ static void __ccw_device_pm_restore(struct ccw_device *cdev) spin_unlock_irq(sch->lock); if (ret) { CIO_MSG_EVEN...
be7a2ddce66991c05a1c6ad19790289591e53547
Analyze and fix the following issue in the Linux kernel code: [S390] cio: ensure to hold a reference for deferred deregistration
Problem Details: Ensure to always hold an extra device reference for scheduling a subchannel deregistration, by moving the get_device to ccw_device_schedule_sch_unregister. This fixes an use after free error in ccw_device_call_sch_unregister where put_device was called on an already freed device structure. Signed-off-...
```diff diff --git a/drivers/s390/cio/device.c b/drivers/s390/cio/device.c index 19b4469a3ca4..a7a340b1d713 100644 --- a/drivers/s390/cio/device.c +++ b/drivers/s390/cio/device.c @@ -333,15 +333,15 @@ ccw_device_remove_disconnected(struct ccw_device *cdev) * Forced offline in disconnected state means * 'throw awa...
efd986db2d720e8f6660ec2c292509ee7d28cc6a
Analyze and fix the following issue in the Linux kernel code: [S390] cio: increase trace level
Problem Details: Move debug traces for start I/O and interrupt events to exclusive trace levels. Also change tracing in hot-path from sprintf (costly) to hex. Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
```diff diff --git a/drivers/s390/cio/cio.c b/drivers/s390/cio/cio.c index 5ec7789bd9d8..390b4e96fd0d 100644 --- a/drivers/s390/cio/cio.c +++ b/drivers/s390/cio/cio.c @@ -139,12 +139,11 @@ cio_start_key (struct subchannel *sch, /* subchannel structure */ __u8 lpm, /* logical path mask */ __u8 key) ...
626e476ae011cafddc0ccb39ab838b90cc5d2272
Analyze and fix the following issue in the Linux kernel code: [S390] cio: fix not oper handling after failed [on|off]line processing
Problem Details: If online/offline processing of a ccw device fails, resulting in not operational state, notify the driver and unregister the device in case the driver dosn't want to keep it. Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
```diff diff --git a/drivers/s390/cio/device_fsm.c b/drivers/s390/cio/device_fsm.c index b8bdb0d75426..9c1452a6b9a1 100644 --- a/drivers/s390/cio/device_fsm.c +++ b/drivers/s390/cio/device_fsm.c @@ -394,6 +394,13 @@ ccw_device_done(struct ccw_device *cdev, int state) ccw_device_schedule_sch_unregister(cdev); cde...
1f1148c88ad37c87f14d2153416a605bf0aeaf74
Analyze and fix the following issue in the Linux kernel code: [S390] cio: fix ineffective verify event
Problem Details: Path verification events occurring for offline devices are currently ignored. As a result, offline devices are not removed, even though they might no longer be accessible (for example because the last path to the device was varied offline). Fix this by scheduling a status evaluation for the affected su...
```diff diff --git a/drivers/s390/cio/device_fsm.c b/drivers/s390/cio/device_fsm.c index 3db88c52d287..b8bdb0d75426 100644 --- a/drivers/s390/cio/device_fsm.c +++ b/drivers/s390/cio/device_fsm.c @@ -730,6 +730,17 @@ static void ccw_device_generic_notoper(struct ccw_device *cdev, css_schedule_eval(sch->schid); } +/...
d993831fa7ffeb89e994f046f93eeb09ec91df08
Analyze and fix the following issue in the Linux kernel code: writeback: add name to backing_dev_info
Problem Details: This enables us to track who does what and print info. Its main use is catching dirty inodes on the default_backing_dev_info, so we can fix that up. Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
```diff diff --git a/block/blk-core.c b/block/blk-core.c index e3299a77a0d8..e695634882a6 100644 --- a/block/blk-core.c +++ b/block/blk-core.c @@ -501,6 +501,7 @@ struct request_queue *blk_alloc_queue_node(gfp_t gfp_mask, int node_id) (VM_MAX_READAHEAD * 1024) / PAGE_CACHE_SIZE; q->backing_dev_info.state = 0; q...
f09b00d3e789a88fa6c7c03cedc62cb65c1de0cb
Analyze and fix the following issue in the Linux kernel code: writeback: add some debug inode list counters to bdi stats
Problem Details: Add some debug entries to be able to inspect the internal state of the writeback details. Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
```diff diff --git a/mm/backing-dev.c b/mm/backing-dev.c index 7f3fa79f25c0..22c45e932e3a 100644 --- a/mm/backing-dev.c +++ b/mm/backing-dev.c @@ -52,9 +52,29 @@ static void bdi_debug_init(void) static int bdi_debug_stats_show(struct seq_file *m, void *v) { struct backing_dev_info *bdi = m->private; + struct bdi_wr...
1d6ed32226326a6e6cd67cd9ee4294bcbb0c9a15
Analyze and fix the following issue in the Linux kernel code: powerpc/iseries: Fix oops reading from /proc/iSeries/mf/*/cmdline
Problem Details: That code uses dma_mapping_error() with a NULL device, which is a bad idea :-) The proper fix might be to start using some kind of pseudo device for all these low level mappings with the hypervisor but that will be for another day. Since it directly calls into the low level iommu code, I see no problem...
```diff diff --git a/arch/powerpc/platforms/iseries/mf.c b/arch/powerpc/platforms/iseries/mf.c index fef4d5150517..0d9343df35bc 100644 --- a/arch/powerpc/platforms/iseries/mf.c +++ b/arch/powerpc/platforms/iseries/mf.c @@ -872,7 +872,7 @@ static int proc_mf_dump_cmdline(char *page, char **start, off_t off, count = 2...