Rockbox.org home
release
dev builds
extras
themes manual
wiki
device status forums
mailing lists
IRC bugs
patches
dev guide



Rockbox mail archive

Subject: Red freeze

Red freeze

From: Mike Holden <rockbox_at_mikeholden.uklinux.net>
Date: Sat, 29 Mar 2003 09:37:46 -0000 (GMT)

Björn Stenberg said:
> However, the single most important problem right now is the "red led
> dead". This appears to be a condition where the drive never recovers
> from failure and thus reports errors forever. Hence my attempt with
> using a hard reset.

Another idea -
we recently added a patch that updated last_disk_activity on each loop
within ata_read_sectors(). This was to resolve the problem where the disk
could spindown during an interrupted read. Since wait_for_rdy() and
wait_for_bsy() have a built in maximum timeout of 10 seconds (10*HZ), we
should do the same here as well. If either of these functions takes a few
seconds, we could be spinning the disk down (default disk spindown is I
think 5 seconds). We could either update it each time round the while()
loop, or we could pre-empt it and set it to the function timeout value on
entry and set it again on exit (I assume that nothing will get "confused"
by having last_disk_activity in the future? It seems to be a simple
integer arithmetic comparison to current_tick-timeout or similar, so
should be ok).

As an additional question, both of these functions use a sleep_thread()
call. The code does some hardware stuff with the SBYCR address, and the
comment says that wakeup is by interrupt. What kind of events will provide
this wakeup?

-- 
Mike Holden
Received on 2003-03-29

Page template was last modified "Tue Sep 7 00:00:02 2021" The Rockbox Crew -- Privacy Policy