summaryrefslogtreecommitdiffstats
path: root/drivers/block/ata_piix.h
diff options
context:
space:
mode:
authorTom Rini <trini@ti.com>2012-09-29 07:35:12 -0700
committerTom Rini <trini@ti.com>2012-10-15 11:54:02 -0700
commit879a57ac0e955e053e21b92c5aba76a0e542b1e4 (patch)
tree1b264e8aba8808d171304fa154ffd8d0297471e4 /drivers/block/ata_piix.h
parente5f24753c9b415adf12def520f051f60433068b4 (diff)
downloadblackbird-obmc-uboot-879a57ac0e955e053e21b92c5aba76a0e542b1e4.tar.gz
blackbird-obmc-uboot-879a57ac0e955e053e21b92c5aba76a0e542b1e4.zip
ata_piix: Fix checkpatch issues
While in here also: - Switch to debug from custom PRINTF for debugging. - Use mdelay rather than custom msleep. Signed-off-by: Tom Rini <trini@ti.com>
Diffstat (limited to 'drivers/block/ata_piix.h')
-rw-r--r--drivers/block/ata_piix.h48
1 files changed, 20 insertions, 28 deletions
diff --git a/drivers/block/ata_piix.h b/drivers/block/ata_piix.h
index 9157cf82c0..c60d0359c9 100644
--- a/drivers/block/ata_piix.h
+++ b/drivers/block/ata_piix.h
@@ -1,12 +1,6 @@
#ifndef __ATA_PIIX_H__
#define __ATA_PIIX_H__
-#if (DEBUG_SATA)
-#define PRINTF(fmt,args...) printf (fmt ,##args)
-#else
-#define PRINTF(fmt,args...)
-#endif
-
struct sata_ioports {
unsigned long cmd_addr;
unsigned long data_addr;
@@ -36,45 +30,43 @@ struct sata_port {
};
/***********SATA LIBRARY SPECIFIC DEFINITIONS AND DECLARATIONS**************/
-#ifdef SATA_DECL /*SATA library specific declarations */
-inline void
-ata_dump_id (u16 * id)
+#ifdef SATA_DECL /* SATA library specific declarations */
+inline void ata_dump_id(u16 *id)
{
- PRINTF ("49 = 0x%04x "
+ debug("49 = 0x%04x "
"53 = 0x%04x "
"63 = 0x%04x "
"64 = 0x%04x "
- "75 = 0x%04x \n", id[49], id[53], id[63], id[64], id[75]);
- PRINTF ("80 = 0x%04x "
+ "75 = 0x%04x\n", id[49], id[53], id[63], id[64], id[75]);
+ debug("80 = 0x%04x "
"81 = 0x%04x "
"82 = 0x%04x "
"83 = 0x%04x "
- "84 = 0x%04x \n", id[80], id[81], id[82], id[83], id[84]);
- PRINTF ("88 = 0x%04x " "93 = 0x%04x\n", id[88], id[93]);
+ "84 = 0x%04x\n", id[80], id[81], id[82], id[83], id[84]);
+ debug("88 = 0x%04x " "93 = 0x%04x\n", id[88], id[93]);
}
#endif
#ifdef SATA_DECL /*SATA library specific declarations */
-int sata_bus_softreset (int num);
-void sata_identify (int num, int dev);
-void sata_port (struct sata_ioports *ioport);
-void set_Feature_cmd (int num, int dev);
-int sata_devchk (struct sata_ioports *ioaddr, int dev);
-void dev_select (struct sata_ioports *ioaddr, int dev);
-u8 sata_busy_wait (struct sata_ioports *ioaddr, int bits, unsigned int max);
-u8 sata_chk_status (struct sata_ioports *ioaddr);
-ulong sata_read (int device, ulong blknr,lbaint_t blkcnt, void * buffer);
-ulong sata_write (int device,ulong blknr, lbaint_t blkcnt, void * buffer);
-void msleep (int count);
+int sata_bus_softreset(int num);
+void sata_identify(int num, int dev);
+void sata_port(struct sata_ioports *ioport);
+void set_Feature_cmd(int num, int dev);
+int sata_devchk(struct sata_ioports *ioaddr, int dev);
+void dev_select(struct sata_ioports *ioaddr, int dev);
+u8 sata_busy_wait(struct sata_ioports *ioaddr, int bits, unsigned int max);
+u8 sata_chk_status(struct sata_ioports *ioaddr);
+ulong sata_read(int device, ulong blknr,lbaint_t blkcnt, void *buffer);
+ulong sata_write(int device,ulong blknr, lbaint_t blkcnt, void *buffer);
#endif
/************DRIVER SPECIFIC DEFINITIONS AND DECLARATIONS**************/
-#ifdef DRV_DECL /*Driver specific declaration */
-int init_sata (int dev);
+#ifdef DRV_DECL /* Driver specific declaration */
+int init_sata(int dev);
#endif
-#ifdef DRV_DECL /*Defines Driver Specific variables */
+#ifdef DRV_DECL /* Defines Driver Specific variables */
struct sata_port port[CONFIG_SYS_SATA_MAXBUS];
#endif
OpenPOWER on IntegriCloud