aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char/ramoops.c
diff options
context:
space:
mode:
authorMarco Stornelli <marco.stornelli@gmail.com>2011-07-26 19:08:57 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2011-07-26 19:49:45 -0400
commit0169256e4bbf29e507cdd1df5812c093d610f1d5 (patch)
tree9eb6a08580341cc4d8499217f89063577e604d3d /drivers/char/ramoops.c
parent13aefd7293e7a697bbf452fca65e69cc1fa8a31c (diff)
ramoops: add new line to each print
Add new line to each print. Signed-off-by: Marco Stornelli <marco.stornelli@gmail.com> Reported-by: Stevie Trujillo <stevie.trujillo@gmail.com> Cc: Kyungmin Park <kyungmin.park@samsung.com> Cc: Américo Wang <xiyou.wangcong@gmail.com> Cc: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/char/ramoops.c')
-rw-r--r--drivers/char/ramoops.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/drivers/char/ramoops.c b/drivers/char/ramoops.c
index 32aa233df300..c9e1028766a4 100644
--- a/drivers/char/ramoops.c
+++ b/drivers/char/ramoops.c
@@ -19,6 +19,8 @@
19 * 19 *
20 */ 20 */
21 21
22#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
23
22#include <linux/kernel.h> 24#include <linux/kernel.h>
23#include <linux/module.h> 25#include <linux/module.h>
24#include <linux/kmsg_dump.h> 26#include <linux/kmsg_dump.h>
@@ -111,14 +113,14 @@ static int __init ramoops_probe(struct platform_device *pdev)
111 int err = -EINVAL; 113 int err = -EINVAL;
112 114
113 if (!pdata->mem_size) { 115 if (!pdata->mem_size) {
114 printk(KERN_ERR "ramoops: invalid size specification"); 116 pr_err("invalid size specification\n");
115 goto fail3; 117 goto fail3;
116 } 118 }
117 119
118 rounddown_pow_of_two(pdata->mem_size); 120 rounddown_pow_of_two(pdata->mem_size);
119 121
120 if (pdata->mem_size < RECORD_SIZE) { 122 if (pdata->mem_size < RECORD_SIZE) {
121 printk(KERN_ERR "ramoops: size too small"); 123 pr_err("size too small\n");
122 goto fail3; 124 goto fail3;
123 } 125 }
124 126
@@ -128,21 +130,21 @@ static int __init ramoops_probe(struct platform_device *pdev)
128 cxt->phys_addr = pdata->mem_address; 130 cxt->phys_addr = pdata->mem_address;
129 131
130 if (!request_mem_region(cxt->phys_addr, cxt->size, "ramoops")) { 132 if (!request_mem_region(cxt->phys_addr, cxt->size, "ramoops")) {
131 printk(KERN_ERR "ramoops: request mem region failed"); 133 pr_err("request mem region failed\n");
132 err = -EINVAL; 134 err = -EINVAL;
133 goto fail3; 135 goto fail3;
134 } 136 }
135 137
136 cxt->virt_addr = ioremap(cxt->phys_addr, cxt->size); 138 cxt->virt_addr = ioremap(cxt->phys_addr, cxt->size);
137 if (!cxt->virt_addr) { 139 if (!cxt->virt_addr) {
138 printk(KERN_ERR "ramoops: ioremap failed"); 140 pr_err("ioremap failed\n");
139 goto fail2; 141 goto fail2;
140 } 142 }
141 143
142 cxt->dump.dump = ramoops_do_dump; 144 cxt->dump.dump = ramoops_do_dump;
143 err = kmsg_dump_register(&cxt->dump); 145 err = kmsg_dump_register(&cxt->dump);
144 if (err) { 146 if (err) {
145 printk(KERN_ERR "ramoops: registering kmsg dumper failed"); 147 pr_err("registering kmsg dumper failed\n");
146 goto fail1; 148 goto fail1;
147 } 149 }
148 150
@@ -161,7 +163,7 @@ static int __exit ramoops_remove(struct platform_device *pdev)
161 struct ramoops_context *cxt = &oops_cxt; 163 struct ramoops_context *cxt = &oops_cxt;
162 164
163 if (kmsg_dump_unregister(&cxt->dump) < 0) 165 if (kmsg_dump_unregister(&cxt->dump) < 0)
164 printk(KERN_WARNING "ramoops: could not unregister kmsg_dumper"); 166 pr_warn("could not unregister kmsg_dumper\n");
165 167
166 iounmap(cxt->virt_addr); 168 iounmap(cxt->virt_addr);
167 release_mem_region(cxt->phys_addr, cxt->size); 169 release_mem_region(cxt->phys_addr, cxt->size);
@@ -185,6 +187,7 @@ static int __init ramoops_init(void)
185 * If we didn't find a platform device, we use module parameters 187 * If we didn't find a platform device, we use module parameters
186 * building platform data on the fly. 188 * building platform data on the fly.
187 */ 189 */
190 pr_info("platform device not found, using module parameters\n");
188 dummy_data = kzalloc(sizeof(struct ramoops_platform_data), 191 dummy_data = kzalloc(sizeof(struct ramoops_platform_data),
189 GFP_KERNEL); 192 GFP_KERNEL);
190 if (!dummy_data) 193 if (!dummy_data)