]> git.sur5r.net Git - u-boot/blobdiff - common/cmd_ide.c
mpc8323erdb: remove RTC and add EEPROM
[u-boot] / common / cmd_ide.c
index bb064eaa04a3ad7869db70aeca2f99f23a3be8b9..c38be4f1a7d0d0c36335f44e6ab7e190326393c9 100644 (file)
 
 #ifndef __PPC__
 #include <asm/io.h>
-#ifdef __MIPS__
-/* Macros depend on this variable */
-unsigned long mips_io_port_base = 0;
-#endif
 #endif
 
 #ifdef CONFIG_IDE_8xx_DIRECT
@@ -72,8 +68,6 @@ DECLARE_GLOBAL_DATA_PTR;
 # define SYNC          /* nothing */
 #endif
 
-#if defined(CONFIG_CMD_IDE)
-
 #ifdef CONFIG_IDE_8xx_DIRECT
 /* Timings for IDE Interface
  *
@@ -892,7 +886,7 @@ input_swap_data(int dev, ulong *sect_buf, int words)
 #endif /* __LITTLE_ENDIAN || CONFIG_AU1X00 */
 
 
-#if defined(__PPC__) || defined(CONFIG_PXA_PCMCIA)
+#if defined(__PPC__) || defined(CONFIG_PXA_PCMCIA) || defined(CONFIG_SH)
 static void
 output_data(int dev, ulong *sect_buf, int words)
 {
@@ -944,7 +938,7 @@ output_data(int dev, ulong *sect_buf, int words)
 }
 #endif /* __PPC__ */
 
-#if defined(__PPC__) || defined(CONFIG_PXA_PCMCIA)
+#if defined(__PPC__) || defined(CONFIG_PXA_PCMCIA) || defined(CONFIG_SH)
 static void
 input_data(int dev, ulong *sect_buf, int words)
 {
@@ -1136,9 +1130,9 @@ static void ide_ident (block_dev_desc_t *dev_desc)
 
        input_swap_data (device, iobuf, ATA_SECTORWORDS);
 
-       ident_cpy (dev_desc->revision, iop->fw_rev, sizeof(dev_desc->revision));
-       ident_cpy (dev_desc->vendor, iop->model, sizeof(dev_desc->vendor));
-       ident_cpy (dev_desc->product, iop->serial_no, sizeof(dev_desc->product));
+       ident_cpy ((unsigned char*)dev_desc->revision, iop->fw_rev, sizeof(dev_desc->revision));
+       ident_cpy ((unsigned char*)dev_desc->vendor, iop->model, sizeof(dev_desc->vendor));
+       ident_cpy ((unsigned char*)dev_desc->product, iop->serial_no, sizeof(dev_desc->product));
 #ifdef __LITTLE_ENDIAN
        /*
         * firmware revision and model number have Big Endian Byte
@@ -1953,9 +1947,9 @@ static void       atapi_inquiry(block_dev_desc_t * dev_desc)
                return;
 
        /* copy device ident strings */
-       ident_cpy(dev_desc->vendor,&iobuf[8],8);
-       ident_cpy(dev_desc->product,&iobuf[16],16);
-       ident_cpy(dev_desc->revision,&iobuf[32],5);
+       ident_cpy((unsigned char*)dev_desc->vendor,&iobuf[8],8);
+       ident_cpy((unsigned char*)dev_desc->product,&iobuf[16],16);
+       ident_cpy((unsigned char*)dev_desc->revision,&iobuf[32],5);
 
        dev_desc->lun=0;
        dev_desc->lba=0;
@@ -2085,5 +2079,3 @@ U_BOOT_CMD(
        "diskboot- boot from IDE device\n",
        "loadAddr dev:part\n"
 );
-
-#endif