Commit graph

33643 commits

Author SHA1 Message Date
Amaury Pouly
7807934a27 atjboottool: document more header fields and crypto code
The encryption definitely uses some standard elliptic curve encryption over
binary fields (163 and 233 bits, standard polynomials). It is still unclear
how this is used in the actual encryption, the key authentification and
derivation do not look standard.

Change-Id: I6b9180ff7e6115e1dceca8489e986a02a9ea6fc9
2017-10-26 18:17:59 +01:00
Franklin Wei
3ad9caeb2a puzzles: make Untangle's input code return UI_UPDATE instead of ""
This was changed upstream and slipped by when I was merging the
changes.

Change-Id: I3a53cd2db5a5cd2ffef52719a048b8ff4c80d1aa
2017-10-24 19:36:19 -04:00
Amaury Pouly
819d3ee02e nwztools: add NW-A45
Change-Id: I75a7723498564ee73c3682391582e354ad672fd7
2017-10-24 17:47:28 +01:00
Amaury Pouly
2ae792c2f5 nwztools: add NW-ZX300A
Change-Id: I8b311ed6b48b92b9ecf4fb25c19119cfb2d5beb1
2017-10-24 11:46:19 +01:00
Franklin Wei
a644489ccf puzzles: adapt frontend to upstream changes
Change-Id: Idd911ac4ac6c2efa3c6b064be6058979d7a15447
2017-10-23 17:41:11 -04:00
Franklin Wei
ef1306764e puzzles: resync with upstream
There have been some improvements with regard to small screen sizes,
which will be nice to have.

Change-Id: I30c740514156258d2818fde325c1a751500f7611
2017-10-23 17:19:29 -04:00
Amaury Pouly
7a8c9daf7e test_mem: increase dram buffer if possible, cap number of iterations
Change-Id: Ie034433184d0dfcd50e3b783b2b6d0b6a44d001f
2017-10-22 15:36:13 +02:00
Amaury Pouly
e441c2696d nwztools/upgtools: make the tool print the whole kas, not just 16 bytes
Change-Id: I9daca9148b7aaea905a765dfeb95faf6fb7198b1
2017-10-22 15:35:10 +02:00
Amaury Pouly
7e42e90294 atjboottool: add support for FwuTail
Change-Id: Ib01a2ff92294dd0bb59439c23f26bc31eafa4a39
2017-10-20 23:57:58 +02:00
Amaury Pouly
6e79c4cb7c nwztools: add KAS for NW-A40 series
Change-Id: I6e22ba0a58eb62dcc9f2025ee7233f5afae1bbec
2017-10-20 19:46:35 +02:00
Amaury Pouly
1eab18c9e4 nwztools/scsitools: don't try to get nodes when we don't know about the device
Change-Id: Id35671f1e039a94e2b319262e4faa51d73f12afd
2017-10-17 13:34:54 +02:00
Amaury Pouly
9a8a52cb07 nwztools/scsitool: slightly rework of help_us and help
Now print list of devices immediately even if the rest of the command line
is empty (ie 'scsitool -s ?' works, whereas before one would need an actual
device to even get a list). Add more information in the help_us command:
print kas, lyr and fpi.

Change-Id: Icfeeaeebe28c774a74ca54661357fafa25c3d114
2017-10-17 13:05:58 +02:00
Amaury Pouly
6922323466 sonynwz: add NW-A47 to the database and regenerate nwz_db.{c,h}
Change-Id: I6331a48a4d336348e90a32cf151427b29eeedb2b
2017-10-17 13:05:11 +02:00
Michael Sevakis
81f5a225f7 Fix plugin core_alloc_maximum functionality
One mustn't assume a plugin will only call plugin_get_audio_buffer one
time or that the buffer_size pointer is always non-NULL. At least one
plugin, pacbox, will call it each time it (re)starts audio, with a NULL
param (which is intentional because it only wants to kill audio
playback), and leak away all the RAM because the handle gets clobbered
by further calls and the memory can't be released.

Change-Id: Ic5b94dbc0277c42964ea85b4e9d0302a7c6f1fe4
2017-10-14 06:07:09 -04:00
Michael Sevakis
a8e4b3a190 PBE+Surround: Localize some variables and fixup some flush ops
Change-Id: I9fba5b8cbf69d261a7ca1c66e080c08d2fc6d9db
2017-10-12 05:59:18 -04:00
Michael Sevakis
5eee28e37d Nitpick configuration code in a few DSP filters to fix some bugs
Most importantly is surround shouldn't operate in mono mode. Have it
watch and (de)activate itself on relevant format changes as it should.

Other changes to better handle buffer allocation failure.

PBE was set internally at 100 by default; SBZ.

Change-Id: I328e0b674e56751a255eae817d7892d685796b06
2017-10-12 04:44:55 -04:00
Amaury Pouly
afbae177a1 sonynwz: add api and debug entries for "acoustic" and "cue/rev" mode
We don't really know what those are supposed to do. They seem to change the
volume curve but it is not very clear what is the intended purpose.

Change-Id: I65f5d18aba139844c23df092277ba17ee8518f96
2017-10-07 22:01:00 +02:00
Amaury Pouly
26d18fd348 Add alsa wrappers to get control values
Change-Id: Ic870261888f35717bfa939029dcd64bfe1a3df33
2017-10-07 22:01:00 +02:00
Amaury Pouly
5af813c5b7 nwztools: add NW-ZX300 KAS, extracted from a device
Now this is very weird, is it yet another format/encryption?

Change-Id: I119dec1e6d636a99508fb1394de27237ca3ab814
2017-10-07 22:01:00 +02:00
Michael Sevakis
ff62528d05 Make playlist CRC the correct path when saving resume info
Playlist was CRC-ing the path from the id3, which may have been
modified to remove "bogus dirs". This would cause a CRC mismatch
in the resume information.

Now, just use the current playlist's current index and call
playlist_get_filename_crc32() to get the original path when
updating resume info.

While technically correct, if this causes any issue(s) it's just
a one-line change and painless to revert.

Change-Id: Ie595ef6c40349c342bd7acac8c542829f9cd5d76
2017-10-07 14:38:46 -04:00
Amaury Pouly
0fbd93b7e6 nwztools/scsitools: fix database
I forgot to add the NW-ZX300 to its series

Change-Id: I78fd9440492e1868b887f6a2e137d4d0c2ff199a
2017-10-07 18:44:30 +02:00
Amaury Pouly
7eb240a288 Add Sony NW-ZX300 model id to database
Change-Id: I8e7a14b86408c52cbd4a059e2db6a9c9d0966fc6
2017-10-07 12:45:48 +02:00
Amaury Pouly
4382f8773e cleanup linux cpuinfo code
sonynwz: quirk for cpufreq broken driver

There was some redundancy between frequency_linux(cpu, true) and
current_scaling_frequency(), also I see no reason to compile the cpuinfo stuff
unconditionally and the scaling info only on DX since it was already printed
some partial scaling info anyway. Thus compile all the code unconditionally
and simplify the logic in the debug menu. Also avoid putting buffers of size
PATH_MAX on stack since it can be quite big and we only requires 64 bytes
for those paths.

On Sony NWZ, the cpu driver reports frequency in MHz instead of kHz thus we need
to make the cpuinfo code aware of that bug.

Change-Id: I61af45ab5f179ecc909b4841b9137a915a60193a
2017-10-06 18:31:35 +02:00
Amaury Pouly
2f3801be34 fix typo
Change-Id: Ic357f82d61cc0004ac6193fa9dbbc90976042574
2017-10-06 18:31:11 +02:00
Amaury Pouly
d9da4833a7 nwztools/scsitool: various improvements
The tool now provides more useful information for developers when the device
is not supported. Is also has a new verb "help_us" that also prints all this
information (notably the device info and model ID).

Change-Id: I04baec8fff23eb83a0408add6296b5d42e9aa8e7
2017-10-06 12:10:40 +02:00
Amaury Pouly
698779e3e8 sonynwz: add nvp nodes for NW-A40/ZX300, various fixes for tools
We still miss the model IDS for those device so scsitool won't be able to
recognize them automatically.

Change-Id: I17ae0f0d95c011cea8e289def63c7673b6c4b667
2017-10-06 12:10:33 +02:00
Franklin Wei
3f1e4a0b1a xworld: only build manual for color targets
Change-Id: Ia6aeddfcae21afaed13debb487bc8b46d515d031
2017-10-02 16:45:53 -04:00
Michael Sevakis
66b49dc0b2 Need limits.h for hosted builds
Change-Id: Iac1433957de80ad5db51396f74acf1f4f8d45bf3
2017-10-01 23:27:41 -04:00
Michael Sevakis
b2a373eb64 Replace fp_sqrt function with one that only uses shift, or and sub.
Simply extends the current isqrt() to be able to do fractional bits
and improves the initial estimate using clz(). iqrt() itself is
no more and is equivalent to fp_sqrt(x, 0). The original also had
a small bug where the guess comparision should have been >=, not >.

Uses no large integer math or division and is very accurate
(simply returns a truncated fraction).

Change-Id: I2ae26e6505df1770dc01e56220f7385369f90ae9
2017-10-01 20:29:38 -04:00
Amaury Pouly
679ae2d21c sonynwzlinux: print debug info to log on crash
Print the crash info and dump the memory map from /proc/self/maps

Change-Id: I99de32e5e6cca3bf1aca4fa253834ca4ad599fbe
2017-10-01 17:28:42 +02:00
Amaury Pouly
a82ebac53a sonynwza10/a20: enable pcm frequency selection
Change-Id: I335fcdbb652253e777d0d7406545d0d44d98f4f0
2017-10-01 17:23:43 +02:00
Amaury Pouly
50e93d5687 sonynwzlinux: enable software tone controls
As far as I know, they are not supported by the hardware

Change-Id: I71be60ef5461fc9fea151cc9ae9de385b8e08eda
2017-10-01 16:14:29 +02:00
Franklin Wei
23e7d0ef19 xworld: support diagonal buttons on Zen X-Fi
Change-Id: Ia738ecd2a39c0c0772d6f939d549dd5d0eda055e
2017-09-30 20:50:33 -04:00
Franklin Wei
bb55fceb70 Remove old keymaps from xworld and puzzles
They've been replaced by the one in apps/plugins/lib/

Change-Id: Icb54ec4caae1149dfddad8c754087686792a8bc2
2017-09-30 20:49:18 -04:00
Franklin Wei
752f7b1698 Harmonize plugin keymaps
Aims to provide a lib/keymaps.h for plugins needing simple button
functionality beyond that provided by PLA. Currently used by puzzles
and xworld.

Change-Id: Icb3493aaf176d401762de834dd48fc76a3824c5a
2017-09-30 20:13:49 -04:00
Franklin Wei
b9386109e8 puzzles: resync with upstream
This brings puzzles to upstream commit 84d3fd2.

Change-Id: I808a197f868032d771fc101a15666c5ec4b9f94b
2017-09-30 20:06:50 -04:00
Amaury Pouly
ea679de837 atjboottool: put afi and fw code in its own files
Change-Id: I16347ebee0f82d5fdf32f5aa8f955c07fe148eba
2017-09-29 18:22:30 +02:00
Amaury Pouly
95c32a505a atjboottool: split fwu code into its own file
Slightly cleanup the code by removing the old and dangerous --force option.

Change-Id: I776633a9924797fcd509b8b80623bcd64b391672
2017-09-29 17:56:04 +02:00
Amaury Pouly
13364c5525 Fix make race conditions reharding lang.h
The bug is due to a stupid make misfeature. The article [1] contains much more
information but in a nutshell, the following code:

a b: c
	bla

is equivalent to:

a: c
	bla
b: c
	bla

This is bad because in parallel runs (make -j typically), "bla" can be run
TWICE and even worse, twice in PARALLEL. Obviously the result will be
completely unexpected. This is a real bummer because on the other hand,
the following code:

%.c %.h: %:in
	bla

actually expresses the fact that bla produces two files. For some reasons,
pattern rules work differently from implicit rules.

This commit attempts to fix the problem with lang.h by rewriting (simplified):

lang.c lang.h: lang.in
	genlang

as

lang.h: lang.in
	genlang
lang.c: lang.h

This works (it correctly expresses the dependency chain and ensures genlang runs
once) but as one drawback: if one manually removes lang.c, then genlang will not
re-run since the second rule does nothing. This is minor drawback since no one
ever removes lang.c manually and "clean" removes lang.h which triggers a rebuild.

[1]: https://www.gnu.org/software/automake/manual/html_node/Multiple-Outputs.html

Change-Id: Ic0bf7c7c203dc599b00fde457946d2316c70474e
2017-09-24 23:32:47 +02:00
Pavel Rzehák
533b2da2ab Rockbox Utility: updated Czech translation
translated missing strings and revised existing

Change-Id: I1814b31b18cda700fb34f23f818ccbe031b4251f
2017-09-23 18:46:27 +02:00
Amaury Pouly
acc3ef3b6f Print "GEN lang.h" when generated language header.
Hopefully this will help narrow down the problem with LANG_* error message,
I have the feeling that lang.h is not generated in time but it's very hard to
reproduce.

Change-Id: I02b6c98ed9c7e7168fad10dcf1142e307fbc6093
2017-09-22 21:06:30 +02:00
Amaury Pouly
9c83e07d8b Fix bug in pcm-alsa.c
I introduced the bug by mistake when adding support for 32-bit sample rate.

Change-Id: I5ac53917c95327672284707b69c59bb98d1aecd7
2017-09-22 11:22:13 +02:00
Johannes Rauh
638eaeb884 Fix keymap for YP-R0 regarding broken keylock, add more key maps
Keylock is now toggled by the key combo User&Power for WPS and FMS.
Pitchscreen has been added as long press of User.

While in bookmark screen, short press of Power deletes bookmark.
While in (most) menus or tree, first press of MENU takes you back to the
main menu, second press to WPS (aka button_context_tree).

Removed ACTION_WPSAB_SINGLE as long press of USER is now Pitchscreen.

Change-Id: I6aee7f8655b1073ed8d74dabe73895a7c0e54bfe
2017-09-20 21:22:24 +02:00
Johannes Rauh
c1097cc847 Rename "Selective Backlight" to "Backlight Exemptions" and add German translation
Change-Id: I1ddb78bd267372617370cc36910fce9980b907cd

Calling the menu entry "Backlight Exemptions" as this better describes the functionality.
Adding the German translation.
2017-09-20 21:17:39 +02:00
Frank Gevaerts
cee7f5c793 Fix some warnings due to the previous commit
Change-Id: I2858a1f0f730be732c9fff64eabaf3866486a686
2017-09-20 21:17:07 +02:00
Frank Gevaerts
c2698c67f3 Update Greek, Swedish, Italian and Serbian.
Thanks to Constantine Mountantonakis, Jonatan Nyberg, Alessandro Stoppani and Ivan Pesic
(FS#13130, FS#13124, FS#13126, FS#13112)

Change-Id: I0581c38b0dab75b1192278ec84b973250b5c3e69
2017-09-20 20:27:00 +02:00
Michael Sevakis
af8d719bfe Remove STORAGE_NEEDS_ALIGN from config headers
It's no longer required or used in the file code.

Change-Id: I11c1bc166c91b99addca8c8d151c5eaace7a61c3
2017-09-20 09:44:04 -04:00
Amaury Pouly
5f4de5bf48 nwztools/scsitools: make do_fw_upgrade output less confusing
Change-Id: If616e646aeddf20aa3cee79a821a420d9102c708
2017-09-19 21:53:52 +02:00
Amaury Pouly
99cc8f8802 upgtools: fix bug in brute force search
DES ignores the parity bit of each byte (making the 64-bit key really 56-bit),
but the current code skipped the parity bit of each half-byte, thus missing
some keys.

Change-Id: Ia523ebb944e458905b7de1742df151df22166150
2017-09-19 15:30:37 +02:00
Amaury Pouly
048aecd82a remove inaccurate comment
Change-Id: I039288ce12c127f60793625356181d5542114105
2017-09-18 09:30:33 +02:00