Commit graph

31289 commits

Author SHA1 Message Date
Amaury Pouly
5e7bd97e04 fuze+: correctly handle settings (flip and invert) accross enable
The flip and invert settings can potentially be reset to their
value accross a disable/enable cycle, so save the value of the
impacted registers and apply it after each enable. Also avoid
poking registers when the lcd is not on.

Change-Id: Ica98f166c060aade7eb205f5628b58aae692024f
2013-01-12 19:04:20 +00:00
Amaury Pouly
0946a1e0f2 imx233: enable underflow recovery in lcdif (needed for freq scale)
When chaging the cpu and memory frequency we need to disable the
external memory interface (EMI) for a small time. This can
underflow the dma and cause some breakage. Hopefully the SSP
controller handles this gracefully by stopping the clock and the
I2C probably handles this naturally because the clock can be
streched anyway. However the LCDIF has a special setting for this
which needs to be enable, otherwise it will send garbage to the
LCD. No other block is known to suffer from this currently but
this issue might have more unexpected consequences.

Change-Id: Ide154cad87929f2bf6cc419ac1d2ff33e30eec66
2013-01-12 18:58:19 +00:00
Marcin Bukat
2ef7a549d5 rk27xx: optimize irq_handler()
Change-Id: Idd3141e57b70e9b28b91748bc71208d9afffcd57
Reviewed-on: http://gerrit.rockbox.org/381
Reviewed-by: Marcin Bukat <marcin.bukat@gmail.com>
Tested-by: Marcin Bukat <marcin.bukat@gmail.com>
2013-01-11 15:41:11 +01:00
Marcin Bukat
efe1042759 rk27xx: substitute magic constants with meaningful names for INTC
Change-Id: Ic93114db351a9940a53d0c1df6439d82ada044e1
2013-01-10 20:23:41 +01:00
Marcin Bukat
15818bef55 rk27xx: substitute magic constants with meaningful names for peripherials reset
Change-Id: Ia411c9be65376d1c3fdf59b7e692b0590d58775e
2013-01-10 20:23:41 +01:00
Marcin Bukat
2b6dfdb34e rk27xx: substitute magic constants with meaningful names for clock gating
Change-Id: I6c66c7496db3db78e5c959414464826134dbe200
2013-01-10 20:23:41 +01:00
Amaury Pouly
1fa406dc21 imx233: modify arm cache timings on frequency switch
The manual recommands to tweak the arm cache settings on frequency
changes. The meaning of these values is undocumented but 0 seems
to be a safe value for all frequencies whereas 3 seems to be valid
only for low frequencies (<=64MHz ?)

Change-Id: Iaa8db4af8191010789cf986b1139ff259d73e2ed
2013-01-10 01:02:12 +00:00
Amaury Pouly
5aa19f3eeb imx233: implement emi frequency scaling (disabled by default)
CPU frequency scaling is basically useless without scaling the
memory frequency. On the i.MX233, the EMI (external memory
interface) and DRAM blocks are responsable for the DDR settings.
This commits implements emi frequency scaling. Only some settings
are implemented and the timings values only apply to mDDR
(extracted from Sigmatel linux port) and have been checked to
work on the Fuze+ and Zen X-Fi2/3. This feature is still disabled
by default but I expected some battery life savings by boosting
higher to 454MHz and unboosting lower to 64MHz.
Note that changing the emi frequency is particularly tricky and
to avoid writing it entirely in assembly we rely on the compiler
to not use the stack except in the prolog and epilog (because
it's in dram which is disabled when doing the change) and to put
constant pools in iram which should always be true if the
compiler isn't completely dumb and since the code itself is put
in iram. If this proves to be insufficient, one can always switch
the stack to the irq stack since interrupts are disabled during
the change.

Change-Id: If6ef5357f7ff091130ca1063e48536c6028f23ba
2013-01-10 00:51:35 +00:00
Amaury Pouly
b9923df170 imxtools/nwztools: fix compilation for windows
There is a windows port of the sg_utils library for scsi pass-
through. This little changes make it compile under mingw. A better
fix would be to implement direct ioctl on both windows and linux
but that's already better than nothing

Change-Id: I0d77cd1bad69806a66f0590362f165f24fa240e9
2013-01-10 00:51:35 +00:00
Cástor Muñoz
758a3ae4bb iPod Classic/6G: PCM support for all CS42L55 rates
pcm_dma_apply_settings(): sets the configured PCM frequency,
all native CS42L55 sample rates are available.

Change-Id: I2fcd5581457a669c3044516804cb64fb972218d0
2013-01-09 22:08:28 +01:00
Cástor Muñoz
17e57e3291 iPod Classic/6G: support USB suspend mode
Actually Rockbox does not use this mode, it is supported by
other iPods, so implemented on Classic as well.

Change-Id: Ia6578506df27a95a7f7522b3034b764631a8bb3a
2013-01-09 22:08:27 +01:00
Cástor Muñoz
1d901a82fd iPod Classic/6G: fix battery voltage ADC scale
Scale battery voltage ADC readings by 1023 instead of 1000,
using ADC1 (substractor) instead of ADC0 (multiplicator) to
get better resolution.

Percent charge/discharge tables are also modified to return
a similar value than the old ones.

Change-Id: I2951c75faa02f4302599ec24f9156cfd209c36eb
2013-01-09 22:08:27 +01:00
Thomas Martitz
d798c721e5 android: Update to SDK r16 and ndk r8d.
SDK r17 is out, however there it only ships a x86 system image for r16 so
it's preferable.

Change-Id: Idc4d375debf407a36c2dc6421420bdbd74ab25ca
2013-01-09 10:33:08 +01:00
Alex Parker
62de15fedf Tidy up the sim x5 image by Martin Sägmüller
Change-Id: I70394e9b81964605d5af32df6dd87a8ca29c78e7
2013-01-03 23:54:41 +00:00
Frank Gevaerts
b90316cab7 Bump the plugin api version. This should have been in 212e7808.
Change-Id: I4525d62782af1ad1c0e5e92605421063b8c9b72b
2013-01-04 00:34:12 +01:00
Jonathan Gordon
c500f4efe5 radio screen: Disable displaying radio art, FS#12797
With radioart enabled there appears to be buffer corruption when
the image is loaded causing the player to data abort in skin_render_line()

So, disable the code untill someone can fix it.

Change-Id: I6acf3f76ce38aa2784b1b24ed6da29a9c5bee479
2013-01-03 23:09:01 +11:00
Richard Quirk
212e7808d5 Use crc32 of filename to resume tracks
As well as using an index, which breaks when a file is added or
removed, use the crc32 of the filename. When the crc32 check passes the
index is used directly. When it fails, the slow path is taken checking
each file name in the playlist until the right crc is found. If that fails
the playlist is started from the beginning.

See http://www.rockbox.org/tracker/6411

Bump plugin API and nvram version numbers

Change-Id: I156f61a9f1ac428b4a682bc680379cb6b60b1b10
Reviewed-on: http://gerrit.rockbox.org/372
Tested-by: Jonathan Gordon <rockbox@jdgordon.info>
Reviewed-by: Jonathan Gordon <rockbox@jdgordon.info>
2013-01-02 08:29:38 +01:00
Hayden Pearce
17181ecf30 Fixes a typo in rockbox.desktop
Change-Id: Ibae1b391205e5372a506dc8f3820a53f7012252c
Reviewed-on: http://gerrit.rockbox.org/378
Reviewed-by: Jonathan Gordon <rockbox@jdgordon.info>
2013-01-02 03:41:10 +01:00
Dominik Riebeling
163ab46170 Provide dealloc function to sansapatcher.
Similar as done with ipodpatcher provide a function to free the allocated
sector buffer.

Change-Id: Ie51e82f7191496bb48973148af1cc35cd37993d3
2013-01-01 15:06:41 +01:00
Dominik Riebeling
a8d291bd20 Fix cross compiling sansapatcher.
windres also needs the cross compiler prefix.

Change-Id: Ia27ac8b9f3b47962764eff6b960e1105544b0b89
2013-01-01 15:06:41 +01:00
Dominik Riebeling
b63d429c8f Provide dealloc function to ipodpatcher.
On Windows the sector buffer is allocated using VirtualAlloc, thus releasing
this buffer should be done using VirtualFree. Provide an additional function
for deallocating the buffer so users of ipodpatcher do not need to know about
this.

Change-Id: Ibb0fc575a185148a389e63935e86a392bf8d180d
2013-01-01 15:06:41 +01:00
Dominik Riebeling
45cda1fdcc Fix version handling for patchers.
The working directory will usually be different than the one libtools.make is
located in, so make sure to use the correct starting folder for the relative
path.

Change-Id: I9a84a0573c9f1f32601f31587425689dcf8fb81f
2013-01-01 15:06:40 +01:00
Dominik Riebeling
9c1ed84d28 sansapatcher: move sectorbuf pointer into sansa_t structure.
Similar as the ipod_t structure for ipodpatcher the sansa_t structure holds all
relevant information for sansapatcher. Put the global sansa_sectorbuf pointer
into it as well.

Change-Id: Iad08ef6aafc49609c3d0d556914246f230ee0179
2013-01-01 15:06:34 +01:00
Dominik Riebeling
24e37ddf57 ipodpatcher: move sectorbuf pointer into ipod_t structure.
The ipod_t structure holds all relevant information for ipodpatcher. Put the
global ipod_sectorbuf pointer into it as well. Allows the Rockbox Utility Ipod
class to be instanciated multiple times since each instance can now have its
own buffer.

Change-Id: Ie319cbadbc20c367ceadba9a46b4dc34b57a79a7
2013-01-01 15:05:52 +01:00
Hayden Pearce
6803d7b10c iPod6G (Classic) - enable HAVE_DISK_STORAGE
Fixes missing Settings - General Settings - System - Disk - Spindown
setting.

Change-Id: Iae686598dfd7ad4ca1faf8db9f1271e7808de752
Reviewed-on: http://gerrit.rockbox.org/376
Reviewed-by: Michael Giacomelli <giac2000@hotmail.com>
Tested-by: Michael Giacomelli <giac2000@hotmail.com>
2012-12-29 21:25:57 +01:00
Amaury Pouly
935d8beab1 imx233: increase irq storm threshold
On heavy storage operations (like database update), the ssp dma
irq can be fired around ~10000/sec.

Change-Id: I0e33df6258e051abd4fe110a0f408a19671cd8ad
2012-12-29 02:53:21 +01:00
Amaury Pouly
68ff43e94b imx233: correctly restore auto slow on cpu frequency change
Change-Id: I3ba495488e20fdd19d391f84ff484c1ce305d11b
2012-12-29 01:40:35 +01:00
Amaury Pouly
2b1159dda0 imx233: move power init to system init
Do low level power init in system_init(). This can be needed
since imx233 must be able to frequecy scale atfer system_init()
and kernel_init() and this is only possible if power system was
initialised.

Change-Id: I27c66ec0dccd60bda26a45be24683c0bfe72c6da
2012-12-29 01:40:35 +01:00
Amaury Pouly
f7132e4044 Fix copyright headers
Change-Id: Ie65920b1192e9b737fcc2554d280fbcedfa39800
2012-12-29 01:40:35 +01:00
Andrew Ryabinin
97250a0156 hm60x/hm801: Add hold button support.
Change-Id: I05557ecfbf0bd821d8966862a38f7f22656b36ef
2012-12-29 00:19:23 +04:00
Michael Sevakis
362ade3892 Fix FS#12794 - new EQ code does not compile for the Nokia N8x0
The old GCC version currently required (sbox-arm-linux-gcc 3.4.4
release) apparently has trouble with function pointers used as
static array initializers when using indexed initializers + ranges
(ie. [A ... B] = fn).

Change-Id: I494c2b607e4d93a9893264749d0ac257fb54ce3b
2012-12-28 14:12:18 -05:00
Amaury Pouly
8ecbcad3d1 imx233: use tick insteaf of msec to collect statistics
The current code uses the msec irq to collect statistics and
detect irq storms (debug). But this irq is triggered 1000 times
per sec and we don't need that accuracy. This commit removes the
msec irq and use the tick timer instead which is triggered only
100 times per second.

Change-Id: If14b9503c89a3af370ef322678f10e35fafb4b8a
2012-12-26 21:26:33 +01:00
Thomas Jarosch
e3fbced283 Prepare new, unofficial maemo release
Change-Id: I6fccaeb131f31938d6f2cc0c0d1ffc62821bd3b6
2012-12-26 19:59:29 +01:00
Thomas Jarosch
1bd2ac5276 Maemo port: Exclude plugins requiring a keymap from packaging
Change-Id: Ia713621a97737966c1fead66965cd33cb711c8bf
2012-12-26 19:58:02 +01:00
Frank Gevaerts
18f0ba003c Revert 64d048be. It breaks h300.
HAVE_USB_CHARGING_ENABLE is not only used for software usb, so checking
for HAVE_USBSTACK is wrong.

Change-Id: I422796b517c262f33f35623e992434219e288424
2012-12-26 18:01:19 +01:00
Frank Gevaerts
64d048be2b Make code that depends on HAVE_USB_CHARGING_ENABLE check HAVE_USBSTACK.
This fixes building without HAVE_USBSTACK

Change-Id: If8fec87a3ed4de583864ed2bab69be1f2ad8ac52
2012-12-26 17:52:15 +01:00
Jean-Louis Biasini
5caaf70f34 [Fuze+] imageviewer: update/complete keymaps
1) update/complete keymaps (now handle slideshow)
2) update/complete manual

Change-Id: I1baf2598941bb781a2f2777f23eb543bd6bf5848
Reviewed-on: http://gerrit.rockbox.org/354
Reviewed-by: Amaury Pouly <amaury.pouly@gmail.com>
2012-12-26 17:30:54 +01:00
Jean-Louis Biasini
0f0adfac71 [Fuze+] PictureFlow: complete keys mapping
1) add quit and menu binding
2) complete manual

Change-Id: Iceee6354c788b8baeefeea2d2d8914e1df83d4a7
Reviewed-on: http://gerrit.rockbox.org/353
Reviewed-by: Amaury Pouly <amaury.pouly@gmail.com>
2012-12-26 17:30:31 +01:00
Jean-Louis Biasini
7c488f5053 [FUZE+] Rockblox plugin slight keymaps update
1) slight keymaps update
Remove mapping of BUTTON_BACK reseting game to avoid pressing it
involuntary.
Direct mapping of BUTTON_POWER to go into menu.
2) manual updated
Change-Id: I28875104c4a4058216532b9aa12bb2defabcca6d
Reviewed-on: http://gerrit.rockbox.org/352
Reviewed-by: Amaury Pouly <amaury.pouly@gmail.com>
2012-12-26 17:30:08 +01:00
Amaury Pouly
c96f580d63 fuze+: fix bootloader build
Change-Id: Ibe221d0f94ec4234ce1459073ba9ae77f6de162f
2012-12-26 02:50:41 +01:00
Amaury Pouly
d9177c4c65 fuze+: implement lcd flip and invert
Change-Id: I1efcd0c6aa5e586b64c1b48d401648c7a933c4d9
2012-12-26 02:41:41 +01:00
Amaury Pouly
38878020d2 fuze+: make sure lcd is ready before chaning a register
The lcd driver does not wait for the refresh to be done to return
from lcd_update(). This means that changing a register is unsafe
if done in the middle of the redraw. This could happen when
disabling the lcd for example. Make sure it doesn't happen by
waiting for the lcdif to be ready.

Change-Id: I43ec62a637dd61c3b2a3a6e131c1a9e8035524b1
2012-12-26 02:39:39 +01:00
Amaury Pouly
7fddc2327b fuze+: add lcd debug screen (display kind)
Change-Id: I08ffcfb8e4cf516aae1c23740eedf80d2cfcea41
2012-12-26 02:38:56 +01:00
Amaury Pouly
09e6b890e6 imx233: rework cpu frequency scaling
When changing the cpu frequency, it is important to make sure that
HBUS stays at a reasonable frequency otherwise the chip will
crash. Special care is needed about auto-slow and clk_p/clk_h
ratio on intermediate steps.

Change-Id: Ief9f68ddf286caabe75c879718dac5027ab1560f
2012-12-26 01:17:28 +01:00
Amaury Pouly
e2da3f47d3 imx233: fix regulator voltage setting + always enable DCDC mode
Make sure DCDC is running at boot (it is disabled by default when
5V is present and we don't want to rely on the bootloader to
change this).
When changing the voltage on a regulator, it usually takes 2ms for
the voltage to stabilize. In DCDC mode, there is an irq to notify
about the event so use it ! This is especially important when
changing cpu frequency because increasing the cpu freq while the
voltage is rising is unreliable.

Change-Id: Icfe9ef3ee90156d1e17da0820d9041859f7f3bca
2012-12-26 01:17:28 +01:00
Amaury Pouly
ca83b558df imx233: fix potential hbus dividor settings + doc
HBUS uses the same field for integer and fractional dividers, the
choice is made by a bit. Make sure both are changed together,
otherwise this could result in the wrong divider to be used and in
HBUS freq to be too low or too high (very bad).

Change-Id: I253d8eeee26c5038868b729c4f791511295a39f0
2012-12-26 01:17:28 +01:00
Amaury Pouly
423755d1bd imxtools/sbtools: improve sb1 key handling
Change-Id: Ib014a102fe44a67dd256e45e804bca9b5812eb61
2012-12-26 01:17:28 +01:00
Amaury Pouly
c3a7190d78 imxtools/sbtools: add crypto code for documentation purpose
Change-Id: I4f3c659d65c1453b192cbce4bf6c85d882761929
2012-12-26 01:17:27 +01:00
Amaury Pouly
54a414b69e elftosb1: fix usage()
Change-Id: I9ce73b907fa6276b9cd1f285156623bdafa6d548
2012-12-26 01:17:27 +01:00
Thomas Jarosch
4dcabec7cc Pandora port: Prepare unofficial release
Code is based on the 'v3.12-final' tag.

Only tweak is that most plugins are not
distributed due to missing keymaps.

Change-Id: Ia09e52076e128504c1f1883078c29c408600f063
2012-12-26 01:00:29 +01:00