diff options
Diffstat (limited to 'fs/pstore')
-rw-r--r-- | fs/pstore/blk.c | 2 | ||||
-rw-r--r-- | fs/pstore/platform.c | 1 | ||||
-rw-r--r-- | fs/pstore/ram.c | 14 |
3 files changed, 16 insertions, 1 deletions
diff --git a/fs/pstore/blk.c b/fs/pstore/blk.c index de8cf5d75f34..65b2473e22ff 100644 --- a/fs/pstore/blk.c +++ b/fs/pstore/blk.c @@ -241,7 +241,7 @@ err: /* get information of pstore/blk */ int pstore_blk_get_config(struct pstore_blk_config *info) { - strncpy(info->device, blkdev, 80); + strscpy(info->device, blkdev); info->max_reason = max_reason; info->kmsg_size = check_size(kmsg_size, 4096); info->pmsg_size = check_size(pmsg_size, 4096); diff --git a/fs/pstore/platform.c b/fs/pstore/platform.c index 7f5810589a26..9c6b7c97fa3c 100644 --- a/fs/pstore/platform.c +++ b/fs/pstore/platform.c @@ -761,4 +761,5 @@ static void __exit pstore_exit(void) module_exit(pstore_exit) MODULE_AUTHOR("Tony Luck <tony.luck@intel.com>"); +MODULE_DESCRIPTION("Persistent Storage - platform driver interface"); MODULE_LICENSE("GPL"); diff --git a/fs/pstore/ram.c b/fs/pstore/ram.c index b1a455f42e93..4311fcbc84f2 100644 --- a/fs/pstore/ram.c +++ b/fs/pstore/ram.c @@ -50,6 +50,10 @@ module_param_hw(mem_address, ullong, other, 0400); MODULE_PARM_DESC(mem_address, "start of reserved RAM used to store oops/panic logs"); +static char *mem_name; +module_param_named(mem_name, mem_name, charp, 0400); +MODULE_PARM_DESC(mem_name, "name of kernel param that holds addr"); + static ulong mem_size; module_param(mem_size, ulong, 0400); MODULE_PARM_DESC(mem_size, @@ -914,6 +918,16 @@ static void __init ramoops_register_dummy(void) { struct ramoops_platform_data pdata; + if (mem_name) { + phys_addr_t start; + phys_addr_t size; + + if (reserve_mem_find_by_name(mem_name, &start, &size)) { + mem_address = start; + mem_size = size; + } + } + /* * Prepare a dummy platform data structure to carry the module * parameters. If mem_size isn't set, then there are no module |