summaryrefslogtreecommitdiff
path: root/firmware/common
AgeCommit message (Collapse)Author
2010-08-30typo in r27953 spotted by kugel: s/long/ssize_t/Rafaël Carré
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27955 a1c6a512-1295-4272-9138-f99709370657
2010-08-30format: supports %zd (ssize_t) and %zu (ssize_t)Rafaël Carré
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27953 a1c6a512-1295-4272-9138-f99709370657
2010-08-12Move memset6() declaration to string-extra.h, kills a warning compiling for ↵Thomas Martitz
android since it ships a memory.h. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27789 a1c6a512-1295-4272-9138-f99709370657
2010-08-08Various minor fixes for Samsung YH* targetsBertrik Sikken
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27751 a1c6a512-1295-4272-9138-f99709370657
2010-08-02Rockbox as an application: Commit current Android port progress.Thomas Martitz
General state is: Rockbox is usable (plays music, saves configuration, touchscreen works too). Problems: - Playing music in the background (i.e. when switching to another app) doesn't work reliably, but I'm working on that now. - no cabbiev2 (only some preliminary files for it), no other default theme. - screen flickers sometimes if the updates are too frequent - no multi screen apk/package - strange behavior when a phone call comes in The java files (and the eclipse project) resides in android/, which is also supposed to be the build folder. I've put a small README in there for instructions. There are some steps needed after the make part, which are described there, and which eclipse mostly handles. But there ought to be some script/makefile rules which do that instead in the future. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27668 a1c6a512-1295-4272-9138-f99709370657
2010-08-01Fix reds.Thomas Martitz
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27657 a1c6a512-1295-4272-9138-f99709370657
2010-08-01Rockbox as an application: add get_user_file_path().Thomas Martitz
For RaaA it evaluates user paths at runtime. For everything but codecs/plugins it will give the path under $HOME/.config/rockbox.org if write access is needed or if the file/folder in question exists there (otherwise it gives /usr/local/share/rockbox). This allows for installing themes under $HOME as well as having config.cfg and other important files there while installing the application (and default themes) under /usr/local. On the DAPs it's a no-op, returing /.rockbox directly. Not converted to use get_user_file_path() are plugins themselves, because RaaA doesn't build plugins yet. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27656 a1c6a512-1295-4272-9138-f99709370657
2010-07-31Let format.c #include its own format.h header fileBertrik Sikken
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27633 a1c6a512-1295-4272-9138-f99709370657
2010-07-26Factor out opening and removing DIRCACHE_FILE into separate functions.Thomas Martitz
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27575 a1c6a512-1295-4272-9138-f99709370657
2010-07-18Revert accidental commit of "%z" support in r26071 (the implementation ↵Frank Gevaerts
assumed size_t==long, which is not always the case in hosted environments) Remove four remaining uses of %z, three of which were in DEBUGF git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27479 a1c6a512-1295-4272-9138-f99709370657
2010-06-21Rockbox as an application: Replace many occurences of #ifdef SIMULATOR with ↵Thomas Martitz
#if (CONFIG_PLATFORM & PLATFORM_HOSTED) (or equivalently). The simulator defines PLATFORM_HOSTED, as RaaA will do (RaaA will not define SIMULATOR). The new define is to (de-)select code to compile on hosted platforms generally. Should be no functional change to targets or the simulator. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27019 a1c6a512-1295-4272-9138-f99709370657
2010-06-21Don't autogenerate version.c. Just version.h is enoughFrank Gevaerts
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27003 a1c6a512-1295-4272-9138-f99709370657
2010-06-06Make disk_init() non-static again. I forgot to look at the bootloadersFrank Gevaerts
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26629 a1c6a512-1295-4272-9138-f99709370657
2010-06-06Remove card_enable_monitoring() and use a mutex instead. The ↵Frank Gevaerts
card_enable_monitoring() method actually didn't eliminate the possible race conditions it was meant to fix. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26627 a1c6a512-1295-4272-9138-f99709370657
2010-06-05remane hotswap.* to sdmmc.*. The contents have nothing at all to do with ↵Frank Gevaerts
hotswapping things git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26598 a1c6a512-1295-4272-9138-f99709370657
2010-05-21dircache:Amaury Pouly
- fix check_event_queue to use queue_peek and not mess message order - change check_dircache_state to a more modest check to avoid messing up dircache state git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26228 a1c6a512-1295-4272-9138-f99709370657
2010-05-21Fix typos in commentMichael Chicoine
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26224 a1c6a512-1295-4272-9138-f99709370657
2010-05-21FS#10913: fix file browser not updated on microsd insertion/removal. This is ↵Amaury Pouly
a synchro bug in dircache: the system send a SYS_FS_CHANGED message which is first handled by the main thread which rescan the directory but as dircache main treats the message after, the file browser get the old version... Workaround is to check message queue before opening a directory. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26222 a1c6a512-1295-4272-9138-f99709370657
2010-05-20disk/file: Do not use & on arraysRafaël Carré
it might be valid C but is confusing, and not consistent with the rest of file.c git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26191 a1c6a512-1295-4272-9138-f99709370657
2010-05-15Revert r26048. APE tags in mp3 is explicitely on ↵Frank Gevaerts
http://www.rockbox.org/wiki/NoDo This sort of change should never go in without prior discussion or consensus git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26071 a1c6a512-1295-4272-9138-f99709370657
2010-05-06Move c/h files implementing/defining standard library stuff into a new libc ↵Thomas Martitz
directory, also standard'ify some parts of the code base (almost entirely #include fixes). This is to a) to cleanup firmware/common and firmware/include a bit, but also b) for Rockbox as an application which should use the host system's c library and headers, separating makes it easy to exclude our files from the build. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25850 a1c6a512-1295-4272-9138-f99709370657
2010-05-06Make open() posix compliant api-wise. A few calls (those with O_CREAT) need ↵Thomas Martitz
the additional optional mode parameter so add it. Impact for the core is almost zero, as open() is a wrapper macro for the real open function which doesn't take the variable parameter. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25844 a1c6a512-1295-4272-9138-f99709370657
2010-05-06Make creat() posix compliant API-wise. Shouldn't affect the core as it's ↵Thomas Martitz
wrapped via a static inline. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25843 a1c6a512-1295-4272-9138-f99709370657
2010-04-22dircache: increase stack size to handle the worse case path during rebuild ↵Amaury Pouly
(dircache->fat->ata-sd-pp+sdhc) and allows directory with depth up to 20 approximately git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25697 a1c6a512-1295-4272-9138-f99709370657
2010-04-07FS#11187 - diacritic.c is in 'drivers' but it does not belong thereTomer Shalev
- Move diacritic.c to firmware/common - The function is_diacritic returns bool now git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25526 a1c6a512-1295-4272-9138-f99709370657
2010-04-03Add IO priority handling. Currently all IO has equal priority, except the ↵Frank Gevaerts
dircache scanning thread which is lower. This fixes the slow boot problem for me, with the added benefit that actual audio playback also starts faster. Lots of the changes are due to changing storage_(read|write)sectors() from macros to wrapper functions. This means that they have to be called with IF_MD2(drive,) again. Flyspray: FS#11167 Author: Frank Gevaerts git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25459 a1c6a512-1295-4272-9138-f99709370657
2010-03-15dir_uncached: fix opendir_uncached to have opened directories keep enough ↵Amaury Pouly
information to update metadata; this is necessary because of the way rmdir_uncached is implemented FS#11107: should be fixed now git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25203 a1c6a512-1295-4272-9138-f99709370657
2010-03-10Get rid of the parent_dir field in dir_uncached.c by using the same FAT ↵Amaury Pouly
trick as in dircache. This should save ~20KB on 512B/sector targets and ~80KB on 2K/sector ones. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25105 a1c6a512-1295-4272-9138-f99709370657
2010-02-22Remove tabs in firmware path (taking into account the original spacing).Andree Buschmann
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24864 a1c6a512-1295-4272-9138-f99709370657
2010-02-21Fix a dircache NULL-pointer dereference.Amaury Pouly
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24835 a1c6a512-1295-4272-9138-f99709370657
2010-02-17Fix error handling in dircache generation.Amaury Pouly
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24730 a1c6a512-1295-4272-9138-f99709370657
2010-02-16-Cosmetic change in a comparisonAmaury Pouly
-Move fat_dir structure out of dircache stack to RAM. Reduce dircache stack size (max level depth should stay be around 20). This should fix nano2g dircache stkov of FS#10679 -Change the structure returned by readdir_cached to match the one returned by readdir_uncached: remove useless fields to save space and avoid any potential incoherence -Remove one field from the internal structure used by {opend,read,close}dir_cached because it was mostly redundant. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24708 a1c6a512-1295-4272-9138-f99709370657
2010-02-14Rewrite dircache generation to take advantage for the FAT code. Reduce RAM ↵Amaury Pouly
usage by ~30Kb and binsize by at least several hundreds bytes. Also remove the directory depth limit of dircache. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24657 a1c6a512-1295-4272-9138-f99709370657
2010-02-07Remove a file that mcuelenaere forgot to delete (see r23763 and r23767).Amaury Pouly
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24543 a1c6a512-1295-4272-9138-f99709370657
2010-02-07Optimize (size and speed) strncasecmp (based on a newlib patch).Amaury Pouly
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24542 a1c6a512-1295-4272-9138-f99709370657
2010-02-01Various dircache improvements: reduce size of a path buffer to MAX_PATH and ↵Amaury Pouly
rewrote copy_path to improve stack usage. Also simplified get_entry. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24445 a1c6a512-1295-4272-9138-f99709370657
2010-01-31Fix a dircache bug (opening a directory opens the first file of that ↵Amaury Pouly
directory). Also clarify the behaviour of dircache_get_entry. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24420 a1c6a512-1295-4272-9138-f99709370657
2010-01-03Final removal of tabs in firmware pathAndree Buschmann
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24158 a1c6a512-1295-4272-9138-f99709370657
2010-01-02Add strlcat to core to match strlcpy (also add to plugin api). Some uses of ↵Torne Wuff
strcat could probably do with being changed to this. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24141 a1c6a512-1295-4272-9138-f99709370657
2010-01-01FS#9409: fix rename which didn't close file handles on error and enventually ↵Amaury Pouly
cause cut/paste to fail between volumes. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24134 a1c6a512-1295-4272-9138-f99709370657
2009-12-23Make read() and write() return -1/EISDIR on directoriesFrank Gevaerts
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24106 a1c6a512-1295-4272-9138-f99709370657
2009-12-23only get the file pointer if fd is actually valid.Frank Gevaerts
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24105 a1c6a512-1295-4272-9138-f99709370657
2009-11-26Move strip_volume() to filefuncs.c and set properties.Maurus Cuelenaere
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23767 a1c6a512-1295-4272-9138-f99709370657
2009-11-26Forgot fileMaurus Cuelenaere
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23763 a1c6a512-1295-4272-9138-f99709370657
2009-11-26 - Split off strip_volume() to a separate fileMaurus Cuelenaere
- fix some yellows git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23762 a1c6a512-1295-4272-9138-f99709370657
2009-11-26Merge branch 'hotswap'Maurus Cuelenaere
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23759 a1c6a512-1295-4272-9138-f99709370657
2009-11-03Rename vfnprintf to vuprintf (u stands for user for the user callback and ↵Thomas Martitz
data passed to it) to avoid confusion with file and buffer size related functions from the printf-family, and add a comment to its declaration. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23503 a1c6a512-1295-4272-9138-f99709370657
2009-10-25Little bit of const correctnessNils Wallménius
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23343 a1c6a512-1295-4272-9138-f99709370657
2009-10-18Use wrap-safe TIME_BEFORE/TIME_AFTER macros to compare times with ↵Bertrik Sikken
current_time, instead of comparing them directly. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23246 a1c6a512-1295-4272-9138-f99709370657
2009-10-02Patch #1 from FS#10633 (Nano 2G developments) by Michael Sparmann - Allows ↵Dave Chapman
targets to set a different sector size than 512 for the storage system. Should not affect any other target. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22874 a1c6a512-1295-4272-9138-f99709370657