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



Rockbox mail archive

Subject: Re: Handling of read-only storage: feeback wanted

Re: Handling of read-only storage: feeback wanted

From: Marcin Bukat <marcin.bukat_at_gmail.com>
Date: Mon, 6 May 2013 11:56:51 +0200

Failing to open file(s) for writes seems to be elegant solution but this
will probably trigger error messages as well. Moreover I think it should
trigger error message to give user feedback that card is write protected
(by accident for example).


2013/5/6 Amaury Pouly <amaury.pouly_at_gmail.com>

> Hi ,
> I'm looking for some feedback on an issue which might not be one:
> read-only storage. It appears that since virtually all DAP use micro-sd
> card we never ran into this problem but I am porting Rockbox to the
> Creative ZEN and ZEN X-Fi which feature a real SD card port and can sense
> the write-protected switch of them.
> The obvious solution is to completely ignore it of course but this is a
> bit of shame. Another option is to simply fail all writes to the storage if
> it is write protected (remember that this is completely software handled).
> I am wondering if there would be any interest in doing something a bit
> more clever, like making the file system code aware of read-only storage.
> Indeed, failing all writes will potentially stress all write path, might
> trigger bugs or obscure error messages to the user. A simple solution would
> be to prevent opening opening a file for writing for example.
>
> Any thoughts ?
>
> Amaury Pouly
>
Received on 2013-05-06

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