id stringlengths 40 40 | instruction stringlengths 68 308 | input stringlengths 17 33.4k | output stringlengths 100 30k |
|---|---|---|---|
2bd0cfbde2c0a74e209acbf045f1298cc2f61e01 | Analyze and fix the following issue in the Linux kernel code: [PATCH] fix x86_64-mm-spinlock-cleanup | Problem Details:
We need processor.h for cpu_relax().
Cc: Andi Kleen <ak@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org> | ```diff
diff --git a/include/asm-x86_64/spinlock.h b/include/asm-x86_64/spinlock.h
index be7a9e629fb2..3daf5b005905 100644
--- a/include/asm-x86_64/spinlock.h
+++ b/include/asm-x86_64/spinlock.h
@@ -4,6 +4,7 @@
#include <asm/atomic.h>
#include <asm/rwlock.h>
#include <asm/page.h>
+#include <asm/processor.h>
/*
... |
133d205a18b7a4d8cb52959c5310f6664277cf61 | Analyze and fix the following issue in the Linux kernel code: [PATCH] Make kmem_cache_destroy() return void | Problem Details:
un-, de-, -free, -destroy, -exit, etc functions should in general return
void. Also,
There is very little, say, filesystem driver code can do upon failed
kmem_cache_destroy(). If it will be decided to BUG in this case, BUG
should be put in generic code, instead.
Signed-off-by: Alexey Dobriyan <adob... | ```diff
diff --git a/include/linux/slab.h b/include/linux/slab.h
index 66d6eb78d1c6..a96fd9310d55 100644
--- a/include/linux/slab.h
+++ b/include/linux/slab.h
@@ -60,7 +60,7 @@ extern void __init kmem_cache_init(void);
extern kmem_cache_t *kmem_cache_create(const char *, size_t, size_t, unsigned long,
void... |
32c2d2bc4bed61323f14f2a7d69ccbd567253d8a | Analyze and fix the following issue in the Linux kernel code: [PATCH] more ext3 16T overflow fixes | Problem Details:
Some of the changes in balloc.c are just cosmetic, as Andreas pointed out -
if they overflow they'll then underflow and things are fine.
5th hunk actually fixes an overflow problem.
Also check for potential overflows in inode & block counts when resizing.
Signed-off-by: Eric Sandeen <esandeen@redhat... | ```diff
diff --git a/fs/ext3/balloc.c b/fs/ext3/balloc.c
index c19be8fc3e51..b41a7d7e20f0 100644
--- a/fs/ext3/balloc.c
+++ b/fs/ext3/balloc.c
@@ -202,7 +202,7 @@ goal_in_my_reservation(struct ext3_reserve_window *rsv, ext3_grpblk_t grp_goal,
ext3_fsblk_t group_first_block, group_last_block;
group_first_block = e... |
a4e4de36dc446b2193bdc8ebb96a96e44b69dd94 | Analyze and fix the following issue in the Linux kernel code: [PATCH] ext3: Fix sparse warnings | Problem Details:
Fixing up some endian-ness warnings in preparation to clone ext4 from ext3.
Signed-off-by: Dave Kleikamp <shaggy@austin.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org> | ```diff
diff --git a/fs/ext3/resize.c b/fs/ext3/resize.c
index 5e1337fd878a..e186f7fb698b 100644
--- a/fs/ext3/resize.c
+++ b/fs/ext3/resize.c
@@ -336,7 +336,7 @@ static int verify_reserved_gdb(struct super_block *sb,
unsigned five = 5;
unsigned seven = 7;
unsigned grp;
- __u32 *p = (__u32 *)primary->b_data;
+ __... |
7543fc7b3abfee8c6cd6349ebd5e5fde02fac984 | Analyze and fix the following issue in the Linux kernel code: [PATCH] ext3: wrong error behavior | Problem Details:
SWsoft Virtuozzo/OpenVZ Linux kernel team has discovered that ext3 error
behavior was broken in linux kernels since 2.5.x versions by the following
patch:
2002/10/31 02:15:26-05:00 tytso@snap.thunk.org
Default mount options from superblock for ext2/3 filesystems
http://linux.bkbits.net:8080/linux-2.6/... | ```diff
diff --git a/fs/ext3/super.c b/fs/ext3/super.c
index bc7a768f9bb4..4b526b496102 100644
--- a/fs/ext3/super.c
+++ b/fs/ext3/super.c
@@ -159,20 +159,21 @@ static void ext3_handle_error(struct super_block *sb)
if (sb->s_flags & MS_RDONLY)
return;
- if (test_opt (sb, ERRORS_RO)) {
- printk (KERN_CRIT "Remou... |
37ed322290eb6d5cf2ab33915793ed4219eae1d6 | Analyze and fix the following issue in the Linux kernel code: [PATCH] JBD: 16T fixes | Problem Details:
These are a few places I've found in jbd that look like they may not be
16T-safe, or consistent with the use of unsigned longs for block
containers. Problems here would be somewhat hard to hit, would require
journal blocks past the 8T boundary, which would not be terribly common.
Still, should fix.
(... | ```diff
diff --git a/fs/jbd/journal.c b/fs/jbd/journal.c
index 2613fca92740..88d970e09ce6 100644
--- a/fs/jbd/journal.c
+++ b/fs/jbd/journal.c
@@ -271,7 +271,7 @@ static void journal_kill_thread(journal_t *journal)
int journal_write_metadata_buffer(transaction_t *transaction,
struct journal_head *jh_in,
... |
eee194e76c681dbdbf5024b889fda1181b66ef57 | Analyze and fix the following issue in the Linux kernel code: [PATCH] ext3: inode numbers are unsigned long | Problem Details:
This is primarily format string fixes, with changes to ialloc.c where large
inode counts could overflow, and also pass around journal_inum as an
unsigned long, just to be pedantic about it....
Signed-off-by: Eric Sandeen <esandeen@redhat.com>
Cc: Mingming Cao <cmm@us.ibm.com>
Signed-off-by: Andrew Mor... | ```diff
diff --git a/fs/ext3/ialloc.c b/fs/ext3/ialloc.c
index 5e288368499b..1e4ded8aa3cd 100644
--- a/fs/ext3/ialloc.c
+++ b/fs/ext3/ialloc.c
@@ -202,7 +202,7 @@ error_return:
static int find_group_dir(struct super_block *sb, struct inode *parent)
{
int ngroups = EXT3_SB(sb)->s_groups_count;
- int freei, avefreei;... |
41f04d852e359582518f950d12b2287766613022 | Analyze and fix the following issue in the Linux kernel code: [PATCH] ext2: fix mounts at 16T | Problem Details:
Signed-off-by: Eric Sandeen <esandeen@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org> | ```diff
diff --git a/fs/ext2/super.c b/fs/ext2/super.c
index 4286ff6330b6..d978d3febb8c 100644
--- a/fs/ext2/super.c
+++ b/fs/ext2/super.c
@@ -544,17 +544,24 @@ static int ext2_check_descriptors (struct super_block * sb)
int i;
int desc_block = 0;
struct ext2_sb_info *sbi = EXT2_SB(sb);
- unsigned long block = le... |
855565e81ad8940cc645b5110ec2c7f124a76d23 | Analyze and fix the following issue in the Linux kernel code: [PATCH] fix ext3 mounts at 16T | Problem Details:
I need to do some actual IO testing now, but this gets things mounting for
a 16T ext3 filesystem. (patched up e2fsprogs is needed too, I'll send that
off the kernel list)
This patch fixes these issues in the kernel:
o sbi->s_groups_count overflows in ext3_fill_super()
sbi->s_groups_count = (le32_t... | ```diff
diff --git a/fs/ext3/super.c b/fs/ext3/super.c
index 4b95bfe4c8f7..762dff7b56fb 100644
--- a/fs/ext3/super.c
+++ b/fs/ext3/super.c
@@ -1174,7 +1174,8 @@ static int ext3_setup_super(struct super_block *sb, struct ext3_super_block *es,
static int ext3_check_descriptors (struct super_block * sb)
{
struct ext3_... |
bbf2bef9f50eb119ffadd735eb0966ac8a04f91f | Analyze and fix the following issue in the Linux kernel code: [PATCH] fix "cpu to node relationship fixup: map cpu to node" | Problem Details:
Fix build error introduced by 3212fe1594e577463bc8601d28aa008f520c3377
Non-NUMA case should be handled.
Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org> | ```diff
diff --git a/arch/ia64/kernel/topology.c b/arch/ia64/kernel/topology.c
index 05bdf7affb43..5629b45e89c6 100644
--- a/arch/ia64/kernel/topology.c
+++ b/arch/ia64/kernel/topology.c
@@ -36,9 +36,7 @@ int arch_register_cpu(int num)
*/
if (!can_cpei_retarget() && is_cpu_cpei_target(num))
sysfs_cpus[num].cpu.... |
9dbd7b9142e95867ee8a56da5d45c72884c107d3 | Analyze and fix the following issue in the Linux kernel code: [MIPS] Fix USER_PTRS_PER_PGD for 64K page size. | Problem Details:
The code in pgtable-64.h assumes TASK_SIZE is always bigger than a first
level PGDIR_SIZE. This is not the case for 64K pages, where task size is
40 bits (1TB) and a pgd entry can map 42 bits. This leads to
USER_PTRS_PER_PGD being zero for 64K pages.
Signed-off-by: Peter Watkins <treestem@gmail.com>
S... | ```diff
diff --git a/include/asm-mips/pgtable-64.h b/include/asm-mips/pgtable-64.h
index c59a1e21f5b0..d05fb6f38aa7 100644
--- a/include/asm-mips/pgtable-64.h
+++ b/include/asm-mips/pgtable-64.h
@@ -93,8 +93,12 @@
#define PTRS_PER_PMD ((PAGE_SIZE << PMD_ORDER) / sizeof(pmd_t))
#define PTRS_PER_PTE ((PAGE_SIZE << PTE_... |
3ee24e1b1e0b5ae413a85ba63677a7110915e3af | Analyze and fix the following issue in the Linux kernel code: [MIPS] Atlas: Fix building the RTC driver | Problem Details:
Atlas maps its RTC chip in the host mmio space rather than using the
"traditional" location in the PCI/ISA port space. A change that has
happened to the generic RTC header requires to define ARCH_RTC_LOCATION
now.
Signed-off-by: Maciej W. Rozycki <macro@mips.com>
Signed-off-by: Ralf Baechle <ralf@lin... | ```diff
diff --git a/include/asm-mips/mach-atlas/mc146818rtc.h b/include/asm-mips/mach-atlas/mc146818rtc.h
index 397522ea5565..fc09928571d6 100644
--- a/include/asm-mips/mach-atlas/mc146818rtc.h
+++ b/include/asm-mips/mach-atlas/mc146818rtc.h
@@ -28,6 +28,8 @@
#include <asm/mips-boards/atlas.h>
#include <asm/mips-boa... |
846acaa2b4974ae2e28038d024dedcfc184efbb7 | Analyze and fix the following issue in the Linux kernel code: [MIPS] Patch to arch/mips/mips-boards/generic/time.c | Problem Details:
In hooking up the perf counter overflow interrupt to the experimental
deprecated-real-soon-now /proc/perf interface last night, I had to
revisit arch/mips/mips-boards/generic/time.c, and discovered that
when the 2.6.9-based SMTC prototype was merged with the more
recent tree, it was missed that arch/mi... | ```diff
diff --git a/arch/mips/mips-boards/generic/time.c b/arch/mips/mips-boards/generic/time.c
index 557bf961f36a..de5798e1e015 100644
--- a/arch/mips/mips-boards/generic/time.c
+++ b/arch/mips/mips-boards/generic/time.c
@@ -92,10 +92,9 @@ extern int (*perf_irq)(struct pt_regs *regs);
irqreturn_t mips_timer_interrup... |
8f9a2b324644d3f8c233287f0a7764d61655cda4 | Analyze and fix the following issue in the Linux kernel code: [MIPS] Fix errors detected by "make headers_check" | Problem Details:
* export asm/sgidefs.h
* include asm/isadep.h only if in kernel
* do not export contents of asm/timex.h and asm/user.h
Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org> | ```diff
diff --git a/include/asm-mips/Kbuild b/include/asm-mips/Kbuild
index c68e1680da01..01ea3e045652 100644
--- a/include/asm-mips/Kbuild
+++ b/include/asm-mips/Kbuild
@@ -1 +1,3 @@
include include/asm-generic/Kbuild.asm
+
+header-y += sgidefs.h
diff --git a/include/asm-mips/ptrace.h b/include/asm-mips/ptrace.h
ind... |
09f451bfb9fe5ceea763a9ebd6ec73dd05e4faf8 | Analyze and fix the following issue in the Linux kernel code: [MIPS] SEAD defconfig build fix | Problem Details:
Signed-off-by: Maciej W. Rozycki <macro@mips.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org> | ```diff
diff --git a/arch/mips/Makefile b/arch/mips/Makefile
index d333ce4ba26b..f4227d24227d 100644
--- a/arch/mips/Makefile
+++ b/arch/mips/Makefile
@@ -330,6 +330,7 @@ load-$(CONFIG_MIPS_MALTA) += 0xffffffff80100000
# MIPS SEAD board
#
core-$(CONFIG_MIPS_SEAD) += arch/mips/mips-boards/sead/
+cflags-$(CONFIG_MIPS_... |
32136568a9828c27c07eedb8d2b3e3d9fe8d87ba | Analyze and fix the following issue in the Linux kernel code: [MIPS] Fix for pci config_access on alchemy au1x000 | Problem Details:
I've encountered a serious problem with PCI config space access on Au1x000
platforms with recent 2.6.x-kernel. With 2.4.31 the same hardware works fine.
So I was looking for the differences:
Symptoms:
- no PCI-device is seen on bootup though two or three cards are present
- lspci output is empty
- OR:... | ```diff
diff --git a/arch/mips/pci/ops-au1000.c b/arch/mips/pci/ops-au1000.c
index 0c0c1e6519f9..8ae46481fcb7 100644
--- a/arch/mips/pci/ops-au1000.c
+++ b/arch/mips/pci/ops-au1000.c
@@ -110,7 +110,7 @@ static int config_access(unsigned char access_type, struct pci_bus *bus,
if (first_cfg) {
/* reserve a wired ent... |
a94d702049569401c65b579d0751ce282f962b41 | Analyze and fix the following issue in the Linux kernel code: [MIPS] MT: Fix setting of XTC. | Problem Details:
XTC can only be set if VPA is clear, which it may not be. There is
also the possibility of a back to back c0 register access hazard to
take care of.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org> | ```diff
diff --git a/arch/mips/kernel/vpe.c b/arch/mips/kernel/vpe.c
index 9ee0ec2cd067..51ddd2166898 100644
--- a/arch/mips/kernel/vpe.c
+++ b/arch/mips/kernel/vpe.c
@@ -768,10 +768,16 @@ int vpe_run(struct vpe * v)
*/
write_tc_c0_tcbind((read_tc_c0_tcbind() & ~TCBIND_CURVPE) | v->minor);
+ write_vpe_c0_vpecon... |
6e74bae9a0c2fc59ffb0e25fec074b4ac0ac7048 | Analyze and fix the following issue in the Linux kernel code: [MIPS] SMTC Build fix. | Problem Details:
Signed-off-by: Ralf Baechle <ralf@linux-mips.org> | ```diff
diff --git a/arch/mips/kernel/smtc-asm.S b/arch/mips/kernel/smtc-asm.S
index 4cc3dea36612..76cb31d57482 100644
--- a/arch/mips/kernel/smtc-asm.S
+++ b/arch/mips/kernel/smtc-asm.S
@@ -8,7 +8,7 @@
#include <asm/regdef.h>
#include <asm/asmmacro.h>
#include <asm/stackframe.h>
-#include <asm/stackframe.h>
+#inclu... |
dc41fb43966ae1318fe34a8e5f959924a7c05d81 | Analyze and fix the following issue in the Linux kernel code: [MIPS] Fix 32-bit kernel by replacing 64-bit-only code. | Problem Details:
dclz() expects its 64-bit argument being passed as a single register
but on 32-bit kernels it'll actually be in a register pair.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org> | ```diff
diff --git a/arch/mips/sibyte/bcm1480/irq.c b/arch/mips/sibyte/bcm1480/irq.c
index ed325f0ab28a..a0222fa4416c 100644
--- a/arch/mips/sibyte/bcm1480/irq.c
+++ b/arch/mips/sibyte/bcm1480/irq.c
@@ -469,21 +469,6 @@ void bcm1480_kgdb_interrupt(struct pt_regs *regs)
#endif /* CONFIG_KGDB */
-static inline int ... |
13fdd31abec5f48cf97693bd14d2e11e0779b4ca | Analyze and fix the following issue in the Linux kernel code: [MIPS] Avoid double signal restarting. | Problem Details:
In entry.S resume_userspace ... jal do_notify_resume form a loop through
which the kernel will iterate as long as work is pending. If we
iterate through this loop more than once with no signal pending for at
least one but the last iteration we will take do the syscall restarting
multiple times resulti... | ```diff
diff --git a/arch/mips/kernel/irixsig.c b/arch/mips/kernel/irixsig.c
index 052ea15f1e80..719364752e77 100644
--- a/arch/mips/kernel/irixsig.c
+++ b/arch/mips/kernel/irixsig.c
@@ -224,6 +224,7 @@ void do_irix_signal(struct pt_regs *regs)
regs->regs[7] = regs->regs[26];
regs->cp0_epc -= 4;
}
+ regs->r... |
bca70d24c09b740d6fd96b972011644cba8383d6 | Analyze and fix the following issue in the Linux kernel code: [MIPS] Fix EV64120 PCI fixup in Makefile | Problem Details:
Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org> | ```diff
diff --git a/arch/mips/pci/Makefile b/arch/mips/pci/Makefile
index 35d5927706ea..368d3d896165 100644
--- a/arch/mips/pci/Makefile
+++ b/arch/mips/pci/Makefile
@@ -28,7 +28,7 @@ obj-$(CONFIG_DDB5477) += fixup-ddb5477.o pci-ddb5477.o ops-ddb5477.o
obj-$(CONFIG_LASAT) += pci-lasat.o
obj-$(CONFIG_MIPS_ATLAS) +=... |
87151ae39bf5556abe83d69af0be9580c32c501b | Analyze and fix the following issue in the Linux kernel code: [MIPS] Miscellaneous cleanup in prologue analysis code | Problem Details:
We usually use backtrace term for dumping a call tree during
debug. Therefore this patch renames show_frametrace() into
show_backtrace() and show_trace() into show_raw_backtrace().
It also uses the new function print_ip_sym().
Signed-off-by: Franck Bui-Huu <vagabon.xyz@gmail.com>
Signed-off-by: Ralf ... | ```diff
diff --git a/arch/mips/kernel/traps.c b/arch/mips/kernel/traps.c
index 4a11a3d8447d..549cbb8209a3 100644
--- a/arch/mips/kernel/traps.c
+++ b/arch/mips/kernel/traps.c
@@ -74,21 +74,18 @@ void (*board_ejtag_handler_setup)(void);
void (*board_bind_eic_interrupt)(int irq, int regset);
-static void show_trace(... |
df586d59a4f069bb60a94ff4e5b64fe5c876f72c | Analyze and fix the following issue in the Linux kernel code: [MIPS] c-r4k: Typo fix. | Problem Details:
Signed-off-by: Ralf Baechle <ralf@linux-mips.org> | ```diff
diff --git a/arch/mips/mm/c-r4k.c b/arch/mips/mm/c-r4k.c
index 069803f58f3b..b3ccb8738d29 100644
--- a/arch/mips/mm/c-r4k.c
+++ b/arch/mips/mm/c-r4k.c
@@ -1242,7 +1242,7 @@ static inline void coherency_setup(void)
clear_c0_config(CONF_CU);
break;
/*
- * We need to catch the ealry Alchemy SOCs with
+ *... |
33573c0e3243aaa38b6ad96942de85a1b713c2ff | Analyze and fix the following issue in the Linux kernel code: sh: Fix occasional flush_cache_4096() stack corruption. | Problem Details:
IRQs disabling in flush_cache_4096 for cache purge. Under certain
workloads we would get an IRQ in the middle of a purge operation,
and the cachelines would remain in an inconsistent state, leading
to occasional stack corruption.
Signed-off-by: Takeo Takahashi <takahashi.takeo@renesas.com>
Signed-off-... | ```diff
diff --git a/arch/sh/mm/cache-sh4.c b/arch/sh/mm/cache-sh4.c
index aa4f62f0e374..e48cc22724d9 100644
--- a/arch/sh/mm/cache-sh4.c
+++ b/arch/sh/mm/cache-sh4.c
@@ -221,22 +221,20 @@ void flush_cache_sigtramp(unsigned long addr)
static inline void flush_cache_4096(unsigned long start,
unsigned long phys... |
87b0ef91b6f27c07bf7dcce8584437481f473092 | Analyze and fix the following issue in the Linux kernel code: sh: dma-mapping compile fixes. | Problem Details:
Silly bug, make it build again..
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/include/asm-sh/dma-mapping.h b/include/asm-sh/dma-mapping.h
index 124968f9866e..56cd4b977232 100644
--- a/include/asm-sh/dma-mapping.h
+++ b/include/asm-sh/dma-mapping.h
@@ -141,25 +141,35 @@ static inline void dma_sync_sg(struct device *dev, struct scatterlist *sg,
}
}
-static void dma_sync_s... |
d153ea88dccf003173315b5d21acabebb897fb4a | Analyze and fix the following issue in the Linux kernel code: sh: stack debugging support. | Problem Details:
This adds a DEBUG_STACK_USAGE and DEBUG_STACKOVERFLOW for SH.
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/arch/sh/Kconfig.debug b/arch/sh/Kconfig.debug
index 75ed1be8a49e..f0188e626be0 100644
--- a/arch/sh/Kconfig.debug
+++ b/arch/sh/Kconfig.debug
@@ -30,6 +30,22 @@ config EARLY_PRINTK
when the kernel may crash or hang before the serial console is
initialised. If unsure, say N.
+config DEBUG_... |
49c3f807f5734605c10cdfb462a8fd5c3075eb76 | Analyze and fix the following issue in the Linux kernel code: sh: Enable verbose BUG() support. | Problem Details:
Add SH to the list of platforms interested in Verbose BUG().
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug
index e7303fe54b01..b0f5ca72599f 100644
--- a/lib/Kconfig.debug
+++ b/lib/Kconfig.debug
@@ -284,7 +284,7 @@ config DEBUG_HIGHMEM
config DEBUG_BUGVERBOSE
bool "Verbose BUG() reporting (adds 70K)" if DEBUG_KERNEL && EMBEDDED
depends on BUG
- depends on ARM |... |
c7afb7e5cbc4baa781ec82731fc9fe9039efee22 | Analyze and fix the following issue in the Linux kernel code: sh: Fix memcpy() build error on sh4eb. | Problem Details:
A trivial bug breaking the build on sh4eb.
Signed-off-by: Nobuhiro Iwamatsu <hemamu@t-base.ne.jp>
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/arch/sh/lib/memcpy-sh4.S b/arch/sh/lib/memcpy-sh4.S
index db6b736537ad..560bc17eebdd 100644
--- a/arch/sh/lib/memcpy-sh4.S
+++ b/arch/sh/lib/memcpy-sh4.S
@@ -727,8 +727,8 @@ ENTRY(memcpy)
mov.l @(0x04,r5), r11 ! 18 LS (latency=2)
xtrct r9, r8 ! 48 EX
- mov.w @(0x02,r5), r12 ! 18 LS (laten... |
4052ebb7a2729bd7c28260cdf8e470c0d81b9c56 | Analyze and fix the following issue in the Linux kernel code: [ARM] 3859/1: Fix devicemaps_init() XIP_KERNEL odd 1MiB XIP_PHYS_ADDR translation error | Problem Details:
The ARM XIP_KERNEL map created in devicemaps_init() is wrong.
The map.pfn is rounded down to an even 1MiB section boundary
which results in va/pa translations errors when XIP_PHYS_ADDR
starts on an odd 1MiB boundary and this causes the kernel to
hang. This patch fixes ARM XIP_KERNEL translation errors... | ```diff
diff --git a/arch/arm/mm/init.c b/arch/arm/mm/init.c
index 1099af6d470a..64262bda8e54 100644
--- a/arch/arm/mm/init.c
+++ b/arch/arm/mm/init.c
@@ -434,9 +434,9 @@ static void __init devicemaps_init(struct machine_desc *mdesc)
* It is always first in the modulearea.
*/
#ifdef CONFIG_XIP_KERNEL
- map.pfn =... |
e96636ccfa373a00a0ee0558e1971baa7856d8b5 | Analyze and fix the following issue in the Linux kernel code: sh: Various nommu fixes. | Problem Details:
This fixes up some of the various outstanding nommu bugs on
SH.
Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/arch/sh/boot/compressed/Makefile b/arch/sh/boot/compressed/Makefile
index 7074267c01b7..903470429cb4 100644
--- a/arch/sh/boot/compressed/Makefile
+++ b/arch/sh/boot/compressed/Makefile
@@ -21,11 +21,17 @@ endif
CONFIG_PAGE_OFFSET ?= 0x80000000
CONFIG_MEMORY_START ?= 0x0c000000
CONFIG_BOOT_L... |
0f08f338083cc1d68788ccbccc44bd0502fc57ae | Analyze and fix the following issue in the Linux kernel code: sh: More cosmetic cleanups and trivial fixes. | Problem Details:
Nothing exciting here, just trivial fixes..
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/arch/sh/drivers/dma/dma-sh.c b/arch/sh/drivers/dma/dma-sh.c
index 40a480d20aaf..cbbe8bce3d67 100644
--- a/arch/sh/drivers/dma/dma-sh.c
+++ b/arch/sh/drivers/dma/dma-sh.c
@@ -80,21 +80,23 @@ static irqreturn_t dma_tei(int irq, void *dev_id, struct pt_regs *regs)
static int sh_dmac_request_dma(str... |
e2d1864da5bfa419a108f42c0615f69432b1b876 | Analyze and fix the following issue in the Linux kernel code: sh: G2 DMA IRQ and residue sampling. | Problem Details:
This fixes a long-standing FIXME for G2 DMA, where we finally
wire up the IRQ handler and allow for sampling remaining bytes
while in-flight.
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/arch/sh/drivers/dma/dma-g2.c b/arch/sh/drivers/dma/dma-g2.c
index 0f866f8789f0..9cb070924180 100644
--- a/arch/sh/drivers/dma/dma-g2.c
+++ b/arch/sh/drivers/dma/dma-g2.c
@@ -3,7 +3,7 @@
*
* G2 bus DMA support
*
- * Copyright (C) 2003, 2004 Paul Mundt
+ * Copyright (C) 2003 - 2006 Paul Mundt... |
ae1f19aeb715098ac06323f279383f3843429d97 | Analyze and fix the following issue in the Linux kernel code: [libata] sata_mv: fix oops by filling in missing hook | Problem Details:
Only two of three ata_port_operations structs had a ->data_xfer member,
which led to, uh, a lack of data xfer.
Signed-off-by: Jeff Garzik <jeff@garzik.org> | ```diff
diff --git a/drivers/ata/sata_mv.c b/drivers/ata/sata_mv.c
index fdce6e07ecd2..c01496df4a99 100644
--- a/drivers/ata/sata_mv.c
+++ b/drivers/ata/sata_mv.c
@@ -463,6 +463,7 @@ static const struct ata_port_operations mv_iie_ops = {
.qc_prep = mv_qc_prep_iie,
.qc_issue = mv_qc_issue,
+ .data_xfer = ata_mm... |
848dd265947c976b6340027088c090ff7f0a0b8b | Analyze and fix the following issue in the Linux kernel code: video: Update header location in hp680_bl. | Problem Details:
Trivial build fix.
Signed-off-by: Andriy Skulysh <askulysh@gmail.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/drivers/video/backlight/hp680_bl.c b/drivers/video/backlight/hp680_bl.c
index ffc72ae3ada8..fe1488374f62 100644
--- a/drivers/video/backlight/hp680_bl.c
+++ b/drivers/video/backlight/hp680_bl.c
@@ -20,7 +20,7 @@
#include <asm/cpu/dac.h>
#include <asm/hp6xx/hp6xx.h>
-#include <asm/hd64461/hd6446... |
ae31825e63e11188d96ad9c4d2d5d4e0fc798a75 | Analyze and fix the following issue in the Linux kernel code: sh: Make O= builds work again. | Problem Details:
Some of the paths were a bit broken, fix it up.
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/arch/sh/Makefile b/arch/sh/Makefile
index 50c5cc31c302..859285d47a29 100644
--- a/arch/sh/Makefile
+++ b/arch/sh/Makefile
@@ -135,17 +135,14 @@ boot := arch/sh/boot
CPPFLAGS_vmlinux.lds := -traditional
-ifneq ($(KBUILD_SRC),)
incdir-prefix := $(srctree)/include/asm-sh/
-else
-incdir-prefix :=... |
00b3aa3fc9bd827caaa859de90d9eba831b77d40 | Analyze and fix the following issue in the Linux kernel code: sh: xchg()/__xchg() always_inline fixes for gcc4. | Problem Details:
Make __xchg() a macro, so that gcc 4.0 doesn't blow up thanks to
always_inline..
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/include/asm-sh/system.h b/include/asm-sh/system.h
index 198d17e3069a..bd7dc0554b11 100644
--- a/include/asm-sh/system.h
+++ b/include/asm-sh/system.h
@@ -79,10 +79,8 @@ static inline void sched_cacheflush(void)
}
#endif
-#define xchg(ptr,x) ((__typeof__(*(ptr)))__xchg((unsigned long)(x),(ptr),s... |
f647d33f879d258de4ab2559975bd6eebda2033e | Analyze and fix the following issue in the Linux kernel code: sh: Fix split ptlock for user mappings in __do_page_fault(). | Problem Details:
There was a bug that got introduced when the split ptlock changes
went in where mm could be unintialized for user mappings, this
fixes it up..
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/arch/sh/mm/fault.c b/arch/sh/mm/fault.c
index 7a03ffe6dadd..dc461d2bc183 100644
--- a/arch/sh/mm/fault.c
+++ b/arch/sh/mm/fault.c
@@ -210,10 +210,11 @@ asmlinkage int __do_page_fault(struct pt_regs *regs, unsigned long writeaccess,
* are always mapped, whether it be due to legacy behaviour in
... |
b7e108ee63624176af85b97d4d80bef6fe099395 | Analyze and fix the following issue in the Linux kernel code: sh: BSS init bugfix and barrier in entry point. | Problem Details:
A synco is needed before we jump to start_kernel().
While we're at it, also move the sh_cpu_init() jump until after
we've zeroed BSS, as this has caused some undesirable results
in sh_cpu_init().
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/arch/sh/kernel/head.S b/arch/sh/kernel/head.S
index 00cd4708ef46..c5e363872b91 100644
--- a/arch/sh/kernel/head.S
+++ b/arch/sh/kernel/head.S
@@ -12,6 +12,17 @@
*/
#include <linux/linkage.h>
+#ifdef CONFIG_CPU_SH4A
+#define SYNCO() synco
+
+#define PREFI(label, reg) \
+ mov.l label, reg; \
+ ... |
634bf4f69b925950ddb09ef99ad7516a449a4333 | Analyze and fix the following issue in the Linux kernel code: sh: Fix libata build. | Problem Details:
Drop virt_to_bus() from sg_dma_address() so libata builds.
While we're at it, move sg_dma_address() and sg_dma_len()
from pci.h to scatterlist.h.
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/include/asm-sh/pci.h b/include/asm-sh/pci.h
index 0a523c85b11c..18a109de0f2e 100644
--- a/include/asm-sh/pci.h
+++ b/include/asm-sh/pci.h
@@ -87,15 +87,6 @@ static inline void pcibios_penalize_isa_irq(int irq, int active)
*/
#define pci_dac_dma_supported(pci_dev, mask) (0)
-/* These macros sho... |
24ab54cb49c099d691c68fdd1ac6a0c2f5177da4 | Analyze and fix the following issue in the Linux kernel code: sh: Fix TCP payload csum bug in csum_partial_copy_generic(). | Problem Details:
There's a bug in the Hitachi SuperH csum_partial_copy_generic()
implementation. If the supplied length is 1 (and several alignment
conditions are met), the function immediately branches to label 4.
However, the assembly at label 4 expects the length to be stored in
register r2. Since this has not occ... | ```diff
diff --git a/arch/sh/lib/checksum.S b/arch/sh/lib/checksum.S
index 7c50dfe68c07..cbdd0d40e545 100644
--- a/arch/sh/lib/checksum.S
+++ b/arch/sh/lib/checksum.S
@@ -202,8 +202,9 @@ ENTRY(csum_partial_copy_generic)
cmp/pz r6 ! Jump if we had at least two bytes.
bt/s 1f
clrt
+ add #2,r6 ! r6 was < 2. Deal ... |
8b395265f81817385f12e62f03f795efb732a445 | Analyze and fix the following issue in the Linux kernel code: sh: Fix fatal oops in copy_user_page() on sh4a (SH7780). | Problem Details:
We had a pretty interesting oops happening, where copy_user_page()
was down()'ing p3map_sem[] with a bogus offset (particularly, an
offset that hadn't been initialized with sema_init(), due to the
mismatch between cpu_data->dcache.n_aliases and what was assumed
based off of the old CACHE_ALIAS value).
... | ```diff
diff --git a/arch/sh/mm/pg-sh4.c b/arch/sh/mm/pg-sh4.c
index c776b60fc250..07371ed7a313 100644
--- a/arch/sh/mm/pg-sh4.c
+++ b/arch/sh/mm/pg-sh4.c
@@ -2,7 +2,7 @@
* arch/sh/mm/pg-sh4.c
*
* Copyright (C) 1999, 2000, 2002 Niibe Yutaka
- * Copyright (C) 2002 Paul Mundt
+ * Copyright (C) 2002 - 2005 Paul M... |
e7be853df79fe8ae08ba7d933bd21e1dbb0db7bc | Analyze and fix the following issue in the Linux kernel code: sh: Fix a sign extension bug in memset(). | Problem Details:
Minor sign-extension bug in SH-specific memset()..
Signed-off-by: Toshinobu Sugioka <sugioka@itonet.co.jp>
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/arch/sh/lib/memset.S b/arch/sh/lib/memset.S
index 95670090680e..af91fe2b72a6 100644
--- a/arch/sh/lib/memset.S
+++ b/arch/sh/lib/memset.S
@@ -29,6 +29,7 @@ ENTRY(memset)
bf/s 1b
mov.b r5,@-r4
2: ! make VVVV
+ extu.b r5,r5
swap.b r5,r0 ! V0
or r0,r5 ! VV
swap.w r5,r0 ! VV00
``` |
0497c8ca282915a1c36d51db33fbf2629d7346f3 | Analyze and fix the following issue in the Linux kernel code: [CPUFREQ] Fix section mismatch warning | Problem Details:
Make the sections proper and get rid of section mismatch warnings.
Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>
Signed-off-by: Dave Jones <davej@redhat.com> | ```diff
diff --git a/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c b/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c
index ea19d091fd41..a3fddc8d651d 100644
--- a/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c
+++ b/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c
@@ -396,13 +396,13 @@ static int acpi_cpufreq_early_init_acpi(void)
... |
0e37b159aa7427bf311487e3ea03d8aa5ff5956e | Analyze and fix the following issue in the Linux kernel code: [CPUFREQ] Fix cut-n-paste bug in suspend printk | Problem Details:
Signed-off-by: Dave Jones <davej@redhat.com> | ```diff
diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c
index d35a9f06ab7b..2caaf71d80c8 100644
--- a/drivers/cpufreq/cpufreq.c
+++ b/drivers/cpufreq/cpufreq.c
@@ -994,7 +994,7 @@ static int cpufreq_suspend(struct sys_device * sysdev, pm_message_t pmsg)
unsigned int cur_freq = 0;
struct cpufreq_p... |
6ae5e8d7598ce01ac0e7dab1b89894c7386a2e61 | Analyze and fix the following issue in the Linux kernel code: sh: Fix kGDB NMI handling. | Problem Details:
in_nmi shifted down a few labels, so we were inadvertently
clearing the lower byte of do_syscall_trace, badness ensues.
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/arch/sh/kernel/entry.S b/arch/sh/kernel/entry.S
index a3a717adbf43..1a05804caf37 100644
--- a/arch/sh/kernel/entry.S
+++ b/arch/sh/kernel/entry.S
@@ -644,7 +644,7 @@ skip_restore:
!
#if defined(CONFIG_KGDB_NMI)
! Clear in_nmi
- mov.l 4f, k0
+ mov.l 6f, k0
mov #0, k1
mov.b k1, @k0
#endif
`... |
765ae317ce030217af556dc46bec238dab15091e | Analyze and fix the following issue in the Linux kernel code: sh: Fixup some uninitialized spinlocks. | Problem Details:
Fix use of uninitialized spinlocks, caught with spinlock debugging..
Signed-off-by: Paul Mundt <lethal@linux-sh.org> | ```diff
diff --git a/arch/sh/kernel/semaphore.c b/arch/sh/kernel/semaphore.c
index a3c24dcbf01d..184119eeae56 100644
--- a/arch/sh/kernel/semaphore.c
+++ b/arch/sh/kernel/semaphore.c
@@ -14,7 +14,7 @@
#include <asm/semaphore.h>
#include <asm/semaphore-helper.h>
-spinlock_t semaphore_wake_lock;
+DEFINE_SPINLOCK(sema... |
c9d86d76c1cdd76d67292ab75643db66573ca7dd | Analyze and fix the following issue in the Linux kernel code: pciehp - fix wrong return value | Problem Details:
This patch fixes the problem that trying to enable already enabled
slot disables the slot by returning the proper value from
pciehp_enable_slot()/pciehp_disable_slot().
Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com>
... | ```diff
diff --git a/drivers/pci/hotplug/pciehp_ctrl.c b/drivers/pci/hotplug/pciehp_ctrl.c
index 33d198768356..41290a106bd8 100644
--- a/drivers/pci/hotplug/pciehp_ctrl.c
+++ b/drivers/pci/hotplug/pciehp_ctrl.c
@@ -762,14 +762,14 @@ int pciehp_enable_slot(struct slot *p_slot)
if (rc || !getstatus) {
info("%s: no a... |
d5cdb67236dba94496de052c9f9f431e1fc658f4 | Analyze and fix the following issue in the Linux kernel code: acpiphp: disable bridges | Problem Details:
Currently acpiphp calls pci_enable_device() against all
hot-added bridges, but acpiphp does not call pci_disable_device()
against them in hot-remove. So ioapic hot-remove would fail.
This patch fixes this issue.
Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: MUNEDA Taka... | ```diff
diff --git a/drivers/pci/hotplug/acpiphp_glue.c b/drivers/pci/hotplug/acpiphp_glue.c
index d36732cd4bad..712f02fb1cbb 100644
--- a/drivers/pci/hotplug/acpiphp_glue.c
+++ b/drivers/pci/hotplug/acpiphp_glue.c
@@ -1105,6 +1105,16 @@ static int enable_device(struct acpiphp_slot *slot)
return retval;
}
+static ... |
0dad3510ee82bcf8a380b81a2184a664a911ef9c | Analyze and fix the following issue in the Linux kernel code: acpiphp: stop bus device before acpi_bus_trim | Problem Details:
Contrary to PCI bridge hot-add, we need to follow the sequence below
for PCI bridge hot-removal.
(1) Stop devices (detach drivers, remove from the global list, etc.)
(2) Unbind ACPI node from the devices (remove the _PRT entries)
(3) Remove devices (remove from the device list, etc.)
This patch... | ```diff
diff --git a/drivers/pci/hotplug/acpiphp_glue.c b/drivers/pci/hotplug/acpiphp_glue.c
index c1001ad81ad4..d36732cd4bad 100644
--- a/drivers/pci/hotplug/acpiphp_glue.c
+++ b/drivers/pci/hotplug/acpiphp_glue.c
@@ -1129,6 +1129,9 @@ static int disable_device(struct acpiphp_slot *slot)
func->bridge = NULL;
}
... |
9b1d19ee86746618a8b43d2aaef8319c01af1514 | Analyze and fix the following issue in the Linux kernel code: acpiphp: do not initialize existing ioapics | Problem Details:
Currently acpiphp initializes all ioapics under the bus on which
hot-add event occured. It also initializes already working ioapics.
This patch fixes this bug.
Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: MUNEDA Takahiro <muneda.takahiro@jp.fujitsu.com>
Signed-off-by:... | ```diff
diff --git a/drivers/pci/hotplug/acpiphp_glue.c b/drivers/pci/hotplug/acpiphp_glue.c
index 7cc782fec70a..c1001ad81ad4 100644
--- a/drivers/pci/hotplug/acpiphp_glue.c
+++ b/drivers/pci/hotplug/acpiphp_glue.c
@@ -841,6 +841,7 @@ ioapic_add(acpi_handle handle, u32 lvl, void *context, void **rv)
static int acpip... |
b99feebe597f7b8c566048e11dbbd2d6df9abc83 | Analyze and fix the following issue in the Linux kernel code: acpiphp: initialize ioapics before starting devices | Problem Details:
Currently acpiphp initializes ioapics after starting devices,
but ioapics should be initialized before starting devices.
This patch fixes this bug.
Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: MUNEDA Takahiro <muneda.takahiro@jp.fujitsu.com>
Signed-off-by: Satoru Take... | ```diff
diff --git a/drivers/pci/hotplug/acpiphp_glue.c b/drivers/pci/hotplug/acpiphp_glue.c
index 768d0f0f450a..7cc782fec70a 100644
--- a/drivers/pci/hotplug/acpiphp_glue.c
+++ b/drivers/pci/hotplug/acpiphp_glue.c
@@ -1075,9 +1075,9 @@ static int enable_device(struct acpiphp_slot *slot)
pci_bus_assign_resources(bus)... |
287af2fbe902206fabd42ade4e94f77db900083e | Analyze and fix the following issue in the Linux kernel code: acpiphp: set hpp values before starting devices | Problem Details:
Currently acpiphp sets hpp values after starting devices, but
the values should be set before starting devices. This patch
fixes this bug.
Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: MUNEDA Takahiro <muneda.takahiro@jp.fujitsu.com>
Signed-off-by: Satoru Takeuchi <tak... | ```diff
diff --git a/drivers/pci/hotplug/acpiphp_glue.c b/drivers/pci/hotplug/acpiphp_glue.c
index be7e91662417..768d0f0f450a 100644
--- a/drivers/pci/hotplug/acpiphp_glue.c
+++ b/drivers/pci/hotplug/acpiphp_glue.c
@@ -1074,9 +1074,9 @@ static int enable_device(struct acpiphp_slot *slot)
pci_bus_assign_resources(bu... |
753388c2e91c15c12550bb20dda05ce657cfdc3e | Analyze and fix the following issue in the Linux kernel code: PCI Hotplug: cleanup pcihp skeleton code. | Problem Details:
Cleanup pcihp skeleton code.
Fix some typos and remove some unnecessary blank lines.
Signed-off-by: Satoru Takeuchi <takeuchi_satoru@jp.fujitsu.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> | ```diff
diff --git a/drivers/pci/hotplug/pcihp_skeleton.c b/drivers/pci/hotplug/pcihp_skeleton.c
index 8ad446605f75..2b9e10e38613 100644
--- a/drivers/pci/hotplug/pcihp_skeleton.c
+++ b/drivers/pci/hotplug/pcihp_skeleton.c
@@ -1,5 +1,5 @@
/*
- * PCI Hot Plug Controller Skeleton Driver - 0.2
+ * PCI Hot Plug Controller... |
b19441af185559118e8247382ea4f2f76ebffc6d | Analyze and fix the following issue in the Linux kernel code: PCI: fix __must_check warnings | Problem Details:
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> | ```diff
diff --git a/drivers/pci/bus.c b/drivers/pci/bus.c
index 5f7db9d2436e..aadaa3c8096b 100644
--- a/drivers/pci/bus.c
+++ b/drivers/pci/bus.c
@@ -77,9 +77,12 @@ pci_bus_alloc_resource(struct pci_bus *bus, struct resource *res,
* This adds a single pci device to the global
* device list and adds sysfs and procf... |
660a0e8fdf85f30b1e5f6905a78361476094eb7c | Analyze and fix the following issue in the Linux kernel code: PCI Hotplug: fix __must_check warnings | Problem Details:
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> | ```diff
diff --git a/drivers/pci/hotplug/pci_hotplug.h b/drivers/pci/hotplug/pci_hotplug.h
index e929b7c11429..772523dc3860 100644
--- a/drivers/pci/hotplug/pci_hotplug.h
+++ b/drivers/pci/hotplug/pci_hotplug.h
@@ -172,8 +172,8 @@ struct hotplug_slot {
extern int pci_hp_register (struct hotplug_slot *slot);
extern... |
e1b95dc6b1cd02c3625ba3d1d770d095d6a4b313 | Analyze and fix the following issue in the Linux kernel code: SHPCHP: fix __must_check warnings | Problem Details:
Cc: Kristen Carlson Accardi <kristen.c.accardi@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> | ```diff
diff --git a/drivers/pci/hotplug/shpchp.h b/drivers/pci/hotplug/shpchp.h
index 7208b95c6ee7..c7103ac5cd06 100644
--- a/drivers/pci/hotplug/shpchp.h
+++ b/drivers/pci/hotplug/shpchp.h
@@ -173,7 +173,7 @@ struct controller {
#define msg_button_cancel "PCI slot #%s - action canceled due to button press.\n"
/* ... |
d33b6fba2c4350651f3f61ff2ab858a2f116e9a4 | Analyze and fix the following issue in the Linux kernel code: Resources: insert identical resources above existing resources | Problem Details:
If you have two resources which aree exactly the same size,
insert_resource() currently inserts the new one below the existing one.
This is wrong because there's no way to insert a resource of the same size
above an existing one.
I took this opportunity to rewrite the initial loop to be a for-loop
in... | ```diff
diff --git a/kernel/resource.c b/kernel/resource.c
index 46286434af80..9db38a1a7520 100644
--- a/kernel/resource.c
+++ b/kernel/resource.c
@@ -344,12 +344,11 @@ EXPORT_SYMBOL(allocate_resource);
*
* Returns 0 on success, -EBUSY if the resource can't be inserted.
*
- * This function is equivalent of reques... |
7d9db67febf67dd76329a9dd8f97cf4611a8ac2e | Analyze and fix the following issue in the Linux kernel code: i2c: __must_check fixes (chip drivers) | Problem Details:
i2c: __must_check fixes (chip drivers)
Check for error on sysfs file creation.
Delete sysfs files on device removal.
The approach taken for the most complex case (pcf8591) is similar to
what Mark M. Hoffman proposed for hardware monitoring chip drivers.
Signed-off-by: Jean Delvare <khali@linux-fr.or... | ```diff
diff --git a/drivers/i2c/chips/eeprom.c b/drivers/i2c/chips/eeprom.c
index 13c108269a6d..cec3a0c3894d 100644
--- a/drivers/i2c/chips/eeprom.c
+++ b/drivers/i2c/chips/eeprom.c
@@ -209,10 +209,14 @@ static int eeprom_detect(struct i2c_adapter *adapter, int address, int kind)
}
/* create the sysfs eeprom fil... |
be53f9b2a08e647396ceaa004199ae4b032a9bd2 | Analyze and fix the following issue in the Linux kernel code: i2c: Fix copy-n-paste in subsystem Kconfig | Problem Details:
i2c: Fix copy-n-paste in subsystem Kconfig
We have:
drivers/i2c/Kconfig:2:# Character device configuration
Which is obviously not true..
Signed-off-by: Arthur Othieno <apgo@patchbomb.org>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> | ```diff
diff --git a/drivers/i2c/Kconfig b/drivers/i2c/Kconfig
index 24383afdda76..11935f66fcd8 100644
--- a/drivers/i2c/Kconfig
+++ b/drivers/i2c/Kconfig
@@ -1,5 +1,5 @@
#
-# Character device configuration
+# I2C subsystem configuration
#
menu "I2C support"
``` |
8859942ede8154c1e90e3b0d1b60aecf0cfaa169 | Analyze and fix the following issue in the Linux kernel code: i2c-au1550: Fix timeout problem | Problem Details:
i2c-au1550: Fix timeout problem
Fix from Jordan Crouse:
If the transmit and recieve FIFOS are not empty, forceably flush them
rather then waiting for them to drain on their own.
This solves at least a problem reported by Clem Taylor:
http://www.linux-mips.org/archives/linux-mips/2006-05/msg00240.html... | ```diff
diff --git a/drivers/i2c/busses/i2c-au1550.c b/drivers/i2c/busses/i2c-au1550.c
index d06edce03bf4..02a359ebc0f0 100644
--- a/drivers/i2c/busses/i2c-au1550.c
+++ b/drivers/i2c/busses/i2c-au1550.c
@@ -118,13 +118,19 @@ do_address(struct i2c_au1550_data *adap, unsigned int addr, int rd)
/* Reset the FIFOs, cle... |
defcb46ed4666095677c8f52904b9e328587a20d | Analyze and fix the following issue in the Linux kernel code: i2c: __must_check fixes, i2c-dev | Problem Details:
i2c: __must_check fixes (i2c-dev)
Check for error on sysfs file creation.
Check for error on device creation.
Delete sysfs file on device destruction.
I couldn't test this one beyond compilation, as it applies on top of
another patch in Greg's tree [1] which breaks all my systems when I
apply it (my ... | ```diff
diff --git a/drivers/i2c/i2c-dev.c b/drivers/i2c/i2c-dev.c
index 2ce083391292..567fb05aeccc 100644
--- a/drivers/i2c/i2c-dev.c
+++ b/drivers/i2c/i2c-dev.c
@@ -406,6 +406,7 @@ static struct class *i2c_dev_class;
static int i2cdev_attach_adapter(struct i2c_adapter *adap)
{
struct i2c_dev *i2c_dev;
+ int res;
... |
b119c6c952a086f74202ccda4b7ed72161bb6522 | Analyze and fix the following issue in the Linux kernel code: i2c: __must_check fixes (core drivers) | Problem Details:
i2c: __must_check fixes (core drivers)
Check for error on sysfs file creation.
Check for error on device registration.
Check for error on class device registration.
Greg, I am not familiar with completion, can you please tell me if I
need to take care of it in the error paths (as I did in this patch,... | ```diff
diff --git a/drivers/i2c/busses/i2c-isa.c b/drivers/i2c/busses/i2c-isa.c
index c3e1d3e888d7..d7486e586068 100644
--- a/drivers/i2c/busses/i2c-isa.c
+++ b/drivers/i2c/busses/i2c-isa.c
@@ -125,6 +125,8 @@ int i2c_isa_del_driver(struct i2c_driver *driver)
static int __init i2c_isa_init(void)
{
+ int err;
+
m... |
ddb4f0df0424d174567a011a176782ffa4202071 | Analyze and fix the following issue in the Linux kernel code: [IA64] CMC/CPE: Reverse the order of fetching log and checking poll threshold | Problem Details:
This patch reverses the order of fetching log from SAL and
checking poll threshold. This will fix following trivial issues:
- If SAL_GET_SATE_INFO is unbelievably slow (due to huge system
or just its silly implementation) and if it takes more than
1/5 sec, CMCI/CPEI will never switch to CMCP/CPE... | ```diff
diff --git a/arch/ia64/kernel/mca.c b/arch/ia64/kernel/mca.c
index 98f3b26d7aff..bfbd8986153b 100644
--- a/arch/ia64/kernel/mca.c
+++ b/arch/ia64/kernel/mca.c
@@ -511,9 +511,6 @@ ia64_mca_cpe_int_handler (int cpe_irq, void *arg, struct pt_regs *ptregs)
/* SAL spec states this should run w/ interrupts enabled ... |
43ed3baf623410b3fa6ca14a9d3f6deca3493c56 | Analyze and fix the following issue in the Linux kernel code: [IA64] printing support for MCA/INIT | Problem Details:
Printing message to console from MCA/INIT handler is useful,
however doing oops_in_progress = 1 in them exactly makes
something in kernel wrong. Especially it sounds ugly if
system goes wrong after returning from recoverable MCA.
This patch adds ia64_mca_printk() function that collects
messages into t... | ```diff
diff --git a/arch/ia64/kernel/mca.c b/arch/ia64/kernel/mca.c
index 2fbe4536fe18..98f3b26d7aff 100644
--- a/arch/ia64/kernel/mca.c
+++ b/arch/ia64/kernel/mca.c
@@ -54,6 +54,9 @@
*
* 2005-10-07 Keith Owens <kaos@sgi.com>
* Add notify_die() hooks.
+ *
+ * 2006-09-15 Hidetoshi Seto <seto.hidetoshi@jp.fu... |
efbf3f14204b77e6afc8c13571357173de9ab707 | Analyze and fix the following issue in the Linux kernel code: [libata] pata_serverworks: fill in ->irq_clear hook | Problem Details:
Required by libata, as it is called unconditionally.
Fixes an obvious oops.
Signed-off-by: Jeff Garzik <jeff@garzik.org> | ```diff
diff --git a/drivers/ata/pata_serverworks.c b/drivers/ata/pata_serverworks.c
index 75cc5a22da0c..d62051b8da05 100644
--- a/drivers/ata/pata_serverworks.c
+++ b/drivers/ata/pata_serverworks.c
@@ -356,6 +356,8 @@ static struct ata_port_operations serverworks_osb4_port_ops = {
.data_xfer = ata_pio_data_xfer,
... |
f5ebbeb57e4b57ac44f29ff9ec2ebde1401999d1 | Analyze and fix the following issue in the Linux kernel code: [SCSI] megaraid: Use the proper type to hold the irq number. | Problem Details:
When testing on a Unisys machine it was discovered that the megaraid driver
would not initialize as it was requesting irq 162 instead of irq 1442 it
was assigned. The problem was the irq number had been truncated by being
stored in an unsigned char.
This patches fixes that problem and the driver now ... | ```diff
diff --git a/drivers/scsi/megaraid/mega_common.h b/drivers/scsi/megaraid/mega_common.h
index 8cd0bd1d0f7c..b50e27e66024 100644
--- a/drivers/scsi/megaraid/mega_common.h
+++ b/drivers/scsi/megaraid/mega_common.h
@@ -175,7 +175,7 @@ typedef struct {
uint8_t max_lun;
uint32_t unique_id;
- uint8_t irq;
+... |
d41ba22a6d330ab1e8d3adde7d2ce9349d4e4dc7 | Analyze and fix the following issue in the Linux kernel code: [SCSI] 3w-xxxx: fix "ATA UDMA upgrade" message number | Problem Details:
sparse "defined twice" warning
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com> | ```diff
diff --git a/drivers/scsi/3w-xxxx.h b/drivers/scsi/3w-xxxx.h
index 31fe5ea15920..bbd654a2b9b1 100644
--- a/drivers/scsi/3w-xxxx.h
+++ b/drivers/scsi/3w-xxxx.h
@@ -74,7 +74,7 @@ static char *tw_aen_string[] = {
[0x00D] = "ERROR: Logical unit deleted: Unit #",
[0x00F] = "WARNING: SMART threshold exceeded: Por... |
76be12de87c4601cf35a88f83d199b940d995c62 | Analyze and fix the following issue in the Linux kernel code: [SCSI] dc395x: fix printk format warning | Problem Details:
drivers/scsi/dc395x.c:1224: warning: format '%i' expects type 'int', but argument 5 has type 'size_t'
Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com> | ```diff
diff --git a/drivers/scsi/dc395x.c b/drivers/scsi/dc395x.c
index ff2b1796fa34..9d7048176e77 100644
--- a/drivers/scsi/dc395x.c
+++ b/drivers/scsi/dc395x.c
@@ -1219,7 +1219,7 @@ static void dump_register_info(struct AdapterCtlBlk *acb,
srb, srb->cmd, srb->cmd->pid,
srb->cmd->cmnd[0], srb->cmd->devi... |
15d1f53fc7654d62af7e9b23049ae3b71f5b161c | Analyze and fix the following issue in the Linux kernel code: [SCSI] qla1280 command timeout | Problem Details:
Original patch from Ian Dall in bugzilla. Set command timeout as
specified by the SCSI layer rather than hardcode it to 30 seconds. I
have received a couple of reports of people hitting this one with
various tape configurations and the patch looks obviously correct.
... | ```diff
diff --git a/drivers/scsi/qla1280.c b/drivers/scsi/qla1280.c
index 8953991462d7..2747c8e02f83 100644
--- a/drivers/scsi/qla1280.c
+++ b/drivers/scsi/qla1280.c
@@ -2862,7 +2862,7 @@ qla1280_64bit_start_scsi(struct scsi_qla_host *ha, struct srb * sp)
memset(((char *)pkt + 8), 0, (REQUEST_ENTRY_SIZE - 8));
/... |
6460e75a104d10458817d2f5b2fbff775bf0b43a | Analyze and fix the following issue in the Linux kernel code: [SCSI] sg: fixes for large page_size | Problem Details:
This sg driver patch addresses the problem with larger
page sizes reported by Brian King in this post:
http://marc.theaimsgroup.com/?l=linux-scsi&m=115867718623631&w=2
Some other related matters are also addressed. Some of these
prevent oopses when the SG_SCATTER_SZ or scatter_elem_sz are
set to inappr... | ```diff
diff --git a/drivers/scsi/sg.c b/drivers/scsi/sg.c
index 34f9343ed0af..3f8b93188567 100644
--- a/drivers/scsi/sg.c
+++ b/drivers/scsi/sg.c
@@ -60,7 +60,7 @@ static int sg_version_num = 30534; /* 2 digits for each component */
#ifdef CONFIG_SCSI_PROC_FS
#include <linux/proc_fs.h>
-static char *sg_version_dat... |
e8216dee838c09776680a6f1a2e54d81f3cdfa14 | Analyze and fix the following issue in the Linux kernel code: [PATCH] s390: fix cmm kernel thread handling | Problem Details:
Convert cmm's usage of kernel_thread to kthread_run. Also create the
cmmthread at module load time, so it is possible to check if creation of
the thread fails.
In addition the cmmthread now gets terminated when the module gets unloaded
instead of leaving a stale kernel thread. Also check the return ... | ```diff
diff --git a/arch/s390/mm/cmm.c b/arch/s390/mm/cmm.c
index f2e00df99bae..607f50ead1fd 100644
--- a/arch/s390/mm/cmm.c
+++ b/arch/s390/mm/cmm.c
@@ -16,6 +16,7 @@
#include <linux/sysctl.h>
#include <linux/ctype.h>
#include <linux/swap.h>
+#include <linux/kthread.h>
#include <asm/pgalloc.h>
#include <asm/ua... |
6b7aaad9ba4f2a059a70014be12a921eceebfc47 | Analyze and fix the following issue in the Linux kernel code: [PATCH] uml: Fix handling of failed execs of helpers | Problem Details:
There were some bugs in handling failures to exec helper programs. errno was
passed back from the child with the wrong sign. It was also ignored. In the
case where it mattered, the errno from the (successful) read in the parent was
used instead.
Signed-off-by: Jeff Dike <jdike@addtoit.com>
Signed-o... | ```diff
diff --git a/arch/um/os-Linux/helper.c b/arch/um/os-Linux/helper.c
index 6987d1d247a2..cd15b9df5b5c 100644
--- a/arch/um/os-Linux/helper.c
+++ b/arch/um/os-Linux/helper.c
@@ -42,7 +42,7 @@ static int helper_child(void *arg)
if(data->pre_exec != NULL)
(*data->pre_exec)(data->pre_data);
execvp(argv[0], arg... |
5e1f65a67d76341795ea527d30bfdca03999d46b | Analyze and fix the following issue in the Linux kernel code: [PATCH] uml: Whitespace fixes | Problem Details:
arch/um/kernel/tlb.c had some pretty serious whitespace problems. I also
fixed some returns.
Signed-off-by: Jeff Dike <jdike@addtoit.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org> | ```diff
diff --git a/arch/um/kernel/tlb.c b/arch/um/kernel/tlb.c
index cca330edf717..54a5ff25645a 100644
--- a/arch/um/kernel/tlb.c
+++ b/arch/um/kernel/tlb.c
@@ -1,4 +1,4 @@
-/*
+/*
* Copyright (C) 2000, 2001, 2002 Jeff Dike (jdike@karaya.com)
* Licensed under the GPL
*/
@@ -16,12 +16,12 @@
#include "os.h"
... |
8f80e9466e18288df7391c9d21532c4125ac9c62 | Analyze and fix the following issue in the Linux kernel code: [PATCH] uml: Fix stack alignment | Problem Details:
Stack randomization needs to be conditional on the personality allowing it.
Signed-off-by: Jeff Dike <jdike@addtoit.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org> | ```diff
diff --git a/arch/um/kernel/process_kern.c b/arch/um/kernel/process_kern.c
index f6a5a502120b..537895d68ad1 100644
--- a/arch/um/kernel/process_kern.c
+++ b/arch/um/kernel/process_kern.c
@@ -23,6 +23,7 @@
#include "linux/proc_fs.h"
#include "linux/ptrace.h"
#include "linux/random.h"
+#include "linux/personal... |
91b165c0594ab78c64f26d26e3174e6dfd60ed9d | Analyze and fix the following issue in the Linux kernel code: [PATCH] uml: Use ARRAY_SIZE more assiduously | Problem Details:
There were a bunch of missed ARRAY_SIZE opportunities.
Also, some formatting fixes in the affected areas of code.
Signed-off-by: Jeff Dike <jdike@addtoit.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org> | ```diff
diff --git a/arch/um/drivers/chan_kern.c b/arch/um/drivers/chan_kern.c
index 7218c754505b..e82764f75e7f 100644
--- a/arch/um/drivers/chan_kern.c
+++ b/arch/um/drivers/chan_kern.c
@@ -544,7 +544,7 @@ static struct chan *parse_chan(struct line *line, char *str, int device,
ops = NULL;
data = NULL;
- for(i =... |
e1da95ae38afdcda83328300c4aed755d9fc01a6 | Analyze and fix the following issue in the Linux kernel code: [PATCH] suspend: make it possible to disable serial console suspend | Problem Details:
Hack uart_suspend_port() and uart_resume_port() so that serial console
ports are not suspended if CONFIG_DISABLE_CONSOLE_SUSPEND is set.
This makes it possible to debug the suspend and resume routines of all
device drivers as well as the lowest-level swsusp code with the help of the
serial console.
S... | ```diff
diff --git a/drivers/serial/serial_core.c b/drivers/serial/serial_core.c
index 372e47f7d596..5f7ba1adb309 100644
--- a/drivers/serial/serial_core.c
+++ b/drivers/serial/serial_core.c
@@ -1929,6 +1929,13 @@ int uart_suspend_port(struct uart_driver *drv, struct uart_port *port)
mutex_lock(&state->mutex);
+#... |
cd560bb2f9e2cd451bb3942af43da19632ba4a8e | Analyze and fix the following issue in the Linux kernel code: [PATCH] swsusp: Fix alloc_pagedir | Problem Details:
Get rid of the FIXME in kernel/power/snapshot.c#alloc_pagedir() and
simplify the functions called by it.
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Acked-by: Pavel Machek <pavel@suse.cz>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org> | ```diff
diff --git a/kernel/power/snapshot.c b/kernel/power/snapshot.c
index 7ad0c0465524..4ca372f2bc14 100644
--- a/kernel/power/snapshot.c
+++ b/kernel/power/snapshot.c
@@ -316,12 +316,12 @@ static void free_pagedir(struct pbe *pblist, int clear_nosave_free)
* fill_pb_page - Create a list of PBEs on a given memory ... |
f623f0db8e6aa86a37be86167e4ff478821a9f4f | Analyze and fix the following issue in the Linux kernel code: [PATCH] swsusp: Fix mark_free_pages | Problem Details:
Clean up mm/page_alloc.c#mark_free_pages() and make it avoid clearing
PageNosaveFree for PageNosave pages. This allows us to get rid of an ugly
hack in kernel/power/snapshot.c#copy_data_pages().
Additionally, the page-copying loop in copy_data_pages() is moved to an
inline function.
Signed-off-by: R... | ```diff
diff --git a/kernel/power/snapshot.c b/kernel/power/snapshot.c
index 81fe8de9e604..4afb7900002b 100644
--- a/kernel/power/snapshot.c
+++ b/kernel/power/snapshot.c
@@ -208,37 +208,36 @@ unsigned int count_data_pages(void)
return n;
}
+static inline void copy_data_page(long *dst, long *src)
+{
+ int n;
+
+ /... |
060ec3d52db417a4fa554b6e14594ca62418c326 | Analyze and fix the following issue in the Linux kernel code: [PATCH] alpha: Fix ALPHA_EV56 dependencies typo | Problem Details:
There appears to be a typo in the EV56 config option. NORITAKE and PRIMO are
be able to set a variation of either.
Signed-off-by: Daniel Drake <dsd@gentoo.org>
Cc: Richard Henderson <rth@twiddle.net>
Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off... | ```diff
diff --git a/arch/alpha/Kconfig b/arch/alpha/Kconfig
index 213c7850d5fb..2b36afd8e969 100644
--- a/arch/alpha/Kconfig
+++ b/arch/alpha/Kconfig
@@ -381,7 +381,7 @@ config ALPHA_EV56
config ALPHA_EV56
prompt "EV56 CPU (speed >= 333MHz)?"
- depends on ALPHA_NORITAKE && ALPHA_PRIMO
+ depends on ALPHA_NORITAKE ... |
3a750363e6075a28e5542ce93a69c620c0cfd605 | Analyze and fix the following issue in the Linux kernel code: [PATCH] Use BUG_ON(foo) instead of "if (foo) BUG()" in include/asm-i386/dma-mapping.h | Problem Details:
Signed-off-by: Rolf Eike Beer <eike-kernel@sf-tec.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org> | ```diff
diff --git a/include/asm-i386/dma-mapping.h b/include/asm-i386/dma-mapping.h
index 9cf20cacf76e..576ae01d71c8 100644
--- a/include/asm-i386/dma-mapping.h
+++ b/include/asm-i386/dma-mapping.h
@@ -21,8 +21,7 @@ static inline dma_addr_t
dma_map_single(struct device *dev, void *ptr, size_t size,
enum dma_... |
92fc707208bb2e601c24b5ab65db37bcb361b658 | Analyze and fix the following issue in the Linux kernel code: [PATCH] FRV: Fix fls() to handle bit 31 being set correctly | Problem Details:
Fix FRV fls() to handle bit 31 being set correctly (it should return 32 not 0).
Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org> | ```diff
diff --git a/include/asm-frv/bitops.h b/include/asm-frv/bitops.h
index 980ae1b0cd28..97fb746f76c7 100644
--- a/include/asm-frv/bitops.h
+++ b/include/asm-frv/bitops.h
@@ -161,16 +161,29 @@ static inline int __test_bit(int nr, const volatile void * addr)
#include <asm-generic/bitops/__ffs.h>
#include <asm-gene... |
b20c8122a3204496fca8b5343c93b60fe11dad04 | Analyze and fix the following issue in the Linux kernel code: [PATCH] selinux: fix tty locking | Problem Details:
Take tty_mutex when accessing ->signal->tty in selinux code. Noted by Alan
Cox. Longer term, we are looking at refactoring the code to provide better
encapsulation of the tty layer, but this is a simple fix that addresses the
immediate bug.
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
Acked-by... | ```diff
diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c
index 55cec4d6f117..e4d81a42fca4 100644
--- a/security/selinux/hooks.c
+++ b/security/selinux/hooks.c
@@ -1689,10 +1689,12 @@ static inline void flush_unauthorized_files(struct files_struct * files)
{
struct avc_audit_data ad;
struct file *fi... |
83e33a4711760469f5c3861b8ffea4947656d4eb | Analyze and fix the following issue in the Linux kernel code: [PATCH] zone reclaim with slab: avoid unecessary off node allocations | Problem Details:
Minor performance fix.
If we reclaimed enough slab pages from a zone then we can avoid going off
node with the current allocation. Take care of updating nr_reclaimed when
reclaiming from the slab.
Signed-off-by: Christoph Lameter <clameter@sgi.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed... | ```diff
diff --git a/mm/vmscan.c b/mm/vmscan.c
index 089e943c4d38..b950f193816e 100644
--- a/mm/vmscan.c
+++ b/mm/vmscan.c
@@ -1566,6 +1566,7 @@ static int __zone_reclaim(struct zone *zone, gfp_t gfp_mask, unsigned int order)
.gfp_mask = gfp_mask,
.swappiness = vm_swappiness,
};
+ unsigned long slab_reclaimable... |
d00bcc98d7ec2c87391c9d9e1cca519ef64d33ef | Analyze and fix the following issue in the Linux kernel code: [PATCH] Extract the allocpercpu functions from the slab allocator | Problem Details:
The allocpercpu functions __alloc_percpu and __free_percpu() are heavily
using the slab allocator. However, they are conceptually slab. This also
simplifies SLOB (at this point slob may be broken in mm. This should fix
it).
Signed-off-by: Christoph Lameter <clameter@sgi.com>
Cc: Matt Mackall <mpm@s... | ```diff
diff --git a/mm/Makefile b/mm/Makefile
index 9dd824c11eeb..60c56c0b5e10 100644
--- a/mm/Makefile
+++ b/mm/Makefile
@@ -23,4 +23,4 @@ obj-$(CONFIG_SLAB) += slab.o
obj-$(CONFIG_MEMORY_HOTPLUG) += memory_hotplug.o
obj-$(CONFIG_FS_XIP) += filemap_xip.o
obj-$(CONFIG_MIGRATION) += migrate.o
-
+obj-$(CONFIG_SMP) +=... |
d2e7b7d0aa021847c59f882b066e7d3812902870 | Analyze and fix the following issue in the Linux kernel code: [PATCH] fix potential stack overflow in mm/slab.c | Problem Details:
On High end systems (1024 or so cpus) this can potentially cause stack
overflow. Fix the stack usage.
Signed-off-by: Suresh Siddha <suresh.b.siddha@intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org> | ```diff
diff --git a/mm/slab.c b/mm/slab.c
index 2b37a62f6314..619337a5cb2b 100644
--- a/mm/slab.c
+++ b/mm/slab.c
@@ -3725,22 +3725,26 @@ static void do_ccupdate_local(void *info)
static int do_tune_cpucache(struct kmem_cache *cachep, int limit,
int batchcount, int shared)
{
- struct ccupdate_struct new;
+ stru... |
056c62418cc639bf2fe962c6a6ee56054b838bc7 | Analyze and fix the following issue in the Linux kernel code: [PATCH] slab: fix lockdep warnings | Problem Details:
Place the alien array cache locks of on slab malloc slab caches on a
seperate lockdep class. This avoids false positives from lockdep
[akpm@osdl.org: build fix]
Signed-off-by: Ravikiran Thirumalai <kiran@scalex86.org>
Signed-off-by: Shai Fultheim <shai@scalex86.org>
Cc: Thomas Gleixner <tglx@linutron... | ```diff
diff --git a/mm/slab.c b/mm/slab.c
index 3233c4c7cbce..2b37a62f6314 100644
--- a/mm/slab.c
+++ b/mm/slab.c
@@ -674,6 +674,8 @@ static struct kmem_cache cache_cache = {
#endif
};
+#define BAD_ALIEN_MAGIC 0x01020304ul
+
#ifdef CONFIG_LOCKDEP
/*
@@ -682,29 +684,53 @@ static struct kmem_cache cache_cache = ... |
dbe5e69d2d6e591996ea2b817b887d03b60bb143 | Analyze and fix the following issue in the Linux kernel code: [PATCH] slab: optimize kmalloc_node the same way as kmalloc | Problem Details:
[akpm@osdl.org: export fix]
Signed-off-by: Christoph Hellwig <hch@lst.de>
Acked-by: Christoph Lameter <clameter@sgi.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org> | ```diff
diff --git a/include/linux/slab.h b/include/linux/slab.h
index 193c03c547ec..2f6bef6a98c9 100644
--- a/include/linux/slab.h
+++ b/include/linux/slab.h
@@ -202,7 +202,30 @@ extern int slab_is_available(void);
#ifdef CONFIG_NUMA
extern void *kmem_cache_alloc_node(kmem_cache_t *, gfp_t flags, int node);
-exter... |
5081dde33f7a61d28d9b185cc386f12cb837c7a4 | Analyze and fix the following issue in the Linux kernel code: [PATCH] oom: kthread infinite loop fix | Problem Details:
Skip kernel threads, rather than having them return 0 from badness.
Theoretically, badness might truncate all results to 0, thus a kernel thread
might be picked first, causing an infinite loop.
Signed-off-by: Nick Piggin <npiggin@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Lin... | ```diff
diff --git a/mm/oom_kill.c b/mm/oom_kill.c
index f1aba7e7b760..12cd4735dc29 100644
--- a/mm/oom_kill.c
+++ b/mm/oom_kill.c
@@ -207,6 +207,9 @@ static struct task_struct *select_bad_process(unsigned long *ppoints)
unsigned long points;
int releasing;
+ /* skip kernel threads */
+ if (!p->mm)
+ contin... |
4a3ede107e422a0c53d28024b0aa902ca22a8768 | Analyze and fix the following issue in the Linux kernel code: [PATCH] oom: handle oom_disable exiting | Problem Details:
Having the oomkilladj == OOM_DISABLE check before the releasing check means
that oomkilladj == OOM_DISABLE tasks exiting will not stop the OOM killer.
Moving the test down will give the desired behaviour. Also: it will allow
them to "OOM-kill" themselves if they are exiting. As per the previous patc... | ```diff
diff --git a/mm/oom_kill.c b/mm/oom_kill.c
index 0131bae2a16d..55a05f1ef76d 100644
--- a/mm/oom_kill.c
+++ b/mm/oom_kill.c
@@ -204,8 +204,6 @@ static struct task_struct *select_bad_process(unsigned long *ppoints)
/* skip the init task with pid == 1 */
if (p->pid == 1)
continue;
- if (p->oomkilladj ==... |
50ec3bbffbe8a96347c54832d48110a5bc9e9ff8 | Analyze and fix the following issue in the Linux kernel code: [PATCH] oom: handle current exiting | Problem Details:
If current *is* exiting, it should actually be allowed to access reserved
memory rather than OOM kill something else. Can't do this via a straight
check in page_alloc.c because that would allow multiple tasks to use up
reserves. Instead cause current to OOM-kill itself which will mark it as
TIF_MEMDI... | ```diff
diff --git a/mm/oom_kill.c b/mm/oom_kill.c
index 4f815b06ac1b..0131bae2a16d 100644
--- a/mm/oom_kill.c
+++ b/mm/oom_kill.c
@@ -210,11 +210,26 @@ static struct task_struct *select_bad_process(unsigned long *ppoints)
/*
* This is in the process of releasing memory so wait for it
* to finish before kill... |
7887a3da753e1ba8244556cc9a2b38c815bfe256 | Analyze and fix the following issue in the Linux kernel code: [PATCH] oom: cpuset hint | Problem Details:
cpuset_excl_nodes_overlap does not always indicate that killing a task will
not free any memory we for us. For example, we may be asking for an
allocation from _anywhere_ in the machine, or the task in question may be
pinning memory that is outside its cpuset. Fix this by just causing
cpuset_excl_nod... | ```diff
diff --git a/mm/oom_kill.c b/mm/oom_kill.c
index 7d056843fa2d..4f815b06ac1b 100644
--- a/mm/oom_kill.c
+++ b/mm/oom_kill.c
@@ -128,6 +128,14 @@ unsigned long badness(struct task_struct *p, unsigned long uptime)
if (cap_t(p->cap_effective) & CAP_TO_MASK(CAP_SYS_RAWIO))
points /= 4;
+ /*
+ * If p's nodes ... |
6ddab3b9ebebc88bfdd8107c64f12d7e4480c559 | Analyze and fix the following issue in the Linux kernel code: [PATCH] mm: swap write failure fixup | Problem Details:
Currently we can silently drop data if the write to swap failed. It
usually doesn't result in data-corruption because on page-in the process
will receive SIGBUS (assuming write-failure implies read-failure).
This assumption might or might not be valid.
This patch will avoid the page being discarded ... | ```diff
diff --git a/mm/page_io.c b/mm/page_io.c
index 88029948d00a..d2f0a5783370 100644
--- a/mm/page_io.c
+++ b/mm/page_io.c
@@ -52,8 +52,23 @@ static int end_swap_bio_write(struct bio *bio, unsigned int bytes_done, int err)
if (bio->bi_size)
return 1;
- if (!uptodate)
+ if (!uptodate) {
SetPageError(page);... |
ca5f9703dffa012cc46166e6206c5a992910e041 | Analyze and fix the following issue in the Linux kernel code: [PATCH] slab: respect architecture and caller mandated alignment | Problem Details:
As explained by Heiko, on s390 (32-bit) ARCH_KMALLOC_MINALIGN is set to
eight because their common I/O layer allocates data structures that need to
have an eight byte alignment. This does not work when CONFIG_SLAB_DEBUG is
enabled because kmem_cache_create will override alignment to BYTES_PER_WORD
whi... | ```diff
diff --git a/mm/slab.c b/mm/slab.c
index 00584dbbec03..d47d0e186973 100644
--- a/mm/slab.c
+++ b/mm/slab.c
@@ -2096,6 +2096,15 @@ kmem_cache_create (const char *name, size_t size, size_t align,
} else {
ralign = BYTES_PER_WORD;
}
+
+ /*
+ * Redzoning and user store require word alignment. Note this will... |
28e4d965e6131ace1e813e93aebca89ac6b82dc1 | Analyze and fix the following issue in the Linux kernel code: [PATCH] mm: remove_mapping() safeness | Problem Details:
Some users of remove_mapping had been unsafe.
Modify the remove_mapping precondition to ensure the caller has locked the
page and obtained the correct mapping. Modify callers to ensure the
mapping is the correct one.
[hugh@veritas.com: swapper_space fix]
Signed-off-by: Nick Piggin <npiggin@suse.de>
... | ```diff
diff --git a/mm/vmscan.c b/mm/vmscan.c
index 41a3da3d6ccc..16180587fd7d 100644
--- a/mm/vmscan.c
+++ b/mm/vmscan.c
@@ -377,8 +377,8 @@ static pageout_t pageout(struct page *page, struct address_space *mapping)
int remove_mapping(struct address_space *mapping, struct page *page)
{
- if (!mapping)
- return 0... |
2f6726e54a9410e2e4cee864947c05e954051916 | Analyze and fix the following issue in the Linux kernel code: [PATCH] Apply type enum zone_type | Problem Details:
After we have done this we can now do some typing cleanup.
The memory policy layer keeps a policy_zone that specifies
the zone that gets memory policies applied. This variable
can now be of type enum zone_type.
The check_highest_zone function and the build_zonelists funnctionm must
then also take a e... | ```diff
diff --git a/include/linux/mempolicy.h b/include/linux/mempolicy.h
index 72440f0a443d..09f0f575ddff 100644
--- a/include/linux/mempolicy.h
+++ b/include/linux/mempolicy.h
@@ -162,9 +162,9 @@ extern struct zonelist *huge_zonelist(struct vm_area_struct *vma,
unsigned long addr);
extern unsigned slab_node(stru... |
4e4785bcf0c8503224fa6c17d8e0228de781bff6 | Analyze and fix the following issue in the Linux kernel code: [PATCH] mempolicies: fix policy_zone check | Problem Details:
There is a check in zonelist_policy that compares pieces of the bitmap
obtained from a gfp mask via GFP_ZONETYPES with a zone number in function
zonelist_policy().
The bitmap is an ORed mask of __GFP_DMA, __GFP_DMA32 and __GFP_HIGHMEM.
The policy_zone is a zone number with the possible values of ZONE_... | ```diff
diff --git a/include/linux/gfp.h b/include/linux/gfp.h
index 2a2153ebfe0b..a0992d392d79 100644
--- a/include/linux/gfp.h
+++ b/include/linux/gfp.h
@@ -85,6 +85,21 @@ static inline int gfp_zone(gfp_t gfp)
return zone;
}
+static inline enum zone_type highest_zone(gfp_t flags)
+{
+ if (flags & __GFP_DMA)
+ r... |
b9b15780f808efa2c897f337644ba7a2bec03ecc | Analyze and fix the following issue in the Linux kernel code: [PATCH] reduce MAX_NR_ZONES: fix i386 SRAT check for MAX_NR_ZONES | Problem Details:
We cannot check MAX_NR_ZONES since it not defined in the preprocessor
anymore.
So remove the check.
The maximum number of zones per node for i386 is 3 since i386 does not
support ZONE_DMA32.
Signed-off-by: Christoph Lameter <clameter@sgi.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-b... | ```diff
diff --git a/arch/i386/kernel/srat.c b/arch/i386/kernel/srat.c
index b1809c9a0899..83db411b3aa7 100644
--- a/arch/i386/kernel/srat.c
+++ b/arch/i386/kernel/srat.c
@@ -42,7 +42,7 @@
#define PXM_BITMAP_LEN (MAX_PXM_DOMAINS / 8)
static u8 pxm_bitmap[PXM_BITMAP_LEN]; /* bitmap of proximity domains */
-#define ... |
27bf71c2a7e596ed34e9bf2d4a5030321a09a1ad | Analyze and fix the following issue in the Linux kernel code: [PATCH] reduce MAX_NR_ZONES: remove display of counters for unconfigured zones | Problem Details:
eventcounters: Do not display counters for zones that are not available on an
arch
Do not define or display counters for the DMA32 and the HIGHMEM zone if such
zones were not configured.
[akpm@osdl.org: s390 fix]
[heiko.carstens@de.ibm.com: s390 fix]
Signed-off-by: Christoph Lameter <clameter@sgi.com... | ```diff
diff --git a/arch/s390/appldata/appldata_mem.c b/arch/s390/appldata/appldata_mem.c
index ab3b0765a64e..8aea3698a77b 100644
--- a/arch/s390/appldata/appldata_mem.c
+++ b/arch/s390/appldata/appldata_mem.c
@@ -117,8 +117,7 @@ static void appldata_get_mem_data(void *data)
mem_data->pgpgout = ev[PGPGOUT] >> 1;
... |
e53ef38d05dd59ed281a35590e4a5b64d8ff4c52 | Analyze and fix the following issue in the Linux kernel code: [PATCH] reduce MAX_NR_ZONES: make ZONE_HIGHMEM optional | Problem Details:
Make ZONE_HIGHMEM optional
- ifdef out code and definitions related to CONFIG_HIGHMEM
- __GFP_HIGHMEM falls back to normal allocations if there is no
ZONE_HIGHMEM
- GFP_ZONEMASK becomes 0x01 if there is no DMA32 and no HIGHMEM
zone.
[jdike@addtoit.com: build fix]
Signed-off-by: Jeff Dike <jdike... | ```diff
diff --git a/arch/um/kernel/mem.c b/arch/um/kernel/mem.c
index b39e624c3291..b1cd5c6e468b 100644
--- a/arch/um/kernel/mem.c
+++ b/arch/um/kernel/mem.c
@@ -226,7 +226,9 @@ void paging_init(void)
for(i=0;i<sizeof(zones_size)/sizeof(zones_size[0]);i++)
zones_size[i] = 0;
zones_size[ZONE_DMA] = (end_iomem >... |
fb0e7942bdcbbd2f90e61cb4cfa4fa892a873f8a | Analyze and fix the following issue in the Linux kernel code: [PATCH] reduce MAX_NR_ZONES: make ZONE_DMA32 optional | Problem Details:
Make ZONE_DMA32 optional
- Add #ifdefs around ZONE_DMA32 specific code and definitions.
- Add CONFIG_ZONE_DMA32 config option and use that for x86_64
that alone needs this zone.
- Remove the use of CONFIG_DMA_IS_DMA32 and CONFIG_DMA_IS_NORMAL
for ia64 and fix up the way per node ZVCs are calcula... | ```diff
diff --git a/arch/ia64/Kconfig b/arch/ia64/Kconfig
index db274da7dba1..f521f2f60a78 100644
--- a/arch/ia64/Kconfig
+++ b/arch/ia64/Kconfig
@@ -66,15 +66,6 @@ config IA64_UNCACHED_ALLOCATOR
bool
select GENERIC_ALLOCATOR
-config DMA_IS_DMA32
- bool
- default y
-
-config DMA_IS_NORMAL
- bool
- depends on IA6... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.