diff options
author | Levente Kurusa <levex@linux.com> | 2013-10-01 13:56:48 -0400 |
---|---|---|
committer | Tejun Heo <tj@kernel.org> | 2013-10-13 16:17:48 -0400 |
commit | 89951f2245e5c31d6b74dea1570db716175a74fe (patch) | |
tree | 27673fef102006d862006d1f691d62c29231a2c1 /drivers/ata | |
parent | ed08d40cdec45f3f1071fa4679127d4b76dc8986 (diff) |
ata_piix: minor typo and a printk fix
The patch fixes a printk() being cut in half, some typos
and a change in comments to better reflect the specs.
Signed-off-by: Levente Kurusa <levex@linux.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'drivers/ata')
-rw-r--r-- | drivers/ata/ata_piix.c | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/drivers/ata/ata_piix.c b/drivers/ata/ata_piix.c index 513ad7ed0c99..6334c8d7c3f1 100644 --- a/drivers/ata/ata_piix.c +++ b/drivers/ata/ata_piix.c | |||
@@ -100,7 +100,7 @@ | |||
100 | 100 | ||
101 | enum { | 101 | enum { |
102 | PIIX_IOCFG = 0x54, /* IDE I/O configuration register */ | 102 | PIIX_IOCFG = 0x54, /* IDE I/O configuration register */ |
103 | ICH5_PMR = 0x90, /* port mapping register */ | 103 | ICH5_PMR = 0x90, /* address map register */ |
104 | ICH5_PCS = 0x92, /* port control and status */ | 104 | ICH5_PCS = 0x92, /* port control and status */ |
105 | PIIX_SIDPR_BAR = 5, | 105 | PIIX_SIDPR_BAR = 5, |
106 | PIIX_SIDPR_LEN = 16, | 106 | PIIX_SIDPR_LEN = 16, |
@@ -233,7 +233,7 @@ static const struct pci_device_id piix_pci_tbl[] = { | |||
233 | PCI_CLASS_STORAGE_IDE << 8, 0xffff00, ich6m_sata }, | 233 | PCI_CLASS_STORAGE_IDE << 8, 0xffff00, ich6m_sata }, |
234 | /* 82801GB/GR/GH (ICH7, identical to ICH6) */ | 234 | /* 82801GB/GR/GH (ICH7, identical to ICH6) */ |
235 | { 0x8086, 0x27c0, PCI_ANY_ID, PCI_ANY_ID, 0, 0, ich6_sata }, | 235 | { 0x8086, 0x27c0, PCI_ANY_ID, PCI_ANY_ID, 0, 0, ich6_sata }, |
236 | /* 2801GBM/GHM (ICH7M, identical to ICH6M) */ | 236 | /* 82801GBM/GHM (ICH7M, identical to ICH6M) */ |
237 | { 0x8086, 0x27c4, PCI_ANY_ID, PCI_ANY_ID, 0, 0, ich6m_sata }, | 237 | { 0x8086, 0x27c4, PCI_ANY_ID, PCI_ANY_ID, 0, 0, ich6m_sata }, |
238 | /* Enterprise Southbridge 2 (631xESB/632xESB) */ | 238 | /* Enterprise Southbridge 2 (631xESB/632xESB) */ |
239 | { 0x8086, 0x2680, PCI_ANY_ID, PCI_ANY_ID, 0, 0, ich6_sata }, | 239 | { 0x8086, 0x2680, PCI_ANY_ID, PCI_ANY_ID, 0, 0, ich6_sata }, |
@@ -517,7 +517,7 @@ static int ich_pata_cable_detect(struct ata_port *ap) | |||
517 | const struct ich_laptop *lap = &ich_laptop[0]; | 517 | const struct ich_laptop *lap = &ich_laptop[0]; |
518 | u8 mask; | 518 | u8 mask; |
519 | 519 | ||
520 | /* Check for specials - Acer Aspire 5602WLMi */ | 520 | /* Check for specials */ |
521 | while (lap->device) { | 521 | while (lap->device) { |
522 | if (lap->device == pdev->device && | 522 | if (lap->device == pdev->device && |
523 | lap->subvendor == pdev->subsystem_vendor && | 523 | lap->subvendor == pdev->subsystem_vendor && |
@@ -1366,38 +1366,39 @@ static const int *piix_init_sata_map(struct pci_dev *pdev, | |||
1366 | const int *map; | 1366 | const int *map; |
1367 | int i, invalid_map = 0; | 1367 | int i, invalid_map = 0; |
1368 | u8 map_value; | 1368 | u8 map_value; |
1369 | char buf[32]; | ||
1370 | char *p = buf, *end = buf + sizeof(buf); | ||
1369 | 1371 | ||
1370 | pci_read_config_byte(pdev, ICH5_PMR, &map_value); | 1372 | pci_read_config_byte(pdev, ICH5_PMR, &map_value); |
1371 | 1373 | ||
1372 | map = map_db->map[map_value & map_db->mask]; | 1374 | map = map_db->map[map_value & map_db->mask]; |
1373 | 1375 | ||
1374 | dev_info(&pdev->dev, "MAP ["); | ||
1375 | for (i = 0; i < 4; i++) { | 1376 | for (i = 0; i < 4; i++) { |
1376 | switch (map[i]) { | 1377 | switch (map[i]) { |
1377 | case RV: | 1378 | case RV: |
1378 | invalid_map = 1; | 1379 | invalid_map = 1; |
1379 | pr_cont(" XX"); | 1380 | p += scnprintf(p, end - p, " XX"); |
1380 | break; | 1381 | break; |
1381 | 1382 | ||
1382 | case NA: | 1383 | case NA: |
1383 | pr_cont(" --"); | 1384 | p += scnprintf(p, end - p, " --"); |
1384 | break; | 1385 | break; |
1385 | 1386 | ||
1386 | case IDE: | 1387 | case IDE: |
1387 | WARN_ON((i & 1) || map[i + 1] != IDE); | 1388 | WARN_ON((i & 1) || map[i + 1] != IDE); |
1388 | pinfo[i / 2] = piix_port_info[ich_pata_100]; | 1389 | pinfo[i / 2] = piix_port_info[ich_pata_100]; |
1389 | i++; | 1390 | i++; |
1390 | pr_cont(" IDE IDE"); | 1391 | p += scnprintf(p, end - p, " IDE IDE"); |
1391 | break; | 1392 | break; |
1392 | 1393 | ||
1393 | default: | 1394 | default: |
1394 | pr_cont(" P%d", map[i]); | 1395 | p += scnprintf(p, end - p, " P%d", map[i]); |
1395 | if (i & 1) | 1396 | if (i & 1) |
1396 | pinfo[i / 2].flags |= ATA_FLAG_SLAVE_POSS; | 1397 | pinfo[i / 2].flags |= ATA_FLAG_SLAVE_POSS; |
1397 | break; | 1398 | break; |
1398 | } | 1399 | } |
1399 | } | 1400 | } |
1400 | pr_cont(" ]\n"); | 1401 | dev_info(&pdev->dev, "MAP [%s ]\n", buf); |
1401 | 1402 | ||
1402 | if (invalid_map) | 1403 | if (invalid_map) |
1403 | dev_err(&pdev->dev, "invalid MAP value %u\n", map_value); | 1404 | dev_err(&pdev->dev, "invalid MAP value %u\n", map_value); |