2007-08-22 21:13:00

by Satyam Sharma

[permalink] [raw]
Subject: [PATCH] ll_rw_blk: blk_cpu_notifier should be __cpuinitdata



On Mon, 20 Aug 2007, Andrew Morton wrote:
>
> <looks at blk_cpu_notifier>
>
> There are a few things to clear up here...

Patch below:


blk_cpu_notifier is marked as __devinitdata, but __devinitdata need not
be __init even if HOTPLUG_CPU=n, which wastes space. It should be marked
__cpuinitdata, and the callback itself as __cpuinit.

Signed-off-by: Satyam Sharma <[email protected]>

---

block/ll_rw_blk.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/block/ll_rw_blk.c b/block/ll_rw_blk.c
index a15845c..91ec907 100644
--- a/block/ll_rw_blk.c
+++ b/block/ll_rw_blk.c
@@ -3563,7 +3563,7 @@ static void blk_done_softirq(struct softirq_action *h)
}
}

-static int blk_cpu_notify(struct notifier_block *self, unsigned long action,
+static int __cpuinit blk_cpu_notify(struct notifier_block *self, unsigned long action,
void *hcpu)
{
/*
@@ -3584,7 +3584,7 @@ static int blk_cpu_notify(struct notifier_block *self, unsigned long action,
}


-static struct notifier_block __devinitdata blk_cpu_notifier = {
+static struct notifier_block blk_cpu_notifier __cpuinitdata = {
.notifier_call = blk_cpu_notify,
};