forked from len0rd/rockbox
Revert the ATA/USB power fix until I find an even more correct way of doing it :-)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8707 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
41e1aa888b
commit
a4504bc276
2 changed files with 9 additions and 14 deletions
|
|
@ -71,13 +71,6 @@ void power_init(void)
|
||||||
or_l(0x00080000, &GPIO1_ENABLE);
|
or_l(0x00080000, &GPIO1_ENABLE);
|
||||||
or_l(0x00080000, &GPIO1_FUNCTION);
|
or_l(0x00080000, &GPIO1_FUNCTION);
|
||||||
|
|
||||||
#ifdef IRIVER_H300_SERIES
|
|
||||||
/* ISD300 3.3V ON */
|
|
||||||
or_l(8,&GPIO1_FUNCTION);
|
|
||||||
or_l(8,&GPIO1_OUT);
|
|
||||||
or_l(8,&GPIO1_ENABLE);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef BOOTLOADER
|
#ifndef BOOTLOADER
|
||||||
/* The boot loader controls the power */
|
/* The boot loader controls the power */
|
||||||
ide_power_enable(true);
|
ide_power_enable(true);
|
||||||
|
|
@ -185,13 +178,6 @@ void ide_power_enable(bool on)
|
||||||
and_l(~0x80000000, &GPIO_OUT);
|
and_l(~0x80000000, &GPIO_OUT);
|
||||||
else
|
else
|
||||||
or_l(0x80000000, &GPIO_OUT);
|
or_l(0x80000000, &GPIO_OUT);
|
||||||
#ifdef IRIVER_H300_SERIES
|
|
||||||
if(on)
|
|
||||||
and_l(~0x00000008,&GPIO1_OUT); /* ISD300 3.3V on */
|
|
||||||
else
|
|
||||||
or_l(0x00000008,&GPIO1_OUT); /* ISD300 3.3V off */
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#elif defined(IAUDIO_X5)
|
#elif defined(IAUDIO_X5)
|
||||||
/* X5 TODO */
|
/* X5 TODO */
|
||||||
#elif (CONFIG_CPU == PP5002) || (CONFIG_CPU == PP5020)
|
#elif (CONFIG_CPU == PP5002) || (CONFIG_CPU == PP5020)
|
||||||
|
|
|
||||||
|
|
@ -151,6 +151,8 @@ void usb_enable(bool on)
|
||||||
/* Power on the Cypress chip */
|
/* Power on the Cypress chip */
|
||||||
#ifdef IRIVER_H100_SERIES
|
#ifdef IRIVER_H100_SERIES
|
||||||
or_l(0x01000040, &GPIO_OUT);
|
or_l(0x01000040, &GPIO_OUT);
|
||||||
|
#else
|
||||||
|
and_l(~0x00000008,&GPIO1_OUT);
|
||||||
#endif
|
#endif
|
||||||
sleep(2);
|
sleep(2);
|
||||||
}
|
}
|
||||||
|
|
@ -159,6 +161,8 @@ void usb_enable(bool on)
|
||||||
/* Power off the Cypress chip */
|
/* Power off the Cypress chip */
|
||||||
#ifdef IRIVER_H100_SERIES
|
#ifdef IRIVER_H100_SERIES
|
||||||
and_l(~0x01000040, &GPIO_OUT);
|
and_l(~0x01000040, &GPIO_OUT);
|
||||||
|
#else
|
||||||
|
or_l(0x00000008,&GPIO1_OUT);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -479,6 +483,11 @@ void usb_init(void)
|
||||||
or_l(0x00000080, &GPIO1_FUNCTION); /* GPIO39 is the USB detect input */
|
or_l(0x00000080, &GPIO1_FUNCTION); /* GPIO39 is the USB detect input */
|
||||||
|
|
||||||
#ifdef IRIVER_H300_SERIES
|
#ifdef IRIVER_H300_SERIES
|
||||||
|
/* ISD300 3.3V ON */
|
||||||
|
or_l(8,&GPIO1_FUNCTION);
|
||||||
|
or_l(8,&GPIO1_OUT);
|
||||||
|
or_l(8,&GPIO1_ENABLE);
|
||||||
|
|
||||||
/* Tristate the SCK/SDA to the ISD300 config EEPROM */
|
/* Tristate the SCK/SDA to the ISD300 config EEPROM */
|
||||||
and_l(~0x03000000, &GPIO_ENABLE);
|
and_l(~0x03000000, &GPIO_ENABLE);
|
||||||
or_l(0x03000000, &GPIO_FUNCTION);
|
or_l(0x03000000, &GPIO_FUNCTION);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue