diff options
author | Joe Perches <joe@perches.com> | 2011-01-31 11:39:24 -0500 |
---|---|---|
committer | Jeff Garzik <jgarzik@pobox.com> | 2011-03-14 02:56:31 -0400 |
commit | 8d7b1c70b3c1aac4b63109f5c73f732f1d63fad6 (patch) | |
tree | 0b09875f032489c28efe29828d7faae2d61afaa8 /drivers/ata/pata_hpt37x.c | |
parent | a17139b6f63709b2d409c027f8ab401f5aa136d3 (diff) |
ata: pata: Convert pr_*(DRV_NAME ...) to pr_fmt/pr_<level>
Commit 40d69ba029c8d5de51aaeb5358999266c482d00a
("pata_hpt{37x|3x2n}: use pr_*(DRV_NAME ...) instead of printk(KERN_* ...)")
used pr_<level>.
Add #define pr_fmt and remove DRV_NAME.
Increment driver version numbers.
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Diffstat (limited to 'drivers/ata/pata_hpt37x.c')
-rw-r--r-- | drivers/ata/pata_hpt37x.c | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/drivers/ata/pata_hpt37x.c b/drivers/ata/pata_hpt37x.c index 4c5b5183225e..9620636aa405 100644 --- a/drivers/ata/pata_hpt37x.c +++ b/drivers/ata/pata_hpt37x.c | |||
@@ -14,6 +14,8 @@ | |||
14 | * Look into engine reset on timeout errors. Should not be required. | 14 | * Look into engine reset on timeout errors. Should not be required. |
15 | */ | 15 | */ |
16 | 16 | ||
17 | #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt | ||
18 | |||
17 | #include <linux/kernel.h> | 19 | #include <linux/kernel.h> |
18 | #include <linux/module.h> | 20 | #include <linux/module.h> |
19 | #include <linux/pci.h> | 21 | #include <linux/pci.h> |
@@ -24,7 +26,7 @@ | |||
24 | #include <linux/libata.h> | 26 | #include <linux/libata.h> |
25 | 27 | ||
26 | #define DRV_NAME "pata_hpt37x" | 28 | #define DRV_NAME "pata_hpt37x" |
27 | #define DRV_VERSION "0.6.22" | 29 | #define DRV_VERSION "0.6.23" |
28 | 30 | ||
29 | struct hpt_clock { | 31 | struct hpt_clock { |
30 | u8 xfer_speed; | 32 | u8 xfer_speed; |
@@ -229,8 +231,8 @@ static int hpt_dma_blacklisted(const struct ata_device *dev, char *modestr, | |||
229 | 231 | ||
230 | while (list[i] != NULL) { | 232 | while (list[i] != NULL) { |
231 | if (!strcmp(list[i], model_num)) { | 233 | if (!strcmp(list[i], model_num)) { |
232 | pr_warning(DRV_NAME ": %s is not supported for %s.\n", | 234 | pr_warn("%s is not supported for %s\n", |
233 | modestr, list[i]); | 235 | modestr, list[i]); |
234 | return 1; | 236 | return 1; |
235 | } | 237 | } |
236 | i++; | 238 | i++; |
@@ -863,8 +865,8 @@ static int hpt37x_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
863 | chip_table = &hpt372; | 865 | chip_table = &hpt372; |
864 | break; | 866 | break; |
865 | default: | 867 | default: |
866 | pr_err(DRV_NAME ": Unknown HPT366 subtype, " | 868 | pr_err("Unknown HPT366 subtype, please report (%d)\n", |
867 | "please report (%d).\n", rev); | 869 | rev); |
868 | return -ENODEV; | 870 | return -ENODEV; |
869 | } | 871 | } |
870 | break; | 872 | break; |
@@ -904,8 +906,7 @@ static int hpt37x_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
904 | *ppi = &info_hpt374_fn1; | 906 | *ppi = &info_hpt374_fn1; |
905 | break; | 907 | break; |
906 | default: | 908 | default: |
907 | pr_err(DRV_NAME ": PCI table is bogus, please report (%d).\n", | 909 | pr_err("PCI table is bogus, please report (%d)\n", dev->device); |
908 | dev->device); | ||
909 | return -ENODEV; | 910 | return -ENODEV; |
910 | } | 911 | } |
911 | /* Ok so this is a chip we support */ | 912 | /* Ok so this is a chip we support */ |
@@ -953,7 +954,7 @@ static int hpt37x_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
953 | u8 sr; | 954 | u8 sr; |
954 | u32 total = 0; | 955 | u32 total = 0; |
955 | 956 | ||
956 | pr_warning(DRV_NAME ": BIOS has not set timing clocks.\n"); | 957 | pr_warn("BIOS has not set timing clocks\n"); |
957 | 958 | ||
958 | /* This is the process the HPT371 BIOS is reported to use */ | 959 | /* This is the process the HPT371 BIOS is reported to use */ |
959 | for (i = 0; i < 128; i++) { | 960 | for (i = 0; i < 128; i++) { |
@@ -1009,7 +1010,7 @@ static int hpt37x_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
1009 | (f_high << 16) | f_low | 0x100); | 1010 | (f_high << 16) | f_low | 0x100); |
1010 | } | 1011 | } |
1011 | if (adjust == 8) { | 1012 | if (adjust == 8) { |
1012 | pr_err(DRV_NAME ": DPLL did not stabilize!\n"); | 1013 | pr_err("DPLL did not stabilize!\n"); |
1013 | return -ENODEV; | 1014 | return -ENODEV; |
1014 | } | 1015 | } |
1015 | if (dpll == 3) | 1016 | if (dpll == 3) |
@@ -1017,7 +1018,7 @@ static int hpt37x_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
1017 | else | 1018 | else |
1018 | private_data = (void *)hpt37x_timings_50; | 1019 | private_data = (void *)hpt37x_timings_50; |
1019 | 1020 | ||
1020 | pr_info(DRV_NAME ": bus clock %dMHz, using %dMHz DPLL.\n", | 1021 | pr_info("bus clock %dMHz, using %dMHz DPLL\n", |
1021 | MHz[clock_slot], MHz[dpll]); | 1022 | MHz[clock_slot], MHz[dpll]); |
1022 | } else { | 1023 | } else { |
1023 | private_data = (void *)chip_table->clocks[clock_slot]; | 1024 | private_data = (void *)chip_table->clocks[clock_slot]; |
@@ -1032,7 +1033,7 @@ static int hpt37x_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
1032 | if (clock_slot < 2 && ppi[0] == &info_hpt370a) | 1033 | if (clock_slot < 2 && ppi[0] == &info_hpt370a) |
1033 | ppi[0] = &info_hpt370a_33; | 1034 | ppi[0] = &info_hpt370a_33; |
1034 | 1035 | ||
1035 | pr_info(DRV_NAME ": %s using %dMHz bus clock.\n", | 1036 | pr_info("%s using %dMHz bus clock\n", |
1036 | chip_table->name, MHz[clock_slot]); | 1037 | chip_table->name, MHz[clock_slot]); |
1037 | } | 1038 | } |
1038 | 1039 | ||