summaryrefslogtreecommitdiff
path: root/firmware/target/arm/imx31
AgeCommit message (Collapse)Author
2010-05-06Gigabeat S: There's no compelling reason to start automatic scaling in the ↵Michael Sevakis
bootloader only stop it milliseconds later. Do init to default frequency and working point, however. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25839 a1c6a512-1295-4272-9138-f99709370657
2010-05-06Changed a macro to a raw in int constant. Didn't mean to do that. Put it ↵Michael Sevakis
back right. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25838 a1c6a512-1295-4272-9138-f99709370657
2010-05-06i.MX31/Gigabeat S: This should fix stability problems. One problem was to ↵Michael Sevakis
start using the DVFS controller properly so that interrupts will be masked at the lowest and highest frequency indexes. Millions of useless interrupts were occurring at 132MHz because its index was 2, not 3, which masks it automatically when it can't go slower. Stopping the flood was enough to actually see the difference in general. IRQ must be disabled when fiddling with the CCM registers and only enabled when waiting for voltage ramp as having them enables also causes spurious DVFS ints. Implement interruptible ISR pro/epilogue more safely (always using IRQ stack even in SVC mode handling). Fix an improper inequality in DVFS code (which set regs for down when going up and v.v.). Misc. support changes. Have internal tables take less RAM. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25837 a1c6a512-1295-4272-9138-f99709370657
2010-05-05i.MX31/Gigabeat S: The nested IRQ code was just totally wrong and not ↵Michael Sevakis
actually working anyway (which is why it wasn't crashing). AVIC doesn't seem truthful about priority of current ISR either :\. Sometimes there were channel swaps during really active DVFS due to FIFO underflow from a needed long delay in the ISR (100us, and IIS TX only has 45us reserve) and DMARQ *must* be serviced low-latency. Get it doing as was intended. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25822 a1c6a512-1295-4272-9138-f99709370657
2010-05-04Merely correct a comment.Michael Sevakis
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25802 a1c6a512-1295-4272-9138-f99709370657
2010-05-04i.MX31/Gigabeat S: Just a little paranoid change to switcher write to active ↵Michael Sevakis
regulators method, to keep things localized a bit more from global data pool, for safety's sake. It's going to Mars afterall. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25801 a1c6a512-1295-4272-9138-f99709370657
2010-05-04i.MX31/Gigabeat S: Actually enable DPTC which can set optimal voltage for ↵Michael Sevakis
528MHz. Requires an SPI and PMIC interface rework because of the low-latency needs for the DPTC to work best with minimal panicing. SPI can work with multitasking and asynchronously from interrupt handlers or normal code. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25800 a1c6a512-1295-4272-9138-f99709370657
2010-05-03Gigabeat S: Those odd calls to irq_handler can still happen rarely after ↵Michael Sevakis
executing WFI. With no explanation forthcoming after trying many things, hide head in sand and ignore them and the IRQ will get vectored to the correct handler anyway. Have vector tables execute an immediate return and remove irq_handler from compilation altogether. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25792 a1c6a512-1295-4272-9138-f99709370657
2010-04-23Gigabeat S: All the target backlight functions are currently called on the ↵Michael Sevakis
backlight thread whereas that wasn't the case when the hardware fading was added. Now there's no danger of setting brightness interfering while setting up fades, so get rid of the superfluous mutex. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25700 a1c6a512-1295-4272-9138-f99709370657
2010-04-23i.MX31/Gigabeat S: Implement frequency and voltage scaling-- 1.6V for ↵Michael Sevakis
528MHz, and 1.35V for 264MHz and 132MHz. Keep DPTC overdrive ( > 400MHz) voltage scaling off for now because of uncertainties. Simplify the (working) mess later. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25699 a1c6a512-1295-4272-9138-f99709370657
2010-04-23i.MX31: Add some enums and a couple helper functions to make dealing with ↵Michael Sevakis
pin muxing and pad configuration a bit more sane. Convert any existing code which changes mux/pad settings to use helpers. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25698 a1c6a512-1295-4272-9138-f99709370657
2010-04-13Gigabeat S: Employ more accurate battery charging curve.Michael Sevakis
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25615 a1c6a512-1295-4272-9138-f99709370657
2010-04-10Gigabeat S/i.MX31: Continue, and most likely complete, the ↵Michael Sevakis
platform/player-specific code/data shuffling begun in r25547. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25564 a1c6a512-1295-4272-9138-f99709370657
2010-04-09Gigabeat S: Slow down the SPI clock to 1/8 current speed. It seems lower ↵Michael Sevakis
voltages can reveal the weakness that forbids maximum-speed clocking per the SPI spec. OF leaves it set much slower. Push it a bit over OF since it's been gotten away with fairly cleanly so far. Settings on pins and interface to be more thoroughly investigated. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25554 a1c6a512-1295-4272-9138-f99709370657
2010-04-09Gigabeat S: More accurate battery level estimation for discharge curve.Michael Sevakis
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25551 a1c6a512-1295-4272-9138-f99709370657
2010-04-09Gigabeat S: A little more housekeeping. Move source clock frequencies to ↵Michael Sevakis
config. header and name them per ref. manual designations. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25549 a1c6a512-1295-4272-9138-f99709370657
2010-04-09Gigabeat S/i.MX31: Sort files in the /target tree into things that are ↵Michael Sevakis
SoC-generic (into /imx31) and player-specific (into /gigabeat-s, based upon current appearances). Move i2s clock init into the appropriate file. Housekeeping only-- no functional changes. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25547 a1c6a512-1295-4272-9138-f99709370657
2010-04-07Make ATA code not bother to retry requests that return IDNF (specified ↵Torne Wuff
sector not valid). There's no point retrying these requests for five seconds, the sector number isn't going to get any more valid. It interferes with being able to detect broken drives like the 5.5G 80GB iPod's. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25525 a1c6a512-1295-4272-9138-f99709370657
2010-04-07Gigabeat S: Add some sanity checks for a strange charging anomaly that I ↵Michael Sevakis
have personally witnessed twice-- no, I don't have photos or a YT video but it did happen. Details are given in a comment in powermgmt-imx31.c. If it happens again, the checks may serve to reveal the true cause. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25524 a1c6a512-1295-4272-9138-f99709370657
2010-04-07Gigabeat S: Extend the upper temperature range for battery charging to 50C: ↵Michael Sevakis
OK and 45C: Resume. Currently extended disk activity can cause it to detect overtemp which doesn't quite seem correct. Add macros for the range so that they may be target-specific. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25508 a1c6a512-1295-4272-9138-f99709370657
2010-04-07Gigabeat S (imx31): Begin voltage and frequency scaling code. For now, to ↵Michael Sevakis
avoid overdrive voltage, just lower core voltage to 1.35V since voltage scaling shouldn't be required for frequencies lower than 399 MHz (according to Freescale BSP, which set all working points to 1.35V for those frequencies). Perhaps battery life will improve as well (cross fingers :). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25506 a1c6a512-1295-4272-9138-f99709370657
2010-01-24ARM: lr addresses the next instruction after the failing one in undefined ↵Rafaël Carré
instruction vector Substract 4 before passing the argument to UIE so the correct address is displayed git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24321 a1c6a512-1295-4272-9138-f99709370657
2010-01-03Fix tabsAndree Buschmann
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24153 a1c6a512-1295-4272-9138-f99709370657
2009-12-31Enable and initialize VFP on imx31. VFP state is not saved on thread change, ↵Andrew Mahone
and it is initialized for scalar operations, rounding toward zero, with exception/error handling and "correct" handling of NaN and denormal values disabled. In this mode it should still be usable for integer divisions (by casting operands to double and result to int or unsigned). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24129 a1c6a512-1295-4272-9138-f99709370657
2009-11-20Increase stack space for the Gigabeat S specific headphone thread to fix ↵Nils Wallménius
stack overflow when compiled with gcc 4.4 git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23678 a1c6a512-1295-4272-9138-f99709370657
2009-10-26Make current_vp static and importings from Gigabeat F/X/S lcd drivers as ↵Thomas Martitz
they don't need it anymore. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23354 a1c6a512-1295-4272-9138-f99709370657
2009-10-26Color targets: Ported assembler optimised transparent bitmap drawing from ↵Jens Arnold
Gigabeat S/F/X to all ARM targets (~23..40% speedup). * C optimised transparent bitmap drawing for non-ARM targets and sims. * Use the more compact boundary checking for non-transparent native bitmap drawing as well. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23353 a1c6a512-1295-4272-9138-f99709370657
2009-10-20Convert lcd_activation callbacks to use the event system to allow for ↵Thomas Martitz
multiple parallel callbacks (for custom statusbar). Increase maximum event count as we need more (I actually had a report about it during custom statusbar testing). Removed corresponding functions from the core and plugin api. Bump min version and sort. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23302 a1c6a512-1295-4272-9138-f99709370657
2009-10-17Revise r23225 a bit, removing the debug_printf function and implementing ↵Nils Wallménius
more generic lcd_(remote)_putsf function(s) instead and use those in more places git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23233 a1c6a512-1295-4272-9138-f99709370657
2009-08-19fix redNils Wallménius
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22432 a1c6a512-1295-4272-9138-f99709370657
2009-08-06Revert static-ing of iim_prod_rev, this function is never used so it causes ↵Bertrik Sikken
a compiler warning. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22185 a1c6a512-1295-4272-9138-f99709370657
2009-08-06Various files: make functions static if they're local or make sure there is ↵Bertrik Sikken
a proper #include if not git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22184 a1c6a512-1295-4272-9138-f99709370657
2009-06-29Put TIMER_FREQ definition in CPU-specific config, and remove timer-target.hRafaël Carré
Note : SH has TIMER_FREQ defined to CPU_FREQ, so any code wanting it must include #config.h before #cpu.h git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21560 a1c6a512-1295-4272-9138-f99709370657
2009-06-29Remove the TIMER_* macros and declare target-specific functions in timer.hRafaël Carré
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21559 a1c6a512-1295-4272-9138-f99709370657
2009-06-29Remove int_prio argument from timer_register, and move the only use for it ↵Rafaël Carré
into alpine_cdc plugin, since this plugin is only built on SH7034 Also remove it from TIMER_START() git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21558 a1c6a512-1295-4272-9138-f99709370657
2009-06-29Move SH7034 timer code in the target treeRafaël Carré
Add an argument int_prio to TIMER_START() macro because SH7034 needs it Leaves a target specific code in timer_register (could be given to target code through timer_set and __timer_set() ) git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21556 a1c6a512-1295-4272-9138-f99709370657
2009-06-29Rename TIMER_REGISTER macro to TIMER_START and TIMER_UNREGISTER to ↵Rafaël Carré
TIMER_STOP to reflect what they does exactly. registering and unregistering are handled by the non target-specific functions of timer.c Remove arguments from the new TIMER_START since they are unused by targets git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21553 a1c6a512-1295-4272-9138-f99709370657
2009-05-21Remove some unused declarationsBertrik Sikken
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21010 a1c6a512-1295-4272-9138-f99709370657
2009-05-17Fix duplicate #includesBertrik Sikken
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20977 a1c6a512-1295-4272-9138-f99709370657
2009-04-26Remove the calls to backlight_lcd_sleep_countdown from target specific code ↵Thomas Martitz
and move it into backlight.c git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20793 a1c6a512-1295-4272-9138-f99709370657
2009-03-22imx31: Oops. Fix a misplaced comma in wmcodec-imx31.c. Add a couple ↵Michael Sevakis
parentheses in statment (just to be clearer). Should take care of things for now :). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20444 a1c6a512-1295-4272-9138-f99709370657
2009-03-22imx31: Rename clkctl-imx31.* to ccm-imx31.* and move up from ↵Michael Sevakis
...imx31/gigabeat-s to .../imx31. A bunch more should probably go up a level too. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20443 a1c6a512-1295-4272-9138-f99709370657
2009-03-22imx31/mc13783: Do some housekeeping with register macros, function names and ↵Michael Sevakis
other defines. No functional changes (except to alter a couple int priorities). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20442 a1c6a512-1295-4272-9138-f99709370657
2009-03-17Rework lcd_enabled and lcd_set/call_enable hookThomas Martitz
a) lcd_enabled() is now lcd_active(), and is available for HAVE_LCD_SLEEP only targets (e.g. ipod video) too. It was depandent on HAVE_LCD_ENALE only before b) rename the hook accordingly, and implement the hook for other other targets too (e.g. the clip [the only mono target with lcd_enable/lcd_sleep yet, so the code is still in the lcd driver], ipod, fuze, c200) git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20331 a1c6a512-1295-4272-9138-f99709370657
2009-03-12Gigabeat S: Implement MDMA and UDMA disk access for bootloader and main ↵Michael Sevakis
binary. Add a needed SDMA API to check channel errors. Increase audio DMA channels' priority as required. Reads and writes measure faster accross all test_disk tests and especially at 4KB and 1MB. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20299 a1c6a512-1295-4272-9138-f99709370657
2009-03-09Gigabeat S: Switch SSI1 and 2 around so that playback can use the shared ↵Michael Sevakis
peripheral DMA with SSI2 which doesn't require use of the peripheral DMA unit-- SSI2 is mapped to the SDMA core address space. Fix some break keywords in get_script_pc(). Use the patched script for mcu_2_app (BSP appears to have neglected to update that). Use _SHP instead of _SP for shared peripheral constants (consistency). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20254 a1c6a512-1295-4272-9138-f99709370657
2009-03-02imx31 ATA: Correct a register #define error (due to error in user's manual). ↵Michael Sevakis
Fix timing for PIO tAX. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20169 a1c6a512-1295-4272-9138-f99709370657
2009-02-13Separate running an SDMA channel from resetting it. It should make usage ↵Michael Sevakis
more flexible since resets are needed only before restarting if aborting transfers (because the script is left awaiting requests, not the next start) which PCM does alot of but other things likely won't. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20000 a1c6a512-1295-4272-9138-f99709370657
2009-02-12Gigabeat S: Handle any DMA playback errors reported and stop in that case ↵Michael Sevakis
(none are expected but it's better to handle than ignore). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19983 a1c6a512-1295-4272-9138-f99709370657
2009-02-12Gigabeat S: No need to do cache writeback on recording buffers now.Michael Sevakis
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19982 a1c6a512-1295-4272-9138-f99709370657