Rockbox

  • Status Closed
  • Percent Complete
    100%
  • Task Type Bugs
  • Category Database
  • Assigned To No-one
  • Operating System All players
  • Severity Low
  • Priority Very Low
  • Reported Version Daily build (which?)
  • Due in Version Undecided
  • Due Date Undecided
  • Votes
  • Private
Attached to Project: Rockbox
Opened by Marcel Barbulescu - 2008-03-09
Last edited by Bertrik Sikken - 2010-07-19

FS#8710 - "Gather Runtime Data" creates problems if "Load to RAM" is disabled

When “Gather Runtime Data” and “Load to RAM” are disabled, any operation that modifies the runtime data (e.g. play) that is followed by a database display can produce unexpected results.

Examples:
- while in WPS press Select, go to Database/Albums, select a song from an album, long press Select for context menu and go to Playlist/Insert; after the song is inserted the current database album is displayed with no tracks or am incomplete number of tracks
- browse the Database/Albums, select a song from an album and press Select two times very fast so it starts playing it and returns back to the Album song list; if the operation is fast enough the song list will be empty or incomplete

It can be reproduced on Sansa e200, Gigabeat and on the e200 Simulator.

From my investigation is probably related to reading the database files while another thread writes the updated runtime data into them. tagcache.c:get_next can return bad data if an update to the runtime data was just performed and a write is in progress. I noticed some read/write locking in tagcache.c but it covers only part of the file read/write operations.

If “Gather Runtime Data” is not enabled (no disk file write) or “Load to RAM” is enabled (no disk file read) everything work smoothly in the above scenarios because there are no overlapping file operations.

Closed by  Bertrik Sikken
2010-07-19 09:57
Reason for closing:  Works For Me
Additional comments about closing:  

Can't reproduce on my e200 either, possibly fixed by tagcache cleanups since february 2010.

Ben Zavala commented on 2008-03-10 16:34

I remember seeing this behavior that the tracks disappear after being selected from the database so I just decided to reproduce it following your steps. The results: I was not able to reproduce any of the 2 scenarios with today’s build r16601-080310. This was tried on an iPod Video 5.5 gen

Marcel Barbulescu commented on 2008-03-10 16:43

I just read the bug description again and I saw that I made a mistake in the first phrase: you need to have “Gather Runtime Data” ENABLED and “Load to RAM” disabled in order to reproduce the bug. Was this your config?

Thanks for testing.

Ben Zavala commented on 2008-03-10 22:28

Marcel,

I did try with Gather Runtime Data ENABLED and Load to RAM DISABLED. On both cases, the screen shows the names of the tracks.

Are you on the most recent build?

Ben

Marcel Barbulescu commented on 2008-03-10 22:36

Yes, the most recent build. I can even reproduced it on the iPod Simulator (while in Album view press Space twice fast and you’ll get an empty or shorter Album list).
(I suspect that any Simulator build will behave the same regarding to this issue.)

Maybe disk reads/writes behave differently on iPods (different disk driver?).
BigBambi from IRC also confirmed the problem with both Sansa e200 and Gigabeat.

Thank you Ben.

amaury pouly commented on 2010-02-06 18:20

Does this bug still exists ? I can’t reproduce it on my Sansa e200.

Loading...

Available keyboard shortcuts

Tasklist

Task Details

Task Editing