diff options
author | Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> | 2014-06-01 22:36:30 +0000 |
---|---|---|
committer | Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> | 2014-06-01 22:36:30 +0000 |
commit | 4b7409d9999513a06865d2012df22437f2664335 (patch) | |
tree | 22c7e87424c339a7dea57c125b7df72b48bb89b8 | |
parent | 850de2891a2a814df7d66b9106575d9f3ef0ac7b (diff) | |
download | flashrom-4b7409d9999513a06865d2012df22437f2664335.zip flashrom-4b7409d9999513a06865d2012df22437f2664335.tar.gz |
atavia: Fix a few problems overlooked/introduced while rebasing
Corresponding to flashrom svn r1811.
Signed-off-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
Acked-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
-rw-r--r-- | Makefile | 5 | ||||
-rw-r--r-- | atavia.c | 9 | ||||
-rw-r--r-- | flashrom.8.tmpl | 2 |
3 files changed, 5 insertions, 11 deletions
@@ -325,11 +325,6 @@ UNSUPPORTED_FEATURES += CONFIG_ATAHPT=yes else override CONFIG_ATAHPT = no endif -ifeq ($(CONFIG_ATAVIA), yes) -UNSUPPORTED_FEATURES += CONFIG_ATAVIA=yes -else -override CONFIG_ATAVIA = no -endif ifeq ($(CONFIG_SATAMV), yes) UNSUPPORTED_FEATURES += CONFIG_SATAMV=yes else @@ -72,7 +72,7 @@ static const struct par_programmer lpc_programmer_atavia = { }; static void *atavia_offset = NULL; -struct pci_dev *dev = NULL; +static struct pci_dev *dev = NULL; static void atavia_prettyprint_access(uint8_t access) { @@ -118,7 +118,7 @@ static bool atavia_ready(struct pci_dev *pcidev_dev) return ready; } -void *atavia_map(const char *descr, unsigned long phys_addr, size_t len) +void *atavia_map(const char *descr, uintptr_t phys_addr, size_t len) { return (atavia_offset != 0) ? atavia_offset : (void *)phys_addr; } @@ -146,7 +146,6 @@ int atavia_init(void) if (rget_io_perms()) return 1; - /* No need to check for errors, pcidev_init() will not return in case of errors. */ dev = pcidev_init(ata_via, PCI_ROM_ADDRESS); /* Acutally no BAR setup needed at all. */ if (!dev) return 1; @@ -172,7 +171,7 @@ int atavia_init(void) static void atavia_chip_writeb(const struct flashctx *flash, uint8_t val, const chipaddr addr) { - msg_pspew("%s: 0x%02x to 0x%08lx.\n", __func__, val, addr); + msg_pspew("%s: 0x%02x to 0x%*" PRIxPTR ".\n", __func__, val, PRIxPTR_WIDTH, addr); pci_write_long(dev, BROM_ADDR, (addr & ~3)); pci_write_long(dev, BROM_DATA, val << BYTE_OFFSET(addr)); pci_write_byte(dev, BROM_ACCESS, BROM_TRIGGER | BROM_WRITE | ENABLE_BYTE(addr)); @@ -192,6 +191,6 @@ static uint8_t atavia_chip_readb(const struct flashctx *flash, const chipaddr ad } uint8_t val = (pci_read_long(dev, BROM_DATA) >> BYTE_OFFSET(addr)) & 0xff; - msg_pspew("%s: 0x%02x from 0x%08lx.\n", __func__, val, addr); + msg_pspew("%s: 0x%02x from 0x%*" PRIxPTR ".\n", __func__, val, PRIxPTR_WIDTH, addr); return val; } diff --git a/flashrom.8.tmpl b/flashrom.8.tmpl index ed0160b..956e4f5 100644 --- a/flashrom.8.tmpl +++ b/flashrom.8.tmpl @@ -192,7 +192,7 @@ cards)" .sp .BR "* atahpt" " (for flash ROMs on Highpoint ATA/RAID controllers)" .sp -.BR "* atavia" " (for flash ROMs on VIA VT6421A ATA controllers)" +.BR "* atavia" " (for flash ROMs on VIA VT6421A SATA controllers)" .sp .BR "* ft2232_spi" " (for SPI flash ROMs attached to an FT2232/FT4232H/FT232H family \ based USB SPI programmer), including the DLP Design DLP-USB1232H, \ |