summaryrefslogtreecommitdiffstats
path: root/drivers/block/zram/zcomp.h
diff options
context:
space:
mode:
authorAnna-Maria Gleixner <anna-maria@linutronix.de>2016-11-27 00:13:46 +0100
committerThomas Gleixner <tglx@linutronix.de>2016-12-02 00:52:39 +0100
commit1dd6c834fa4a75a86fecefb6d1f1525f1cb755c7 (patch)
tree1f2cc168f44a5d4ff4e0c4aa8b3c9318249053b4 /drivers/block/zram/zcomp.h
parent3f7cd919f3df05918535de39273174710409eb40 (diff)
downloadop-kernel-dev-1dd6c834fa4a75a86fecefb6d1f1525f1cb755c7.zip
op-kernel-dev-1dd6c834fa4a75a86fecefb6d1f1525f1cb755c7.tar.gz
zram: Convert to hotplug state machine
Install the callbacks via the state machine with multi instance support and let the core invoke the callbacks on the already online CPUs. [bigeasy: wire up the multi instance stuff] Signed-off-by: Anna-Maria Gleixner <anna-maria@linutronix.de> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> Cc: Minchan Kim <minchan@kernel.org> Cc: rt@linutronix.de Cc: Nitin Gupta <ngupta@vflare.org> Link: http://lkml.kernel.org/r/20161126231350.10321-19-bigeasy@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'drivers/block/zram/zcomp.h')
-rw-r--r--drivers/block/zram/zcomp.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/block/zram/zcomp.h b/drivers/block/zram/zcomp.h
index 478cac2..41c1002 100644
--- a/drivers/block/zram/zcomp.h
+++ b/drivers/block/zram/zcomp.h
@@ -19,11 +19,12 @@ struct zcomp_strm {
/* dynamic per-device compression frontend */
struct zcomp {
struct zcomp_strm * __percpu *stream;
- struct notifier_block notifier;
-
const char *name;
+ struct hlist_node node;
};
+int zcomp_cpu_up_prepare(unsigned int cpu, struct hlist_node *node);
+int zcomp_cpu_dead(unsigned int cpu, struct hlist_node *node);
ssize_t zcomp_available_show(const char *comp, char *buf);
bool zcomp_available_algorithm(const char *comp);
OpenPOWER on IntegriCloud