id stringlengths 40 40 | instruction stringlengths 68 308 | input stringlengths 17 33.4k | output stringlengths 100 30k |
|---|---|---|---|
3b87487ac5008072f138953b07505a7e3493327f | Analyze and fix the following issue in the Linux kernel code: Revert "clockevents: Set noop handler in clockevents_exchange_device()" | Problem Details:
This reverts commit de28f25e8244c7353abed8de0c7792f5f883588c.
It results in resume problems for various people. See for example
http://thread.gmane.org/gmane.linux.kernel/1233033
http://thread.gmane.org/gmane.linux.kernel/1233389
http://thread.gmane.org/gmane.linux.kernel/1233159
http://threa... | ```diff
diff --git a/kernel/time/clockevents.c b/kernel/time/clockevents.c
index c4eb71c8b2ea..1ecd6ba36d6c 100644
--- a/kernel/time/clockevents.c
+++ b/kernel/time/clockevents.c
@@ -387,7 +387,6 @@ void clockevents_exchange_device(struct clock_event_device *old,
* released list and do a notify add later.
*/
if... |
b16ec6f735b8f8588c7c3e7703f7ad6267715eb8 | Analyze and fix the following issue in the Linux kernel code: [media] tm6000: using an uninitialized variable in debug code | Problem Details:
dprintk() dereferences "ir". I'm not sure why gcc doesn't complain
about this.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> | ```diff
diff --git a/drivers/media/video/tm6000/tm6000-input.c b/drivers/media/video/tm6000/tm6000-input.c
index 8d925274c8d6..7844607dd45a 100644
--- a/drivers/media/video/tm6000/tm6000-input.c
+++ b/drivers/media/video/tm6000/tm6000-input.c
@@ -408,13 +408,13 @@ int tm6000_ir_init(struct tm6000_core *dev)
if (!dev-... |
a7187c324ff5a879b5b0e6bb947664071c870803 | Analyze and fix the following issue in the Linux kernel code: [media] [BUG] Re: add support for IT9135 9005 devices | Problem Details:
Re: [git:v4l-dvb/for_v3.3] [media] it9135: add support for IT9135 9005 devices
On Sun, 2011-12-11 at 11:55 +0100, Mauro Carvalho Chehab wrote:
> This is an automatic generated email to let you know that the following patch were queued at the
> http://git.linuxtv.org/media_tree.git tree:
>
> Subject: [... | ```diff
diff --git a/drivers/media/dvb/dvb-usb/it913x.c b/drivers/media/dvb/dvb-usb/it913x.c
index 47317e9faa41..627fb819122d 100644
--- a/drivers/media/dvb/dvb-usb/it913x.c
+++ b/drivers/media/dvb/dvb-usb/it913x.c
@@ -775,7 +775,7 @@ static struct dvb_usb_device_properties it913x_properties = {
.rc_codes = RC_MAP_M... |
1b7acf0ccd61b814032668d1d21740cfae3304e3 | Analyze and fix the following issue in the Linux kernel code: [media] xc4000: Use kcalloc instead of kzalloc to allocate array | Problem Details:
The advantage of kcalloc is, that will prevent integer overflows which could
result from the multiplication of number of elements and size and it is also
a bit nicer to read.
The semantic patch that makes this change is available
in https://lkml.org/lkml/2011/11/25/107
Signed-off-by: Thomas Meyer <th... | ```diff
diff --git a/drivers/media/common/tuners/tuner-xc2028.c b/drivers/media/common/tuners/tuner-xc2028.c
index e531267babce..4df952c47f86 100644
--- a/drivers/media/common/tuners/tuner-xc2028.c
+++ b/drivers/media/common/tuners/tuner-xc2028.c
@@ -311,7 +311,7 @@ static int load_all_firmwares(struct dvb_frontend *fe... |
9884d7bea756a4657c6a5d20249bffadc460e140 | Analyze and fix the following issue in the Linux kernel code: [media] v4l2-ctrls: Use kcalloc instead of kzalloc to allocate array | Problem Details:
The advantage of kcalloc is, that will prevent integer overflows which could
result from the multiplication of number of elements and size and it is also
a bit nicer to read.
The semantic patch that makes this change is available
in https://lkml.org/lkml/2011/11/25/107
Signed-off-by: Thomas Meyer <th... | ```diff
diff --git a/drivers/media/video/stk-webcam.c b/drivers/media/video/stk-webcam.c
index cbc105f975de..dba2317ba5b9 100644
--- a/drivers/media/video/stk-webcam.c
+++ b/drivers/media/video/stk-webcam.c
@@ -377,8 +377,8 @@ static int stk_prepare_iso(struct stk_camera *dev)
if (dev->isobufs)
STK_ERROR("isobufs ... |
d0d97488dd1e8131ac9d8f7d3487c355f4bf9d72 | Analyze and fix the following issue in the Linux kernel code: [media] uvcvideo: Use kcalloc instead of kzalloc to allocate array | Problem Details:
The advantage of kcalloc is, that will prevent integer overflows which could
result from the multiplication of number of elements and size and it is also
a bit nicer to read.
The semantic patch that makes this change is available
in https://lkml.org/lkml/2011/11/25/107
Signed-off-by: Thomas Meyer <th... | ```diff
diff --git a/drivers/media/video/uvc/uvc_ctrl.c b/drivers/media/video/uvc/uvc_ctrl.c
index 3e849d977bd4..0efd3b10b353 100644
--- a/drivers/media/video/uvc/uvc_ctrl.c
+++ b/drivers/media/video/uvc/uvc_ctrl.c
@@ -1874,7 +1874,7 @@ int uvc_ctrl_init_device(struct uvc_device *dev)
if (ncontrols == 0)
continu... |
505b534d9611023a5fcd6010c4366d5cb884d751 | Analyze and fix the following issue in the Linux kernel code: [media] v4l: s5p-tv: Use kcalloc instead of kzalloc to allocate array | Problem Details:
The advantage of kcalloc is, that will prevent integer overflows which could
result from the multiplication of number of elements and size and it is also
a bit nicer to read.
The semantic patch that makes this change is available
in https://lkml.org/lkml/2011/11/25/107
Signed-off-by: Thomas Meyer <th... | ```diff
diff --git a/drivers/media/video/s5p-tv/hdmi_drv.c b/drivers/media/video/s5p-tv/hdmi_drv.c
index 0279e6e89feb..8199288481f3 100644
--- a/drivers/media/video/s5p-tv/hdmi_drv.c
+++ b/drivers/media/video/s5p-tv/hdmi_drv.c
@@ -838,8 +838,8 @@ static int hdmi_resources_init(struct hdmi_device *hdev)
dev_err(dev, ... |
b9d5efcceb6b34ee20111b62cf7be61ae79af4e9 | Analyze and fix the following issue in the Linux kernel code: [media] DVB: dvb_frontend: fix delayed thread exit | Problem Details:
There are some issues and miss-behaves at the dvb fe thread:
1) dvb_shutdown_timeout should be dvb_shutdown_timeout * HZ
instead of (dvb_shutdown_timeout * HZ + 1);
2) add a memory barrier to warrant that all CPU's will consider the
new value for release_jiffies;
3) wake up dvb thread also whe... | ```diff
diff --git a/drivers/media/dvb/dvb-core/dvb_frontend.c b/drivers/media/dvb/dvb-core/dvb_frontend.c
index 66537b10132c..3ff37cfde6ab 100644
--- a/drivers/media/dvb/dvb-core/dvb_frontend.c
+++ b/drivers/media/dvb/dvb-core/dvb_frontend.c
@@ -507,7 +507,7 @@ static int dvb_frontend_is_exiting(struct dvb_frontend *f... |
a1dca1e30ac7991d8a90a3377008c850eb466edf | Analyze and fix the following issue in the Linux kernel code: [media] [saa7134] do not change mute state for capturing audio | Problem Details:
The attached patch fixes the automute logic of saa7134.
It avoids the white noise on the pulseaudio startup.
(pulseaudio reads the saa7134 alsa device on startup)
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> | ```diff
diff --git a/drivers/media/video/saa7134/saa7134-core.c b/drivers/media/video/saa7134/saa7134-core.c
index ca65cda3e101..5fbb4e49495c 100644
--- a/drivers/media/video/saa7134/saa7134-core.c
+++ b/drivers/media/video/saa7134/saa7134-core.c
@@ -1263,7 +1263,6 @@ static int saa7134_resume(struct pci_dev *pci_dev)
... |
8cc20dd89c9ec807b169c8db42192377da470acc | Analyze and fix the following issue in the Linux kernel code: [media] wl128x: fmdrv_tx: fix signedness bugs | Problem Details:
Message-Id: <1322820073-19347-4-git-send-email-xi.wang@gmail.com>
The error handling with (ret < 0) didn't work where ret is a u32.
Use int instead. To be consistent we also change the functions to
return an int.
Signed-off-by: Xi Wang <xi.wang@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mcheha... | ```diff
diff --git a/drivers/media/radio/wl128x/fmdrv_tx.c b/drivers/media/radio/wl128x/fmdrv_tx.c
index be54068b56a8..6ea33e09d63b 100644
--- a/drivers/media/radio/wl128x/fmdrv_tx.c
+++ b/drivers/media/radio/wl128x/fmdrv_tx.c
@@ -24,10 +24,10 @@
#include "fmdrv_common.h"
#include "fmdrv_tx.h"
-u32 fm_tx_set_stereo... |
d24674c60b6fe790a274d4936bcdc8c482bbd9fe | Analyze and fix the following issue in the Linux kernel code: [media] wl128x: fmdrv_rx: fix signedness bugs | Problem Details:
Message-Id: <1322820073-19347-3-git-send-email-xi.wang@gmail.com>
The error handling with (ret < 0) didn't work where ret is a u32.
Use int instead. To be consistent we also change the functions to
return an int.
Signed-off-by: Xi Wang <xi.wang@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mcheha... | ```diff
diff --git a/drivers/media/radio/wl128x/fmdrv_rx.c b/drivers/media/radio/wl128x/fmdrv_rx.c
index ec529b55b040..43fb72291bea 100644
--- a/drivers/media/radio/wl128x/fmdrv_rx.c
+++ b/drivers/media/radio/wl128x/fmdrv_rx.c
@@ -43,12 +43,13 @@ void fm_rx_reset_station_info(struct fmdev *fmdev)
fmdev->rx.stat_info.... |
a61278037b57b1d75467dcfeb255584d5f11743d | Analyze and fix the following issue in the Linux kernel code: [media] wl128x: fmdrv_common: fix signedness bugs | Problem Details:
Message-Id: <1322820073-19347-2-git-send-email-xi.wang@gmail.com>
The error handling with (ret < 0) didn't work where ret is a u32.
Use int instead. To be consistent we also change the functions to
return an int.
Signed-off-by: Xi Wang <xi.wang@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mcheha... | ```diff
diff --git a/drivers/media/radio/wl128x/fmdrv_common.c b/drivers/media/radio/wl128x/fmdrv_common.c
index 5991ab60303d..bf867a6b5ea0 100644
--- a/drivers/media/radio/wl128x/fmdrv_common.c
+++ b/drivers/media/radio/wl128x/fmdrv_common.c
@@ -387,7 +387,7 @@ static void send_tasklet(unsigned long arg)
* Queues FM... |
27d3e366091b13c26d5d996709fd9d99858455eb | Analyze and fix the following issue in the Linux kernel code: [media] gscpa_vicam: Fix oops if unplugged while streaming | Problem Details:
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> | ```diff
diff --git a/drivers/media/video/gspca/vicam.c b/drivers/media/video/gspca/vicam.c
index 81dd4c99d025..8423ee1c305c 100644
--- a/drivers/media/video/gspca/vicam.c
+++ b/drivers/media/video/gspca/vicam.c
@@ -324,7 +324,8 @@ static void sd_stop0(struct gspca_dev *gspca_dev)
dev->work_thread = NULL;
mutex_lock... |
47faa6f83633aa4839ea680ca794ee210009064c | Analyze and fix the following issue in the Linux kernel code: [media] gspca: Fix bulk mode cameras no longer working (regression fix) | Problem Details:
The new iso bandwidth calculation code accidentally has broken support
for bulk mode cameras. This has broken the following drivers:
finepix, jeilinj, ovfx2, ov534, ov534_9, se401, sq905, sq905c, sq930x,
stv0680, vicam.
Thix patch fixes this. Fix tested with: se401, sq905, sq905c, stv0680 &
vicam cams... | ```diff
diff --git a/drivers/media/video/gspca/gspca.c b/drivers/media/video/gspca/gspca.c
index 271be9866893..5ce3557bde89 100644
--- a/drivers/media/video/gspca/gspca.c
+++ b/drivers/media/video/gspca/gspca.c
@@ -838,13 +838,13 @@ static int gspca_init_transfer(struct gspca_dev *gspca_dev)
gspca_dev->usb_err = 0;
... |
57e43cfb6cf9b88d776f3193f12cd6f81177bd6e | Analyze and fix the following issue in the Linux kernel code: [media] videobuf2-core: fix a warning at vb2 | Problem Details:
It seems that a cut-and-past error were added by the last patch:
drivers/media/video/videobuf2-core.c: In function ‘vb2_qbuf’:
drivers/media/video/videobuf2-core.c:1099:14: warning: comparison between ‘enum v4l2_buf_type’ and ‘enum v4l2_memory’ [-Wenum-compare]
On all places V4L2_MEMORY_USERPTR is us... | ```diff
diff --git a/drivers/media/video/videobuf2-core.c b/drivers/media/video/videobuf2-core.c
index 26cfbf5c9f8c..2e8f1df775b6 100644
--- a/drivers/media/video/videobuf2-core.c
+++ b/drivers/media/video/videobuf2-core.c
@@ -1096,7 +1096,7 @@ int vb2_qbuf(struct vb2_queue *q, struct v4l2_buffer *b)
* beggining of ... |
a00d02663735df4027809da4412280925c7c9453 | Analyze and fix the following issue in the Linux kernel code: [media] media: vb2: review mem_priv usage and fix potential bugs | Problem Details:
This patch is a result of review of mem_priv entry usage in videobuf2 core.
It fixes all all potential places where it was not checked against NULL or
zeroed after freeing as well as a few style issues.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.p... | ```diff
diff --git a/drivers/media/video/videobuf2-core.c b/drivers/media/video/videobuf2-core.c
index 9dc887b2aac0..26cfbf5c9f8c 100644
--- a/drivers/media/video/videobuf2-core.c
+++ b/drivers/media/video/videobuf2-core.c
@@ -65,8 +65,10 @@ static int __vb2_buf_mem_alloc(struct vb2_buffer *vb)
return 0;
free:
/* ... |
b037c0fde22b1d3cd0b3c3717d28e54619fc1592 | Analyze and fix the following issue in the Linux kernel code: [media] media: vb2: fix potential deadlock in mmap vs. get_userptr handling | Problem Details:
To get direct access to userspace memory pages vb2 allocator needs to
gather read access on mmap semaphore in the current process.
The same semaphore is taken before calling mmap operation, while
both mmap and qbuf are called by the driver or v4l2 core with
driver's lock held. To avoid a AB-BA deadlock... | ```diff
diff --git a/drivers/media/video/videobuf2-core.c b/drivers/media/video/videobuf2-core.c
index 4d22b8214f98..a3a9bf908d84 100644
--- a/drivers/media/video/videobuf2-core.c
+++ b/drivers/media/video/videobuf2-core.c
@@ -1082,46 +1082,76 @@ EXPORT_SYMBOL_GPL(vb2_prepare_buf);
*/
int vb2_qbuf(struct vb2_queue *... |
f0b7c7fc6f15e823cb4a5d225d9ef28b884ab6ec | Analyze and fix the following issue in the Linux kernel code: [media] media: vb2: fix queueing of userptr buffers with null buffer pointer | Problem Details:
Heuristic that checks if the memory pointer has been changed lacked a check
if the pointer was actually provided by the userspace, what allowed one to
queue a NULL pointer which was accepted without further checking. This
patch fixes this issue.
Reported-by: Sylwester Nawrocki <s.nawrocki@samsung.com>... | ```diff
diff --git a/drivers/media/video/videobuf2-core.c b/drivers/media/video/videobuf2-core.c
index 95a3f5e82aef..4d22b8214f98 100644
--- a/drivers/media/video/videobuf2-core.c
+++ b/drivers/media/video/videobuf2-core.c
@@ -883,7 +883,8 @@ static int __qbuf_userptr(struct vb2_buffer *vb, const struct v4l2_buffer *b)... |
54828d19f82be0d62e22fbd5a6354136c50a20eb | Analyze and fix the following issue in the Linux kernel code: [media] lgdt330x: warn on errors blasting modulation config to the lgdt3303 | Problem Details:
fix the following build warning:
lgdt330x.c: In function "lgdt330x_set_parameters":
lgdt330x.c:346:6: warning: variable "err" set but not used
[-Wunused-but-set-variable]
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> | ```diff
diff --git a/drivers/media/dvb/frontends/lgdt330x.c b/drivers/media/dvb/frontends/lgdt330x.c
index d45827158a24..c39d8d63979b 100644
--- a/drivers/media/dvb/frontends/lgdt330x.c
+++ b/drivers/media/dvb/frontends/lgdt330x.c
@@ -347,7 +347,7 @@ static int lgdt330x_set_parameters(struct dvb_frontend* fe,
stati... |
26110dac8b3b30a99555d85fc1308a21fba5b746 | Analyze and fix the following issue in the Linux kernel code: [media] lgdt330x: fix behavior of read errors in lgdt330x_read_ucblocks | Problem Details:
initialize *ucblocks to zero & fix the following build warning:
lgdt330x.c: In function "lgdt330x_read_ucblocks":
lgdt330x.c:288:6: warning: variable "err" set but not used
[-Wunused-but-set-variable]
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@re... | ```diff
diff --git a/drivers/media/dvb/frontends/lgdt330x.c b/drivers/media/dvb/frontends/lgdt330x.c
index 43971e63baa7..d45827158a24 100644
--- a/drivers/media/dvb/frontends/lgdt330x.c
+++ b/drivers/media/dvb/frontends/lgdt330x.c
@@ -288,6 +288,8 @@ static int lgdt330x_read_ucblocks(struct dvb_frontend* fe, u32* ucblo... |
1ca8dde859844c50e043182060acf14be5288463 | Analyze and fix the following issue in the Linux kernel code: [media] tda18271c2dd: fix support for DVB-C | Problem Details:
As reported by Hartmut <e9hack@googlemail.com>:
> A break is missing before the default statement. Delivery systems for DVB-C result always
> in an error.
Reported-by: Hartmut <e9hack@googlemail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> | ```diff
diff --git a/drivers/media/dvb/frontends/tda18271c2dd.c b/drivers/media/dvb/frontends/tda18271c2dd.c
index 0f8e9622bc96..f8933cf66ebb 100644
--- a/drivers/media/dvb/frontends/tda18271c2dd.c
+++ b/drivers/media/dvb/frontends/tda18271c2dd.c
@@ -1159,6 +1159,7 @@ static int set_params(struct dvb_frontend *fe,
... |
5b2acf384c8a8707d32a98106192ee7187e4446d | Analyze and fix the following issue in the Linux kernel code: ARM: imx6: fix v7_invalidate_l1 by adding I-Cache invalidation | Problem Details:
The recent suspend/resume and reset testing on imx6q discovers that
not only D-Cache but also I-Cache has random data and validity when
the core comes out of a power recycle.
This patch adds I-Cache invalidation into v7_invalidate_l1 to make
sure both D-Cache and I-Cache invalidated on power-up.
Sign... | ```diff
diff --git a/arch/arm/mach-imx/head-v7.S b/arch/arm/mach-imx/head-v7.S
index 6229efbc70cb..c844112061be 100644
--- a/arch/arm/mach-imx/head-v7.S
+++ b/arch/arm/mach-imx/head-v7.S
@@ -33,6 +33,7 @@
*/
ENTRY(v7_invalidate_l1)
mov r0, #0
+ mcr p15, 0, r0, c7, c5, 0 @ invalidate I cache
mcr p15, 2, r0, c0, c... |
7f9ab6ac2e79b9658eba7c8e3ad8a4392d308057 | Analyze and fix the following issue in the Linux kernel code: tipc: rename struct bcbearer* to tipc_bcbearer* | Problem Details:
This changes both the struct bcbearer and struct bcbearer_pair to
have the "tipc_" prefix. Runtime behaviour is unchanged.
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> | ```diff
diff --git a/net/tipc/bcast.c b/net/tipc/bcast.c
index e88da1cfe3db..c24690fbaa7f 100644
--- a/net/tipc/bcast.c
+++ b/net/tipc/bcast.c
@@ -46,7 +46,7 @@
#define BCLINK_WIN_DEFAULT 20 /* bcast link window size (default) */
/**
- * struct bcbearer_pair - a pair of bearers used by broadcast link
+ * struct ti... |
358a0d1c9edcf6ff041776d65cdc2bc59887ab9c | Analyze and fix the following issue in the Linux kernel code: tipc: rename struct media to struct tipc_media | Problem Details:
Give it a meaningful prefix, as suggested by DaveM, so that it
is consistent with things like struct tipc_bearer, and so it isn't
confused with anything else. This has no impact on the actual
runtime code behaviour.
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> | ```diff
diff --git a/net/tipc/bcast.c b/net/tipc/bcast.c
index 048b7a3e848e..b6afe7356a86 100644
--- a/net/tipc/bcast.c
+++ b/net/tipc/bcast.c
@@ -76,7 +76,7 @@ struct bcbearer_pair {
struct bcbearer {
struct tipc_bearer bearer;
- struct media media;
+ struct tipc_media media;
struct bcbearer_pair bpairs[MAX_BEA... |
b0365c8d0cb6e79eb5f21418ae61ab511f31b575 | Analyze and fix the following issue in the Linux kernel code: mm: hugetlb: fix non-atomic enqueue of huge page | Problem Details:
If a huge page is enqueued under the protection of hugetlb_lock, then the
operation is atomic and safe.
Signed-off-by: Hillf Danton <dhillf@gmail.com>
Reviewed-by: Michal Hocko <mhocko@suse.cz>
Acked-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: <stable@vger.kernel.org> [2.6.37+]
Signed-... | ```diff
diff --git a/mm/hugetlb.c b/mm/hugetlb.c
index 73f17c0293c0..2316840b337a 100644
--- a/mm/hugetlb.c
+++ b/mm/hugetlb.c
@@ -901,7 +901,6 @@ retry:
h->resv_huge_pages += delta;
ret = 0;
- spin_unlock(&hugetlb_lock);
/* Free the needed pages to the hugetlb pool */
list_for_each_entry_safe(page, tmp, &sur... |
34845636a184f3be91a531098192592cbe6db587 | Analyze and fix the following issue in the Linux kernel code: procfs: do not confuse jiffies with cputime64_t | Problem Details:
Commit 2a95ea6c0d129b4 ("procfs: do not overflow get_{idle,iowait}_time
for nohz") did not take into account that one some architectures jiffies
and cputime use different units.
This causes get_idle_time() to return numbers in the wrong units, making
the idle time fields in /proc/stat wrong.
Instead ... | ```diff
diff --git a/arch/ia64/include/asm/cputime.h b/arch/ia64/include/asm/cputime.h
index 6073b187528a..5a274af31b2b 100644
--- a/arch/ia64/include/asm/cputime.h
+++ b/arch/ia64/include/asm/cputime.h
@@ -60,6 +60,7 @@ typedef u64 cputime64_t;
*/
#define cputime_to_usecs(__ct) ((__ct) / NSEC_PER_USEC)
#define us... |
e26a51148f3ebd859bca8bf2e0f212839b447f62 | Analyze and fix the following issue in the Linux kernel code: mm/mempolicy.c: refix mbind_range() vma issue | Problem Details:
commit 8aacc9f550 ("mm/mempolicy.c: fix pgoff in mbind vma merge") is the
slightly incorrect fix.
Why? Think following case.
1. map 4 pages of a file at offset 0
[0123]
2. map 2 pages just after the first mapping of the same file but with
page offset 2
[0123][23]
3. mbind() 2 pages from ... | ```diff
diff --git a/mm/mempolicy.c b/mm/mempolicy.c
index adc395481813..c3fdbcb17658 100644
--- a/mm/mempolicy.c
+++ b/mm/mempolicy.c
@@ -636,6 +636,7 @@ static int mbind_range(struct mm_struct *mm, unsigned long start,
struct vm_area_struct *prev;
struct vm_area_struct *vma;
int err = 0;
+ pgoff_t pgoff;
unsi... |
757e55c23dc62eb5adf45368a72f6b26d6a71ae5 | Analyze and fix the following issue in the Linux kernel code: gspca: Fix bulk mode cameras no longer working (regression fix) | Problem Details:
The new iso bandwidth calculation code accidentally has broken support
for bulk mode cameras. This has broken the following drivers:
finepix, jeilinj, ovfx2, ov534, ov534_9, se401, sq905, sq905c, sq930x,
stv0680, vicam.
Thix patch fixes this. Fix tested with: se401, sq905, sq905c, stv0680 & vicam
cams... | ```diff
diff --git a/drivers/media/video/gspca/gspca.c b/drivers/media/video/gspca/gspca.c
index 881e04c7ffe6..512f32ff446a 100644
--- a/drivers/media/video/gspca/gspca.c
+++ b/drivers/media/video/gspca/gspca.c
@@ -838,13 +838,13 @@ static int gspca_init_transfer(struct gspca_dev *gspca_dev)
gspca_dev->usb_err = 0;
... |
c0e0c89c089f4bd66dbbd1a44da90abe74fe3f02 | Analyze and fix the following issue in the Linux kernel code: m68knommu: fix broken boot logo inclusion | Problem Details:
Compiling for the m68knommu/68328 Palm/Pilot target you get:
AS arch/m68k/platform/68328/head-pilot.o
arch/m68k/platform/68328/head-pilot.S:37:23: fatal error: bootlogo.rh: No such file or directory
The build for this target used to do a conversion on a C coded boot logo
and include this in th... | ```diff
diff --git a/arch/m68k/platform/68328/Makefile b/arch/m68k/platform/68328/Makefile
index e4dfd8fde068..ee61bf84d4a0 100644
--- a/arch/m68k/platform/68328/Makefile
+++ b/arch/m68k/platform/68328/Makefile
@@ -14,12 +14,8 @@ obj-$(CONFIG_M68328) += config.o
obj-$(CONFIG_ROM) += romvec.o
extra-y := head.o
-ex... |
8ade06c616b34b4237c0ed77d1ff0ce04ad7d056 | Analyze and fix the following issue in the Linux kernel code: ipv6: Fix neigh lookup using NULL device. | Problem Details:
In some of the rt6_bind_neighbour() call sites, it hasn't hooked
up the rt->dst.dev pointer yet, so we'd deref a NULL pointer when
obtaining dev->ifindex for the neighbour hash function computation.
Just pass the netdevice explicitly in to fix this problem.
Reported-by: Bjarke Istrup Pedersen <gurlig... | ```diff
diff --git a/net/ipv6/route.c b/net/ipv6/route.c
index 30de9e74a813..4a62c47599b4 100644
--- a/net/ipv6/route.c
+++ b/net/ipv6/route.c
@@ -129,11 +129,14 @@ static struct neighbour *ip6_neigh_lookup(const struct dst_entry *dst, const voi
return neigh_create(&nd_tbl, daddr, dst->dev);
}
-static int rt6_bind... |
a4b4f4371b94552973109f6b9ebe6af7a9efa0bd | Analyze and fix the following issue in the Linux kernel code: sparc32: fix PAGE_SIZE definition | Problem Details:
Use _AC() in definition of PAGE_SIZE so the same definition
can be used in C and assembler.
Also use PAGE_SIZE in definition of THREAD_SIZE.
This commit kill the following comment:
"I have my suspicions... -DaveM"
I did not find any clue what this referred to anyway.
Signed-off-by: Sam Ravnborg... | ```diff
diff --git a/arch/sparc/include/asm/page_32.h b/arch/sparc/include/asm/page_32.h
index 156707b0f18d..bb5c2ac4055d 100644
--- a/arch/sparc/include/asm/page_32.h
+++ b/arch/sparc/include/asm/page_32.h
@@ -8,14 +8,10 @@
#ifndef _SPARC_PAGE_H
#define _SPARC_PAGE_H
-#define PAGE_SHIFT 12
+#include <linux/const... |
7c9c3a1e5fc8728e948b8fa3cbcfcfb86db3afda | Analyze and fix the following issue in the Linux kernel code: x86/intel config: Fix the APB_TIMER selection | Problem Details:
Seems Kconfig SELECT isn't selecting things hierarchically when
selected.
config APB_TIMER
def_bool y if X86_INTEL_MID
prompt "Intel MID APB Timer Support" if X86_INTEL_MID
select DW_APB_TIMER
depends on X86_INTEL_MID && SFI
when we select APB_TIMER doesn't select DW_APB_T... | ```diff
diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index 07620bc913db..78fbb346959b 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -409,12 +409,14 @@ config X86_MRST
depends on PCI
depends on PCI_GOANY
depends on X86_IO_APIC
+ select X86_INTEL_MID
+ select SFI
+ select DW_APB_TIMER
select APB_TIM... |
f2328062726d36e562f1458d6346b77aa048acad | Analyze and fix the following issue in the Linux kernel code: perf tools: Fix feature-bits rework fallout, remove unused variable | Problem Details:
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Cc: Robert Richter <robert.richter@amd.com>
Link: http://lkml.kernel.org/n/tip-lfckuwbl8m1ykb7t9ydsxe4r@git.kernel.org
Signed-o... | ```diff
diff --git a/tools/perf/util/header.c b/tools/perf/util/header.c
index e509a9dea00b..3e7e0b09c12c 100644
--- a/tools/perf/util/header.c
+++ b/tools/perf/util/header.c
@@ -1415,15 +1415,12 @@ static int perf_header__adds_write(struct perf_header *header,
struct perf_evlist *evlist, int fd)
{
int nr_se... |
bc94b52167596e4f9c0a020c10e2f49b04a2e48b | Analyze and fix the following issue in the Linux kernel code: netfilter: Kconfig: fix unmet xt_nfacct dependencies | Problem Details:
warning: (NETFILTER_XT_MATCH_NFACCT) selects NETFILTER_NETLINK_ACCT which has
unmet direct dependencies (NET && INET && NETFILTER && NETFILTER_ADVANCED)
and then
ERROR: "nfnetlink_subsys_unregister" [net/netfilter/nfnetlink_acct.ko] undefined!
ERROR: "nfnetlink_subsys_register" [net/netfilter/nfnetli... | ```diff
diff --git a/net/netfilter/Kconfig b/net/netfilter/Kconfig
index f6275a0f1ea7..f8ac4ef0b794 100644
--- a/net/netfilter/Kconfig
+++ b/net/netfilter/Kconfig
@@ -908,7 +908,7 @@ config NETFILTER_XT_MATCH_MULTIPORT
config NETFILTER_XT_MATCH_NFACCT
tristate '"nfacct" match support'
- default m if NETFILTER_ADVA... |
6ccbcf2cb41131f8d56ef0723bf3f7c1f8486076 | Analyze and fix the following issue in the Linux kernel code: Input: sentelic - fix retrieving number of buttons | Problem Details:
Fixing wrong register offset which is used to retrieve the number of buttons
attached to the hardware.
Signed-off-by: Tai-hwa Liang <avatar@sentelic.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru> | ```diff
diff --git a/drivers/input/mouse/sentelic.c b/drivers/input/mouse/sentelic.c
index a2c15e9a8e79..86d6f39178b0 100644
--- a/drivers/input/mouse/sentelic.c
+++ b/drivers/input/mouse/sentelic.c
@@ -2,7 +2,7 @@
* Finger Sensing Pad PS/2 mouse driver.
*
* Copyright (C) 2005-2007 Asia Vital Components Co., Ltd.... |
32c78de8f17369def492ea3ddd785f0cc140af02 | Analyze and fix the following issue in the Linux kernel code: regulator: Fix checking return value of create_regulator | Problem Details:
create_regulator() returns NULL on fail.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> | ```diff
diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c
index 6cb9d399affd..e70e15c4aa28 100644
--- a/drivers/regulator/core.c
+++ b/drivers/regulator/core.c
@@ -985,9 +985,8 @@ static int set_supply(struct regulator_dev *rdev,
rdev_info(rdev, "supplied by %s\n", rdev_get_name(supply_rdev));
rdev... |
bcda432194fc7c4a2dbe9d7146f00b4b21e66c8c | Analyze and fix the following issue in the Linux kernel code: regulator: Fix the error handling if create_regulator fails | Problem Details:
In the case of create_regulator() fails, goto the error path immediately.
It does not make sense to update rdev->open_count if create_regulator fails.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> | ```diff
diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c
index 6f7d411b048b..6cb9d399affd 100644
--- a/drivers/regulator/core.c
+++ b/drivers/regulator/core.c
@@ -1282,6 +1282,7 @@ found:
if (regulator == NULL) {
regulator = ERR_PTR(-ENOMEM);
module_put(rdev->owner);
+ goto out;
}
rdev->o... |
f2b20d436534f22ccc3f5ad172499fcb013bb315 | Analyze and fix the following issue in the Linux kernel code: block: fix blk_queue_end_tag() | Problem Details:
Commit 5e081591 "block: warn if tag is greater than real_max_depth"
cleaned up blk_queue_end_tag() to warn when the tag is truly invalid
(greater than real_max_depth). However, it changed behavior in the tag <
max_depth case to not end the request. Leading to triggering of
BUG_ON(blk_queued_rq(rq)) i... | ```diff
diff --git a/block/blk-tag.c b/block/blk-tag.c
index e74d6d13838f..4af6f5cc1167 100644
--- a/block/blk-tag.c
+++ b/block/blk-tag.c
@@ -282,18 +282,9 @@ EXPORT_SYMBOL(blk_queue_resize_tags);
void blk_queue_end_tag(struct request_queue *q, struct request *rq)
{
struct blk_queue_tag *bqt = q->queue_tags;
- int... |
2d91cf17b58b4d8228190103bef507bc73094bef | Analyze and fix the following issue in the Linux kernel code: drm/exynos: Fix a fake mmap offset creation | Problem Details:
Make a fake mmap offset only when it needs.
Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> | ```diff
diff --git a/drivers/gpu/drm/exynos/exynos_drm_gem.c b/drivers/gpu/drm/exynos/exynos_drm_gem.c
index 44ce07c2133f..90aa6302eaf9 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_gem.c
+++ b/drivers/gpu/drm/exynos/exynos_drm_gem.c
@@ -55,13 +55,6 @@ static unsigned int convert_to_vm_err_msg(int msg)
return out_ms... |
88635ca277adb67db34e88281817d1ce10713553 | Analyze and fix the following issue in the Linux kernel code: ext4: add missing spaces to debugging printk's | Problem Details:
Fix ext4_debug format in ext4_ext_handle_uninitialized_extents() and
ext4_end_io_dio().
Signed-off-by: Zheng Liu <wenqing.lz@taobao.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu> | ```diff
diff --git a/fs/ext4/extents.c b/fs/ext4/extents.c
index 5684f2510921..b35bb40556dc 100644
--- a/fs/ext4/extents.c
+++ b/fs/ext4/extents.c
@@ -3456,8 +3456,8 @@ ext4_ext_handle_uninitialized_extents(handle_t *handle, struct inode *inode,
int err = 0;
ext4_io_end_t *io = EXT4_I(inode)->cur_aio_dio;
- ext_d... |
1ba37268cd19e5a2a80924bfe8618bf1ba3e8249 | Analyze and fix the following issue in the Linux kernel code: jbd2: clear revoked flag on buffers before a new transaction started | Problem Details:
Currently, we clear revoked flag only when a block is reused. However,
this can tigger a false journal error. Consider a situation when a block
is used as a meta block and is deleted(revoked) in ordered mode, then the
block is allocated as a data block to a file. At this moment, user changes
the fil... | ```diff
diff --git a/fs/jbd2/commit.c b/fs/jbd2/commit.c
index 68d704db787f..5069b8475150 100644
--- a/fs/jbd2/commit.c
+++ b/fs/jbd2/commit.c
@@ -429,6 +429,12 @@ void jbd2_journal_commit_transaction(journal_t *journal)
jbd_debug(3, "JBD2: commit phase 1\n");
+ /*
+ * Clear revoked flag to reflect there is no r... |
32288eb4d940b10e40c6d4178fe3a40d1437d2f8 | Analyze and fix the following issue in the Linux kernel code: netrom: avoid overflows in nr_setsockopt() | Problem Details:
Check setsockopt arguments to avoid overflows and return -EINVAL for
too large arguments.
Signed-off-by: Xi Wang <xi.wang@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net> | ```diff
diff --git a/net/netrom/af_netrom.c b/net/netrom/af_netrom.c
index c329b474eace..7dab229bfbcc 100644
--- a/net/netrom/af_netrom.c
+++ b/net/netrom/af_netrom.c
@@ -306,26 +306,26 @@ static int nr_setsockopt(struct socket *sock, int level, int optname,
{
struct sock *sk = sock->sk;
struct nr_sock *nr = nr_sk... |
ba1cffe0257bcd4d0070bc0e64f8ead97fefd148 | Analyze and fix the following issue in the Linux kernel code: ax25: avoid overflows in ax25_setsockopt() | Problem Details:
Commit be639ac6 ("NET: AX.25: Check ioctl arguments to avoid overflows
further down the road") rejects very large arguments, but doesn't
completely fix overflows on 64-bit systems. Consider the AX25_T2 case.
int opt;
...
if (opt < 1 || opt > ULONG_MAX / HZ) {
res = -EINVAL;
break;
}
ax25->t2... | ```diff
diff --git a/net/ax25/af_ax25.c b/net/ax25/af_ax25.c
index b863c1877c80..3cd0a0dc91cb 100644
--- a/net/ax25/af_ax25.c
+++ b/net/ax25/af_ax25.c
@@ -545,15 +545,16 @@ static int ax25_setsockopt(struct socket *sock, int level, int optname,
ax25_cb *ax25;
struct net_device *dev;
char devname[IFNAMSIZ];
- int ... |
cf1ee98d800459e6f055742f84355b1aa9e937ae | Analyze and fix the following issue in the Linux kernel code: ASoC: sgtl5000: Fix voltage units in dev_err message | Problem Details:
vdda, vddio and vddd are voltages expressed in milivolts (mV), so use the
proper annotation.
Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> | ```diff
diff --git a/sound/soc/codecs/sgtl5000.c b/sound/soc/codecs/sgtl5000.c
index 250175755eb2..827a43bec531 100644
--- a/sound/soc/codecs/sgtl5000.c
+++ b/sound/soc/codecs/sgtl5000.c
@@ -1076,7 +1076,7 @@ static int sgtl5000_set_power_regs(struct snd_soc_codec *codec)
/* according to datasheet, maximum voltage of... |
2aff57b0c052344e8401a8b4a33c2a1ecb0f627c | Analyze and fix the following issue in the Linux kernel code: ext4: allocate delalloc blocks before changing journal mode | Problem Details:
delalloc blocks should be allocated before changing journal mode,
otherwise they can not be allocated and even more truncate on
delalloc blocks could triggre BUG by flushing delalloc buffers.
Signed-off-by: Yongqiang Yang <xiaoqiangnk@gmail.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu> | ```diff
diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c
index 92655fd89657..cb0ba9d77a8e 100644
--- a/fs/ext4/inode.c
+++ b/fs/ext4/inode.c
@@ -4647,6 +4647,17 @@ int ext4_change_inode_journal_flag(struct inode *inode, int val)
return 0;
if (is_journal_aborted(journal))
return -EROFS;
+ /* We have to allocate ph... |
6abda3e129bfe4d74b5c274da7dff0e2b1488818 | Analyze and fix the following issue in the Linux kernel code: ARM: mxs: select HAVE_CLK_PREPARE for clock | Problem Details:
This patch adds clk_prepare/clk_unprepare for mxs clock api by
renaming the existing non-atomic clk_enable/clk_disable to
clk_prepare/clk_unprepare and adding a pair of dummy
clk_enable/clk_disable. Then with selecting HAVE_CLK_PREPARE for
mxs clock, we can fix the mutex locking warning that has been
... | ```diff
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 776d76b8cb69..dc461637e778 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -442,6 +442,7 @@ config ARCH_MXS
select ARCH_REQUIRE_GPIOLIB
select CLKDEV_LOOKUP
select CLKSRC_MMIO
+ select HAVE_CLK_PREPARE
help
Support for Freescale MXS-base... |
d4d9820b4ad6d6227cad090a9f695eea37814215 | Analyze and fix the following issue in the Linux kernel code: ASoC: Fix build error in sound/soc/kirkwood/kirkwood-i2s.c | Problem Details:
Since commit db33f4de "ARM: Orion: Remove address map info from all platform data structures",
the dram is removed from struct kirkwood_asoc_platform_data.
This patch fixes below build error:
CC sound/soc/kirkwood/kirkwood-i2s.o
sound/soc/kirkwood/kirkwood-i2s.c: In function 'kirkwood_i2s_dev_p... | ```diff
diff --git a/sound/soc/kirkwood/kirkwood-i2s.c b/sound/soc/kirkwood/kirkwood-i2s.c
index f6bb21156876..3cb9aa4299d3 100644
--- a/sound/soc/kirkwood/kirkwood-i2s.c
+++ b/sound/soc/kirkwood/kirkwood-i2s.c
@@ -441,13 +441,12 @@ static __devinit int kirkwood_i2s_dev_probe(struct platform_device *pdev)
goto err_i... |
61cbaa928705eaeabefb8a5264bc22b4ca909f6b | Analyze and fix the following issue in the Linux kernel code: ARM: pxa: Include linux/export.h in balloon3.c | Problem Details:
Include linux/export.h to fix below build warning:
CC arch/arm/mach-pxa/balloon3.o
arch/arm/mach-pxa/balloon3.c:85: warning: data definition has no type or storage class
arch/arm/mach-pxa/balloon3.c:85: warning: type defaults to 'int' in declaration of 'EXPORT_SYMBOL_GPL'
arch/arm/mach-pxa/ball... | ```diff
diff --git a/arch/arm/mach-pxa/balloon3.c b/arch/arm/mach-pxa/balloon3.c
index 4b81f59a4cba..f3a456a0680e 100644
--- a/arch/arm/mach-pxa/balloon3.c
+++ b/arch/arm/mach-pxa/balloon3.c
@@ -13,6 +13,7 @@
* published by the Free Software Foundation.
*/
+#include <linux/export.h>
#include <linux/init.h>
#in... |
baaf939db44d08ef910558ff5eb16d123df3f621 | Analyze and fix the following issue in the Linux kernel code: ARM: SAMSUNG: Fix build error when selecting CPU_FREQ_S3C24XX_DEBUGFS on S3C2440 | Problem Details:
Following is happened when CONFIG_CPU_FREQ_S3C24XX_DEBUGFS
is selected without building of s3c2410-iotiming.c file:
arch/arm/mach-s3c2440/built-in.o:(.data+0x38c): undefined reference to `s3c2410_iotiming_debugfs
Basically, the CONFIG_S3C2410_IOTIMING is not selected for
MACH_MINI2440. Because the s3... | ```diff
diff --git a/arch/arm/plat-samsung/include/plat/cpu-freq-core.h b/arch/arm/plat-samsung/include/plat/cpu-freq-core.h
index dac4760c0f0a..95509d8eb140 100644
--- a/arch/arm/plat-samsung/include/plat/cpu-freq-core.h
+++ b/arch/arm/plat-samsung/include/plat/cpu-freq-core.h
@@ -202,14 +202,6 @@ extern int s3c_pllta... |
aef950b4ba3196622a5bd5e21ab1d63f30658285 | Analyze and fix the following issue in the Linux kernel code: packet: fix possible dev refcnt leak when bind fail | Problem Details:
If bind is fail when bind is called after set PACKET_FANOUT
sock option, the dev refcnt will leak.
Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: David S. Miller <davem@davemloft.net> | ```diff
diff --git a/net/packet/af_packet.c b/net/packet/af_packet.c
index 3891702b81df..d9d4970b9b07 100644
--- a/net/packet/af_packet.c
+++ b/net/packet/af_packet.c
@@ -2448,8 +2448,12 @@ static int packet_do_bind(struct sock *sk, struct net_device *dev, __be16 protoc
{
struct packet_sock *po = pkt_sk(sk);
- if ... |
75c71848f22e6381f48614da23df2a43e374b498 | Analyze and fix the following issue in the Linux kernel code: of/pdt: fix section mismatch warning | Problem Details:
Fix the following section mismatch warning - seen when building sparc32:
WARNING: vmlinux.o(.text+0x1ff9c0): Section mismatch in reference from the function kernel_tree_alloc() to the function .init.text:prom_early_alloc()
The function kernel_tree_alloc() references
the function __init prom_early_allo... | ```diff
diff --git a/drivers/of/pdt.c b/drivers/of/pdt.c
index bc5b3990f6ed..07cc1d678e4d 100644
--- a/drivers/of/pdt.c
+++ b/drivers/of/pdt.c
@@ -229,7 +229,7 @@ static struct device_node * __init of_pdt_build_tree(struct device_node *parent,
return ret;
}
-static void *kernel_tree_alloc(u64 size, u64 align)
+sta... |
ab17da5cb9d4aaf9f04c706761d3a8024897bedd | Analyze and fix the following issue in the Linux kernel code: apbuart: fix section mismatch warning | Problem Details:
Fix following warnings:
WARNING: drivers/tty/serial/built-in.o(.text+0x7370): Section mismatch in reference from the function grlib_apbuart_configure() to the variable .init.data:apbuart_match
The function grlib_apbuart_configure() references
the variable __initdata apbuart_match.
This is often becaus... | ```diff
diff --git a/drivers/tty/serial/apbuart.c b/drivers/tty/serial/apbuart.c
index 77554fd68d1f..7162f70d9260 100644
--- a/drivers/tty/serial/apbuart.c
+++ b/drivers/tty/serial/apbuart.c
@@ -577,7 +577,7 @@ static int __devinit apbuart_probe(struct platform_device *op)
return 0;
}
-static struct of_device_id _... |
0d098587cec70048336a3809bcde8044c7e9aa08 | Analyze and fix the following issue in the Linux kernel code: watchdog: iTCO_wdt.c - problems with newer hardware due to SMI clearing (part 2) | Problem Details:
Redhat Bugzilla: Bug 727875 - TCO_EN bit is disabled by TCO driver
The previous patch breaks reset watchdog behaviour on the older hardware.
It is therefor better to make sure that the behaviour for older hardware (<=ICH5 or
6300ESB) is preserved and that the behaviour for newer hardware is changed.
W... | ```diff
diff --git a/drivers/watchdog/iTCO_wdt.c b/drivers/watchdog/iTCO_wdt.c
index ba6ad662635a..99796c5d913d 100644
--- a/drivers/watchdog/iTCO_wdt.c
+++ b/drivers/watchdog/iTCO_wdt.c
@@ -384,10 +384,10 @@ MODULE_PARM_DESC(nowayout,
"Watchdog cannot be stopped once started (default="
__MODULE_STRING(WATCHDOG_... |
c0d2b8376ae2d74aa862e946a372502603e9066d | Analyze and fix the following issue in the Linux kernel code: net: meth: Add set_rx_mode hook to fix ICMPv6 neighbor discovery | Problem Details:
SGI IP32 (O2)'s ethernet driver (meth) lacks a set_rx_mode function, which
prevents IPv6 from working completely because any ICMPv6 neighbor
solicitation requests aren't picked up by the driver. So the machine can
ping out and connect to other systems, but other systems will have a very
hard time conn... | ```diff
diff --git a/arch/mips/include/asm/ip32/mace.h b/arch/mips/include/asm/ip32/mace.h
index d08d7c672139..c523123df380 100644
--- a/arch/mips/include/asm/ip32/mace.h
+++ b/arch/mips/include/asm/ip32/mace.h
@@ -95,7 +95,7 @@ struct mace_video {
* Ethernet interface
*/
struct mace_ethernet {
- volatile unsigned... |
65cb5df51acaa6b1070a81d6c2e0a1535d3a7b8d | Analyze and fix the following issue in the Linux kernel code: net: calxeda xgmac ethernet driver add missing HAS_IOMEM dependency | Problem Details:
Fix allyesconfig build on architectures without IOMEM:
drivers/net/ethernet/calxeda/xgmac.c:1800:2:
error: implicit declaration of function 'iounmap' [-Werror=implicit-function-declaration]
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Rob Herring <rob.herring@calxeda.com>
Acked-by:... | ```diff
diff --git a/drivers/net/ethernet/calxeda/Kconfig b/drivers/net/ethernet/calxeda/Kconfig
index a52e725c861c..aba435c3d4ae 100644
--- a/drivers/net/ethernet/calxeda/Kconfig
+++ b/drivers/net/ethernet/calxeda/Kconfig
@@ -1,6 +1,6 @@
config NET_CALXEDA_XGMAC
tristate "Calxeda 1G/10G XGMAC Ethernet driver"
-
+ d... |
c98b2cc29af8e84e7364b53e9bb4cc7cfaf62555 | Analyze and fix the following issue in the Linux kernel code: block: remove WARN_ON_ONCE() in exit_io_context() | Problem Details:
6e736be7 "block: make ioc get/put interface more conventional and fix
race on alloction" added WARN_ON_ONCE() in exit_io_context() which
triggers if !PF_EXITING. All tasks hitting exit_io_context() from
task exit should have PF_EXITING set but task struct tearing down
after fork failure calls into the... | ```diff
diff --git a/block/blk-ioc.c b/block/blk-ioc.c
index 33fae7df16a0..27a06e00eaec 100644
--- a/block/blk-ioc.c
+++ b/block/blk-ioc.c
@@ -230,9 +230,6 @@ void exit_io_context(struct task_struct *task)
{
struct io_context *ioc;
- /* PF_EXITING prevents new io_context from being attached to @task */
- WARN_ON_O... |
4ae1652ef1bf38e07caa5d1d86ffd3b31103b55a | Analyze and fix the following issue in the Linux kernel code: Bluetooth: Fix a compile warning in RFCOMM | Problem Details:
sock and sk were leftover from another change.
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> | ```diff
diff --git a/net/bluetooth/rfcomm/core.c b/net/bluetooth/rfcomm/core.c
index 1524418f39e3..09a3cbcf794e 100644
--- a/net/bluetooth/rfcomm/core.c
+++ b/net/bluetooth/rfcomm/core.c
@@ -1774,9 +1774,6 @@ static inline int rfcomm_process_tx(struct rfcomm_dlc *d)
return skb_queue_len(&d->tx_queue);
while (d->... |
cd3decdfd1dbab8a585eafe2e5b9866f193de99e | Analyze and fix the following issue in the Linux kernel code: tipc: Ensure broadcast link spinlock is held when updating node map | Problem Details:
Fixes oversight that allowed broadcast link node map to be updated without
first taking the broadcast link spinlock that protects the map. As part
of this fix the node map has been incorporated into the broadcast link
structure to make the need for such protection more evident.
Signed-off-by: Allan St... | ```diff
diff --git a/net/tipc/bcast.c b/net/tipc/bcast.c
index 738cb642d31b..5ca8fdda63ca 100644
--- a/net/tipc/bcast.c
+++ b/net/tipc/bcast.c
@@ -87,6 +87,7 @@ struct bcbearer {
* struct bclink - link used for broadcast messages
* @link: (non-standard) broadcast link structure
* @node: (non-standard) node struct... |
c47e9b918844ab7bb139eada7b085c576ddf0afb | Analyze and fix the following issue in the Linux kernel code: tipc: Eliminate dynamic allocation of broadcast link data structures | Problem Details:
Creates global variables to hold the broadcast link's pseudo-bearer and
pseudo-link structures, rather than allocating them dynamically. There
is only a single instance of each structure, and changing over to static
allocation allows elimination of code to handle the cases where dynamic
allocation was ... | ```diff
diff --git a/net/tipc/bcast.c b/net/tipc/bcast.c
index 28908f54459e..738cb642d31b 100644
--- a/net/tipc/bcast.c
+++ b/net/tipc/bcast.c
@@ -98,10 +98,13 @@ struct bclink {
struct tipc_node *retransmit_to;
};
+static struct bcbearer bcast_bearer;
+static struct bclink bcast_link;
+
+static struct bcbearer *b... |
02834eece0786b6e9c77029f0bfb597052a2e86f | Analyze and fix the following issue in the Linux kernel code: [S390] Enable exception traces by default | Problem Details:
Enable exception traces by default so that early user space breakage
(e.g. broken code in initrd) can be easily indentified.
If not needed afterwards it can be disabled by writing '0' in one of
these two files:
/proc/sys/kernel/userprocess_debug
/proc/sys/debug/exception-trace
Signed-off-by: Heiko C... | ```diff
diff --git a/arch/s390/kernel/traps.c b/arch/s390/kernel/traps.c
index dc6cc1b0ae66..5ce3750b181f 100644
--- a/arch/s390/kernel/traps.c
+++ b/arch/s390/kernel/traps.c
@@ -45,7 +45,7 @@
void (*pgm_check_table[128])(struct pt_regs *regs);
-int show_unhandled_signals;
+int show_unhandled_signals = 1;
#defi... |
77ecd06ae40d0d9532c6aebc81f3d09462f20358 | Analyze and fix the following issue in the Linux kernel code: [S390] sysctl: get rid of dead declaration | Problem Details:
Remove dead sysctl_userprocess_debug. The variable is
gone since we map our old userprocess_debug sysctl to
the common code show_unhandled_signals sysctl on s390.
Signed-off-by: Heiko Carsten <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> | ```diff
diff --git a/arch/s390/include/asm/system.h b/arch/s390/include/asm/system.h
index ef573c1d71a7..d73cc6b60000 100644
--- a/arch/s390/include/asm/system.h
+++ b/arch/s390/include/asm/system.h
@@ -20,8 +20,6 @@
struct task_struct;
-extern int sysctl_userprocess_debug;
-
extern struct task_struct *__switch_t... |
b38f27e8425a132ed2dc49ffb3741404e81363d8 | Analyze and fix the following issue in the Linux kernel code: [S390] dasd: fix fixpoint divide exception in define_extent | Problem Details:
If an IO request is build on an alias device without prefix enabled
we try to calculate with zero data from the alias device. This
triggers a BUG statement with fixpoint divide exception.
This case is very unlikely and can only happen if the pathgroup is
lost with an alias device already in use.
Preven... | ```diff
diff --git a/drivers/s390/block/dasd_alias.c b/drivers/s390/block/dasd_alias.c
index c388eda1e2b1..553b3c5abb0a 100644
--- a/drivers/s390/block/dasd_alias.c
+++ b/drivers/s390/block/dasd_alias.c
@@ -705,6 +705,16 @@ struct dasd_device *dasd_alias_get_start_dev(struct dasd_device *base_device)
if (lcu->pav == ... |
e58b0d902f7c7c407bae9c8bc8d90fa1d06184c5 | Analyze and fix the following issue in the Linux kernel code: [S390] qdio: fix kernel panic for zfcp 31-bit | Problem Details:
The queue_start_poll function pointer field in struct qdio_initialize
had to change its type and become a vector of function pointers to
support asynchronous delivery of storage blocks so rename the field to
make the type change explicit and ensure no other user of qdio tries
to use the field the old w... | ```diff
diff --git a/arch/s390/include/asm/qdio.h b/arch/s390/include/asm/qdio.h
index e63d13dd3bf5..d75c8e78f7e3 100644
--- a/arch/s390/include/asm/qdio.h
+++ b/arch/s390/include/asm/qdio.h
@@ -352,7 +352,7 @@ typedef void qdio_handler_t(struct ccw_device *, unsigned int, int,
* @no_output_qs: number of output queue... |
1afcfd5948ff27cdbc6d91e9f3cdbdd7f3b1e566 | Analyze and fix the following issue in the Linux kernel code: [S390] dasd: fix expiration handling for recovery requests | Problem Details:
The 'expires' value of a ccw requests defines how long the device
driver should wait for a response from the evice after the request has
been submitted to the channel subsystem. After the expiration time
(e.g. 30 seconds) the waiting request will be cancelled and started
again. This protects the DASD d... | ```diff
diff --git a/drivers/s390/block/dasd_3990_erp.c b/drivers/s390/block/dasd_3990_erp.c
index 87a0cf160fe5..0326571e7ffa 100644
--- a/drivers/s390/block/dasd_3990_erp.c
+++ b/drivers/s390/block/dasd_3990_erp.c
@@ -1718,7 +1718,7 @@ dasd_3990_erp_action_1B_32(struct dasd_ccw_req * default_erp, char *sense)
erp->s... |
2389aef47efe32bd4ad2b7d47f157766d3680caa | Analyze and fix the following issue in the Linux kernel code: [S390] zcrypt: Fix error return codes. | Problem Details:
Return EINVAL instead of EFAULT for invalid input parameter.
Signed-off-by: Holger Dengler <hd@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> | ```diff
diff --git a/drivers/s390/crypto/zcrypt_pcixcc.c b/drivers/s390/crypto/zcrypt_pcixcc.c
index 646fb8f11512..077b7d109fde 100644
--- a/drivers/s390/crypto/zcrypt_pcixcc.c
+++ b/drivers/s390/crypto/zcrypt_pcixcc.c
@@ -260,7 +260,7 @@ static int ICACRT_msg_to_type6CRT_msgX(struct zcrypt_device *zdev,
* @ap_msg: p... |
7fe6f0970cf87dfd71452f5ec7ea54654acc9d6f | Analyze and fix the following issue in the Linux kernel code: [S390] zcrypt: Rework length parameter checking. | Problem Details:
Fix length checking of the expected reply and remove re-adjustment of
expected control block length.
Signed-off-by: Holger Dengler <hd@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> | ```diff
diff --git a/drivers/s390/crypto/zcrypt_pcixcc.c b/drivers/s390/crypto/zcrypt_pcixcc.c
index dd4737808e06..646fb8f11512 100644
--- a/drivers/s390/crypto/zcrypt_pcixcc.c
+++ b/drivers/s390/crypto/zcrypt_pcixcc.c
@@ -56,11 +56,6 @@
#define PCIXCC_MAX_ICA_RESPONSE_SIZE 0x77c /* max size type86 v2 reply */
... |
400d829153aea9487654f588d4d06e8beb8b251f | Analyze and fix the following issue in the Linux kernel code: [S390] qdio: fix qdio_allocate_aob() declaration | Problem Details:
drivers/s390/cio/qdio_setup.c:24:32:
warning: non-ANSI function declaration of function 'qdio_allocate_aob'
While at it also simplify the function.
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> | ```diff
diff --git a/drivers/s390/cio/qdio_setup.c b/drivers/s390/cio/qdio_setup.c
index 2acc01f90a6a..74bb1a088261 100644
--- a/drivers/s390/cio/qdio_setup.c
+++ b/drivers/s390/cio/qdio_setup.c
@@ -22,12 +22,9 @@
static struct kmem_cache *qdio_q_cache;
static struct kmem_cache *qdio_aob_cache;
-struct qaob *qdio_a... |
3931723f36165e137c67b8c62346024a6c4f223d | Analyze and fix the following issue in the Linux kernel code: [S390] kernel: Fix smp_switch_to_ipl_cpu() stack frame setup | Problem Details:
Currently, when smp_switch_to_ipl_cpu() is done, the backchain in the dump
analysis tool crash looks like the following:
#0 [1f746e70] __machine_kexec at 11dd92
#1 [1f746eb8] smp_restart_cpu at 11820e
#0 [00907eb0] cpu_idle at 10602e
#1 [00907ef8] start_kernel at 979a08
It would be good to see th... | ```diff
diff --git a/arch/s390/kernel/smp.c b/arch/s390/kernel/smp.c
index ee327365e436..14d5211a185d 100644
--- a/arch/s390/kernel/smp.c
+++ b/arch/s390/kernel/smp.c
@@ -149,10 +149,10 @@ void smp_switch_to_ipl_cpu(void (*func)(void *), void *data)
sp -= sizeof(struct pt_regs);
regs = (struct pt_regs *) sp;
memc... |
44e5ddc4e9d52cd5eeda42bb7518b306beab24ee | Analyze and fix the following issue in the Linux kernel code: [S390] Rework create_mem_hole() function | Problem Details:
This patch makes the create_mem_hole() function more readable and
fixes some minor bugs (e.g. off-by-one problems).
Signed-off-by: Michael Holzheu <holzheu@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> | ```diff
diff --git a/arch/s390/kernel/mem_detect.c b/arch/s390/kernel/mem_detect.c
index 19b4568f4cee..22d502e885ed 100644
--- a/arch/s390/kernel/mem_detect.c
+++ b/arch/s390/kernel/mem_detect.c
@@ -63,71 +63,83 @@ void detect_memory_layout(struct mem_chunk chunk[])
}
EXPORT_SYMBOL(detect_memory_layout);
+/*
+ * Mo... |
c86cce2a20207cbf2b3dfe97c985a1f5aa5d3798 | Analyze and fix the following issue in the Linux kernel code: [S390] kvm: fix sleeping function ... at mm/page_alloc.c:2260 | Problem Details:
commit cc772456ac9b460693492b3a3d89e8c81eda5874
[S390] fix list corruption in gmap reverse mapping
added a potential dead lock:
BUG: sleeping function called from invalid context at mm/page_alloc.c:2260
in_atomic(): 1, irqs_disabled(): 0, pid: 1108, name: qemu-system-s39
3 locks held by qemu-syst... | ```diff
diff --git a/arch/s390/mm/pgtable.c b/arch/s390/mm/pgtable.c
index 301c84d3b542..dc2269f1821c 100644
--- a/arch/s390/mm/pgtable.c
+++ b/arch/s390/mm/pgtable.c
@@ -267,7 +267,10 @@ static int gmap_alloc_table(struct gmap *gmap,
struct page *page;
unsigned long *new;
+ /* since we dont free the gmap table u... |
272f01bf9b6da93f49fcca2656c24da8d2cfcc09 | Analyze and fix the following issue in the Linux kernel code: [S390] irq: fix accounting of external call/emergency signal | Problem Details:
Mask the extint_code parameter of the smp external interrupt handler
to get the interruption code. Otherwise emergency call interrupts
erroneously might be accounted as emergency signal interrupts.
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky... | ```diff
diff --git a/arch/s390/kernel/smp.c b/arch/s390/kernel/smp.c
index 3ea872890da2..ee327365e436 100644
--- a/arch/s390/kernel/smp.c
+++ b/arch/s390/kernel/smp.c
@@ -187,7 +187,7 @@ static void do_ext_call_interrupt(unsigned int ext_int_code,
{
unsigned long bits;
- if (ext_int_code == 0x1202)
+ if ((ext_int_... |
da69dee073a27ee2d4e50c9b19e9faf8776857eb | Analyze and fix the following issue in the Linux kernel code: KVM: PPC: Whitespace fix for kvm.h | Problem Details:
kvm.h had sparse whitespace at the end of the line. Clean it
up so syncing with QEMU gets easier.
Signed-off-by: Alexander Graf <agraf@suse.de> | ```diff
diff --git a/arch/powerpc/include/asm/kvm.h b/arch/powerpc/include/asm/kvm.h
index 0ad432bc81d6..f7727d91ac6b 100644
--- a/arch/powerpc/include/asm/kvm.h
+++ b/arch/powerpc/include/asm/kvm.h
@@ -170,8 +170,8 @@ struct kvm_sregs {
} ppc64;
struct {
__u32 sr[16];
- __u64 ibat[8];
- __u64 dbat[... |
98362dec835218206fdb55212667040d23d3a440 | Analyze and fix the following issue in the Linux kernel code: KVM: Fix whitespace in kvm_para.h | Problem Details:
When syncing KVM headers with QEMU I (or whoever applies the
diff) end up automatically fixing whitespaces. One of them
is in kvm_para.h.
It's a lot more consistent for people who don't do the whitespace
fixups automatically to already have fixed headers in Linux. So
remove the sparse empty line at th... | ```diff
diff --git a/include/linux/kvm_para.h b/include/linux/kvm_para.h
index 47a070b0520e..ff476ddaf310 100644
--- a/include/linux/kvm_para.h
+++ b/include/linux/kvm_para.h
@@ -35,4 +35,3 @@ static inline int kvm_para_has_feature(unsigned int feature)
}
#endif /* __KERNEL__ */
#endif /* __LINUX_KVM_PARA_H */
-
``` |
80bdec64c05b645708b0dd97919783ad077fcdc8 | Analyze and fix the following issue in the Linux kernel code: KVM: x86 emulator: fix RDPMC privilege check | Problem Details:
RDPMC is only privileged if CR4.PCE=0. check_rdpmc() already implements this,
so all we need to do is drop the Priv flag.
Signed-off-by: Avi Kivity <avi@redhat.com>
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Signed-off-by: Avi Kivity <avi@redhat.com> | ```diff
diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/emulate.c
index de7be77820d5..d270f1a817dc 100644
--- a/arch/x86/kvm/emulate.c
+++ b/arch/x86/kvm/emulate.c
@@ -3411,7 +3411,7 @@ static struct opcode twobyte_table[256] = {
II(ImplicitOps | Priv, em_wrmsr, wrmsr),
IIP(ImplicitOps, em_rdtsc, rdtsc, check_rd... |
f5132b01386b5a67f1ff673bb2b96a507a3f7e41 | Analyze and fix the following issue in the Linux kernel code: KVM: Expose a version 2 architectural PMU to a guests | Problem Details:
Use perf_events to emulate an architectural PMU, version 2.
Based on PMU version 1 emulation by Avi Kivity.
[avi: adjust for cpuid.c]
[jan: fix anonymous field initialization for older gcc]
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by... | ```diff
diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_host.h
index 020413afb285..fb60ffdb4e43 100644
--- a/arch/x86/include/asm/kvm_host.h
+++ b/arch/x86/include/asm/kvm_host.h
@@ -16,10 +16,12 @@
#include <linux/mmu_notifier.h>
#include <linux/tracepoint.h>
#include <linux/cpumask.h>
+#inc... |
4f69b6805c4f818cf7f4126978cc4a54c489119f | Analyze and fix the following issue in the Linux kernel code: KVM: ensure that debugfs entries have been created | Problem Details:
by checking the return value from kvm_init_debug, we
can ensure that the entries under debugfs for KVM have
been created correctly.
Signed-off-by: Yang Bai <hamo.by@gmail.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com> | ```diff
diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c
index 0835c4b90d2f..7287bf5d1c9e 100644
--- a/virt/kvm/kvm_main.c
+++ b/virt/kvm/kvm_main.c
@@ -2654,15 +2654,29 @@ static const struct file_operations *stat_fops[] = {
[KVM_STAT_VM] = &vm_stat_fops,
};
-static void kvm_init_debug(void)
+static int k... |
43771ebfc9d34ab1f74095d052d225a82ae0898c | Analyze and fix the following issue in the Linux kernel code: KVM: Make KVM_INTEL depend on CPU_SUP_INTEL | Problem Details:
PMU virtualization needs to talk to Intel-specific bits of perf; these are
only available when CPU_SUP_INTEL=y.
Fixes
arch/x86/built-in.o: In function `atomic_switch_perf_msrs':
vmx.c:(.text+0x6b1d4): undefined reference to `perf_guest_get_msrs'
Reported-by: Ingo Molnar <mingo@elte.hu>
Reported-... | ```diff
diff --git a/arch/x86/kvm/Kconfig b/arch/x86/kvm/Kconfig
index ff5790d8e990..ca4d49ed9a6c 100644
--- a/arch/x86/kvm/Kconfig
+++ b/arch/x86/kvm/Kconfig
@@ -52,6 +52,8 @@ config KVM
config KVM_INTEL
tristate "KVM for Intel processors support"
depends on KVM
+ # for perf_guest_get_msrs():
+ depends on CPU_SUP... |
831bf664e9c1fc08fc6b3984d00d275cac82f5e9 | Analyze and fix the following issue in the Linux kernel code: KVM: Refactor and simplify kvm_dev_ioctl_get_supported_cpuid | Problem Details:
This patch cleans and simplifies kvm_dev_ioctl_get_supported_cpuid by using a table
instead of duplicating code as Avi suggested.
This patch also fixes a bug where kvm_dev_ioctl_get_supported_cpuid would return
-E2BIG when amount of entries passed was just right.
Signed-off-by: Sasha Levin <levinsash... | ```diff
diff --git a/arch/x86/kvm/cpuid.c b/arch/x86/kvm/cpuid.c
index 47be763e1b60..52593e8e1ae8 100644
--- a/arch/x86/kvm/cpuid.c
+++ b/arch/x86/kvm/cpuid.c
@@ -183,9 +183,10 @@ static bool supported_xcr0_bit(unsigned bit)
#define F(x) bit(X86_FEATURE_##x)
-static void do_cpuid_ent(struct kvm_cpuid_entry2 *entry... |
d77fe6354d5b67f4d4eb62a47621da2b3ee3539e | Analyze and fix the following issue in the Linux kernel code: KVM: Allow aligned byte and word writes to IOAPIC registers. | Problem Details:
This fixes byte accesses to IOAPIC_REG_SELECT as mandated by at least the
ICH10 and Intel Series 5 chipset specs. It also makes ioapic_mmio_write
consistent with ioapic_mmio_read, which also allows byte and word accesses.
Signed-off-by: Julian Stecklina <js@alien8.de>
Signed-off-by: Avi Kivity <avi@re... | ```diff
diff --git a/virt/kvm/ioapic.c b/virt/kvm/ioapic.c
index 3eed61eb4867..71e2253edee7 100644
--- a/virt/kvm/ioapic.c
+++ b/virt/kvm/ioapic.c
@@ -332,9 +332,18 @@ static int ioapic_mmio_write(struct kvm_io_device *this, gpa_t addr, int len,
(void*)addr, len, val);
ASSERT(!(addr & 0xf)); /* check alignmen... |
60f9a9ef5492cae66aca2ad9873360161320d5af | Analyze and fix the following issue in the Linux kernel code: KVM: IA64: fix struct redefinition | Problem Details:
There is the same struct definition in ia64 and kvm common code:
arch/ia64/kvm//kvm-ia64.c: At top level:
arch/ia64/kvm//kvm-ia64.c:777:8: error: redefinition of ‘struct kvm_io_range’
include/linux/kvm_host.h:62:8: note: originally defined here
So, rename kvm_io_range to kvm_ia64_io_range in ia64 code... | ```diff
diff --git a/arch/ia64/kvm/kvm-ia64.c b/arch/ia64/kvm/kvm-ia64.c
index 92d9f1e4740f..405052002493 100644
--- a/arch/ia64/kvm/kvm-ia64.c
+++ b/arch/ia64/kvm/kvm-ia64.c
@@ -774,13 +774,13 @@ struct kvm *kvm_arch_alloc_vm(void)
return kvm;
}
-struct kvm_io_range {
+struct kvm_ia64_io_range {
unsigned long s... |
bc00f8d2c2df33c6e7fc8a12c94c0c74d491e566 | Analyze and fix the following issue in the Linux kernel code: KVM: x86 emulator: Use opcode::execute for MOV to cr/dr | Problem Details:
MOV: 0F 22 (move to control registers)
MOV: 0F 23 (move to debug registers)
Signed-off-by: Takuya Yoshikawa <yoshikawa.takuya@oss.ntt.co.jp>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com> | ```diff
diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/emulate.c
index 6b7a03b18f89..7fe5ed126f6f 100644
--- a/arch/x86/kvm/emulate.c
+++ b/arch/x86/kvm/emulate.c
@@ -2638,6 +2638,34 @@ static int em_mov(struct x86_emulate_ctxt *ctxt)
return X86EMUL_CONTINUE;
}
+static int em_cr_write(struct x86_emulate_ctxt *... |
1a214246cbb431f7430f7d0c0fb66218a6f442d2 | Analyze and fix the following issue in the Linux kernel code: KVM: make checks stricter in coalesced_mmio_in_range() | Problem Details:
My testing version of Smatch complains that addr and len come from
the user and they can wrap. The path is:
-> kvm_vm_ioctl()
-> kvm_vm_ioctl_unregister_coalesced_mmio()
-> coalesced_mmio_in_range()
I don't know what the implications are of wrapping here, but we may
as well fix it, if ... | ```diff
diff --git a/virt/kvm/coalesced_mmio.c b/virt/kvm/coalesced_mmio.c
index a6ec206f36ba..88b2fe3ddf42 100644
--- a/virt/kvm/coalesced_mmio.c
+++ b/virt/kvm/coalesced_mmio.c
@@ -28,9 +28,15 @@ static int coalesced_mmio_in_range(struct kvm_coalesced_mmio_dev *dev,
* (addr,len) is fully included in
* (zone->ad... |
b297e672e24687546ac74af5ae5e8c4a022b9806 | Analyze and fix the following issue in the Linux kernel code: KVM: Fix include dependency for mmu_notifier | Problem Details:
The kvm_host struct can include an mmu_notifier struct but mmu_notifier.h is
not included directly.
Signed-off-by: Eric B Munson <emunson@mgebm.net>
Signed-off-by: Avi Kivity <avi@redhat.com> | ```diff
diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h
index 9fedeb356b95..c6a2ec925846 100644
--- a/include/linux/kvm_host.h
+++ b/include/linux/kvm_host.h
@@ -14,6 +14,7 @@
#include <linux/signal.h>
#include <linux/sched.h>
#include <linux/mm.h>
+#include <linux/mmu_notifier.h>
#include <linux/p... |
5d9ca30e96f567b67a36727aa4ebb34911a2b84a | Analyze and fix the following issue in the Linux kernel code: KVM: MMU: fix detecting misaligned accessed | Problem Details:
Sometimes, we only modify the last one byte of a pte to update status bit,
for example, clear_bit is used to clear r/w bit in linux kernel and 'andb'
instruction is used in this function, in this case, kvm_mmu_pte_write will
treat it as misaligned access, and the shadow page table is zapped
Signed-off... | ```diff
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c
index 986aea55366b..ca6f72ab4c3b 100644
--- a/arch/x86/kvm/mmu.c
+++ b/arch/x86/kvm/mmu.c
@@ -3602,6 +3602,14 @@ static bool detect_write_misaligned(struct kvm_mmu_page *sp, gpa_t gpa,
offset = offset_in_page(gpa);
pte_size = sp->role.cr4_pae ? 8 : 4;
+... |
51cfe38ea50aa631f58ed8c340ed6f0143c325a8 | Analyze and fix the following issue in the Linux kernel code: KVM: nVMX: Fix warning-causing idt-vectoring-info behavior | Problem Details:
When L0 wishes to inject an interrupt while L2 is running, it emulates an exit
to L1 with EXIT_REASON_EXTERNAL_INTERRUPT. This was explained in the original
nVMX patch 23, titled "Correct handling of interrupt injection".
Unfortunately, it is possible (though rare) that at this point there is valid
id... | ```diff
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index d75d91465246..6e28d582a514 100644
--- a/arch/x86/kvm/vmx.c
+++ b/arch/x86/kvm/vmx.c
@@ -4080,11 +4080,12 @@ static void vmx_set_nmi_mask(struct kvm_vcpu *vcpu, bool masked)
static int vmx_interrupt_allowed(struct kvm_vcpu *vcpu)
{
if (is_guest_mode(... |
b3b73ec0d7fe5bf8f950232aa58dfa0416a62372 | Analyze and fix the following issue in the Linux kernel code: PM / Freezer: fix return value of freezable_schedule_timeout_killable() | Problem Details:
...it should return the return code from schedule_timeout_killable(),
not the one from freezer_count().
All of the current callers ignore the return code so the bug is
harmless but it's worth fixing.
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl> | ```diff
diff --git a/include/linux/freezer.h b/include/linux/freezer.h
index 7bcfe73d999b..0ab54e16a91f 100644
--- a/include/linux/freezer.h
+++ b/include/linux/freezer.h
@@ -116,9 +116,11 @@ static inline int freezer_should_skip(struct task_struct *p)
/* Like schedule_timeout_killable(), but should not block the free... |
c159d30c59dc84934f8ef46f934ce1232c558ecd | Analyze and fix the following issue in the Linux kernel code: ipv6: Kill useless route tracing bits in net/ipv6/route.c | Problem Details:
RDBG() wasn't even used, and the messages printed by RT6_DEBUG() were
far from useful. Just get rid of all this stuff, we can replace it
with something more suitable if we want.
Signed-off-by: David S. Miller <davem@davemloft.net> | ```diff
diff --git a/net/ipv6/route.c b/net/ipv6/route.c
index 5855e9ede3cb..35b07cc33aad 100644
--- a/net/ipv6/route.c
+++ b/net/ipv6/route.c
@@ -62,17 +62,6 @@
#include <linux/sysctl.h>
#endif
-/* Set to 3 to get tracing. */
-#define RT6_DEBUG 2
-
-#if RT6_DEBUG >= 3
-#define RDBG(x) printk x
-#define RT6_TRACE(x... |
e143a1ada39110f9596e4ffd4e0b8399e5ab88d4 | Analyze and fix the following issue in the Linux kernel code: mlx4: Add missing include of linux/slab.h | Problem Details:
Include linux/slab.h to fix below build error:
CC drivers/net/ethernet/mellanox/mlx4/resource_tracker.o
drivers/net/ethernet/mellanox/mlx4/resource_tracker.c: In function 'mlx4_init_resource_tracker':
drivers/net/ethernet/mellanox/mlx4/resource_tracker.c:233: error: implicit declaration of func... | ```diff
diff --git a/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c b/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c
index b41762db5602..ed20751a057d 100644
--- a/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c
+++ b/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c
@@ -38,6 +38,7 @@
#include <... |
3b0723c12e825e26aa5fc0c6970108425824b51d | Analyze and fix the following issue in the Linux kernel code: unix_diag: Fix incoming connections nla length | Problem Details:
The NLA_PUT macro should accept the actual attribute length, not
the amount of elements in array :(
Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
Signed-off-by: David S. Miller <davem@davemloft.net> | ```diff
diff --git a/net/unix/diag.c b/net/unix/diag.c
index 91d57828499c..39e44c98176a 100644
--- a/net/unix/diag.c
+++ b/net/unix/diag.c
@@ -72,7 +72,8 @@ static int sk_diag_dump_icons(struct sock *sk, struct sk_buff *nlskb)
if (sk->sk_state == TCP_LISTEN) {
spin_lock(&sk->sk_receive_queue.lock);
- buf = UNIX... |
6d4b9e38d3980826abccfbd90e95bf4bd41b8dd2 | Analyze and fix the following issue in the Linux kernel code: vfs: fix handling of lock allocation failure in lease-break case | Problem Details:
Bruce Fields notes that commit 778fc546f749 ("locks: fix tracking of
inprogress lease breaks") introduced a possible error pointer
dereference on failure to allocate memory. locks_conflict() will
dereference the passed-in new lease lock structure that may be an error pointer.
This means an open (with... | ```diff
diff --git a/fs/locks.c b/fs/locks.c
index 3b0d05dcd7c1..637694bf3a03 100644
--- a/fs/locks.c
+++ b/fs/locks.c
@@ -1205,6 +1205,8 @@ int __break_lease(struct inode *inode, unsigned int mode)
int want_write = (mode & O_ACCMODE) != O_RDONLY;
new_fl = lease_alloc(NULL, want_write ? F_WRLCK : F_RDLCK);
+ if (... |
d9cba48358d858a1edea877d7b7b0bce58cee850 | Analyze and fix the following issue in the Linux kernel code: mfd: Fix annotations in da9052-core | Problem Details:
Device initialisation should be marked __devinit and __devinitdata.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> | ```diff
diff --git a/drivers/mfd/da9052-core.c b/drivers/mfd/da9052-core.c
index a7c115ca56c8..2a5e27168cac 100644
--- a/drivers/mfd/da9052-core.c
+++ b/drivers/mfd/da9052-core.c
@@ -383,7 +383,7 @@ static struct resource da9052_tsi_resources[] = {
},
};
-static struct mfd_cell __initdata da9052_subdev_info[] = {
... |
bb558dac6776386a4d6994540a009231dcf53ee1 | Analyze and fix the following issue in the Linux kernel code: watchdog: sp805: Fix section mismatch in ID table. | Problem Details:
The AMBA ID table is marked as __initdata, yet it is referenced by the
driver struct which is not. This causes a (somewhat unhelpful) section
mismatch warning:
WARNING: drivers/watchdog/sp805_wdt.o(.data+0x4c): Section mismatch in
reference from the variable sp805_wdt_driver to the (unkn... | ```diff
diff --git a/drivers/watchdog/sp805_wdt.c b/drivers/watchdog/sp805_wdt.c
index cc2cfbe33b30..bfaf9bb1ee0d 100644
--- a/drivers/watchdog/sp805_wdt.c
+++ b/drivers/watchdog/sp805_wdt.c
@@ -351,7 +351,7 @@ static int __devexit sp805_wdt_remove(struct amba_device *adev)
return 0;
}
-static struct amba_id sp805... |
251da03897b383904901620835044e298061875f | Analyze and fix the following issue in the Linux kernel code: KVM: PPC: fix kvmppc_start_thread() for CONFIG_SMP=N | Problem Details:
Currently kvmppc_start_thread() tries to wake other SMT threads via
xics_wake_cpu(). Unfortunately xics_wake_cpu only exists when
CONFIG_SMP=Y so when compiling with CONFIG_SMP=N we get:
arch/powerpc/kvm/built-in.o: In function `.kvmppc_start_thread':
book3s_hv.c:(.text+0xa1e0): undefined referen... | ```diff
diff --git a/arch/powerpc/kvm/book3s_hv.c b/arch/powerpc/kvm/book3s_hv.c
index 0cb137a9b038..336983da9e72 100644
--- a/arch/powerpc/kvm/book3s_hv.c
+++ b/arch/powerpc/kvm/book3s_hv.c
@@ -538,7 +538,7 @@ static void kvmppc_start_thread(struct kvm_vcpu *vcpu)
tpaca->kvm_hstate.napping = 0;
vcpu->cpu = vc->pcp... |
4d25a066b69fb749a39d0d4c610689dd765a0b0e | Analyze and fix the following issue in the Linux kernel code: KVM: Don't automatically expose the TSC deadline timer in cpuid | Problem Details:
Unlike all of the other cpuid bits, the TSC deadline timer bit is set
unconditionally, regardless of what userspace wants.
This is broken in several ways:
- if userspace doesn't use KVM_CREATE_IRQCHIP, and doesn't emulate the TSC
deadline timer feature, a guest that uses the feature will break
- ... | ```diff
diff --git a/Documentation/virtual/kvm/api.txt b/Documentation/virtual/kvm/api.txt
index 4df9af4f6132..e2a4b5287361 100644
--- a/Documentation/virtual/kvm/api.txt
+++ b/Documentation/virtual/kvm/api.txt
@@ -1100,6 +1100,15 @@ emulate them efficiently. The fields in each entry are defined as follows:
eax, eb... |
733d1724d7c5c79113d8063d3d9d93e8c80cea82 | Analyze and fix the following issue in the Linux kernel code: ARM: imx6q: resume PL310 only when CACHE_L2X0 defined | Problem Details:
Original patch from Lothar Waßmann, this patch fixes a building error
when CONFIG_CACHE_L2X0 is not defined.
Cc: Lothar Waßmann <lw@karo-electronics.de>
Signed-off-by: Eric Miao <eric.miao@linaro.org>
Signed-off-by: Shawn Guo <shawn.guo@linaro.org> | ```diff
diff --git a/arch/arm/mach-imx/head-v7.S b/arch/arm/mach-imx/head-v7.S
index a59cae747af4..cec23a857c7e 100644
--- a/arch/arm/mach-imx/head-v7.S
+++ b/arch/arm/mach-imx/head-v7.S
@@ -80,6 +80,7 @@ ENDPROC(v7_secondary_startup)
.data
.align
+#ifdef CONFIG_CACHE_L2X0
.macro pl310_resume
ldr r2, phys_l2x... |
3d27e23b17010c668db311140b17bbbb70c78fb9 | Analyze and fix the following issue in the Linux kernel code: KVM: Device assignment permission checks | Problem Details:
Only allow KVM device assignment to attach to devices which:
- Are not bridges
- Have BAR resources (assume others are special devices)
- The user has permissions to use
Assigning a bridge is a configuration error, it's not supported, and
typically doesn't result in the behavior the user is expect... | ```diff
diff --git a/Documentation/virtual/kvm/api.txt b/Documentation/virtual/kvm/api.txt
index ee2c96b3ba5a..4df9af4f6132 100644
--- a/Documentation/virtual/kvm/api.txt
+++ b/Documentation/virtual/kvm/api.txt
@@ -1154,6 +1154,10 @@ following flags are specified:
The KVM_DEV_ASSIGN_ENABLE_IOMMU flag is a mandatory op... |
0924ab2cfa98b1ece26c033d696651fd62896c69 | Analyze and fix the following issue in the Linux kernel code: KVM: x86: Prevent starting PIT timers in the absence of irqchip support | Problem Details:
User space may create the PIT and forgets about setting up the irqchips.
In that case, firing PIT IRQs will crash the host:
BUG: unable to handle kernel NULL pointer dereference at 0000000000000128
IP: [<ffffffffa10f6280>] kvm_set_irq+0x30/0x170 [kvm]
...
Call Trace:
[<ffffffffa11228c1>] pit_do_work+... | ```diff
diff --git a/arch/x86/kvm/i8254.c b/arch/x86/kvm/i8254.c
index 76e3f1cd0369..405f2620392f 100644
--- a/arch/x86/kvm/i8254.c
+++ b/arch/x86/kvm/i8254.c
@@ -338,11 +338,15 @@ static enum hrtimer_restart pit_timer_fn(struct hrtimer *data)
return HRTIMER_NORESTART;
}
-static void create_pit_timer(struct kvm_k... |
fd63836811d6e5b5f5f608abf865bc9e91762c8c | Analyze and fix the following issue in the Linux kernel code: block: an exiting task should be allowed to create io_context | Problem Details:
While fixing io_context creation / task exit race condition,
6e736be7f2 "block: make ioc get/put interface more conventional and
fix race on alloction" also prevented an exiting (%PF_EXITING) task
from creating its own io_context. This is incorrect as exit path may
issue IOs, e.g. from exit_files(), a... | ```diff
diff --git a/block/blk-ioc.c b/block/blk-ioc.c
index ce9b35a9468e..33fae7df16a0 100644
--- a/block/blk-ioc.c
+++ b/block/blk-ioc.c
@@ -281,9 +281,16 @@ void create_io_context_slowpath(struct task_struct *task, gfp_t gfp_flags,
INIT_HLIST_HEAD(&ioc->icq_list);
INIT_WORK(&ioc->release_work, ioc_release_fn);
... |
010dc8af8f283cc04b7d8f8844f01dd90eca69e5 | Analyze and fix the following issue in the Linux kernel code: ARM: mx5: use generic irq chip pm interface for pm functions on | Problem Details:
Two problems exist in the current i.MX5 pm suspend/resume and idle
functions. The first is the current i.MX5 suspend routine will call
tzic_enable_wake(1) to set wake source, this will set all enabled
irq as wake source rather than those wake capable. The second
is i.MX5 idle will call mx5_cpu_lp_set()... | ```diff
diff --git a/arch/arm/mach-mx5/mm.c b/arch/arm/mach-mx5/mm.c
index df4a508f240a..bc17dfea3817 100644
--- a/arch/arm/mach-mx5/mm.c
+++ b/arch/arm/mach-mx5/mm.c
@@ -13,6 +13,7 @@
#include <linux/mm.h>
#include <linux/init.h>
+#include <linux/clk.h>
#include <asm/mach/map.h>
@@ -21,10 +22,26 @@
#include ... |
60b778ce519625102d3f72a2071ea72a05e990ce | Analyze and fix the following issue in the Linux kernel code: rfs: better sizing of dev_flow_table | Problem Details:
Aim of this patch is to provide full range of rps_flow_cnt on 64bit arches.
Theorical limit on number of flows is 2^32
Fix some buggy RPS/RFS macros as well.
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
CC: Tom Herbert <therbert@google.com>
CC: Xi Wang <xi.wang@gmail.com>
CC: Laurent Chavey ... | ```diff
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index 603730804da5..a776a675c0e5 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -597,7 +597,7 @@ struct rps_map {
struct rcu_head rcu;
u16 cpus[0];
};
-#define RPS_MAP_SIZE(_num) (sizeof(struct rps_map) + (_num * ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.