From: Henrik Kretzschmar <henne@nachtwindheim.de>
To: jonathan@buzzard.org.uk
Cc: alan@linux.intel.com, tlinux-users@tce.toshiba-dme.co.jp,
linux-kernel@vger.kernel.org,
Henrik Kretzschmar <henne@nachtwindheim.de>
Subject: [PATCH 3/4] [DRIVERS] loglevel clenup in toshiba.c
Date: Fri, 22 Jan 2010 22:41:11 +0100 [thread overview]
Message-ID: <1264196472-5387-3-git-send-email-henne@nachtwindheim.de> (raw)
In-Reply-To: <1264196472-5387-2-git-send-email-henne@nachtwindheim.de>
Add the missing loglevels and intorduce DEV_NAME to replace the
dispersed "toshiba" s.
Signed-off-by: Henrik Kretzschmar <henne@nachtwindheim.de>
---
drivers/char/toshiba.c | 14 +++++++++-----
1 files changed, 9 insertions(+), 5 deletions(-)
diff --git a/drivers/char/toshiba.c b/drivers/char/toshiba.c
index 8e686ac..111baba 100644
--- a/drivers/char/toshiba.c
+++ b/drivers/char/toshiba.c
@@ -72,6 +72,7 @@
#include <linux/smp_lock.h>
#include <linux/toshiba.h>
+#define DRV_NAME "toshiba"
#define TOSH_MINOR_DEV 181
MODULE_LICENSE("GPL");
@@ -395,7 +396,8 @@ static int __init tosh_get_machine_id(void __iomem *bios)
value. This has been verified on a Satellite Pro 430CDT,
Tecra 750CDT, Tecra 780DVD and Satellite 310CDT. */
#if TOSH_DEBUG
- printk("toshiba: debugging ID ebx=0x%04x\n", regs.ebx);
+ printk(KERN_DEBUG DRV_NAME ": debugging ID ebx=0x%04x\n",
+ regs.ebx);
#endif
bx = 0xe6f5;
@@ -439,7 +441,8 @@ static int __init tosh_probe(void)
for (i=0;i<7;i++) {
if (readb(bios+0xe010+i)!=signature[i]) {
- printk("toshiba: not a supported Toshiba laptop\n");
+ printk(KERN_WARNING DRV_NAME
+ ": not a supported Toshiba laptop\n");
iounmap(bios);
return -ENODEV;
}
@@ -455,7 +458,8 @@ static int __init tosh_probe(void)
/* if this is not a Toshiba laptop carry flag is set and ah=0x86 */
if ((flag==1) || ((regs.eax & 0xff00)==0x8600)) {
- printk("toshiba: not a supported Toshiba laptop\n");
+ printk(KERN_WARNING DRV_NAME
+ ": not a supported Toshiba laptop\n");
iounmap(bios);
return -ENODEV;
}
@@ -523,7 +527,7 @@ static int __init toshiba_init(void)
{
struct proc_dir_entry *pde;
- pde = proc_create("toshiba", 0, NULL, &proc_toshiba_fops);
+ pde = proc_create(DRV_NAME, 0, NULL, &proc_toshiba_fops);
if (!pde) {
misc_deregister(&tosh_device);
return -ENOMEM;
@@ -536,7 +540,7 @@ static int __init toshiba_init(void)
static void __exit toshiba_exit(void)
{
- remove_proc_entry("toshiba", NULL);
+ remove_proc_entry(DRV_NAME, NULL);
misc_deregister(&tosh_device);
}
--
1.6.5
next prev parent reply other threads:[~2010-01-22 21:49 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-22 21:41 [PATCH 1/4] [DRIVERS]: add Toshiba Portege M100 Fn key port Henrik Kretzschmar
2010-01-22 21:41 ` [PATCH 2/4] [DRIVERS]: use __init in drivers/char/toshiba.c Henrik Kretzschmar
2010-01-22 21:41 ` Henrik Kretzschmar [this message]
2010-01-22 21:41 ` [PATCH 4/4] [DRIVERS] add a register dumper for debugging Henrik Kretzschmar
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1264196472-5387-3-git-send-email-henne@nachtwindheim.de \
--to=henne@nachtwindheim.de \
--cc=alan@linux.intel.com \
--cc=jonathan@buzzard.org.uk \
--cc=linux-kernel@vger.kernel.org \
--cc=tlinux-users@tce.toshiba-dme.co.jp \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®