Skip to content

Commit 3947be1

Browse files
hansendcLinus Torvalds
authored andcommitted
[PATCH] memory hotplug: sysfs and add/remove functions
This adds generic memory add/remove and supporting functions for memory hotplug into a new file as well as a memory hotplug kernel config option. Individual architecture patches will follow. For now, disable memory hotplug when swsusp is enabled. There's a lot of churn there right now. We'll fix it up properly once it calms down. Signed-off-by: Matt Tolentino <[email protected]> Signed-off-by: Dave Hansen <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
1 parent bdc8cb9 commit 3947be1

File tree

10 files changed

+777
-3
lines changed

10 files changed

+777
-3
lines changed

drivers/base/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ obj-y := core.o sys.o bus.o dd.o \
77
obj-y += power/
88
obj-$(CONFIG_FW_LOADER) += firmware_class.o
99
obj-$(CONFIG_NUMA) += node.o
10+
obj-$(CONFIG_MEMORY_HOTPLUG) += memory.o
1011

1112
ifeq ($(CONFIG_DEBUG_DRIVER),y)
1213
EXTRA_CFLAGS += -DDEBUG

drivers/base/init.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99

1010
#include <linux/device.h>
1111
#include <linux/init.h>
12+
#include <linux/memory.h>
1213

1314
#include "base.h"
1415

@@ -33,5 +34,6 @@ void __init driver_init(void)
3334
platform_bus_init();
3435
system_bus_init();
3536
cpu_dev_init();
37+
memory_dev_init();
3638
attribute_container_init();
3739
}

0 commit comments

Comments
 (0)