Hector Martin
b4822eb02c
adt: improve APIs for iterating through child nodes
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-28 23:48:35 +09:00
Hector Martin
db902ce01f
wdt: move WDT disable code to wdt.c & use ADT regs
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-28 23:48:35 +09:00
Hector Martin
3733ea153f
smp: fix broken spin-table routine
...
Only read target_cpu once, then keep a pointer our spin table.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-28 23:48:35 +09:00
Hector Martin
ba1162e322
adt: add an API for resolving reg properties
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-28 23:48:35 +09:00
Sven Peter
9242c820ae
MMU: clean and invalidate all caches after shutdown
...
Signed-off-by: Sven Peter <sven@svenpeter.dev>
2021-01-28 23:20:15 +09:00
Sven Peter
2f84b33ba8
MMU: add cache operations by set/way
...
this embeds a slightly modified file taken from
arm-trusted-firmware.
Signed-off-by: Sven Peter <sven@svenpeter.dev>
2021-01-28 23:20:15 +09:00
Sven Peter
f244919c98
MMU: add initial support
...
Signed-off-by: Sven Peter <sven@svenpeter.dev>
2021-01-28 23:20:15 +09:00
Sven Peter
63fad7e3e2
utils.h: add panic() macro
...
Signed-off-by: Sven Peter <sven@svenpeter.dev>
2021-01-28 23:20:15 +09:00
Hector Martin
d762391a68
Add code to spin up secondary CPUs
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-28 16:06:12 +09:00
Hector Martin
65276fdd3f
utils.h: add memory clobbers
...
We mostly use read32/write32 and friends to poke hardware registers,
which might have side effects on RAM, so just make everything a memory
clobber to avoid potential issues.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-28 16:06:12 +09:00
Hector Martin
08763968ac
malloc.py: add memalign
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-28 16:06:12 +09:00
Hector Martin
0145830772
chickens: add firestorm chicken bits
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-28 16:06:12 +09:00
Hector Martin
35e24d58d9
linkerscript: add a dummy payload section starting at EOF
...
So it turns out iBoot is happy to load mach-o files with a section hanging
"off the end" of the file (it does not over-read, it just ignores the
excess). We can use this to our advantage to support appending payloads
to m1n1 with a simple `cat`.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-28 16:06:12 +09:00
Hector Martin
344c84da17
clang-format everything
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-28 16:06:12 +09:00
Hector Martin
5ce22e5c3a
.clang-format: AlignConsecutiveMacros: true, 100 columns
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-28 16:06:12 +09:00
Ariel Machado
51bf5c870a
adt: replaces int to u32 and size_t for unsigned values.
...
Makefile: increases compiler warnings
Signed-off-by: Ariel Machado <ariel@fe.up.pt>
2021-01-25 19:18:30 +09:00
Hector Martin
cc34ace39a
startup: Implement setting CPU chicken bits for Icestorm
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-25 19:11:54 +09:00
Hector Martin
d0d691524c
chickens.py: disable unnecessary stuff
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-25 19:11:42 +09:00
Hector Martin
58b643df77
clang-format a few missed things
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-25 17:25:49 +09:00
Hector Martin
a637b77816
Move minlzma.h -> src/minilzlib
...
This stops clang-format from running on this header.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-25 17:25:44 +09:00
Hector Martin
14db0224af
Add config.h for build-time config options
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-25 17:24:29 +09:00
Hector Martin
7419295d62
dts/apple-j274: add WIP Mac Mini devicetree
...
Also fix some Makefile brokenness
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-25 17:24:29 +09:00
Hector Martin
fc6163c8d2
linux.py: add simple Linux loader
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-25 17:24:29 +09:00
Hector Martin
2647df774d
chickens.py: chickenbits/tunables test code
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-25 17:24:29 +09:00
Hector Martin
c648a517e3
memdump.py: add simple memory dumper
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-23 22:43:21 +09:00
Hector Martin
e5caf91d79
utils: add u.inst() to run arbitrary instructions
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-23 22:43:21 +09:00
Hector Martin
99fb647a9b
utils.py: add more ARM registers
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-23 22:43:19 +09:00
Hector Martin
7b53b0ae9c
shell.py: remove missing unused import
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-23 22:43:18 +09:00
Hector Martin
644ab28e32
setup.py: fb is the framebuffer
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-23 22:43:16 +09:00
Hector Martin
e1f0be37b4
proxy.py: add a ttymode() call to switch to a dump terminal print
...
TODO: implement input
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-23 22:43:14 +09:00
Hector Martin
674a82a2bb
aic_test: UART IRQ testing stuff
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-23 22:42:59 +09:00
Hector Martin
63319ed348
utils: implement udelay()
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-23 22:42:25 +09:00
Hector Martin
009f04775e
utils: add __assert_fail function to make assert() work
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-23 22:42:25 +09:00
Hector Martin
cfe597e447
proxy: introduce reboot() as distinct from vector()
...
vector() does not expect a reply, reboot() expects a hello reply.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-23 22:42:25 +09:00
Hector Martin
ee12d053a9
proxy: add XZ and GZ decompression functions and code
...
This embeds tinf and minlzma.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-23 22:42:23 +09:00
Ferdinand Bachmann
afc5813635
exceptions: fix clang warning for msr arg
...
Signed-off-by: Ferdinand Bachmann <theferdi265@gmail.com>
2021-01-23 22:09:22 +09:00
Ferdinand Bachmann
505eb4ce4f
m1n1.ld: clang compat, define _base symbol inside SECTIONS for relative symbol resolution
...
Signed-off-by: Ferdinand Bachmann <theferdi265@gmail.com>
2021-01-23 22:09:22 +09:00
Ferdinand Bachmann
8511d9ff74
start.S: clang compat, don't use '\r' in asm files
...
Signed-off-by: Ferdinand Bachmann <theferdi265@gmail.com>
2021-01-23 22:09:22 +09:00
Ferdinand Bachmann
75c3cd39d4
start.S: don't use caller-saved registers accross calls
...
Signed-off-by: Ferdinand Bachmann <theferdi265@gmail.com>
2021-01-23 22:09:22 +09:00
Ferdinand Bachmann
d48fa181c4
clang support: fix LLD warning about implicitly added sections by adding them explicitly
...
Signed-off-by: Ferdinand Bachmann <theferdi265@gmail.com>
2021-01-23 22:09:22 +09:00
Ferdinand Bachmann
c6da21ceff
Makefile: clang support
...
Signed-off-by: Ferdinand Bachmann <theferdi265@gmail.com>
2021-01-23 22:09:22 +09:00
Ferdinand Bachmann
6ecf5d9fb5
types.h: remove redundant definition of NULL (defined in stddef.h)
...
Signed-off-by: Ferdinand Bachmann <theferdi265@gmail.com>
2021-01-23 22:05:37 +09:00
Ferdinand Bachmann
274ea2baf2
exceptions: remove unused push_hi_regs symbol, make _exc_entry a function
...
Signed-off-by: Ferdinand Bachmann <theferdi265@gmail.com>
2021-01-23 22:05:24 +09:00
Hector Martin
31b6af14b2
exception.c: fix sp calculation in print_regs
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-18 01:57:27 +09:00
Hector Martin
74d3575369
proxyclient: Add aic_test
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-17 00:50:50 +09:00
Hector Martin
397bfa17c6
proxyclient: new asm/malloc/utils, clean up
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-17 00:50:34 +09:00
Hector Martin
81aaf2ed35
Basic exceptions, irq, cache mgmt support
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-01-17 00:49:22 +09:00
Shiz
73e79c5372
build: fix problem with arch-less data on older GNU binutils
...
Signed-off-by: Shiz <hi@shiz.me>
2021-01-16 11:29:48 +09:00
Ferdinand Bachmann
d49d0b781b
adt: fix ignored qualifiers in adt_getprop_copy function prototype
...
Signed-off-by: Ferdinand Bachmann <theferdi265@gmail.com>
2021-01-16 05:12:48 +09:00
Ferdinand Bachmann
b02d70730a
proxyclient: fix mask commands accidently sending clear opcode instead
...
Signed-off-by: Ferdinand Bachmann <theferdi265@gmail.com>
2021-01-16 02:48:48 +09:00