summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2013-08-28 19:31:33 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2013-08-28 19:31:33 -0700
commitc95389b4cd6a4b52af78bea706a274453e886251 (patch)
tree01e0046bdef0121e57ebecbead1d757494dcbd13 /drivers
parent98474236f72e5a8b89c14cd7c74f0bb77a4b1a99 (diff)
parent49fa8140e487b492da24c76ac3cccad0a0ae63e4 (diff)
Merge branch 'akpm' (patches from Andrew Morton)
Merge fixes from Andrew Morton: "Five fixes. err, make that six. let me try again" * emailed patches from Andrew Morton <akpm@linux-foundation.org>: fs/ocfs2/super.c: Use bigger nodestr to accomodate 32-bit node numbers memcg: check that kmem_cache has memcg_params before accessing it drivers/base/memory.c: fix show_mem_removable() to handle missing sections IPC: bugfix for msgrcv with msgtyp < 0 Omnikey Cardman 4000: pull in ioctl.h in user header timer_list: correct the iterator for timer_list
Diffstat (limited to 'drivers')
-rw-r--r--drivers/base/memory.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/base/memory.c b/drivers/base/memory.c
index 2b7813ec6d0..ec386ee9cb2 100644
--- a/drivers/base/memory.c
+++ b/drivers/base/memory.c
@@ -141,6 +141,8 @@ static ssize_t show_mem_removable(struct device *dev,
container_of(dev, struct memory_block, dev);
for (i = 0; i < sections_per_block; i++) {
+ if (!present_section_nr(mem->start_section_nr + i))
+ continue;
pfn = section_nr_to_pfn(mem->start_section_nr + i);
ret &= is_mem_section_removable(pfn, PAGES_PER_SECTION);
}