diff options
author | Joe Perches <joe@perches.com> | 2011-03-29 18:21:40 -0400 |
---|---|---|
committer | Matthew Garrett <mjg@redhat.com> | 2011-05-27 12:35:48 -0400 |
commit | 611f5763fd0e38f896aa38346d4bc3f5c388b608 (patch) | |
tree | 4723648711ba28168057eb96b563ff807cf633ee /drivers/platform | |
parent | 77bad7c830e20085deba6a760ce85c13ecb12f4d (diff) |
hdaps: Convert printks to pr_<level>
Added pr_fmt, converted printks and removed
hard coded prefixes.
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Matthew Garrett <mjg@redhat.com>
Diffstat (limited to 'drivers/platform')
-rw-r--r-- | drivers/platform/x86/hdaps.c | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/drivers/platform/x86/hdaps.c b/drivers/platform/x86/hdaps.c index 067bf36d32f3..5a34973dc164 100644 --- a/drivers/platform/x86/hdaps.c +++ b/drivers/platform/x86/hdaps.c | |||
@@ -26,6 +26,8 @@ | |||
26 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA | 26 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA |
27 | */ | 27 | */ |
28 | 28 | ||
29 | #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt | ||
30 | |||
29 | #include <linux/delay.h> | 31 | #include <linux/delay.h> |
30 | #include <linux/platform_device.h> | 32 | #include <linux/platform_device.h> |
31 | #include <linux/input-polldev.h> | 33 | #include <linux/input-polldev.h> |
@@ -238,7 +240,7 @@ static int hdaps_device_init(void) | |||
238 | __check_latch(0x1611, 0x01)) | 240 | __check_latch(0x1611, 0x01)) |
239 | goto out; | 241 | goto out; |
240 | 242 | ||
241 | printk(KERN_DEBUG "hdaps: initial latch check good (0x%02x).\n", | 243 | printk(KERN_DEBUG "hdaps: initial latch check good (0x%02x)\n", |
242 | __get_latch(0x1611)); | 244 | __get_latch(0x1611)); |
243 | 245 | ||
244 | outb(0x17, 0x1610); | 246 | outb(0x17, 0x1610); |
@@ -299,7 +301,7 @@ static int hdaps_probe(struct platform_device *dev) | |||
299 | if (ret) | 301 | if (ret) |
300 | return ret; | 302 | return ret; |
301 | 303 | ||
302 | printk(KERN_INFO "hdaps: device successfully initialized.\n"); | 304 | pr_info("device successfully initialized\n"); |
303 | return 0; | 305 | return 0; |
304 | } | 306 | } |
305 | 307 | ||
@@ -480,7 +482,7 @@ static struct attribute_group hdaps_attribute_group = { | |||
480 | /* hdaps_dmi_match - found a match. return one, short-circuiting the hunt. */ | 482 | /* hdaps_dmi_match - found a match. return one, short-circuiting the hunt. */ |
481 | static int __init hdaps_dmi_match(const struct dmi_system_id *id) | 483 | static int __init hdaps_dmi_match(const struct dmi_system_id *id) |
482 | { | 484 | { |
483 | printk(KERN_INFO "hdaps: %s detected.\n", id->ident); | 485 | pr_info("%s detected\n", id->ident); |
484 | return 1; | 486 | return 1; |
485 | } | 487 | } |
486 | 488 | ||
@@ -488,8 +490,7 @@ static int __init hdaps_dmi_match(const struct dmi_system_id *id) | |||
488 | static int __init hdaps_dmi_match_invert(const struct dmi_system_id *id) | 490 | static int __init hdaps_dmi_match_invert(const struct dmi_system_id *id) |
489 | { | 491 | { |
490 | hdaps_invert = (unsigned long)id->driver_data; | 492 | hdaps_invert = (unsigned long)id->driver_data; |
491 | printk(KERN_INFO "hdaps: inverting axis (%u) readings.\n", | 493 | pr_info("inverting axis (%u) readings\n", hdaps_invert); |
492 | hdaps_invert); | ||
493 | return hdaps_dmi_match(id); | 494 | return hdaps_dmi_match(id); |
494 | } | 495 | } |
495 | 496 | ||
@@ -543,7 +544,7 @@ static int __init hdaps_init(void) | |||
543 | int ret; | 544 | int ret; |
544 | 545 | ||
545 | if (!dmi_check_system(hdaps_whitelist)) { | 546 | if (!dmi_check_system(hdaps_whitelist)) { |
546 | printk(KERN_WARNING "hdaps: supported laptop not found!\n"); | 547 | pr_warn("supported laptop not found!\n"); |
547 | ret = -ENODEV; | 548 | ret = -ENODEV; |
548 | goto out; | 549 | goto out; |
549 | } | 550 | } |
@@ -595,7 +596,7 @@ static int __init hdaps_init(void) | |||
595 | if (ret) | 596 | if (ret) |
596 | goto out_idev; | 597 | goto out_idev; |
597 | 598 | ||
598 | printk(KERN_INFO "hdaps: driver successfully loaded.\n"); | 599 | pr_info("driver successfully loaded\n"); |
599 | return 0; | 600 | return 0; |
600 | 601 | ||
601 | out_idev: | 602 | out_idev: |
@@ -609,7 +610,7 @@ out_driver: | |||
609 | out_region: | 610 | out_region: |
610 | release_region(HDAPS_LOW_PORT, HDAPS_NR_PORTS); | 611 | release_region(HDAPS_LOW_PORT, HDAPS_NR_PORTS); |
611 | out: | 612 | out: |
612 | printk(KERN_WARNING "hdaps: driver init failed (ret=%d)!\n", ret); | 613 | pr_warn("driver init failed (ret=%d)!\n", ret); |
613 | return ret; | 614 | return ret; |
614 | } | 615 | } |
615 | 616 | ||
@@ -622,7 +623,7 @@ static void __exit hdaps_exit(void) | |||
622 | platform_driver_unregister(&hdaps_driver); | 623 | platform_driver_unregister(&hdaps_driver); |
623 | release_region(HDAPS_LOW_PORT, HDAPS_NR_PORTS); | 624 | release_region(HDAPS_LOW_PORT, HDAPS_NR_PORTS); |
624 | 625 | ||
625 | printk(KERN_INFO "hdaps: driver unloaded.\n"); | 626 | pr_info("driver unloaded\n"); |
626 | } | 627 | } |
627 | 628 | ||
628 | module_init(hdaps_init); | 629 | module_init(hdaps_init); |