https://bitbucket.org/daniel_fort/magic-lantern

sort by:
Revision Author Date Message Commit Date
16b8881 M50: added installer. Still needs more work before it is working. Need to find bmp_vram_info stub. 16 April 2019, 04:24:32 UTC
707714e M50: updated qemu debugmsg.gdb to Canon firmware version 1.0.2 16 April 2019, 03:48:48 UTC
a7b2de4 Merged in digic6-dumper 16 April 2019, 03:44:16 UTC
1d21a06 Merged in latest qemu 16 April 2019, 03:41:20 UTC
7ceebbc QEMU install: also install python3 and use it by default for additional packages (todo: update all our python scripts) 15 April 2019, 17:50:36 UTC
9580d9a QEMU: updated some test scripts for Python 3 15 April 2019, 17:22:29 UTC
1b7baa2 M50: update to Canon firmware version 1.0.2 13 April 2019, 19:51:19 UTC
0a1df48 Merged in latest qemu 11 April 2019, 21:31:28 UTC
8c2d047 QEMU install: reworked toolchain options - on all x86_64 Linux systems, user can choose between 32-bit and 64-bit toolchain - on all Intel systems, user can choose to override the existing ARM toolchain (and install a precompiled version that's known to work) - on x86 Linux systems, the script should install a 32-bit toolchain without asking - on all systems, user may keep the existing ARM compiler (arm-none-eabi-gdb) and compile gdb 8.1 from source - on non-Intel systems, the script should just check for a valid toolchain, and ask the user to install it manually (not tested) 11 April 2019, 20:10:20 UTC
287300b QEMU install: dropped support for arm-none-eabi-gdb installed from Ubuntu package manager Too much of a moving target, e.g. working on Xenial and Bionic (with different packages!) but broken on Cosmic. Keeping arm-none-eabi-gcc from package manager as an option. For gdb, we'll use either a precompiled toolchain (64-bit 7-2018-q2, or any 32-bit version), or compile gdb 8.1 from source. 11 April 2019, 06:13:58 UTC
1b27fdc QEMU install: minor cleanups 10 April 2019, 19:37:23 UTC
8422af3 QEMU install: on WSL, do not execute anything when user selects invalid options (32-bit binaries are not going to work anyway) 10 April 2019, 19:12:32 UTC
300333f QEMU install: on Ubuntu/WSL, install the precompiled toolchain even if another (valid) gcc version is present (option #2 in the Ubuntu/WSL menu) 10 April 2019, 19:06:54 UTC
761866d QEMU install: GDB 8.2.x does not work :( - back to GDB 8.1 - GDB 8.2.x is no longer accepted - using precompiled toolchain 7-2018-q2-update for both Mac and WSL (with GDB 8.1.x) 10 April 2019, 08:52:41 UTC
7c89157 QEMU: script for reverting changes made in qemu-eos (i.e. go back to some vanilla version without full reinstallation) Usage: ./sure_copy_from_contrib.sh [-q] (from qemu-eos directory) Name starts with different letter to avoid typing ./copy_back_to_contrib.sh by mistake. 09 April 2019, 21:49:50 UTC
4317f6e QEMU tests: updated IDC "needles" for DIGIC 7 (minor changes after e1c6fd6) 12 April 2019, 15:39:24 UTC
27d6df3 QEMU install: use gdb 8.2.1 when compiling from source (8.1 still accepted as valid) 09 April 2019, 19:32:10 UTC
b2a638c QEMU install: gdb-multiarch 8.1 or newer may be available on recent WSL (use the same heuristics as with plain Ubuntu) 09 April 2019, 19:27:44 UTC
7d6c3a6 QEMU: various fixes regarding Thumb disassembly Quirk: if CPU is in ARM mode, the disassembler looks at the Thumb bit of the requested address. If CPU is in Thumb mode, the disassembler ignores the Thumb bit from the address, and always disassembles as Thumb. This inconsistency is also present in latest QEMU from git. Why? IDC scripts: comments containing disassembled Thumb code were updated (DIGIC 6/7/8 and 1300D). 09 April 2019, 13:10:37 UTC
4f25bd1 GDB scripts: removed NULL_STR definition from 5D4 (was breaking the tests; not required on this camera anyway) 09 April 2019, 08:26:34 UTC
eb5f552 QEMU logging: in icount mode, print instruction count for every single function call Instruction count is printed when returning from the function. Instructions executed by other tasks/interrupts (i.e. outside the tested function) are not included in the printed value. This feature is very useful for optimizing code. Example: -d debugmsg,calls -icount 5 08 April 2019, 17:42:00 UTC
d8083d6 QEMU logging: updated DryOS and VxWorks task switch handling It was quite hard to pass the test suite, as there were lots of edge cases: - context switch may happen either in a timer interrupt, or in a regular task (e.g. msleep, sempahores and so on) - context switch is not atomic - it happens a few instructions (or function calls!) afterh updating the current task pointer - until the registers are swapped for the new task, we are still on the stack of the previous task - there may be dummy task switches (i.e. from one task to the same task) - an interrupt can occur in the middle of a (non-atomic) context switch (!) - VxWorks models do not even use a unique task ID (!) Result: QEMU no longer crashes during logging tests! Issue: these cameras do not appear to use an unique task ID. Workaround: assign our own task IDs. 09 April 2019, 08:04:24 UTC
71c23de QEMU test suite: only use 2/3 of available CPU cores. It appears to improve the repeatability of results in some CPU- and IO-intensive tests. In other words, don't believe the Hyper-Threading hype :) 08 April 2019, 14:17:00 UTC
effcd7a QEMU logging: removed magic stack ID values for interrupt and invalid task 06 April 2019, 19:35:17 UTC
2ec8209 QEMU: refactored with eos_get_mem_w Before: uint32_t x; cpu_physical_memory_read(addr, &x, 4) After: uint32_t x = eos_get_mem_w(s, addr); Also, minor cleanups to eos_get_current_task_* (not expected to make a difference) 06 April 2019, 19:22:10 UTC
e3a7397 77D: empty gui.h required for compiling 27 March 2019, 19:42:59 UTC
30c8823 qemu-fio: burn-in test for FindClose (FindFirst/FindClose/FindNext repeated many times) 27 March 2019, 09:47:47 UTC
1081787 qemu-fio: minimal test code for file I/O routines in QEMU Only FindFirst/FindNext test for now; others to be added later. Compile with e.g.: cd minimal/qemu-fio make MODEL=60D clean make MODEL=60D install_qemu CONFIG_QEMU=y FIXME: works on DIGIC 4/5, fails on DIGIC >= 6, not tested on DIGIC 2/3. 25 March 2019, 21:02:50 UTC
8896e73 QEMU tests: minor fix for HPTimer test (slightly faster, no longer times out) 25 March 2019, 21:06:13 UTC
0f433fb 5D4: sync debugmsg.gdb to the one from chris_overseas (a8bdfa9) 25 March 2019, 17:14:43 UTC
a105b57 fio-ml.h: updated fio_file structure for DIGIC 6/7/8 Tested on 5D4, 200D, 77D and M50, all in QEMU. 23 March 2019, 17:41:48 UTC
007b0ec Merged qemu into digic6-dumper (minimal/qemu-fio test) 27 March 2019, 09:53:35 UTC
96a2ffe DIGIC 6/7/8 Hello World: reworked with 32-bit access in the display buffer 23 March 2019, 22:52:32 UTC
a8c6554 DIGIC 6/7/8 Hello World: also set opacity for all pixels (should now work in LiveView for UYVY models, such as 80D and 200D) 23 March 2019, 22:47:44 UTC
87bd868 DIGIC 6/7/8 Hello World: set U and V for all pixels on UYVY models (80D, 200D and others) No more color artifacts at font edges. 23 March 2019, 21:47:22 UTC
3131140 DIGIC 6/7/8 Hello World: use rgb2yuv422 from imgconv.c/h; (@names_are_hard, why did you swap the endianness in your rgb2yuv422?!) 23 March 2019, 22:41:28 UTC
b1cb6b1 imgconv.h: updated YUV<->RGB routines for DIGIC 6/7/8 (to be tested) U and V now have an offset of 0x80; previously, on DIGIC 5 and earlier models, achromatic was 0. 23 March 2019, 21:33:55 UTC
a900e0a internals-common: assuming all DIGIC 5 and newer models use Rec.709 TODO: need a trained eye to check. 23 March 2019, 19:34:00 UTC
f0a866c DIGIC 6/7/8: generic Hello World code, based on names_are_hard's and chris_overseas' work. To be tested. MARV structure: https://www.magiclantern.fm/forum/index.php?topic=17360.msg212411#msg212411 23 March 2019, 20:55:05 UTC
6af04b4 internals-common: enabled new DryOS task hooks on all new models (DIGIC 6/7/8; to be tested) 23 March 2019, 18:58:29 UTC
5b61a11 internals-common.h: common definitions for CPU types and DIGIC families 23 March 2019, 17:15:29 UTC
f42df4c check_stubs.py: fix crash when attempting to compare stubs present in only one file 24 March 2019, 23:02:17 UTC
2e40e30 DIGIC 6/7/8: explicit macros for Thumb code, ARM code and data pointers in stubs.S - THUMB_FN: for Thumb functions - ARM32_FN: for 32-bit ARM functions - DATA_PTR: for stubs not pointing to code (these can't be called as functions) Advantages: - Thumb bit handled automatically (less error-prone) - easier to read (compared to checking address parity manually) - easier to copy stubs from/to IDA or GDB scripts (no more need to edit the Thumb bit manually) Also: - updated maintenance scripts from contrib/stub-format and stub-checker - declared data stubs so they won't be incorrectly tagged as code - removed "Thumb" mentions from comments 25 March 2019, 15:51:22 UTC
3f416d1 DIGIC 6/7/8: aligned comments 25 March 2019, 15:45:31 UTC
a300f3a DIGIC 7/8: malloc/free stubs should be private (not yet used in source code) 23 March 2019, 15:47:18 UTC
a27e004 DIGIC 6/7/8: reordered stubs 25 March 2019, 15:30:30 UTC
dbe9fb9 stub-reorder.py: do not attempt to find missing stubs by default 25 March 2019, 15:25:43 UTC
35924da stub-reorder.py: updated sorting order heuristics: - ignore the underscore from stub names - free and free_dma_memory should be right after malloc/alloc_dma_memory - file stubs should be first - create/delete/open/close/etc should be grouped, usually first - property functions: logical order is very close to reverse alphabetical order 25 March 2019, 15:22:56 UTC
dd42296 stub-reorder.py: minor updates for DIGIC 6/7/8 15 March 2019, 07:56:57 UTC
3d64ff9 200D, 77D: comments for interrupt and memory allocation stubs 15 March 2019, 07:25:55 UTC
e3c759f 77D: some nitpicks 23 March 2019, 15:23:52 UTC
b83de2d 77D.102 stubs, firmware signature based on the work from aprofiti in ML forum https://www.magiclantern.fm/forum/index.php?topic=19737.msg206736#msg206736 (f387fc1, b44e17e, e25589c, 1578fb6, 397b9a2, 0264f84, minus the experiments -- a1ex) 19 March 2019, 06:48:15 UTC
54cac0d move platform directory 77D.100 to 77D.102 14 March 2019, 21:57:27 UTC
04fed83 QEMU: 32-bit DIGIC timer support (DIGIC 6 and newer) 05 March 2019, 14:22:32 UTC
d531c26 QEMU: updated emulation for 7D2 1.0.4 (ROM from real hardware; no longer using 80D bootloader). Some workarounds were required to emulate the bootloader. Communication between the two cores is not yet handled. 03 March 2019, 23:59:18 UTC
a9a9fbe QEMU: renamed 7D2M to 7D2 (slave core is still 7D2S) 04 March 2019, 09:37:30 UTC
cf601ef QEMU: updated tests for 5D 1.1.1 and 400D 1.1.1, both ROMs from real hardware (previously, it was a mix between an incomplete 5D firmware and 1000D bootloader) 04 March 2019, 09:34:36 UTC
e1f335e QEMU: imported scnprintf/vscnprintf from Linux kernel and fixed incorrect usage in previous code (adapted commit e8bb011b) 04 March 2019, 09:27:50 UTC
bca7890 QEMU: fixed indentation of multiline debug strings (-d debugmsg) 04 March 2019, 08:44:46 UTC
99b6ab0 Memory backend: use const char * for read-only strings 28 February 2019, 22:08:50 UTC
7d77ecb tasks: use const char * for DryOS task names 28 February 2019, 21:51:32 UTC
867d6d0 tasks.h: renamed current_task->name to current_task->task_name; updated old code to use get_current_task_name() instead. A few places still require raw access to the task_name field (e.g. tskmon). 28 February 2019, 21:18:48 UTC
813b161 get_current_task_name: updated interrupt ID for DIGIC 6/7/8 (no need to shift it by 2, unlike DIGIC 5 and earlier) 28 February 2019, 21:11:36 UTC
be15292 get_current_task_name: moved into tasks.h to remove duplicate code It was in 5 different places in ML source, not counting current_task->name and QEMU source. 28 February 2019, 21:11:36 UTC
27ee197 log-d678: maximum MPU message size is 0xFF chars (no reason to use a smaller size) 28 February 2019, 17:37:14 UTC
b50f71f log-d678: use 512 bytes for MPU messages; use the same buffer for both mpu_send/recv 27 February 2019, 19:33:37 UTC
22ee541 log-d678: only check for MPU messages on the first CPU core (they don't arrive on the second core anyway, but our checks may cause race conditions) 26 February 2019, 22:19:38 UTC
c2588ab log-d678: attempt to use Canon's cli/spinlock function on DIGIC 7/8 (200D for now) It appears to be some sort of cli/sei valid for both cores. To be tested. 26 February 2019, 21:35:28 UTC
51a991f arm-mcr.h: read_cpsr 26 February 2019, 21:27:16 UTC
77049f1 spinlock: volatile keyword is required 26 February 2019, 20:50:28 UTC
fa0dedd Moved spinlock functions into arm-mcr.h (spin_lock, spin_unlock); refactored log-d678.c 26 February 2019, 13:58:45 UTC
ec48414 log-d6: __sync_lock_test_and_set requires an explicit spinning loop https://stackoverflow.com/questions/1383363/is-my-spin-lock-implementation-correct-and-optimal 26 February 2019, 13:41:51 UTC
4e158ab log-d678: attempt to log messages from both CPU cores on DIGIC 7/8 (to be tested on real hardware) http://infocenter.arm.com/help/topic/com.arm.doc.faqs/ka4175.html http://infocenter.arm.com/help/topic/com.arm.doc.ddi0388f/CBBDIIFI.html 26 February 2019, 08:45:05 UTC
47be065 Renamed log-d6.[ch] to log-d678.[ch] and minimal-d6.c to minimal-d678.c These files are starting to get code specific to DIGIC 7/8. They are not directly usable on DIGIC 8 yet, as most of the functions we need to override are in ROM. Only in QEMU for now. 26 February 2019, 07:33:53 UTC
d89e9a1 arm-mcr.h, log-d6.h: renamed get_cpuid to get_cpu_id to avoid confusion with CPUID aka CPU model identification MPIDR is not 100% correct; we extract only specific bits from it. These bits are called "CPU ID" in ARM docs. http://infocenter.arm.com/help/topic/com.arm.doc.ddi0388e/CIHEBGFG.html 26 February 2019, 07:21:20 UTC
b882ef8 log-d6: refuse to run on CPU cores other than #0 Fixes corrupted logs on DIGIC 7/8 (confirmed on 200D by @names_are_hard ). Cause: race condition between the two processor cores. Even if we load ML on core #0 only, when overriding DebugMsg / ISR hooks / etc, the change is also visible from the second core. Disabling interrupts won't help. TODO: figure out how to do mutual exclusion between the two cores. 25 February 2019, 22:36:34 UTC
73ea1bb arm-mcr.h: get_cpuid() for multi-core processors (DIGIC 7/8) 25 February 2019, 22:36:34 UTC
041d3be 5D4: hardcoded logging buffers, based on chris_overseas' experiment https://www.magiclantern.fm/forum/index.php?topic=17695.msg212320#msg212320 CONFIG_MMIO_TRACE works in QEMU. 21 February 2019, 19:09:43 UTC
b6775ab io_trace: allow CONFIG_MMIO_TRACE for minimal targets, too (removed the 80D workaround) 21 February 2019, 17:40:10 UTC
00c70bd 5D4: updated the codebase to 1.1.2 3bf2df7, 73990b1, 24dbfdb, c0f8a82, 3e04262 from https://bitbucket.org/chris_miller/ml-fork/branch/5d4-112 21 February 2019, 19:53:32 UTC
ab004de check-stubs.py: also check ROM/RAM contents, 8 bytes for each stub (optional) RAM files should be created with the Portable ROM dumper. RAM files, if any, should be created with romcpy.sh (QEMU: -d romcpy). 21 February 2019, 17:15:19 UTC
7e5ccc0 check-stubs.py: updated heuristics for DIGIC 6/7/8 - everything above E0000000 is ROM - check parity differences (Thumb bit) - check "delta" changes (it's expected to drift, but no large jumps) 20 February 2019, 09:06:22 UTC
f06a432 EOS R: skip 0x82000000-0x83000000 for CONFIG_MARK_UNUSED_MEMORY_AT_STARTUP (apparently used as shared memory by a secondary core, codenamed Shirahama) 15 February 2019, 22:57:31 UTC
c062b32 EOS R: UNCACHEABLE macro is no longer valid; using a workaround for CONFIG_MARK_UNUSED_MEMORY_AT_STARTUP 15 February 2019, 22:13:11 UTC
55fface EOS R, M50: updated CONFIG_MARK_UNUSED_MEMORY_AT_STARTUP (see bee6ec3 for details and usage notes) 15 February 2019, 22:01:11 UTC
d7c9d6b M50: uart_printf (not yet used, but... required to compile) 14 February 2019, 22:31:58 UTC
2a62182 EOS R: added uart_printf for easier debugging 14 February 2019, 20:57:23 UTC
5e6d34c minimal-d78: need to call FIO_RemoveFile before FIO_CreateFile 14 February 2019, 20:43:05 UTC
f065f08 EOS R: LED test code (not enabled by default) 14 February 2019, 18:34:40 UTC
9dd709e EOS R: updated to 1.1.0 (note to self: check firmware version next time) 14 February 2019, 18:13:18 UTC
0c1b6be EOS R: initial platform directory - firmware 1.0.0 - boot process tested in QEMU - confirmed to boot on real hardware - very simple logging works (with Canon's DebugMsg) - ROM dumping from main firmware also works 14 February 2019, 17:15:19 UTC
3b26e45 reboot.c: debug code for jumping into Canon's main firmware (disabled by default) 14 February 2019, 06:32:53 UTC
e1397a5 DIGIC 8: MMIO tricks required to boot (tested on EOS R; maybe also needed on M50/SX70) 14 February 2019, 06:29:41 UTC
e83d43c DIGIC 6: moved MMIO boot tricks in reboot.c - for consistency - 7D may use two different boot methods ("classic" and "cache hack"); keeping this in reboot.c reduces code duplication - in the future, we will want to be able to jump to any Canon firmware from the same binary; this will have to be done from reboot.c 13 February 2019, 09:34:39 UTC
b41ef49 7D, 7D2, 5DS, 5DSR: use CONFIG_DUAL_DIGIC (to enable the specific boot tricks) 13 February 2019, 09:30:35 UTC
f5dd789 CONFIG_DIGIC_version is now mandatory; defined CONFIG_DIGIC_IV on models using one. 13 February 2019, 09:28:18 UTC
1a816d9 QEMU: fixed Thumb code disassembly with qdisas This used to work in earlier versions, but target_disas changed its syntax in 2.5.0. Useful for debugging io_trace on DIGIC 6 (with CONFIG_QEMU=y). 11 February 2019, 13:25:32 UTC
f8742e6 QEMU: fixed TCM size info (broken in df56963); simplified condition for 946_PRBS size info 04 March 2019, 09:31:07 UTC
a4c2f32 QEMU: better description for DRSR, useful for emulating io_trace on DIGIC 6: - enable bit (similar to PRBS on DIGIC 5 and earlier) - consistency check for base address and size (base address must be multiple of size - Cortex R4 TRM p.178) - subregion disable bits (if used) Useful for emulating io_trace. Note: QEMU already calls tlb_flush when writing to DRSR, DRBAR or DRACR. No need to apply e4fd44e on DIGIC 6. 11 February 2019, 13:25:32 UTC
3643ed5 QEMU: print PC when taking an exception 11 February 2019, 13:25:32 UTC
back to top