forked from len0rd/rockbox
Added ata_disk_is_active() function
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@1479 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
fce2a28982
commit
ad8ac5c3ce
2 changed files with 8 additions and 2 deletions
|
@ -174,7 +174,7 @@ int ata_read_sectors(unsigned long start,
|
|||
return ret;
|
||||
}
|
||||
|
||||
#ifdef DISK_WRITE
|
||||
//#ifdef DISK_WRITE
|
||||
int ata_write_sectors(unsigned long start,
|
||||
unsigned char count,
|
||||
void* buf)
|
||||
|
@ -230,7 +230,7 @@ int ata_write_sectors(unsigned long start,
|
|||
mutex_unlock(&ata_mtx);
|
||||
return i;
|
||||
}
|
||||
#endif
|
||||
//#endif
|
||||
|
||||
static int check_registers(void)
|
||||
{
|
||||
|
@ -269,6 +269,11 @@ void ata_spindown(int seconds)
|
|||
sleep_timeout = seconds * HZ;
|
||||
}
|
||||
|
||||
bool ata_disk_is_active(void)
|
||||
{
|
||||
return !sleeping;
|
||||
}
|
||||
|
||||
static int ata_perform_sleep(void)
|
||||
{
|
||||
int ret = 0;
|
||||
|
|
|
@ -35,6 +35,7 @@
|
|||
extern void ata_enable(bool on);
|
||||
extern void ata_spindown(int seconds);
|
||||
extern int ata_sleep(void);
|
||||
extern bool ata_disk_is_active(void);
|
||||
extern int ata_hard_reset(void);
|
||||
extern int ata_soft_reset(void);
|
||||
extern int ata_init(void);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue