aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char
diff options
context:
space:
mode:
authorSergiu Iordache <sergiu@chromium.org>2011-08-03 19:21:09 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2011-08-03 20:25:21 -0400
commitf7b9fcbbc3b8593ff7dc587f90c2fe90a2fd1e6f (patch)
tree8f025aefd6cd80d5b1062b43668553c2a2296c5a /drivers/char
parentf2d34fd9435c7e60cb5189d036efe9abfc911862 (diff)
ramoops: update module parameters
Update the module parameters when platform data is used. This means that they can be read from /sys/module/ramoops/parameters in order to parse the memory area. Signed-off-by: Sergiu Iordache <sergiu@chromium.org> Cc: Marco Stornelli <marco.stornelli@gmail.com> Cc: Seiji Aguchi <seiji.aguchi@hds.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/char')
-rw-r--r--drivers/char/ramoops.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/char/ramoops.c b/drivers/char/ramoops.c
index fca0c51bbc9..810aff9e750 100644
--- a/drivers/char/ramoops.c
+++ b/drivers/char/ramoops.c
@@ -147,6 +147,14 @@ static int __init ramoops_probe(struct platform_device *pdev)
147 cxt->phys_addr = pdata->mem_address; 147 cxt->phys_addr = pdata->mem_address;
148 cxt->record_size = pdata->record_size; 148 cxt->record_size = pdata->record_size;
149 cxt->dump_oops = pdata->dump_oops; 149 cxt->dump_oops = pdata->dump_oops;
150 /*
151 * Update the module parameter variables as well so they are visible
152 * through /sys/module/ramoops/parameters/
153 */
154 mem_size = pdata->mem_size;
155 mem_address = pdata->mem_address;
156 record_size = pdata->record_size;
157 dump_oops = pdata->dump_oops;
150 158
151 if (!request_mem_region(cxt->phys_addr, cxt->size, "ramoops")) { 159 if (!request_mem_region(cxt->phys_addr, cxt->size, "ramoops")) {
152 pr_err("request mem region failed\n"); 160 pr_err("request mem region failed\n");