summaryrefslogtreecommitdiff
path: root/firmware/kernel.c (follow)
Commit message (Collapse)AuthorAge
...
* Finally, out goes struct spinlock for anything but mutiprocessor targets ↵Michael Sevakis2008-01-18
| | | | | | where it becomes a reenterable corelock. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16105 a1c6a512-1295-4272-9138-f99709370657
* Fix FS#8052 - kernel.c compilation errors when compiling for debug. Just ↵Michael Sevakis2007-10-30
| | | | | | some minor typos that got in with last minute SW corelock changes. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15380 a1c6a512-1295-4272-9138-f99709370657
* Add queue_peek to the kernel (written by Mike Sevakis), and use it to ↵Nicolas Pennequin2007-10-27
| | | | | | improve upon my previous commit. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15336 a1c6a512-1295-4272-9138-f99709370657
* Be sure to register a new mutex owner _before_ waking it. Won't be an issue ↵Michael Sevakis2007-10-21
| | | | | | now but would be with mutex recursion on one used for > 1 core where ownership transfer and cs entry/recursion are allowed to run in parallel (by design). TODO: Add true exchange to wakeup_thread but that's not really important for the time being. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15251 a1c6a512-1295-4272-9138-f99709370657
* Finally full multicore support for PortalPlayer 502x targets with an eye ↵Michael Sevakis2007-10-16
| | | | | | towards the possibility of other types. All SVN targets the low-lag code to speed up blocking operations. Most files are modified here simple due to a name change to actually support a real event object and a param change to create_thread. Add some use of new features but just sit on things for a bit and leave full integration for later. Work will continue on to address size on sensitive targets and simplify things if possible. Any PP target having problems with SWP can easily be changed to sw corelocks with one #define change in config.h though only PP5020 has shown an issue and seems to work without any difficulties. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15134 a1c6a512-1295-4272-9138-f99709370657
* Stabilize PP5020 targets - tested on H10 5/20GB and iPod Color. Use no ↵Michael Sevakis2007-10-05
| | | | | | interrupts on COP but pulse it through the control interface. Don't mess with LCD clocking during clock changes. Give a reset register a name (DEV_OFF_MASK). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14998 a1c6a512-1295-4272-9138-f99709370657
* Enable auto reply for queue messages sent with queue_send. It's only ↵Michael Sevakis2007-09-30
| | | | | | nescessary to use queue_reply to return a value other than zero or to return a result before waiting on the queue again. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14923 a1c6a512-1295-4272-9138-f99709370657
* Commit a subset of the dual core changes that have to do with cache ↵Michael Sevakis2007-09-28
| | | | | | handling, stacks, firmware startup and thread startup. Tested on e200, H10-20GB, iPod Color and 5.5G. Thread function return implemented for all targets. Some changes to plugins to follow shortly. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14879 a1c6a512-1295-4272-9138-f99709370657
* Merge the Gigabeat S branch back into trunk. Fingers crossed nothing breaks.Will Robertson2007-09-21
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14805 a1c6a512-1295-4272-9138-f99709370657
* Add a new timeout API to the kernel. Enable only for e200 right now since ↵Michael Sevakis2007-07-29
| | | | | | it's the only user. Use that as the one-shot delay for SD card inserts. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14049 a1c6a512-1295-4272-9138-f99709370657
* Gigabeat: Add timer functionality. Rework tick timer setup to be exactly ↵Michael Sevakis2007-07-06
| | | | | | 100Hz. Metronome should work now but some pcm changes are needed to have faster tocks work correctly (in the works). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13806 a1c6a512-1295-4272-9138-f99709370657
* Gigabeat: Use vectored IRQ mode interrupts and add a trap for unhandled ones.Michael Sevakis2007-07-05
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13792 a1c6a512-1295-4272-9138-f99709370657
* current_tick really does need to be volatile since gcc can optimize away ↵Michael Sevakis2007-06-25
| | | | | | checking the value otherwise - found out the hard way. :) git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13715 a1c6a512-1295-4272-9138-f99709370657
* Messages queues must be guarded on both ends or else it's a race between ↵Michael Sevakis2007-05-12
| | | | | | detecting a message present and missing a wakeup on thread about to wait. Keeping IRQs from interacting with the scheduler would be preferable but this should do at the moment. Add more detailed panic info regarding blocking violations so we know who. Make panicf function well enough on Gigabeat and PortalPlayer targets. Move the core sleep instructions into a CPU-specific inline to keep thing organized. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13374 a1c6a512-1295-4272-9138-f99709370657
* Simplification, queue pointers don't wrap (except at INT_MAX, but the ↵Jens Arnold2007-04-14
| | | | | | calculation is still correct in this case). Implemented queue_count() for the simulator. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13154 a1c6a512-1295-4272-9138-f99709370657
* Make scheduler functions thread safe core wise. A big step towards playback ↵Miika Pekkarinen2007-03-26
| | | | | | running on COP (not yet possible because more protection on file system level is necessary). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12926 a1c6a512-1295-4272-9138-f99709370657
* Fix a hole in the scheduler where collisions between waking blocked threads ↵Michael Sevakis2007-03-26
| | | | | | in mutexes with interrupts waking blocked threads in message queues can occur. Queue posts will put the threads on a separate list that is then added to the running list with IRQs disabled on the next task switch or CPU wakeup. Basically no overhead for other operations. Seems a likely cause of my occasional observation of the backlight fade causing playback threads to stop running and a recently reported blocking violation upon USB plugging. Time will tell but banging the backlight on and off frequently hasn't hiccuped again for me on H120. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12915 a1c6a512-1295-4272-9138-f99709370657
* PNX0101 changes:Tomasz Malesinski2007-03-24
| | | | | | | | | | Make PNX0101-specific system.c and crt0.S. Add new register names from LPC2880 user manual. Add support for timer. Enable CPU frequency changing. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12904 a1c6a512-1295-4272-9138-f99709370657
* In reponse to a report of a blocking violation, give sync queues a going ↵Michael Sevakis2007-03-23
| | | | | | over and catch any old, obscure leftover issues. A couple spots needed interrupt stopage where there could be confict if an IRQ post wakes a waiting thread because the queue is overflowing. There does appear to be an issue with wakeup_thread, interrupts and running list modification in general. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12895 a1c6a512-1295-4272-9138-f99709370657
* Update sync queues to use a statically allocated return value in order to ↵Michael Sevakis2007-03-21
| | | | | | facilitate upcoming COP updates. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12881 a1c6a512-1295-4272-9138-f99709370657
* Disable bootloader messages in the H10 and Sansa bootloaders unless the PLAY ↵Barry Wardell2007-03-12
| | | | | | (on H10) or RIGHT (on Sansa) button is being held. Messages are still displayed if an error occurs. This has already been implemented for iPod bootloaders, but still needs implementing for the other bootloaders. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12742 a1c6a512-1295-4272-9138-f99709370657
* Optimized the gui list code performance, including automatic frame dropping ↵Miika Pekkarinen2007-03-11
| | | | | | and cpu boosting when button events are getting queued. Improved scrollwheel acceleration code is needed to notice a real change. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12721 a1c6a512-1295-4272-9138-f99709370657
* Put an end to priority inversion in the ata driver. Gave up trying to have ↵Michael Sevakis2007-03-09
| | | | | | fully atomic dual use mutexes so just replaced the ata driver locking with spins. Maybe I'll have better luck later. Things should run smoothly with database updates and such happening in the background. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12688 a1c6a512-1295-4272-9138-f99709370657
* Dual core support for PP502x players (iPod G4 and later, iriver h10, Sansa - ↵Daniel Ankers2007-03-04
| | | | | | iPod G3 will be coming soon.) This allows threads to be run on either core provided that all communications between the cores is done using uncached memory. There should be no significant change in battery life from doing this. Documentation (on the RockboxKernel wiki page) will follow shortly. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12601 a1c6a512-1295-4272-9138-f99709370657
* merge a big part of the unofficial gigabeat cvs back. Includes working ↵Marcoen Hirschberg2006-12-29
| | | | | | bootloader and rockbox with audio. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11850 a1c6a512-1295-4272-9138-f99709370657
* Convert queues to use intptr_t for event data and return values as most of ↵Michael Sevakis2006-12-19
| | | | | | the time pointer are not passed and it should make some things a bit cleaner. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11818 a1c6a512-1295-4272-9138-f99709370657
* Add queue_send synchronous message sending. Right now only for SWCODEC. ↵Michael Sevakis2006-12-16
| | | | | | Actual usage to be added to playback and recording shortly in upcoming commits. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11776 a1c6a512-1295-4272-9138-f99709370657
* Change if CONFIG_CPU==PP50XX to ifdef CPU_PP where appropriateDaniel Ankers2006-11-22
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11569 a1c6a512-1295-4272-9138-f99709370657
* Thread API enhancements.Brandon Low2006-11-11
| | | | | | | | 1) block_thread -> block_thread + block_thread_w_tmo -- this call was always used in distinct ways so having one call with a conditional was ugly. 2) enhance Slasheri's scheduler controlled boost concept. now any thread may trigger a boost which will last until that thread next sleeps. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11509 a1c6a512-1295-4272-9138-f99709370657
* Removed the Gmini 120 and Gmini SP code. These ports are dead, unfortunately.Jens Arnold2006-11-10
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11504 a1c6a512-1295-4272-9138-f99709370657
* Patch #6052 - More responsive skip on ArchosLinus Nielsen Feltzing2006-10-19
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11273 a1c6a512-1295-4272-9138-f99709370657
* New scheduler, with priorities for swcodec platforms. Frequent taskMiika Pekkarinen2006-09-16
| | | | | | | | | | switching should be more efficient and tasks are stored in linked lists to eliminate unnecessary task switching to improve performance. Audio should no longer skip on swcodec targets caused by too CPU hungry UI thread or background threads. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10958 a1c6a512-1295-4272-9138-f99709370657
* Fixed an off-by-one error in the portalplayer timer handling.Jens Arnold2006-09-01
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10837 a1c6a512-1295-4272-9138-f99709370657
* Initial commit of work for port to the Tatung Elio TPJ-1022 - yet another ↵Dave Chapman2006-08-31
| | | | | | PortalPlayer PP5020 target. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10828 a1c6a512-1295-4272-9138-f99709370657
* initial gigabeat bootloader (only test code)Marcoen Hirschberg2006-08-12
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10536 a1c6a512-1295-4272-9138-f99709370657
* update the gigabeat code and move to target_treeMarcoen Hirschberg2006-08-12
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10535 a1c6a512-1295-4272-9138-f99709370657
* better check for portalplayer targetsDaniel Stenberg2006-08-02
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10407 a1c6a512-1295-4272-9138-f99709370657
* added mostly dummy changes to allow building of a Sansa e200 bootloaderDaniel Stenberg2006-08-01
| | | | | | | without functionality git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10399 a1c6a512-1295-4272-9138-f99709370657
* Further iPod 3G work from Seven Le MesleDave Chapman2006-02-05
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8583 a1c6a512-1295-4272-9138-f99709370657
* Removed PP5020_ prefix from register defines and added/renamed someThom Johansen2006-01-24
| | | | | | | defines. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8438 a1c6a512-1295-4272-9138-f99709370657
* Properly configurable tick timer for PP5020.Thom Johansen2006-01-24
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8437 a1c6a512-1295-4272-9138-f99709370657
* Slightly safer version of queue_delete()Linus Nielsen Feltzing2006-01-23
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8425 a1c6a512-1295-4272-9138-f99709370657
* New kernel function, queue_delete(struct event_queue *q)Linus Nielsen Feltzing2006-01-23
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8424 a1c6a512-1295-4272-9138-f99709370657
* Work-in-progress iriver iFP-7xx port by Tomasz MalesinskiDave Chapman2006-01-12
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8342 a1c6a512-1295-4272-9138-f99709370657
* iPod: Fix the bootloader so it can load and run the original Apple firmware ↵Dave Chapman2006-01-05
| | | | | | again. The Rockbox firmware was doing too much to the hardware so we remove most of the initialisation. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8301 a1c6a512-1295-4272-9138-f99709370657
* Add interrupt handler for iPod. Add timer tick support. Remove temporary ↵Thom Johansen2005-12-12
| | | | | | thread sleep solution. Remove temporary iPod current_tick solution. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8224 a1c6a512-1295-4272-9138-f99709370657
* First attempt at iPod threading.Thom Johansen2005-11-13
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7852 a1c6a512-1295-4272-9138-f99709370657
* Use ICODE_ATTR instead of __attribute__ ((section(".icode")))Dave Chapman2005-11-12
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7820 a1c6a512-1295-4272-9138-f99709370657
* iPod: Code cleanup - the bootloader now compiles with zero warningsDave Chapman2005-11-11
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7812 a1c6a512-1295-4272-9138-f99709370657
* Initial commit of work-in-progress iPod portDave Chapman2005-11-07
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7781 a1c6a512-1295-4272-9138-f99709370657