id
stringlengths
40
40
instruction
stringlengths
68
308
input
stringlengths
17
33.4k
output
stringlengths
100
30k
95cb1b02b0f8e690cbcc479924573b4fb26c2e8f
Analyze and fix the following issue in the Linux kernel code: drm/i915: don't frob the vblank ts in finish_page_flip
Problem Details: Now that we correctly generate it, this hack is no longer required (and might actually paper over a serious bug). pageflip timestamps are sanity check in the latest version of the flip-test in intel-gpu-tools. v2: Also remove the gettimeofday(&now) which is no longer used. Noticed by Mario Kleiner. ...
```diff diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index 57c1309733f6..67912febb322 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c @@ -6181,15 +6181,13 @@ static void do_intel_finish_page_flip(struct drm_device *dev, struct in...
4d0f817e7482969a31c2295a530c966f135faa7e
Analyze and fix the following issue in the Linux kernel code: drm/i915: print warning if vmi915_gem_fault error is not handled
Problem Details: Falling into default case in vmi915_gem_fault is a bug. Be more verbose about it. Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
```diff diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c index 5fa3419461c5..b55eee38af76 100644 --- a/drivers/gpu/drm/i915/i915_gem.c +++ b/drivers/gpu/drm/i915/i915_gem.c @@ -1409,6 +1409,7 @@ out: case -ENOMEM: return VM_FAULT_OOM; default: + WARN_ON_ONCE(ret); return VM_FAUL...
e79e0fe380847493266fba557217e2773c61bd1b
Analyze and fix the following issue in the Linux kernel code: drm/i915: EBUSY status handling added to i915_gem_fault().
Problem Details: Subsequent threads returning EBUSY from vm_insert_pfn() was not handled correctly. As a result concurrent access from new threads to mmapped data caused SIGBUS. Note that this fixes i-g-t/tests/gem_threaded_tiled_access. Tested-by: Mika Kuoppala <mika.kuoppala@intel.com> Signed-off-by: Dmitry Rogozhk...
```diff diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c index 76bbb379d389..5fa3419461c5 100644 --- a/drivers/gpu/drm/i915/i915_gem.c +++ b/drivers/gpu/drm/i915/i915_gem.c @@ -1400,6 +1400,11 @@ out: case 0: case -ERESTARTSYS: case -EINTR: + case -EBUSY: + /* + * EBUSY is ok: thi...
066258f4293128bb489e42790637dd6d9b7ff206
Analyze and fix the following issue in the Linux kernel code: ARM: pxa: remove sharpsl_fatal_check function
Problem Details: The sharpsl_fatal_check has not been used since Pavel Machek removed the caller in 99f329a2b "pxa/sharpsl_pm: zaurus c3000 aka spitz: fix resume". Nobody has complained since 2009, so it's safe to assume we can just remove the function. Without this patch, building corgi_defconfig results in: /home/a...
```diff diff --git a/arch/arm/mach-pxa/sharpsl_pm.c b/arch/arm/mach-pxa/sharpsl_pm.c index bdf4cb88ca0a..6c9658f4695a 100644 --- a/arch/arm/mach-pxa/sharpsl_pm.c +++ b/arch/arm/mach-pxa/sharpsl_pm.c @@ -55,7 +55,6 @@ #ifdef CONFIG_PM static int sharpsl_off_charge_battery(void); static int sharpsl_check_battery_volta...
9c7f4f5ce6523af6b6e103a991b2ca71b962acb7
Analyze and fix the following issue in the Linux kernel code: ARM: shark: fix shark_pci_init return code
Problem Details: When run on the wrong platform, the shark_pci_init function returns an undefined value, as reported by a gcc warning, so let's just return -ENODEV. Without this patch, building shark_defconfig results in: arch/arm/mach-shark/pci.c: In function 'shark_pci_init': arch/arm/mach-shark/pci.c:42:3: warning...
```diff diff --git a/arch/arm/mach-shark/pci.c b/arch/arm/mach-shark/pci.c index 9089407d5326..2b351a339c93 100644 --- a/arch/arm/mach-shark/pci.c +++ b/arch/arm/mach-shark/pci.c @@ -38,7 +38,7 @@ static struct hw_pci shark_pci __initdata = { static int __init shark_pci_init(void) { if (!machine_is_shark()) - retu...
d900bd7366463fd96a907b2c212242e2b68b27d8
Analyze and fix the following issue in the Linux kernel code: powerpc/iommu: Fix multiple issues with IOMMU pools code
Problem Details: There are a number of issues in the recent IOMMU pools code: - On a preempt kernel we might switch CPUs in the middle of building a scatter gather list. When this happens the handle hint passed in no longer falls within the local CPU's pool. Check for this and fall back to the pool hint. - We w...
```diff diff --git a/arch/powerpc/kernel/iommu.c b/arch/powerpc/kernel/iommu.c index ff5a6ce027b8..8226c6cb348a 100644 --- a/arch/powerpc/kernel/iommu.c +++ b/arch/powerpc/kernel/iommu.c @@ -215,7 +215,8 @@ static unsigned long iommu_range_alloc(struct device *dev, spin_lock_irqsave(&(pool->lock), flags); again: -...
c8adfeccee01ce3de6a7d14fcd4e3be02e27f03c
Analyze and fix the following issue in the Linux kernel code: powerpc: Fix VMX fix for memcpy case
Problem Details: In 2fae7cdb60240e2e2d9b378afbf6d9fcce8a3890 ("powerpc: Fix VMX in interrupt check in POWER7 copy loops"), Anton inadvertently introduced a regression for memcpy on POWER7 machines. copyuser and memcpy diverge slightly in their use of cr1 (copyuser doesn't use it, but memcpy does) and you end up clobber...
```diff diff --git a/arch/powerpc/lib/memcpy_power7.S b/arch/powerpc/lib/memcpy_power7.S index 7ba6c96de778..0663630baf3b 100644 --- a/arch/powerpc/lib/memcpy_power7.S +++ b/arch/powerpc/lib/memcpy_power7.S @@ -239,8 +239,8 @@ _GLOBAL(memcpy_power7) ori r9,r9,1 /* stream=1 */ srdi r7,r5,7 /* length in cacheline...
ca16f580a5db7e60bfafe59a50bb133bd3347491
Analyze and fix the following issue in the Linux kernel code: lguest: fix occasional crash in example launcher.
Problem Details: We usually got away with ->next on the final entry being NULL, but it finally bit me. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Cc: stable@kernel.org
```diff diff --git a/tools/lguest/lguest.c b/tools/lguest/lguest.c index f759f4f097c7..fd2f9221b241 100644 --- a/tools/lguest/lguest.c +++ b/tools/lguest/lguest.c @@ -1299,6 +1299,7 @@ static struct device *new_device(const char *name, u16 type) dev->feature_len = 0; dev->num_vq = 0; dev->running = false; + dev->...
fab9f8d093a60e524efbf6afe6c10e10c91f1642
Analyze and fix the following issue in the Linux kernel code: drm/exynos: fix kcalloc size of g2d cmdlist node
Problem Details: The size argument means just one element size when we call kcalloc, so G2D_CMDLIST_NUM * sizeof(*node) is wrong. Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com>
```diff diff --git a/drivers/gpu/drm/exynos/exynos_drm_g2d.c b/drivers/gpu/drm/exynos/exynos_drm_g2d.c index dcbc4cb423be..3fbe5915ccce 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_g2d.c +++ b/drivers/gpu/drm/exynos/exynos_drm_g2d.c @@ -165,8 +165,7 @@ static int g2d_init_cmdlist(struct g2d_data *g2d) return -ENOM...
2ab97921786f614bc9296722d8a2e2ce32d1760b
Analyze and fix the following issue in the Linux kernel code: drm/exynos: fix to calculate CRTC shown via screen
Problem Details: This patch is to exactly calculate CRTC shown via screen for all cases. Refer exynos_plane_get_size() function for this. Also source position of fb is fixed when start position of CRTC is negative number. Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.pa...
```diff diff --git a/drivers/gpu/drm/exynos/exynos_drm_plane.c b/drivers/gpu/drm/exynos/exynos_drm_plane.c index 8c3036dd512b..2a27b5678893 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_plane.c +++ b/drivers/gpu/drm/exynos/exynos_drm_plane.c @@ -32,6 +32,42 @@ static const uint32_t formats[] = { DRM_FORMAT_NV12MT, ...
58f6aad7d93f7ce009d371aa5065b70d593d3b17
Analyze and fix the following issue in the Linux kernel code: drm/exynos: fix display power call issue.
Problem Details: Changelog v3: make exynos_drm_display_power function use exynos_drm_best_encoder function instead of connector->encoder to get a valid encoder. connector->encoder could be NULL because with DRM_IOCTL_MODE_RMFB request, connector->encoder is NULL so fix this issue. Changelog v2: remove static prefix so...
```diff diff --git a/drivers/gpu/drm/exynos/exynos_drm_connector.c b/drivers/gpu/drm/exynos/exynos_drm_connector.c index 87cf3783efdc..da074746967c 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_connector.c +++ b/drivers/gpu/drm/exynos/exynos_drm_connector.c @@ -199,8 +199,7 @@ static int exynos_drm_connector_mode_vali...
53bd5556547d72fb9c572d66c3b7bfe0f096972b
Analyze and fix the following issue in the Linux kernel code: drm/exynos: Fix potential NULL pointer dereference
Problem Details: drm_mode_create() returns NULL if it fails to create a new display mode. Check the value returned to avoid NULL pointer deferencing later. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> 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_connector.c b/drivers/gpu/drm/exynos/exynos_drm_connector.c index 59e79ff4b2eb..87cf3783efdc 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_connector.c +++ b/drivers/gpu/drm/exynos/exynos_drm_connector.c @@ -150,8 +150,12 @@ static int exynos_drm_connector_get_mode...
471d60fe594ed1a7ae28a3f911d1200ae51efbdc
Analyze and fix the following issue in the Linux kernel code: drm/exynos: fix duplicated mutex lock issue
Problem Details: exynos_drm_crtc_dpms function doesn't need mutex lock because mutex lock was called by drm framework so this patch removes mutex lock call from that function to avoid duplicated mutex locking. 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_crtc.c b/drivers/gpu/drm/exynos/exynos_drm_crtc.c index b612bf5bc1a8..8bd4d7ed964b 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_crtc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_crtc.c @@ -66,7 +66,6 @@ struct exynos_drm_crtc { static void exynos_drm_crtc_dpms(st...
bcf4cef94294992f7cd11d5a90fa58b0eae6c795
Analyze and fix the following issue in the Linux kernel code: drm/exynos: Disable plane when released
Problem Details: this patch ensures that each plane connected to encoder is disabled when released, by adding disable callback function of encoder helper we had faced with one issue that invalid memory is accessed by dma once drm is released and then the dma is turned on again. actually, in our case, page fault was in...
```diff diff --git a/drivers/gpu/drm/exynos/exynos_drm_encoder.c b/drivers/gpu/drm/exynos/exynos_drm_encoder.c index 92f9acf77b7f..96a10c38cd72 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_encoder.c +++ b/drivers/gpu/drm/exynos/exynos_drm_encoder.c @@ -214,12 +214,27 @@ static void exynos_drm_encoder_commit(struct dr...
50caf25c583b938c681b61e64dac58da9b640f2f
Analyze and fix the following issue in the Linux kernel code: drm/exynos: fixed duplicated mode setting.
Problem Details: this patch fixes that when drm_crtc_helper_set_mode() is called, mode data for hardware overlay and conntroller are updated two times. for example, in case that drm_crtc_helper_set_mode() is called, overlay_ops->commit() and manager_ops->commit() callbacks can be called two times, first at drm_crtc_hel...
```diff diff --git a/drivers/gpu/drm/exynos/exynos_drm_connector.c b/drivers/gpu/drm/exynos/exynos_drm_connector.c index 9dce3b9c3896..59e79ff4b2eb 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_connector.c +++ b/drivers/gpu/drm/exynos/exynos_drm_connector.c @@ -40,6 +40,7 @@ struct exynos_drm_connector { struct drm_...
5d55393a85f9a3c9ce93d17ae85b53c4f9f33bff
Analyze and fix the following issue in the Linux kernel code: drm/exynos: separeated fimd_power_on into some parts.
Problem Details: Changelog v2: fix pm operation when resume. Changelog v1: this patch separetes fimd_power_on into fimd_activate and fimd_clock and fimd_activate function will call fimd_clock to control fimd power and vsync interrupt. Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Kyungmin Park <kyungm...
```diff diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimd.c b/drivers/gpu/drm/exynos/exynos_drm_fimd.c index 47396e13b460..28733cd52745 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fimd.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fimd.c @@ -747,16 +747,10 @@ static void fimd_clear_win(struct fimd_context *ctx, int wi...
c0b8b99287235626a5850ef7e5bfc842d1ebcecd
Analyze and fix the following issue in the Linux kernel code: cxgb4: Fix build error due to missing linux/vmalloc.h include.
Problem Details: Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: David S. Miller <davem@davemloft.net>
```diff diff --git a/drivers/net/ethernet/chelsio/cxgb4/cxgb4.h b/drivers/net/ethernet/chelsio/cxgb4/cxgb4.h index 745a1f53361f..31752b24434e 100644 --- a/drivers/net/ethernet/chelsio/cxgb4/cxgb4.h +++ b/drivers/net/ethernet/chelsio/cxgb4/cxgb4.h @@ -43,6 +43,7 @@ #include <linux/pci.h> #include <linux/spinlock.h> #...
abb139e75c2cdbb955e840d6331cb5863e409d0e
Analyze and fix the following issue in the Linux kernel code: firmware: teach the kernel to load firmware files directly from the filesystem
Problem Details: This is a first step in allowing people to by-pass udev for loading device firmware. Current versions of udev will deadlock (causing us to block for the 30 second timeout) under some circumstances if the firmware is loaded as part of the module initialization path, and this is causing problems for med...
```diff diff --git a/drivers/base/firmware_class.c b/drivers/base/firmware_class.c index 6e210802c37b..e85763de928f 100644 --- a/drivers/base/firmware_class.c +++ b/drivers/base/firmware_class.c @@ -21,18 +21,85 @@ #include <linux/firmware.h> #include <linux/slab.h> #include <linux/sched.h> +#include <linux/file.h> ...
b973b4c91be8f7de0531cf8ca2df41021d8f39b3
Analyze and fix the following issue in the Linux kernel code: xtensa: fix TIOCGSERIAL and TIOCSSERIAL definitions
Problem Details: Put equivalent constants into TIOCGSERIAL and TIOCSSERIAL definitions: size subfield of these IOCTL codes is not used and no other architecture uses _IO* macros here. The other way could be putting #include <linux/serial.h> into net/bluetooth/rfcomm/tty.c. Signed-off-by: Max Filippov <jcmvbkbc@gmail....
```diff diff --git a/arch/xtensa/include/asm/ioctls.h b/arch/xtensa/include/asm/ioctls.h index fd1d1369a407..2aa4cd9f0cec 100644 --- a/arch/xtensa/include/asm/ioctls.h +++ b/arch/xtensa/include/asm/ioctls.h @@ -71,8 +71,8 @@ #define TIOCSSOFTCAR _IOW('T', 26, unsigned int) #define TIOCLINUX _IOW('T', 28, char) #defi...
a753cd9abf389ce8fea79e7f30640926356778d3
Analyze and fix the following issue in the Linux kernel code: xtensa: fix CODA build
Problem Details: Signed-off-by: Max Filippov <jcmvbkbc@gmail.com> Signed-off-by: Chris Zankel <chris@zankel.net>
```diff diff --git a/arch/xtensa/Makefile b/arch/xtensa/Makefile index f973754ddf90..b201d4486098 100644 --- a/arch/xtensa/Makefile +++ b/arch/xtensa/Makefile @@ -31,7 +31,7 @@ PLATFORM = $(platform-y) export PLATFORM # temporarily until string.h is fixed -KBUILD_CFLAGS += -ffreestanding +KBUILD_CFLAGS += -ffreesta...
7c94fe4a012e6d0858b9a80cbc18b7ee788f572d
Analyze and fix the following issue in the Linux kernel code: xtensa: fix parallel make
Problem Details: Make vmlinux.tmp and vmlinux.tmp.gz separate build targets, avoid removing vmlinux.tmp during vmlinux.tmp.gz build. Signed-off-by: Max Filippov <jcmvbkbc@gmail.com> Signed-off-by: Chris Zankel <chris@zankel.net>
```diff diff --git a/arch/xtensa/boot/boot-elf/Makefile b/arch/xtensa/boot/boot-elf/Makefile index 08e8814f8c71..4bbc26f797f1 100644 --- a/arch/xtensa/boot/boot-elf/Makefile +++ b/arch/xtensa/boot/boot-elf/Makefile @@ -20,9 +20,11 @@ boot-y := bootstrap.o OBJS := $(addprefix $(obj)/,$(boot-y)) -Image: vmlinux $(...
02f3774877382bac52972a677c2c5fbd3532a1a1
Analyze and fix the following issue in the Linux kernel code: xtensa: fix ioremap
Problem Details: - fix ioremap_nocache to actually return non-cacheable address - add explicit ioremap_cache - fix KIO aperture checking arithmetic Signed-off-by: Max Filippov <jcmvbkbc@gmail.com> Signed-off-by: Chris Zankel <chris@zankel.net>
```diff diff --git a/arch/xtensa/include/asm/io.h b/arch/xtensa/include/asm/io.h index 4beb43c087d3..4f66dfc103a5 100644 --- a/arch/xtensa/include/asm/io.h +++ b/arch/xtensa/include/asm/io.h @@ -67,12 +67,12 @@ static inline void * phys_to_virt(unsigned long address) * Return the virtual (cached) address for the spec...
af42e970b6097a34cb2b93ec4c12c2a226b1d008
Analyze and fix the following issue in the Linux kernel code: modpost: fix modpost warnings for xtensa
Problem Details: Suppress warnings for two informational sections (.xt.lit and .xt.prop) used by the Xtensa architecture. Signed-off-by: Max Filippov <jcmvbkbc@gmail.com> Signed-off-by: Chris Zankel <chris@zankel.net>
```diff diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c index 68e9f5ed0a6f..00f7512a217f 100644 --- a/scripts/mod/modpost.c +++ b/scripts/mod/modpost.c @@ -827,6 +827,8 @@ static const char *section_white_list[] = ".note*", ".got*", ".toc*", + ".xt.prop", /* xtensa */ + ".xt.lit", /* xtensa...
717460ee3e8399eb66799cac0bb83217475b7027
Analyze and fix the following issue in the Linux kernel code: xtensa: ISS: fix __simc implementation
Problem Details: Do not rely on compiler implicitly placing function arguments into specifc registers, place them explicitly. Move __simc and related helpers to platform/simcall.h Signed-off-by: Max Filippov <jcmvbkbc@gmail.com> Signed-off-by: Chris Zankel <chris@zankel.net>
```diff diff --git a/arch/xtensa/platforms/iss/console.c b/arch/xtensa/platforms/iss/console.c index f9726f6afdf1..daee86cdf0cc 100644 --- a/arch/xtensa/platforms/iss/console.c +++ b/arch/xtensa/platforms/iss/console.c @@ -41,19 +41,6 @@ static struct timer_list serial_timer; static DEFINE_SPINLOCK(timer_lock); -i...
33c8213d6930cfa1d09e2912b9e2d59f251c33b7
Analyze and fix the following issue in the Linux kernel code: xtensa: fix xtensa_irq_unmask calls
Problem Details: xtensa_irq_disable/xtensa_irq_enable used to call xtensa_irq_unmask with wrong argument. Signed-off-by: Max Filippov <jcmvbkbc@gmail.com> Signed-off-by: Chris Zankel <chris@zankel.net>
```diff diff --git a/arch/xtensa/kernel/irq.c b/arch/xtensa/kernel/irq.c index 4340ee076bd5..98e77c3ef1c3 100644 --- a/arch/xtensa/kernel/irq.c +++ b/arch/xtensa/kernel/irq.c @@ -84,12 +84,12 @@ static void xtensa_irq_unmask(struct irq_data *d) static void xtensa_irq_enable(struct irq_data *d) { variant_irq_enable(...
2e6ee5ec88dd9d4d4e934709200259538160039d
Analyze and fix the following issue in the Linux kernel code: xtensa/PCI: fix WT caching attribute
Problem Details: Fix caching attributes setup providing correct _PAGE_CA_* names. Signed-off-by: Max Filippov <jcmvbkbc@gmail.com> Signed-off-by: Chris Zankel <chris@zankel.net>
```diff diff --git a/arch/xtensa/kernel/pci.c b/arch/xtensa/kernel/pci.c index 69759e9cb3ea..43e9fdce40d6 100644 --- a/arch/xtensa/kernel/pci.c +++ b/arch/xtensa/kernel/pci.c @@ -341,7 +341,7 @@ __pci_mmap_set_pgprot(struct pci_dev *dev, struct vm_area_struct *vma, int prot = pgprot_val(vma->vm_page_prot); /* Set...
f6a03a12ecdbe0dd80a55f6df3b7206c5a403a49
Analyze and fix the following issue in the Linux kernel code: xtensa: fix linker script transformation for .text.unlikely
Problem Details: Now that binutils generate *.unlikely sections which don't follow documented (info as) literal section naming rules, section name transformation script doesn't work well resulting in the following errors at vmlinux link time: main.c:(.text.unlikely+0x3): dangerous relocation: l32r: literal p...
```diff diff --git a/arch/xtensa/kernel/Makefile b/arch/xtensa/kernel/Makefile index 59fc3fe15572..0f9f35fc191a 100644 --- a/arch/xtensa/kernel/Makefile +++ b/arch/xtensa/kernel/Makefile @@ -24,6 +24,7 @@ obj-$(CONFIG_MODULES) += xtensa_ksyms.o module.o # Replicate rules in scripts/Makefile.build sed-y = -e 's/\*(\...
cf9fd75cbccde47c205c3d0202ad674d6bc00ee2
Analyze and fix the following issue in the Linux kernel code: RDMA/nes: Bump the version number of nes driver
Problem Details: Bumpthe version of the nes driver to reflect recent fixes. Signed-off-by: Tatyana Nikolova <Tatyana.E.Nikolova@intel.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
```diff diff --git a/drivers/infiniband/hw/nes/nes.h b/drivers/infiniband/hw/nes/nes.h index 454271b3b7be..5cac29e6bc1c 100644 --- a/drivers/infiniband/hw/nes/nes.h +++ b/drivers/infiniband/hw/nes/nes.h @@ -57,7 +57,7 @@ #define QUEUE_DISCONNECTS #define DRV_NAME "iw_nes" -#define DRV_VERSION "1.5.0.0" +#define ...
d5fb476a10a9de56fb518886619ae9a6bf7c7efd
Analyze and fix the following issue in the Linux kernel code: RDMA/nes: Add missing break to switch.
Problem Details: Static code analyzer cppcheck points out a missing break. Reported-by: David Binderman <dcb314@hotmail.com> Addresses: <https://bugzilla.kernel.org/show_bug.cgi?id=47671> Signed-off-by: Tatyana Nikolova <Tatyana.E.Nikolova@intel.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
```diff diff --git a/drivers/infiniband/hw/nes/nes_verbs.c b/drivers/infiniband/hw/nes/nes_verbs.c index 1dadcf388c02..9eb54b7794fb 100644 --- a/drivers/infiniband/hw/nes/nes_verbs.c +++ b/drivers/infiniband/hw/nes/nes_verbs.c @@ -3006,6 +3006,7 @@ int nes_modify_qp(struct ib_qp *ibqp, struct ib_qp_attr *attr, sw...
74b217d0d3a46132fb61adab91d53c57e0d8f68a
Analyze and fix the following issue in the Linux kernel code: ore: signedness bug in _sp2d_min_pg()
Problem Details: This for loop doesn't work correctly when "p" is unsigned. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
```diff diff --git a/fs/exofs/ore_raid.c b/fs/exofs/ore_raid.c index 5f376d14fdcc..b963f38ac298 100644 --- a/fs/exofs/ore_raid.c +++ b/fs/exofs/ore_raid.c @@ -203,7 +203,7 @@ static unsigned _sp2d_min_pg(struct __stripe_pages_2d *sp2d) static unsigned _sp2d_max_pg(struct __stripe_pages_2d *sp2d) { - unsigned p; + i...
065f8b9210b46c49b578d188ce8b8ee240a55777
Analyze and fix the following issue in the Linux kernel code: bnx2x: fix ring size for 10G functions
Problem Details: Commit d760fc37b0f74502b3f748951f22c6683b079a8e caused 1G functions to allocate rx rings which were 1/10 of the size of 10G functions' rx rings. However, it also caused 10G functions on 5771x boards to allocate small rings, which limits their possible (default) rx throughput. This patch causes all 10G...
```diff diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c index 30f04a389227..24220992413f 100644 --- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c +++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c @@ -3523,15 +3523,18 @@ static int bnx2x_alloc_fp_mem...
702e490211b2b7e448ebe1b3a07d97ad2fc07e03
Analyze and fix the following issue in the Linux kernel code: userns: Fix build of drivers/staging/dgrp
Problem Details: Explicitly test for GLOBAL_ROOT_UID and GLOBAL_ROOT_GID instead of using 0, allowing dgrp to compile and work properly when user namespace support is enabled. Cc: Bill Pemberton <wfp5p@virginia.edu> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: "Eric W. Biederman" <ebiederm@xmissi...
```diff diff --git a/drivers/staging/dgrp/dgrp_common.c b/drivers/staging/dgrp/dgrp_common.c index fce74e7fb834..3553998b72bc 100644 --- a/drivers/staging/dgrp/dgrp_common.c +++ b/drivers/staging/dgrp/dgrp_common.c @@ -179,9 +179,9 @@ void dgrp_carrier(struct ch_struct *ch) */ int dgrp_chk_perm(int mode, int op) { ...
6285bc231277419255f3498d3eb5ddc9f8e7fe79
Analyze and fix the following issue in the Linux kernel code: ceph: avoid 32-bit page index overflow
Problem Details: A pgoff_t is defined (by default) to have type (unsigned long). On architectures such as i686 that's a 32-bit type. The ceph address space code was attempting to produce 64 bit offsets by shifting a page's index by PAGE_CACHE_SHIFT, but the result was not what was desired because the shift occurred b...
```diff diff --git a/fs/ceph/addr.c b/fs/ceph/addr.c index 4469b63c9b7b..22b6e4583faa 100644 --- a/fs/ceph/addr.c +++ b/fs/ceph/addr.c @@ -205,7 +205,7 @@ static int readpage_nounlock(struct file *filp, struct page *page) dout("readpage inode %p file %p page %p index %lu\n", inode, filp, page, page->index); ...
4a97df0bfaa8c0c1cd057cb8f1030a71cb4d8832
Analyze and fix the following issue in the Linux kernel code: ixgbe: fix poll loop for FDIRCTRL.INIT_DONE bit
Problem Details: The loop in ixgbe_reinit_fdir_tables_82599() only polls for up to 100us resulting in failures to update the FDIR filter table at 1Gbps and 10Gbps when under load. The poll times for FDIRCTRL.INIT_DONE are 55us, 550us and 5.5ms for 10Gbps, 1Gbps and 100Mbps respectively. This patch sets the wait time ...
```diff diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c index 18bf08c9d7a4..1077cb2b38db 100644 --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c @@ -1099,7 +1099,7 @@ s32 ixgbe_reinit_fdir_tables_82599(...
1cc92eb871d6cbb1da038b4bcd89eec3c73b9781
Analyze and fix the following issue in the Linux kernel code: ixgbe: fix PTP ethtool timestamping function
Problem Details: This patch fixes a development issue that occurred due to invalid modes reported in the ethtool get_ts_info function. The issue is resolved by removing unsupported modes from the Rx supported list. CC: stable <stable@vger.kernel.org> [3.5] Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-...
```diff diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c index 4104ea25d818..56b20d17d0e4 100644 --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c @@ -2690,10 +2690,7 @@ static int ixgbe_get_ts_in...
db0677fa29862d29e9956980d9fab43c52179e34
Analyze and fix the following issue in the Linux kernel code: ixgbe: (PTP) Fix PPS interrupt code
Problem Details: Driver was enabling PPS interrupt even when user wasn't enabling it via the ptp core. This patch fixes the PPS so that it is only enabled explicitly, and moves the interrupt enabling code into the correct location in the driver Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Cc: Stable <stable@...
```diff diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c index 868af6938219..c407b2f0f0f9 100644 --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c @@ -2322,6 +2322,12 @@ static inline void ixgbe_irq_enable(st...
8208367371b7f581dd13fe8bf28f8d7f17f4bf32
Analyze and fix the following issue in the Linux kernel code: ixgbe: Fix PTP X540 SDP alignment code for PPS signal
Problem Details: This patch fixes a bug in the method used for calculating the trigger alignment for SDP0 when enabling a PPS output on the X540. The alignment math wasn't properly taking into account the overflow cyclecounter, and was misaligning the pin triggers so that two X540 devices synced properly had mis-aligne...
```diff diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_ptp.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_ptp.c index 39881cb17a4b..58d930dc6766 100644 --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_ptp.c +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_ptp.c @@ -105,6 +105,94 @@ static struct sock_filter ptp_filter[] = { ...
387a8cbdf84d5c417d24eabfdf9fe4e0b94458da
Analyze and fix the following issue in the Linux kernel code: mmc: sdhci-s3c: Fix crash on module insertion for second time
Problem Details: If sdhci-s3c driver is built as module, it gives following error if inserted again after removing. This was happening as pm_runtime_use_autosuspend() is called in sdhci_s3c_probe() function but in sdhci_s3c_remove() its complementary pm_runtime_dont_use_autosuspend() is not called. BUG: spinlock bad m...
```diff diff --git a/drivers/mmc/host/sdhci-s3c.c b/drivers/mmc/host/sdhci-s3c.c index 4d9acf833590..f64108f2664a 100644 --- a/drivers/mmc/host/sdhci-s3c.c +++ b/drivers/mmc/host/sdhci-s3c.c @@ -788,6 +788,7 @@ static int __devexit sdhci_s3c_remove(struct platform_device *pdev) sdhci_remove_host(host, 1); + pm_ru...
f6ad0a481342223b2e7ae9f55b154e14f1391ada
Analyze and fix the following issue in the Linux kernel code: mmc: mxcmmc: fix bug that may block a data transfer forever
Problem Details: The problem can be easily reproduced using a script that loops copying a file in an SD card to another place in the same SD card and its related to read transfers. This only happens with DMA enabled. This is related to the fact that, when reading, an MMC irq signals the fact that all data from the SD ...
```diff diff --git a/drivers/mmc/host/mxcmmc.c b/drivers/mmc/host/mxcmmc.c index 28ed52d58f7f..fc42a2e088ee 100644 --- a/drivers/mmc/host/mxcmmc.c +++ b/drivers/mmc/host/mxcmmc.c @@ -44,6 +44,7 @@ #include <mach/hardware.h> #define DRIVER_NAME "mxc-mmc" +#define MXCMCI_TIMEOUT_MS 10000 #define MMC_REG_STR_STP_CL...
4a90920c6b39a3af26470cfc26b8e5ec9c4e7f3c
Analyze and fix the following issue in the Linux kernel code: mmc: dw_mmc: convert copy of struct device in struct dw_mci to a reference
Problem Details: The 'struct dw_mci' maintains a copy of the pdev->dev instance instead of maintaining a reference to that 'struct device' instance. Any resource allocated using the device resource management kernel API with the instance of 'struct device' in 'struct dw_mci' is then incorrect. Fix this by converting th...
```diff diff --git a/drivers/mmc/host/dw_mmc-pci.c b/drivers/mmc/host/dw_mmc-pci.c index f5ab03d32fb9..edb37e9135ae 100644 --- a/drivers/mmc/host/dw_mmc-pci.c +++ b/drivers/mmc/host/dw_mmc-pci.c @@ -59,7 +59,7 @@ static int __devinit dw_mci_pci_probe(struct pci_dev *pdev, host->irq = pdev->irq; host->irq_flags = ...
b1e0d8b70fa31821ebca3965f2ef8619d7c5e316
Analyze and fix the following issue in the Linux kernel code: kbuild: Fix gcc -x syntax
Problem Details: The correct syntax for gcc -x is "gcc -x assembler", not "gcc -xassembler". Even though the latter happens to work, the former is what is documented in the manual page and thus what gcc wrappers such as icecream do expect. This isn't a cosmetic change. The missing space prevents icecream from recogniz...
```diff diff --git a/arch/mips/Makefile b/arch/mips/Makefile index 764e37a9dbb3..654b1ad39f05 100644 --- a/arch/mips/Makefile +++ b/arch/mips/Makefile @@ -225,7 +225,7 @@ KBUILD_CPPFLAGS += -DDATAOFFSET=$(if $(dataoffset-y),$(dataoffset-y),0) LDFLAGS += -m $(ld-emul) ifdef CONFIG_MIPS -CHECKFLAGS += $(shell $(CC)...
608da7e3fc7259eca0d983b31bc8915af14cf15e
Analyze and fix the following issue in the Linux kernel code: slab: Fix build failure in __kmem_cache_create()
Problem Details: Fix build failure with CONFIG_DEBUG_SLAB=y && CONFIG_DEBUG_PAGEALLOC=y caused by commit 8a13a4cc "mm/sl[aou]b: Shrink __kmem_cache_create() parameter lists". mm/slab.c: In function '__kmem_cache_create': mm/slab.c:2474: error: 'align' undeclared (first use in this function) mm/slab.c:2474: error: (Eac...
```diff diff --git a/mm/slab.c b/mm/slab.c index d011030e9613..c4f6e14c2c71 100644 --- a/mm/slab.c +++ b/mm/slab.c @@ -2492,8 +2492,9 @@ __kmem_cache_create (const char *name, size_t size, size_t align, } #if FORCED_DEBUG && defined(CONFIG_DEBUG_PAGEALLOC) if (size >= malloc_sizes[INDEX_L3 + 1].cs_size - && ca...
71d9c5f9e60846fa40c9efadda122d9cf275c1d2
Analyze and fix the following issue in the Linux kernel code: IPoIB: Fix build with CONFIG_INFINIBAND_IPOIB_CM=n
Problem Details: With the new netlink support in commit 862096a8bbf8 ("IB/ipoib: Add more rtnl_link_ops callbacks") we need ipoib_set_mode() to be available even if connected mode isn't built. Move the function from ipoib_cm.c to ipoib_main.c (and make a few CM-related macros available unconditonally). This fixes the...
```diff diff --git a/drivers/infiniband/ulp/ipoib/ipoib.h b/drivers/infiniband/ulp/ipoib/ipoib.h index 196eb52f0035..07ca6fd5546b 100644 --- a/drivers/infiniband/ulp/ipoib/ipoib.h +++ b/drivers/infiniband/ulp/ipoib/ipoib.h @@ -535,14 +535,14 @@ void ipoib_drain_cq(struct net_device *dev); void ipoib_set_ethtool_ops(st...
864499449f256e32815575a9b860267ebefa6d70
Analyze and fix the following issue in the Linux kernel code: tg3: Fix sparse warnings.
Problem Details: drivers/net/ethernet/broadcom/tg3.c:8121:8: warning: symbol 'i' shadows an earlier one drivers/net/ethernet/broadcom/tg3.c:8003:6: originally declared here drivers/net/ethernet/broadcom/tg3.c:785:5: warning: symbol 'tg3_ape_scratchpad_read' was not declared. Should it be static? drivers/net/ethernet/br...
```diff diff --git a/drivers/net/ethernet/broadcom/tg3.c b/drivers/net/ethernet/broadcom/tg3.c index 46280ba4c5d4..a8800ac10df9 100644 --- a/drivers/net/ethernet/broadcom/tg3.c +++ b/drivers/net/ethernet/broadcom/tg3.c @@ -782,7 +782,8 @@ static int tg3_ape_wait_for_event(struct tg3 *tp, u32 timeout_us) return i == t...
5da444aae54f64575a60f1d596ed7706e3089fb0
Analyze and fix the following issue in the Linux kernel code: sparc: fix format string argument for prom_printf()
Problem Details: prom_printf() takes printf style arguments. Specifing GCC's format attribute reveals that there are several wrong usages of prom_printf(). This fixes those wrong format strings and arguments, and also leaves format attributes in order to detect similar mistakes at compile time. Signed-off-by: Akinob...
```diff diff --git a/arch/sparc/include/asm/oplib_32.h b/arch/sparc/include/asm/oplib_32.h index 27517879a6c2..c72f3045820c 100644 --- a/arch/sparc/include/asm/oplib_32.h +++ b/arch/sparc/include/asm/oplib_32.h @@ -94,7 +94,7 @@ extern int prom_getprev(void); extern void prom_console_write_buf(const char *buf, int len...
b9f10852fcb1f09369d931dcbfbaad89ad1da4ad
Analyze and fix the following issue in the Linux kernel code: drm/nv98/crypt: fix fuc build with latest envyas
Problem Details: Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
```diff diff --git a/drivers/gpu/drm/nouveau/core/engine/crypt/fuc/nv98.fuc b/drivers/gpu/drm/nouveau/core/engine/crypt/fuc/nv98.fuc index 7393813044de..629da02dc352 100644 --- a/drivers/gpu/drm/nouveau/core/engine/crypt/fuc/nv98.fuc +++ b/drivers/gpu/drm/nouveau/core/engine/crypt/fuc/nv98.fuc @@ -238,7 +238,7 @@ ih: ...
002d0c735c1bd8bffd3786ad5aadb205a76878fa
Analyze and fix the following issue in the Linux kernel code: drm/nv41/vm: fix and enable use of "real" pciegart
Problem Details: Hopefully fixed the tlb flush timeout issue. Was able to observe this condition occur occasionally, and it appears the binary driver doesn't wait on the old condition either.. Should give 39-bit DMA addressing on the relevant chipsets. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
```diff diff --git a/drivers/gpu/drm/nouveau/core/subdev/device/nv40.c b/drivers/gpu/drm/nouveau/core/subdev/device/nv40.c index 18de4c5b202f..42deadca0f0a 100644 --- a/drivers/gpu/drm/nouveau/core/subdev/device/nv40.c +++ b/drivers/gpu/drm/nouveau/core/subdev/device/nv40.c @@ -78,7 +78,7 @@ nv40_identify(struct nouvea...
e5f186c4f9812eccbc291da6dfe8b15da546f961
Analyze and fix the following issue in the Linux kernel code: drm/nv44/vm: fix and enable use of "real" pciegart
Problem Details: Something seems to be missing in regards to flushing specific ranges of the TLB. For the moment, flushing the entire thing seems to make it work alright. Should give 39-bit DMA addressing on the relevant chipsets. v2: allocate contig 16KiB for dummy pages, reported by mwk on irc Signed-off-by: Ben ...
```diff diff --git a/drivers/gpu/drm/nouveau/core/subdev/device/nv40.c b/drivers/gpu/drm/nouveau/core/subdev/device/nv40.c index 320ccc4ae05c..18de4c5b202f 100644 --- a/drivers/gpu/drm/nouveau/core/subdev/device/nv40.c +++ b/drivers/gpu/drm/nouveau/core/subdev/device/nv40.c @@ -218,7 +218,7 @@ nv40_identify(struct nouv...
7d70e9c1c69a5d22588ff5977249ac944d7cdfb0
Analyze and fix the following issue in the Linux kernel code: drm/nouveau/therm: rework thermal table parsing
Problem Details: As an accident, it should also fix temperature reading on nv4x. v2: introduce nvbios_therm_entry as advised by darktama Signed-off-by: Martin Peres <martin.peres@labri.fr> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
```diff diff --git a/drivers/gpu/drm/nouveau/Makefile b/drivers/gpu/drm/nouveau/Makefile index 1c506c5a9a48..b6a6fa7fbcd4 100644 --- a/drivers/gpu/drm/nouveau/Makefile +++ b/drivers/gpu/drm/nouveau/Makefile @@ -35,6 +35,7 @@ nouveau-y += core/subdev/bios/i2c.o nouveau-y += core/subdev/bios/init.o nouveau-y += core/su...
d89c8ce07168ef6cd16c71d0a9f618829e866e87
Analyze and fix the following issue in the Linux kernel code: drm/nouveau: fix pm initialization order
Problem Details: If nouveau_pm_perflvl_get() fails, pm->profiles list will be left uninitialized, which causes oops during nouveau_pm_fini(). Move INIT_LIST_HEAD before call to nouveau_pm_perflvl_get(). Signed-off-by: Dmitry Eremin-Solenikov <dmitry_eremin@mentor.com> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
```diff diff --git a/drivers/gpu/drm/nouveau/nouveau_pm.c b/drivers/gpu/drm/nouveau/nouveau_pm.c index 3c55ec2366d3..d2f2de67f688 100644 --- a/drivers/gpu/drm/nouveau/nouveau_pm.c +++ b/drivers/gpu/drm/nouveau/nouveau_pm.c @@ -916,6 +916,8 @@ nouveau_pm_init(struct drm_device *dev) nouveau_volt_init(dev); nouveau_t...
da07e52cf10c9584c7e197ac3d49455e1a4d4756
Analyze and fix the following issue in the Linux kernel code: drm/nouveau: log channel debug/error messages from client object rather than drm client
Problem Details: This will make it more obvious which application caused particular messages. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
```diff diff --git a/drivers/gpu/drm/nouveau/nouveau_chan.c b/drivers/gpu/drm/nouveau/nouveau_chan.c index 3b3791453178..c1d7301c0e9c 100644 --- a/drivers/gpu/drm/nouveau/nouveau_chan.c +++ b/drivers/gpu/drm/nouveau/nouveau_chan.c @@ -47,7 +47,7 @@ module_param_named(vram_pushbuf, nouveau_vram_pushbuf, int, 0400); int...
49981046e3dc2f934663548a270d4bf1a4534bb9
Analyze and fix the following issue in the Linux kernel code: drm/nve0: use async copy engine for ttm buffer moves if available
Problem Details: Kepler PFIFO lost the ability to address multiple engines from a single channel, so we need a separate one for the copy engine. v2: Marcin Slusarz <marcin.slusarz@gmail.com> - regression fix: restore hw accelerated buffer copies Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
```diff diff --git a/drivers/gpu/drm/nouveau/nouveau_abi16.c b/drivers/gpu/drm/nouveau/nouveau_abi16.c index 9e6ced3b941a..cc79c796afee 100644 --- a/drivers/gpu/drm/nouveau/nouveau_abi16.c +++ b/drivers/gpu/drm/nouveau/nouveau_abi16.c @@ -264,6 +264,11 @@ nouveau_abi16_ioctl_channel_alloc(ABI16_IOCTL_ARGS) abi16->han...
5999933f4de7de7bcaae4be87667b0cff57d6e45
Analyze and fix the following issue in the Linux kernel code: drm/nouveau: add Kconfig options for debug control
Problem Details: Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
```diff diff --git a/drivers/gpu/drm/nouveau/Kconfig b/drivers/gpu/drm/nouveau/Kconfig index 97a81260485a..8a55beeb8bdc 100644 --- a/drivers/gpu/drm/nouveau/Kconfig +++ b/drivers/gpu/drm/nouveau/Kconfig @@ -17,6 +17,34 @@ config DRM_NOUVEAU help Choose this option for open-source nVidia support. +config NOUVEAU...
70c0f263cc2eb12e02506eb75f0a71490e7dea4d
Analyze and fix the following issue in the Linux kernel code: drm/nouveau/bios: pull in basic vbios subdev, more to come later
Problem Details: v2: Ben Skeggs <bskeggs@redhat.com> - use unaligned macros to access vbios image - endianness fixes Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
```diff diff --git a/drivers/gpu/drm/nouveau/Makefile b/drivers/gpu/drm/nouveau/Makefile index f6927ae8ebed..d10ec93c5ad8 100644 --- a/drivers/gpu/drm/nouveau/Makefile +++ b/drivers/gpu/drm/nouveau/Makefile @@ -18,6 +18,8 @@ nouveau-y += core/core/printk.o nouveau-y += core/core/ramht.o nouveau-y += core/core/subdev....
d6ba6d215a538a58f0f0026f0961b0b9125e8042
Analyze and fix the following issue in the Linux kernel code: drm/nvc0/fence: restore pre-suspend fence buffer context on resume
Problem Details: Fixes some unfortunate races on resume. The G84 version of the code doesn't need this as "gpuobj"s are automagically suspended/resumed by the core code whereas pinned buffer objects are not. Cc: stable@vger.kernel.org Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
```diff diff --git a/drivers/gpu/drm/nouveau/nvc0_fence.c b/drivers/gpu/drm/nouveau/nvc0_fence.c index 47ab388a606e..8e5a2f407ed4 100644 --- a/drivers/gpu/drm/nouveau/nvc0_fence.c +++ b/drivers/gpu/drm/nouveau/nvc0_fence.c @@ -32,6 +32,7 @@ struct nvc0_fence_priv { struct nouveau_fence_priv base; struct nouveau_bo...
5316cf9a5197eb80b2800e1acadde287924ca975
Analyze and fix the following issue in the Linux kernel code: 8021q: fix mac_len recomputation in vlan_untag()
Problem Details: skb_reset_mac_len() relies on the value of the skb->network_header pointer, therefore we must wait for such pointer to be recalculated before computing the new mac_len value. Signed-off-by: Antonio Quartulli <ordex@autistici.org> Signed-off-by: David S. Miller <davem@davemloft.net>
```diff diff --git a/net/8021q/vlan_core.c b/net/8021q/vlan_core.c index b258da88f675..add69d0fd99d 100644 --- a/net/8021q/vlan_core.c +++ b/net/8021q/vlan_core.c @@ -105,7 +105,6 @@ static struct sk_buff *vlan_reorder_header(struct sk_buff *skb) return NULL; memmove(skb->data - ETH_HLEN, skb->data - VLAN_ETH_HLEN...
62b54dd91567686a1cb118f76a72d5f4764a86dd
Analyze and fix the following issue in the Linux kernel code: ipv6: don't add link local route when there is no link local address
Problem Details: When an address is added on loopback (ip -6 a a 2002::1/128 dev lo), a route to fe80::/64 is added in the main table: unreachable fe80::/64 dev lo proto kernel metric 256 error -101 This route does not match any prefix (no fe80:: address on lo). In fact, addrconf_dev_config() will not add link lo...
```diff diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c index 480e68422efb..d7c56f8a5b4e 100644 --- a/net/ipv6/addrconf.c +++ b/net/ipv6/addrconf.c @@ -1769,14 +1769,6 @@ static void sit_route_add(struct net_device *dev) } #endif -static void addrconf_add_lroute(struct net_device *dev) -{ - struct in6_addr a...
da1586461e53a4dd045738cce309ab488970f0ef
Analyze and fix the following issue in the Linux kernel code: pch_gbe: Fix PTP dependencies.
Problem Details: The config combination: CONFIG_PCH_GBE=y CONFIG_PCH_PTP=y CONFIG_PTP_1588_CLOCK=m doesn't work, because then you have a built-in kernel object (the PCH_PTP code) referring to symbols in a module (PTP_1588_CLOCK). Fix this like IXGBE, by using "select PTP_1588_CLOCK" instead o...
```diff diff --git a/drivers/net/ethernet/oki-semi/pch_gbe/Kconfig b/drivers/net/ethernet/oki-semi/pch_gbe/Kconfig index bce01641ee6b..97302419a377 100644 --- a/drivers/net/ethernet/oki-semi/pch_gbe/Kconfig +++ b/drivers/net/ethernet/oki-semi/pch_gbe/Kconfig @@ -26,7 +26,7 @@ if PCH_GBE config PCH_PTP bool "PCH PTP ...
df86b5765a48d5f557489577652bd6df145b0e1b
Analyze and fix the following issue in the Linux kernel code: drm/savage: re-add busmaster enable, regression fix
Problem Details: 466e69b8b03b8c1987367912782bc12988ad8794 dropped busmaster enable from the global drm code and moved it to the individual drivers, but missed the savage driver. So, this re-adds busmaster enable to the savage driver, fixing the regression. Signed-off-by: Florian Zumbiehl <florz@florz.de> Reviewed-by: ...
```diff diff --git a/drivers/gpu/drm/savage/savage_bci.c b/drivers/gpu/drm/savage/savage_bci.c index 1efbb9075837..c89aef420971 100644 --- a/drivers/gpu/drm/savage/savage_bci.c +++ b/drivers/gpu/drm/savage/savage_bci.c @@ -547,6 +547,8 @@ int savage_driver_load(struct drm_device *dev, unsigned long chipset) dev_pri...
25a1a6211dd2fcbf0e45a07030703e2a42d7aa87
Analyze and fix the following issue in the Linux kernel code: NFSv4.1: Deal with wraparound when updating the layout "barrier" seqid
Problem Details: ...and fix a bug in pnfs_set_layout_stateid. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
```diff diff --git a/fs/nfs/pnfs.c b/fs/nfs/pnfs.c index f1387e87513f..de827251bdac 100644 --- a/fs/nfs/pnfs.c +++ b/fs/nfs/pnfs.c @@ -572,7 +572,7 @@ pnfs_set_layout_stateid(struct pnfs_layout_hdr *lo, const nfs4_stateid *new, if (update_barrier) { u32 new_barrier = be32_to_cpu(new->seqid); - if ((int)(new_...
251ec410c495cb93c7ae2cb4beda29205d9bd35f
Analyze and fix the following issue in the Linux kernel code: NFSv4.1: Fix another refcount issue in pnfs_find_alloc_layout
Problem Details: Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
```diff diff --git a/fs/nfs/pnfs.c b/fs/nfs/pnfs.c index d737557747b9..fe9968a62cad 100644 --- a/fs/nfs/pnfs.c +++ b/fs/nfs/pnfs.c @@ -907,18 +907,19 @@ pnfs_find_alloc_layout(struct inode *ino, dprintk("%s Begin ino=%p layout=%p\n", __func__, ino, nfsi->layout); - if (nfsi->layout) { - pnfs_get_layout_hdr(nfsi-...
ae2bb03236fc978bdf673c19d39832500793b83c
Analyze and fix the following issue in the Linux kernel code: NFSv4: don't put ACCESS in OPEN compound if O_EXCL
Problem Details: Don't put an ACCESS op in OPEN compound if O_EXCL, because ACCESS will return permission denied for all bits until close. Fixes a regression due to commit 6168f62c (NFSv4: Add ACCESS operation to OPEN compound) Signed-off-by: Weston Andros Adamson <dros@netapp.com> Signed-off-by: Trond Myklebust <Tro...
```diff diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index ccada6856f0d..21cfac7c2ff8 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c @@ -862,9 +862,15 @@ static struct nfs4_opendata *nfs4_opendata_alloc(struct dentry *dentry, p->o_arg.fh = NFS_FH(dir); p->o_arg.open_flags = flags; p->o_arg.fmode = f...
bbd3a8eee82a2a6f4aa1cce60ccb014f25e5c560
Analyze and fix the following issue in the Linux kernel code: NFSv4: don't check MAY_WRITE access bit in OPEN
Problem Details: Don't check MAY_WRITE as a newly created file may not have write mode bits, but POSIX allows the creating process to write regardless. This is ok because NFSv4 OPEN ops handle write permissions correctly - the ACCESS in the OPEN compound is to differentiate READ v EXEC permissions. Fixes a regression ...
```diff diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index 1e0faf9fa078..ccada6856f0d 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c @@ -1661,10 +1661,10 @@ static int nfs4_opendata_access(struct rpc_cred *cred, return 0; mask = 0; + /* don't check MAY_WRITE - a newly created file may not have + *...
ce3810cdb4ca31238c87e095d2c494a5eaa4f65d
Analyze and fix the following issue in the Linux kernel code: ARM: OMAP: SmartReflex: fix error path in init function
Problem Details: Fix the error handling path in omap_sr_probe to correctly de-allocate resources in case of problems. Signed-off-by: Jean Pihet <j-pihet@ti.com> Signed-off-by: Kevin Hilman <khilman@ti.com>
```diff diff --git a/drivers/power/avs/smartreflex.c b/drivers/power/avs/smartreflex.c index 44efc6e202af..92f67283c965 100644 --- a/drivers/power/avs/smartreflex.c +++ b/drivers/power/avs/smartreflex.c @@ -928,7 +928,7 @@ static int __init omap_sr_probe(struct platform_device *pdev) if (!sr_info->base) { dev_err(...
904753da183566c71211d23c169a80184648c121
Analyze and fix the following issue in the Linux kernel code: iscsit: remove incorrect unlock in iscsit_build_sendtargets_resp
Problem Details: Fix a potential multiple spin-unlock -> deadlock scenario during the overflow check within iscsit_build_sendtargets_resp() as found by sparse static checking. Signed-off-by: Christoph Hellwig <hch@lst.de> Cc: stable@vger.kernel.org Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
```diff diff --git a/drivers/target/iscsi/iscsi_target.c b/drivers/target/iscsi/iscsi_target.c index cca6d1384a1f..29f3b2414596 100644 --- a/drivers/target/iscsi/iscsi_target.c +++ b/drivers/target/iscsi/iscsi_target.c @@ -3274,7 +3274,6 @@ static int iscsit_build_sendtargets_response(struct iscsi_cmd *cmd) len += 1...
4e34d9588b46f44a4dba718606913133f15e4b21
Analyze and fix the following issue in the Linux kernel code: perf tools: Convert to BACKTRACE_SUPPORT
Problem Details: For building perf without stack backtrace debug, we can set NO_BACKTRACE=1 as a argument of make. It then defines NO_BACKTRACE macro for C code to do the proper handling. However it usually used in a negative semantics - e.g. #ifndef - so we saw double negations which can be misleading. Convert it t...
```diff diff --git a/tools/perf/Makefile b/tools/perf/Makefile index 5216ade909d0..f9126f89efef 100644 --- a/tools/perf/Makefile +++ b/tools/perf/Makefile @@ -45,6 +45,8 @@ include config/utilities.mak # # Define NO_LIBUNWIND if you do not want libunwind dependency for dwarf # backtrace post unwind. +# +# Define NO_...
93b44bea0c17130e62d8b1b82c0e2a0d671230d1
Analyze and fix the following issue in the Linux kernel code: ARM: OMAP2+: PM: fix return value check in omap2_set_init_voltage()
Problem Details: In case of error, the function voltdm_lookup() returns NULL not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test. dpatch engine is used to auto generate this patch. (https://github.com/weiyj/dpatch) Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Ack...
```diff diff --git a/arch/arm/mach-omap2/pm.c b/arch/arm/mach-omap2/pm.c index 9cb5cede0f50..ab15e5c1bba5 100644 --- a/arch/arm/mach-omap2/pm.c +++ b/arch/arm/mach-omap2/pm.c @@ -176,7 +176,7 @@ static int __init omap2_set_init_voltage(char *vdd_name, char *clk_name, } voltdm = voltdm_lookup(vdd_name); - if (IS_E...
07684c1b582ddd991c908f3de26e823b977d0a75
Analyze and fix the following issue in the Linux kernel code: ARM: OMAP2+: SmartReflex: fix return value check in sr_dev_init()
Problem Details: In case of error, the function voltdm_lookup() returns NULL not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test. dpatch engine is used to auto generate this patch. (https://github.com/weiyj/dpatch) Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Ack...
```diff diff --git a/arch/arm/mach-omap2/sr_device.c b/arch/arm/mach-omap2/sr_device.c index d033a65f4e4e..c248b309415b 100644 --- a/arch/arm/mach-omap2/sr_device.c +++ b/arch/arm/mach-omap2/sr_device.c @@ -123,7 +123,7 @@ static int __init sr_dev_init(struct omap_hwmod *oh, void *user) sr_data->senp_mod = 0x1; s...
a87e662827bca4b10a320e62da3fb21826eab987
Analyze and fix the following issue in the Linux kernel code: ARM: OMAP: omap_device: fix return value check in omap_device_build_ss()
Problem Details: In case of error, the function omap_device_alloc() returns ERR_PTR() and never returns NULL pointer. The NULL test in the return value check should be replaced with IS_ERR(). dpatch engine is used to auto generated this patch. (https://github.com/weiyj/dpatch) Signed-off-by: Wei Yongjun <yongjun_wei@...
```diff diff --git a/arch/arm/plat-omap/omap_device.c b/arch/arm/plat-omap/omap_device.c index c490240bb82c..3f62de67fa4a 100644 --- a/arch/arm/plat-omap/omap_device.c +++ b/arch/arm/plat-omap/omap_device.c @@ -671,7 +671,7 @@ struct platform_device __init *omap_device_build_ss(const char *pdev_name, int p dev_set_n...
104c7949e20e84dedddb66c1fc4b599931382d21
Analyze and fix the following issue in the Linux kernel code: ARM: OMAP: fix return value check in beagle_opp_init()
Problem Details: In case of error, the function omap_device_get_by_hwmod_name() returns ERR_PTR() not NULL pointer. The NULL test in the return value check should be replaced with IS_ERR(). dpatch engine is used to auto generated this patch. (https://github.com/weiyj/dpatch) Signed-off-by: Wei Yongjun <yongjun_wei@tr...
```diff diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c index 6202fc76e490..a548d7058c91 100644 --- a/arch/arm/mach-omap2/board-omap3beagle.c +++ b/arch/arm/mach-omap2/board-omap3beagle.c @@ -466,7 +466,7 @@ static void __init beagle_opp_init(void) mpu_dev = omap_device...
d7ca663c775bd1aafb718bdd6c208b49a9d53f50
Analyze and fix the following issue in the Linux kernel code: target/iscsi: precedence bug in iscsit_set_dataout_sequence_values()
Problem Details: Clang warns about this bug: drivers/target/iscsi/iscsi_target_erl0.c:52:45: warning: operator '?:' has lower precedence than '+'; '+' will be evaluated first [-Wparentheses] Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
```diff diff --git a/drivers/target/iscsi/iscsi_target_erl0.c b/drivers/target/iscsi/iscsi_target_erl0.c index 1a02016ecdab..2067efd2b7f7 100644 --- a/drivers/target/iscsi/iscsi_target_erl0.c +++ b/drivers/target/iscsi/iscsi_target_erl0.c @@ -48,9 +48,9 @@ void iscsit_set_dataout_sequence_values( if (cmd->unsolicited...
2425bb3d4016ed95ce83a90b53bd92c7f31091e4
Analyze and fix the following issue in the Linux kernel code: em28xx: regression fix: use DRX-K sync firmware requests on em28xx
Problem Details: As em28xx-dvb will always be initialized asynchronously, there's no need anymore for a separate thread to load the DRX-K firmware. Fixes a known regression with kernel 3.6 with tda18271 driver and asynchronous DRX-K firmware load. Antti tested it with the following hardware: Hauppauge WinTV H...
```diff diff --git a/drivers/media/usb/em28xx/em28xx-dvb.c b/drivers/media/usb/em28xx/em28xx-dvb.c index 1662b70435b3..913e5227897a 100644 --- a/drivers/media/usb/em28xx/em28xx-dvb.c +++ b/drivers/media/usb/em28xx/em28xx-dvb.c @@ -318,6 +318,7 @@ static struct drxk_config terratec_h5_drxk = { .no_i2c_bridge = 1, .m...
ddfc4e171292d63d7e3f8c95ff9c3ef9932870ce
Analyze and fix the following issue in the Linux kernel code: NFS: Set key construction data for the legacy upcall
Problem Details: This prevents a null pointer dereference when nfs_idmap_complete_pipe_upcall_locked() calls complete_request_key(). Fixes a regression caused by commit 0cac12023 (NFSv4: Ensure that idmap_pipe_downcall sanity-checks the downcall data). Signed-off-by: Bryan Schumaker <bjschuma@netapp.com> Signed-off-b...
```diff diff --git a/fs/nfs/idmap.c b/fs/nfs/idmap.c index 675b389cba5b..9cc4a3fbf4b0 100644 --- a/fs/nfs/idmap.c +++ b/fs/nfs/idmap.c @@ -707,6 +707,7 @@ static int nfs_idmap_legacy_upcall(struct key_construction *cons, msg = &data->pipe_msg; im = &data->idmap_msg; data->idmap = idmap; + data->key_cons = cons; ...
99e3fcfa34e7ea6dbb44fe5df51b79ccb6f73d3d
Analyze and fix the following issue in the Linux kernel code: hyperv: Fix page buffer handling in rndis_filter_send_request()
Problem Details: To prevent possible data corruption in RNDIS requests, add another page buffer if the request message crossed page boundary. Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com> Reviewed-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: David S. Miller <davem@davemloft.net>
```diff diff --git a/drivers/net/hyperv/rndis_filter.c b/drivers/net/hyperv/rndis_filter.c index 617eb2e4b06e..f25f41e1fdb7 100644 --- a/drivers/net/hyperv/rndis_filter.c +++ b/drivers/net/hyperv/rndis_filter.c @@ -45,7 +45,8 @@ struct rndis_request { /* Simplify allocation by having a netvsc packet inline */ str...
ea4963745f712a746ccb45871a22e0814141a891
Analyze and fix the following issue in the Linux kernel code: hyperv: Fix the missing return value in rndis_filter_set_packet_filter()
Problem Details: Return ETIMEDOUT when the reply message is not received in time. Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com> Reviewed-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: David S. Miller <davem@davemloft.net>
```diff diff --git a/drivers/net/hyperv/rndis_filter.c b/drivers/net/hyperv/rndis_filter.c index 1337b64b36a4..617eb2e4b06e 100644 --- a/drivers/net/hyperv/rndis_filter.c +++ b/drivers/net/hyperv/rndis_filter.c @@ -647,6 +647,7 @@ int rndis_filter_set_packet_filter(struct rndis_device *dev, u32 new_filter) if (t == 0...
fb1d074edb92604f313ac671f67e806c3223d191
Analyze and fix the following issue in the Linux kernel code: hyperv: Fix the max_xfer_size in RNDIS initialization
Problem Details: According to RNDIS specs, Windows sets this size to 0x4000. I use the same value here. Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com> Reviewed-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: David S. Miller <davem@davemloft.net>
```diff diff --git a/drivers/net/hyperv/rndis_filter.c b/drivers/net/hyperv/rndis_filter.c index 06f8601f32fc..1337b64b36a4 100644 --- a/drivers/net/hyperv/rndis_filter.c +++ b/drivers/net/hyperv/rndis_filter.c @@ -684,8 +684,7 @@ static int rndis_filter_init_device(struct rndis_device *dev) init = &request->request_...
3a50597de8635cd05133bd12c95681c82fe7b878
Analyze and fix the following issue in the Linux kernel code: KEYS: Make the session and process keyrings per-thread
Problem Details: Make the session keyring per-thread rather than per-process, but still inherited from the parent thread to solve a problem with PAM and gdm. The problem is that join_session_keyring() will reject attempts to change the session keyring of a multithreaded program but gdm is now multithreaded before it g...
```diff diff --git a/include/linux/cred.h b/include/linux/cred.h index ebbed2ce6637..0142aacb70b7 100644 --- a/include/linux/cred.h +++ b/include/linux/cred.h @@ -76,21 +76,6 @@ extern int groups_search(const struct group_info *, kgid_t); extern int in_group_p(kgid_t); extern int in_egroup_p(kgid_t); -/* - * The co...
7208507ed9dc39a7ac3bd2c64440c461762d8174
Analyze and fix the following issue in the Linux kernel code: [media] s5p-tv: Report only multi-plane capabilities in vidioc_querycap
Problem Details: The mixer video node supports only multi-planar API so the driver should not be setting V4L2_CAP_VIDEO_OUTPUT flags. Fix this and also switch to device_caps. Additionally fix the VIDIOC_ENUM_FMT ioctl handler which now works for V4L2_BUF_TYPE_CAPTURE, rather than expected V4L2_BUF_TYPE_CAPTURE_MPLANE. ...
```diff diff --git a/drivers/media/platform/s5p-tv/mixer_video.c b/drivers/media/platform/s5p-tv/mixer_video.c index bd42ea301650..0c1cd895ff66 100644 --- a/drivers/media/platform/s5p-tv/mixer_video.c +++ b/drivers/media/platform/s5p-tv/mixer_video.c @@ -164,9 +164,8 @@ static int mxr_querycap(struct file *file, void *...
81c9bcfbefec212548058eeac612d98dc9290d55
Analyze and fix the following issue in the Linux kernel code: [media] s5p-mfc: Fix misplaced return statement in s5p_mfc_suspend()
Problem Details: return statement was wrongly placed before a code that needs to be executed. Moved the return statement to the end of the function. Tested suspend/resume on SMDK4412 board using 3.5-rc6 kernel. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Acked-by: Kamil Debski <k.debski@samsung.com> Signed-o...
```diff diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc.c b/drivers/media/platform/s5p-mfc/s5p_mfc.c index 4486a2340532..5587ef15ca4f 100644 --- a/drivers/media/platform/s5p-mfc/s5p_mfc.c +++ b/drivers/media/platform/s5p-mfc/s5p_mfc.c @@ -1215,7 +1215,7 @@ static int s5p_mfc_suspend(struct device *dev) if (m_de...
d2331c991354a50bf65d114b2e88d77980223035
Analyze and fix the following issue in the Linux kernel code: [media] exynos-gsc: Add missing static storage class specifiers
Problem Details: Fixes the following warnings: drivers/media/platform/exynos-gsc/gsc-core.c:313:5: warning: symbol 'get_plane_info' was not declared. Should it be static? drivers/media/platform/exynos-gsc/gsc-core.c:746:28: warning: symbol 'gsc_ctrl_ops' was not declared. Should it be static? drivers/media/platform/exy...
```diff diff --git a/drivers/media/platform/exynos-gsc/gsc-core.c b/drivers/media/platform/exynos-gsc/gsc-core.c index 90a6c55b4d08..bfec9e65aefb 100644 --- a/drivers/media/platform/exynos-gsc/gsc-core.c +++ b/drivers/media/platform/exynos-gsc/gsc-core.c @@ -310,7 +310,7 @@ int gsc_enum_fmt_mplane(struct v4l2_fmtdesc *...
f68247fcdc361bc7db2ecb269451247235c21079
Analyze and fix the following issue in the Linux kernel code: [media] s5p-fimc: Fix incorrect condition in fimc_lite_reqbufs()
Problem Details: Fixes a typo in a conditional evaluation. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
```diff diff --git a/drivers/media/platform/s5p-fimc/fimc-lite.c b/drivers/media/platform/s5p-fimc/fimc-lite.c index 5e6c704f1085..70bcf39de879 100644 --- a/drivers/media/platform/s5p-fimc/fimc-lite.c +++ b/drivers/media/platform/s5p-fimc/fimc-lite.c @@ -829,7 +829,7 @@ static int fimc_lite_reqbufs(struct file *file, v...
970e85f87067638262a5c165aff404e6190817f8
Analyze and fix the following issue in the Linux kernel code: [media] s5p-tv: Fix potential NULL pointer dereference error
Problem Details: When mdev is NULL, the error print statement will try to dereference the NULL pointer. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Acked-by: Tomasz Stanislawski <t.stanislaws@samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab...
```diff diff --git a/drivers/media/platform/s5p-tv/mixer_drv.c b/drivers/media/platform/s5p-tv/mixer_drv.c index a15ca0595b87..ca0f29717448 100644 --- a/drivers/media/platform/s5p-tv/mixer_drv.c +++ b/drivers/media/platform/s5p-tv/mixer_drv.c @@ -384,7 +384,7 @@ static int __devinit mxr_probe(struct platform_device *pd...
c0522b6cc1237c935b2cead3fa7b45465df2f839
Analyze and fix the following issue in the Linux kernel code: UAPI: x86: Fix insn_sanity build failure after UAPI split
Problem Details: Fix a build failure in the x86 insn_sanity program after the UAPI split. The problem is that insn_sanity.c #includes arch/x86/lib/insn.c - which uses the kernel string header. This leads to conflicts for various definitions against the /usr/include/ headers. linux/string.h can be replaced with the n...
```diff diff --git a/arch/x86/lib/insn.c b/arch/x86/lib/insn.c index b1e6c4b2e8eb..54fcffed28ed 100644 --- a/arch/x86/lib/insn.c +++ b/arch/x86/lib/insn.c @@ -18,7 +18,11 @@ * Copyright (C) IBM Corporation, 2002, 2004, 2009 */ +#ifdef __KERNEL__ #include <linux/string.h> +#else +#include <string.h> +#endif #inc...
584c5ef813c63354ed9e03b732048240c09b86af
Analyze and fix the following issue in the Linux kernel code: UAPI: x86: Fix the test_get_len tool
Problem Details: Fix the x86 test_get_len tool to have the right include paths in the right order (it includes a non-exported kernel header directly), otherwise errors like the following occur: /data/fs/linux-2.6-hdr/include/linux/types.h:18:26: error: conflicting types for 'fd_set' /usr/include/sys/select.h:78:5: not...
```diff diff --git a/arch/x86/tools/Makefile b/arch/x86/tools/Makefile index 733057b435b0..bae601f900ef 100644 --- a/arch/x86/tools/Makefile +++ b/arch/x86/tools/Makefile @@ -28,7 +28,7 @@ posttest: $(obj)/test_get_len vmlinux $(obj)/insn_sanity hostprogs-y += test_get_len insn_sanity # -I needed for generated C so...
94c15b5e6755711af6dd81bde0f8396e24b75dc2
Analyze and fix the following issue in the Linux kernel code: [media] s5k6aa: Fix possible NULL pointer dereference
Problem Details: Make sure __s5k6aa_get_crop_rect() always returns valid pointer, as it is assumed at the callers. crop->which is already validated when subdev set_crop and get_crop callbacks are called from within the v4l2-core. If it ever happens the crop operations are called directly for some reason in kernel space...
```diff diff --git a/drivers/media/i2c/s5k6aa.c b/drivers/media/i2c/s5k6aa.c index 045ca7f4f6ca..57cd4fa0193d 100644 --- a/drivers/media/i2c/s5k6aa.c +++ b/drivers/media/i2c/s5k6aa.c @@ -1061,10 +1061,9 @@ __s5k6aa_get_crop_rect(struct s5k6aa *s5k6aa, struct v4l2_subdev_fh *fh, { if (which == V4L2_SUBDEV_FORMAT_ACTI...
613ad4837964e9b9ea914c74e7d8f57b86b75a52
Analyze and fix the following issue in the Linux kernel code: xen/Makefile: fix dom-y build
Problem Details: We need to add $(dom0-y) to obj-$(CONFIG_XEN_DOM0) after dom0-y is defined otherwise we end up adding nothing. Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
```diff diff --git a/drivers/xen/Makefile b/drivers/xen/Makefile index cd28aae575dd..275abfc615cb 100644 --- a/drivers/xen/Makefile +++ b/drivers/xen/Makefile @@ -8,10 +8,10 @@ obj-y += xenbus/ nostackp := $(call cc-option, -fno-stack-protector) CFLAGS_features.o := $(nostackp) -obj-$(CONFIG_XEN_DOM0) += $(dom0...
edb39244fad2e96ba03ea97a4b2c585c7f2fc7e4
Analyze and fix the following issue in the Linux kernel code: drm/i915/dp: Fetch downstream port info if needed during DPCD fetch
Problem Details: v2: Fix parenthesis mismatch, spotted by Jani Nikula Tested-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> [danvet: Fixup merge conflict and MAX_DOWNSTREAM #define as spotted by Jani.] Signed-off-by: Daniel Vetter <daniel...
```diff diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c index 1474f84fdbd0..42bdca47c5d6 100644 --- a/drivers/gpu/drm/i915/intel_dp.c +++ b/drivers/gpu/drm/i915/intel_dp.c @@ -37,6 +37,7 @@ #include "i915_drm.h" #include "i915_drv.h" +#define DP_RECEIVER_CAP_SIZE 0xf #define DP_LINK_...
27810fb2d2edacf2961dbedfe9e9f8d2e5080ea5
Analyze and fix the following issue in the Linux kernel code: drm/radeon/pm: fix multi-head profile handling on BTC+ (v2)
Problem Details: Starting on BTC, there are no longer separate states for single head and multi-head, we just use the high mclk/voltage for all states for multi-head. Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=49981 v2: fix typo Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
```diff diff --git a/drivers/gpu/drm/radeon/evergreen.c b/drivers/gpu/drm/radeon/evergreen.c index ef47879c5d40..c4ded396b78d 100644 --- a/drivers/gpu/drm/radeon/evergreen.c +++ b/drivers/gpu/drm/radeon/evergreen.c @@ -325,6 +325,64 @@ void sumo_pm_init_profile(struct radeon_device *rdev) rdev->pm.power_state[idx].n...
f7eff60ea0e4e35732604e3591e2ff7b3ef41981
Analyze and fix the following issue in the Linux kernel code: drm: refcnt drm_framebuffer (v4.1)
Problem Details: This simplifies drm fb lifetime, and if the crtc/plane needs to hold a ref to the fb when disabling a pipe until the next vblank, this avoids the need to make disabling an overlay synchronous. This is a problem that shows up when userspace is using a drm plane to implement a hw cursor.. making overlay...
```diff diff --git a/drivers/gpu/drm/drm_crtc.c b/drivers/gpu/drm/drm_crtc.c index c418c772a7e5..39afe13a5fa2 100644 --- a/drivers/gpu/drm/drm_crtc.c +++ b/drivers/gpu/drm/drm_crtc.c @@ -294,6 +294,8 @@ int drm_framebuffer_init(struct drm_device *dev, struct drm_framebuffer *fb, { int ret; + kref_init(&fb->refcoun...
87b526d349b04c31d7b3a40b434eb3f825d22305
Analyze and fix the following issue in the Linux kernel code: seccomp: Make syscall skipping and nr changes more consistent
Problem Details: This fixes two issues that could cause incompatibility between kernel versions: - If a tracer uses SECCOMP_RET_TRACE to select a syscall number higher than the largest known syscall, emulate the unknown vsyscall by returning -ENOSYS. (This is unlikely to make a noticeable difference on x86-...
```diff diff --git a/Documentation/prctl/seccomp_filter.txt b/Documentation/prctl/seccomp_filter.txt index 597c3c581375..1e469ef75778 100644 --- a/Documentation/prctl/seccomp_filter.txt +++ b/Documentation/prctl/seccomp_filter.txt @@ -95,12 +95,15 @@ SECCOMP_RET_KILL: SECCOMP_RET_TRAP: Results in the kernel sendin...
759643ce39f13c416236e2609ccaed9792107b2f
Analyze and fix the following issue in the Linux kernel code: dma-debug: Remove local BUS_NOTIFY_UNBOUND_DRIVER define
Problem Details: Remove local BUS_NOTIFY_UNBOUND_DRIVER define. This is not used since BUS_NOTIFY_UNBOUND_DRIVER is defined in include/linux/device.h Signed-off-by: Shuah Khan <shuah.khan@hp.com> Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
```diff diff --git a/lib/dma-debug.c b/lib/dma-debug.c index 66ce41489133..b9087bff008b 100644 --- a/lib/dma-debug.c +++ b/lib/dma-debug.c @@ -120,11 +120,6 @@ static const char *type2name[4] = { "single", "page", static const char *dir2name[4] = { "DMA_BIDIRECTIONAL", "DMA_TO_DEVICE", "DMA_FROM_DEVICE", "DMA_...
821f0f68ca5fa93c757a892129392e751a7407a3
Analyze and fix the following issue in the Linux kernel code: iommu/amd: Fix possible use after free in get_irq_table()
Problem Details: We should return NULL on error instead of the freed pointer. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
```diff diff --git a/drivers/iommu/amd_iommu.c b/drivers/iommu/amd_iommu.c index 312dd4dd4791..ff16c5ece735 100644 --- a/drivers/iommu/amd_iommu.c +++ b/drivers/iommu/amd_iommu.c @@ -3865,6 +3865,7 @@ static struct irq_remap_table *get_irq_table(u16 devid, bool ioapic) table->table = kmem_cache_alloc(amd_iommu_irq_ca...
5bb61643f6a70d48de9cfe91ad0fee0d618b6816
Analyze and fix the following issue in the Linux kernel code: drm/i915: Flush the pending flips on the CRTC before modification
Problem Details: This was meant to be the purpose of the intel_crtc_wait_for_pending_flips() function which is called whilst preparing the CRTC for a modeset or before disabling. However, as Ville Syrjala pointed out, we set the pending flip notification on the old framebuffer that is no longer attached to the CRTC by ...
```diff diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index f6e274c5db62..57c1309733f6 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c @@ -2806,13 +2806,34 @@ static void ironlake_fdi_disable(struct drm_crtc *crtc) udelay(100); }...
d09f53a735bae43806a77754312a45d3f1198342
Analyze and fix the following issue in the Linux kernel code: remoteproc: Fix use of format specifyer
Problem Details: The dma_addr_t type can be either u32 or u64 depending on the configuration. We should use a format specifyer for the larger type and explicitly cast to it. Sparse warnings: drivers/remoteproc/remoteproc_core.c:234:2: warning: format ‘%x’ expects argument of type ‘unsigned int’, but argument 6 has t...
```diff diff --git a/drivers/remoteproc/remoteproc_core.c b/drivers/remoteproc/remoteproc_core.c index f163704b6ce5..dd3bfaf1ad40 100644 --- a/drivers/remoteproc/remoteproc_core.c +++ b/drivers/remoteproc/remoteproc_core.c @@ -231,8 +231,8 @@ int rproc_alloc_vring(struct rproc_vdev *rvdev, int i) /* Store largest not...
7168d914a782086e217214c57ddfc7cc4b738c0c
Analyze and fix the following issue in the Linux kernel code: remoteproc: fix a potential NULL-dereference on cleanup
Problem Details: We only need to allocate mapping if there is an IOMMU domain. Otherwise, when the mappings are released, the assumption that an IOMMU domain is there will crash and burn. CC: stable@vger.kernel.org Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> [ohad: revise commit log] Signed-off-by: Ohad B...
```diff diff --git a/drivers/remoteproc/remoteproc_core.c b/drivers/remoteproc/remoteproc_core.c index b6c622982f8c..f163704b6ce5 100644 --- a/drivers/remoteproc/remoteproc_core.c +++ b/drivers/remoteproc/remoteproc_core.c @@ -573,17 +573,10 @@ static int rproc_handle_carveout(struct rproc *rproc, dev_dbg(dev, "carve...
3d4f860583bf4aa55dd5c6d5ba6ccf1f25fb473a
Analyze and fix the following issue in the Linux kernel code: dw_dmac: fix a regression in dwc_prep_dma_memcpy
Problem Details: Sometimes memory-to-memory test is failed, that's why we need to choose minimum data portion between source and destination limits together. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Vinod Koul <vinod.koul@linux.intel.com>
```diff diff --git a/drivers/dma/dw_dmac.c b/drivers/dma/dw_dmac.c index 9ca9ca41b83e..c4b0eb3cde81 100644 --- a/drivers/dma/dw_dmac.c +++ b/drivers/dma/dw_dmac.c @@ -716,6 +716,7 @@ dwc_prep_dma_memcpy(struct dma_chan *chan, dma_addr_t dest, dma_addr_t src, size_t offset; unsigned int src_width; unsigned int ...
3dfd8235002727dbd759bb0f80f8ac862f392071
Analyze and fix the following issue in the Linux kernel code: ACPI: Fix build when disabled
Problem Details: "ACPI: Store valid ACPI tables passed via early initrd in reserved memblock areas" breaks the build if either CONFIG_ACPI or CONFIG_BLK_DEV_INITRD is disabled: arch/x86/kernel/setup.c: In function 'setup_arch': arch/x86/kernel/setup.c:944: error: implicit declaration of function 'acpi_initrd_override'...
```diff diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c index 764e543b2297..bf82c1e05464 100644 --- a/arch/x86/kernel/setup.c +++ b/arch/x86/kernel/setup.c @@ -941,7 +941,9 @@ void __init setup_arch(char **cmdline_p) reserve_initrd(); +#if defined(CONFIG_ACPI) && defined(CONFIG_BLK_DEV_INITRD) ac...
13b74085d92feda78bad1045516d332a1e9a3407
Analyze and fix the following issue in the Linux kernel code: sata_mv: Fix warnings when no PCI
Problem Details: Dove can be configured without PCI. We then get a number of warnings: warning: 'msi' defined but not used warning: 'mv5_sht' defined but not used warning: 'mv_dump_pci_cfg' defined but not used. Move around variables and add #ifdef as necassary to fix the warnings. Signed-off-by: Andrew Lunn <andrew...
```diff diff --git a/drivers/ata/sata_mv.c b/drivers/ata/sata_mv.c index 311be18d3f03..68f4fb54d627 100644 --- a/drivers/ata/sata_mv.c +++ b/drivers/ata/sata_mv.c @@ -79,8 +79,8 @@ * module options */ -static int msi; #ifdef CONFIG_PCI +static int msi; module_param(msi, int, S_IRUGO); MODULE_PARM_DESC(msi, "En...
40dad0af2d5c3122d883b2baed4bb39baf6561ec
Analyze and fix the following issue in the Linux kernel code: [libata] Makefile: Fix build error in sata_highbank
Problem Details: Allow sata_highbank to build even if no other users of libahci.o are built. Signed-off-by: Mark Langsdorf <mark.langsdorf@calxeda.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
```diff diff --git a/drivers/ata/Makefile b/drivers/ata/Makefile index 8b384f1885f7..9329dafba91b 100644 --- a/drivers/ata/Makefile +++ b/drivers/ata/Makefile @@ -9,7 +9,7 @@ obj-$(CONFIG_SATA_FSL) += sata_fsl.o obj-$(CONFIG_SATA_INIC162X) += sata_inic162x.o obj-$(CONFIG_SATA_SIL24) += sata_sil24.o obj-$(CONFIG_SAT...
974a847e00cf3ff1695e62b276892137893706ab
Analyze and fix the following issue in the Linux kernel code: drivers: bus: omap_l3: fixup merge conflict resolution
Problem Details: This fixes a local merge conflict resolution done wrong locally in arm-soc for-next. soc.h was added on a cleanup branch, but the driver was moved and the header no longer needed. Signed-off-by: Olof Johansson <olof@lixom.net> [ .. and I did the same wrong merge, since git automatically does the who...
```diff diff --git a/drivers/bus/omap_l3_noc.c b/drivers/bus/omap_l3_noc.c index 44b2b3e57882..ab911a33f8a8 100644 --- a/drivers/bus/omap_l3_noc.c +++ b/drivers/bus/omap_l3_noc.c @@ -28,7 +28,6 @@ #include <linux/kernel.h> #include <linux/slab.h> -#include "soc.h" #include "omap_l3_noc.h" /* ```