diff options
author | Felipe Balbi <felipe.lima@indt.org.br> | 2007-08-15 10:38:12 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2007-10-12 17:55:13 -0400 |
commit | 7b5cd5fefbe023625a7ff7604e8beb9a15a9efab (patch) | |
tree | 8f3e7da59962ae3f2e965de77a9cbfb65c7ecd09 /drivers/usb/misc/sisusbvga/sisusb_con.c | |
parent | ecb8b190bcf49e67a6bd955340ecc07d243b6efa (diff) |
USB: SisUSB2VGA: Convert printk to dev_* macros
This patch convert printk entries to dev_* macros, this provide better
debugging and better readability to the code.
Signed-off-by: Felipe Balbi <felipe.lima@indt.org.br>
Cc: Thomas <thomas@winischhofer.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/misc/sisusbvga/sisusb_con.c')
-rw-r--r-- | drivers/usb/misc/sisusbvga/sisusb_con.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/drivers/usb/misc/sisusbvga/sisusb_con.c b/drivers/usb/misc/sisusbvga/sisusb_con.c index 20938cd09ed4..43722e5a49d1 100644 --- a/drivers/usb/misc/sisusbvga/sisusb_con.c +++ b/drivers/usb/misc/sisusbvga/sisusb_con.c | |||
@@ -52,6 +52,7 @@ | |||
52 | #include <linux/kernel.h> | 52 | #include <linux/kernel.h> |
53 | #include <linux/signal.h> | 53 | #include <linux/signal.h> |
54 | #include <linux/fs.h> | 54 | #include <linux/fs.h> |
55 | #include <linux/usb.h> | ||
55 | #include <linux/tty.h> | 56 | #include <linux/tty.h> |
56 | #include <linux/console.h> | 57 | #include <linux/console.h> |
57 | #include <linux/string.h> | 58 | #include <linux/string.h> |
@@ -537,7 +538,7 @@ sisusbcon_switch(struct vc_data *c) | |||
537 | */ | 538 | */ |
538 | if (c->vc_origin == (unsigned long)c->vc_screenbuf) { | 539 | if (c->vc_origin == (unsigned long)c->vc_screenbuf) { |
539 | mutex_unlock(&sisusb->lock); | 540 | mutex_unlock(&sisusb->lock); |
540 | printk(KERN_DEBUG "sisusb: ASSERT ORIGIN != SCREENBUF!\n"); | 541 | dev_dbg(&sisusb->sisusb_dev->dev, "ASSERT ORIGIN != SCREENBUF!\n"); |
541 | return 0; | 542 | return 0; |
542 | } | 543 | } |
543 | 544 | ||
@@ -1428,7 +1429,7 @@ static const struct consw sisusb_dummy_con = { | |||
1428 | int | 1429 | int |
1429 | sisusb_console_init(struct sisusb_usb_data *sisusb, int first, int last) | 1430 | sisusb_console_init(struct sisusb_usb_data *sisusb, int first, int last) |
1430 | { | 1431 | { |
1431 | int i, ret, minor = sisusb->minor; | 1432 | int i, ret; |
1432 | 1433 | ||
1433 | mutex_lock(&sisusb->lock); | 1434 | mutex_lock(&sisusb->lock); |
1434 | 1435 | ||
@@ -1461,9 +1462,7 @@ sisusb_console_init(struct sisusb_usb_data *sisusb, int first, int last) | |||
1461 | /* Set up text mode (and upload default font) */ | 1462 | /* Set up text mode (and upload default font) */ |
1462 | if (sisusb_reset_text_mode(sisusb, 1)) { | 1463 | if (sisusb_reset_text_mode(sisusb, 1)) { |
1463 | mutex_unlock(&sisusb->lock); | 1464 | mutex_unlock(&sisusb->lock); |
1464 | printk(KERN_ERR | 1465 | dev_err(&sisusb->sisusb_dev->dev, "Failed to set up text mode\n"); |
1465 | "sisusbvga[%d]: Failed to set up text mode\n", | ||
1466 | minor); | ||
1467 | return 1; | 1466 | return 1; |
1468 | } | 1467 | } |
1469 | 1468 | ||
@@ -1484,9 +1483,7 @@ sisusb_console_init(struct sisusb_usb_data *sisusb, int first, int last) | |||
1484 | /* Allocate screen buffer */ | 1483 | /* Allocate screen buffer */ |
1485 | if (!(sisusb->scrbuf = (unsigned long)vmalloc(sisusb->scrbuf_size))) { | 1484 | if (!(sisusb->scrbuf = (unsigned long)vmalloc(sisusb->scrbuf_size))) { |
1486 | mutex_unlock(&sisusb->lock); | 1485 | mutex_unlock(&sisusb->lock); |
1487 | printk(KERN_ERR | 1486 | dev_err(&sisusb->sisusb_dev->dev, "Failed to allocate screen buffer\n"); |
1488 | "sisusbvga[%d]: Failed to allocate screen buffer\n", | ||
1489 | minor); | ||
1490 | return 1; | 1487 | return 1; |
1491 | } | 1488 | } |
1492 | 1489 | ||