Commit graph

31683 commits

Author SHA1 Message Date
Amaury Pouly
239219ee70 imx233: fix power for stmp3600 and stmp3700
There are many small differences between them. In particular
some regulators are not available on stmp3600. Also the vbusvalid
detect method is not available as an irq on stmp3600 and seems
broken on stmp3700. Finally die temperature is handled by the
power block on stmp3600.

Change-Id: I2c68b418738f15564e445d3a1496018cef97fff7
2013-06-17 00:29:25 +02:00
Amaury Pouly
2d0d752bf8 imx233: fix clkctrl for stmp3600 and stmp3700
Change-Id: I7596e41c0d0b7fdcc18f7d328a0927c2c78dc4cb
2013-06-17 00:29:24 +02:00
Amaury Pouly
023621d401 imx233: fix icoll for stmp3600 and stmp3700
Change-Id: I97b86d67b53615eca0d870058ff5c095c3063151
2013-06-17 00:29:24 +02:00
Amaury Pouly
8ed8a79f5c imx233: various sdmmc fixes
Change-Id: I261d0bdea1e7c5bc9139b10bf42e7ce7ce6b6dd8
2013-06-17 00:29:24 +02:00
Amaury Pouly
fbee03e0f0 imx233: simplify timer code
Change-Id: I845c3f20c17ce6091ed02bc4fbfca176358d31b7
2013-06-17 00:29:24 +02:00
Amaury Pouly
f1c6c71218 imx233: improve ssp
Under some circumstance (timeout), the dma interrupt is not fired
and only the error one is. This can happen with some picky SD
cards and with the current code it causes a 1 second timeout.
This code properly catches the error interrupt to stop as soon
as possible.

Change-Id: I9c53ea272d01793f0f229571502e99eb62f1b723
2013-06-17 00:29:24 +02:00
Amaury Pouly
49ea1b3cef imx233: make linker file more regular
Change-Id: Ic3fe21be9124af71eae88a00793f914fe03ee5a2
2013-06-17 00:29:24 +02:00
Amaury Pouly
f8d2984875 imx233: enhance pwm
The current pwm interface is too low-level. Introduce a higher
level setup function which directly computes the parameters from
the required frequency.

Change-Id: Ie95c7522e9f42492fe872203f4cab46770a9649a
2013-06-17 00:29:24 +02:00
Amaury Pouly
f5ac658d16 imx233: normalise clkctrl
The clkctrl functions were becoming a mess. Normalise the names,
get rid of the xtal derived as special case and use the same
interface.

Change-Id: Ib954a8d30a6bd691914b5e0d97774ec9fc560c50
2013-06-17 00:29:24 +02:00
Amaury Pouly
84fc327aeb imx233: introduce virtual pins to simplify pin setup
A number of pins on the imx233 are standard and manually calling
functions to acquire, set function/drive/output is painful. This
will become unmanageable when we will add support for the other
stmp chips.
Introduce the concept of virtual pin which is a way to completely
describe a virtual pin (virtual because pins are muxed).

Change-Id: I01b6e040945648e58e1d1abab06529c9571c5f10
2013-06-17 00:29:24 +02:00
Amaury Pouly
8f351d6e21 imx233: enhance pinctrl irq with user pointer
Change-Id: I191704299487598a853af4df5aebbbf8a7134a34
2013-06-17 00:29:24 +02:00
Amaury Pouly
918a06a12a imx233: normalise pinctrl names
The current pinctrl functions were a mess. Normalise the functions
names to make them shorter and clearer.

Change-Id: Iac6ff84625ef2b7610268e3a5802dc0088de3167
2013-06-17 00:29:24 +02:00
Frank Gevaerts
abb7d1dcfe plugin_midi: expand gustable[] to 128 entries
The code assumes that gustable[] has 128 entries, while it
only had 120. Since the entries follow a simple pattern (they
seem to be note frequencies, so each entry is the previous one
multiplied by the 2^(1/12)), expanding the table is the simple
fix.

Change-Id: If5b5a50378afd3206c9d550227dd9aac8e355c96
2013-06-16 18:33:57 +02:00
Frank Gevaerts
d4061a46d8 Silence some (harmless) warnings.
Change-Id: I8d1278b8cfaa376d2ad5a99dd552dc980c66e1da
2013-06-16 18:23:18 +02:00
Amaury Pouly
8390eb931e imx233: rewrite dma using new register headers
Change-Id: If73b84d9c9f4a152a54fb9d2dbec895e72d2e753
2013-06-16 18:21:49 +02:00
Amaury Pouly
852a82b90a imx233: rewrite timrot using new register headers
Change-Id: Ia6dc7ac7e1fdf471a518111f5593bd96bc3acfac
2013-06-16 18:21:49 +02:00
Amaury Pouly
96b1d02b05 imx233: rewrite digctl using new register headers
Change-Id: I910a09e07b9f5a82bb6cb150739fcebc942cb7c1
2013-06-16 18:21:48 +02:00
Amaury Pouly
a759242b55 imx233: rewrite ssp using new register headers
Change-Id: Ibf186b610beb07bd615c976630cdca9de2c7448e
2013-06-16 18:21:48 +02:00
Amaury Pouly
94cb72301d imx233: fix sdmmc code
The SD SWITCH command has a result and can take a long time to
finish. Ignoring the answer and waiting an arbitrary time is
unreliable at best.

Change-Id: I1bfbb193952b96598f8bb056bac88220d4edf1fc
2013-06-16 18:21:48 +02:00
Amaury Pouly
2d12ef6c73 imx233: rewrite rtc using new registers
Change-Id: I30794dac2175d5717ea8e05e911abec65a214c44
2013-06-16 18:21:48 +02:00
Amaury Pouly
3e8c2dc46d imx233: rewrite pwm using new registers
Change-Id: Ie222f0b25f4b8af9ccf21aecd82a7f4eba40aa3c
2013-06-16 18:21:48 +02:00
Amaury Pouly
7c5b65b9d2 imx233: rewrite power using new registers
Change-Id: Ifbee91161220419f4d1750672b5c4ae3537cefca
2013-06-16 18:21:43 +02:00
Amaury Pouly
b73fda3a05 imx233: rewrite pinctrl using new registers
Change-Id: I907a0b599ef65061360c215580f96f59b78b615b
2013-06-16 16:58:01 +02:00
Amaury Pouly
6f0eaf4827 imx233: rewrite ocotp using new register headers
Change-Id: I3c622119a1e296ec6b3f35f27e81b5118ab7f6cc
2013-06-16 16:58:00 +02:00
Amaury Pouly
d815cf3c79 imx233: rewrite lradc using new register headers
Change-Id: I06e4467c0ffe33145e6192528b074a23a8df67cc
2013-06-16 16:57:54 +02:00
Amaury Pouly
8517cf8bed imx233: rewrite lcdif using the new register headers
Change-Id: I94329a65a7c6a4127fa05b77b9a7a291f8a50013
2013-06-16 16:32:03 +02:00
Amaury Pouly
0fa014a6fe imx233: rewrite i2c using new register headers
Change-Id: Ieffb389fb74404e86d8ba51ee8c48bab6b299763
2013-06-16 15:58:36 +02:00
Amaury Pouly
3d62000fcb imx233: rewrite gpmi using new register headers
Change-Id: I8284836a79ac7e6d59da040df63f6fcf43857191
2013-06-16 15:52:03 +02:00
Amaury Pouly
444a8b1da0 imx233: rewrite audioin using new register headers
Change-Id: I7d71d16361a29030d0eb6de5c518168947516d39
2013-06-16 15:47:55 +02:00
Amaury Pouly
df9e6c3147 imx233: rewrite audioout using new register headers
Change-Id: I20dddec437187c0974ac16027548dbe3dd097c59
2013-06-16 15:45:32 +02:00
Amaury Pouly
e6a931301f imx233: rewrite emi using new register headers
Change-Id: Ie893162aac38ea3aaf73b4e84e54be714a5fc33f
2013-06-16 15:30:46 +02:00
Amaury Pouly
2a01b3766f imx233: rewrite clkctrl using new register headers
Change-Id: I6c79e99ed4ab20e00c3110d870e144a6c8596769
2013-06-16 15:28:04 +02:00
Amaury Pouly
f545908c16 imx233: rewrite icoll to use new register headers
Change-Id: I0bf30849d18a8493627025b383ce75ce524777ab
2013-06-16 14:46:58 +02:00
Amaury Pouly
81224c62bb imx233: add subtarget and package type to configure files
Change-Id: I234dab0e861d38abf866803bfcd729c63a8ee3ed
2013-06-16 14:39:58 +02:00
Amaury Pouly
d561017f35 mkimxboot: factor code, add support for ELF files
Refactor code.
This tool can now either load a scrambled rockbox
firmware (in which case the model is check against the
firmware), or any ELF file. This is useful for example
for hwstub which produces a ELF file and still needs
to be loaded by producing a SB file.

Change-Id: I7aa381b3f6587788d1950793e89ce5608c53cccc
2013-06-16 02:14:52 +02:00
Amaury Pouly
7c7fa36918 sbtools,mkximboot: fix whitespace
Change-Id: I8d8adb783707172d1aaef302366c240310350ed8
2013-06-15 22:27:34 +02:00
Amaury Pouly
58e27b9fa1 mkimxboot: refactor code, no functional change
The mkimxboot was becoming messy with juge functions and
redundant code. Factor reading/writing/loading code into smaller
functions. Introduce the concept of rockbox firmware to simplify
support of other formats than scramble.

Change-Id: I3a61295ca5abca1a0eee8c9e8709c6b8dfa256a6
2013-06-15 22:27:34 +02:00
Amaury Pouly
6483e23f07 mkximxboot: fix usage() formatting
Change-Id: I2f708e2830168f481018b8d8ce98134e40b4e8f8
2013-06-15 22:27:34 +02:00
Amaury Pouly
5aab4431fb Cosmetics
Change-Id: Id7974f1a79b5d803155ccfc417277a73ffd9046a
2013-06-15 22:27:34 +02:00
Amaury Pouly
dda1d5ca48 imx233: add register selector file
Register set selection is based on the value of the
IMX233_SUBTARGET value. The reg-select.h file (used by the
generated headers), does the selection based on this value as
follows:
- 3600 <= . < 3700: stmp3600 register set
- 3700 <= . < 3780: stmp3700 register set
- 3780 <= .: imx233 register set
Note that this selector relies on the name of the socs in the
register description to be respectively stmp3600, stmp3700 and
imx233.

Change-Id: I793b18e6c4f3fea85aa74f4c6be3affb0622c14e
2013-06-15 22:27:34 +02:00
Amaury Pouly
017667c2dc imx233: generate register headers for stmp3600, stmp3700 and imx233
Change-Id: Ia87086f4f4f4ecbb844ffd869407b14ea2509934
2013-06-15 22:27:34 +02:00
Amaury Pouly
97b9ade639 regtools: improve header generator
The generator now has more options to generate or not selectors.
It can also generate a macro header containing lots of using
macros for register operations.

Change-Id: I9dd6b4bdc7daeabd1a2c9365ce082358475721b5
2013-06-15 22:27:33 +02:00
Dominik Riebeling
b6ddbc41a5 Fix id3v2 album art if more than one image is present.
Rockbox only uses the first album art image (APIC / PIC frame) found in id3v2
tags. When a file contains more than one image the second one is ignored but
the parsealbumart() callback overwrites the already set data. This causes the
metadata structure to contain an invalid pointer to the image data, resulting
in no image shown.

Make parsealbumart() aware of this and skip parsing when an albumart image has
already been found. Fixes FS#12870.

Change-Id: Id8164f319cd5e1ee868b581f8f4ad3ea69c17f77
2013-06-15 21:04:13 +02:00
Nils Wallménius
084c75e5f9 Fix building of sh, arm and m68k toolchains with new texinfo
Recent versions of texinfo breaks various binutils and GCC
builds. For GCC setting MAKEINFO=missing at configure time works
but not for binutils where patches are used to fix parsing errors.
This also makes rockboxdev.sh handle applying multiple patches.

Change-Id: Ia8e6dc7662ab725490e4b4428676d235f0bd38bb
Reviewed-on: http://gerrit.rockbox.org/471
Reviewed-by: Nils Wallménius <nils@rockbox.org>
2013-06-15 21:01:26 +02:00
Rafaël Carré
ab56afefc1 test_mem: silence -Wunused-but-set-variable warning
Change-Id: I4a14c8b0cf1a8c822166ce01087b31c06722d8ae
2013-06-13 18:56:23 +02:00
Rafaël Carré
b4ca244af2 Always build test plugins in simulators
Change-Id: I13094bfbed9fe05a48b4e81759978d112e19f48b
2013-06-13 18:42:29 +02:00
Amaury Pouly
9ad50ade17 imxtools: add Zen, Zen Mozaic and Zen X-Fi bootloader keys
Change-Id: I856e5b91c8e9a1c02b367960052c36f9b527046b
2013-06-13 02:31:19 +02:00
Amaury Pouly
07e82c163e imxtools: rewrite sbloader to handle both versions + user friendly
The tool can now load sb1 and sb files to devices. Detection has
been improved and the tool can infer the packet size for the HID
description as well. The command line interface has been vastly
improved too, this breaks the old one.

Change-Id: I01a0ff8f8a007514aa81c56f114c0f0a86e3303c
2013-06-13 02:29:36 +02:00
Amaury Pouly
1dae3a82e2 sbtools: fix encryption and cosmetics
Change-Id: Id302f236ad3ec13a5166de4e22a3fc85b2a6c64f
2013-06-13 02:27:30 +02:00
Amaury Pouly
f9cb5de580 hwstub: introduce lua code for the STMP and Creative ZEN V/Mozaic
Change-Id: Ice5f509a2e0d2114436d4760f338b9203ef96691
2013-06-13 02:25:15 +02:00