Hector Martin
4027c34c7a
proxy: Add proxy ops for pcie_init/shutdown
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-22 16:04:35 +09:00
Hector Martin
660d7482b9
hv/trace_pmgr.py: New script
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-22 07:21:07 +09:00
Hector Martin
23c3617cf2
payload: Complain loudly about devicetree platform mismatches.
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-20 02:26:24 +09:00
Hector Martin
f4e11a78c6
i2c: Add explicit delay to the i2c_xfer_read timeout loop
...
We now set the timeout at 10ms without any bytes received.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-18 22:29:51 +09:00
Hector Martin
850a669436
tps6598x: Add a delay in the command poll loop
...
It seems that if we poll too fast, we DoS the poor thing...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-18 22:15:38 +09:00
Hector Martin
cc1fa67ff2
i2c: Use Repeat-Start condition for SMBus reads
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-18 22:15:13 +09:00
Hector Martin
26f636dbbb
fb: Use 128-bitwise copies to speed up FB updates
...
This makes it almost as fast as it was before the switch to an
uncached framebuffer, as far as I can tell.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-17 19:23:44 +09:00
Hector Martin
3b0d53d7b8
mcc: Guard against MCC count > max
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-17 10:14:15 +09:00
Hector Martin
0df392d0d3
mcc: Fix mcc_num_channels prop on t8103
...
Bad copy and paste...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-17 01:45:49 +09:00
Hector Martin
4b80041d6d
mcc: New module to initialize the MCC memory controller.
...
This turns on the system level cache. The carveout unmapping also moves
here, and now it handles T8103/T6000 properly.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-16 21:09:48 +09:00
Hector Martin
ecc80f4b32
kboot: Fix warning/bug introduced by ecb6c82e
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-16 21:09:12 +09:00
Hector Martin
b9ec73b019
smp: Leave the default boot stack for CPU#0 set in case it resets
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-16 17:26:52 +09:00
Hector Martin
33d09cc7c0
hv_exc: Filter out CYC_OVRD_DISABLE_WFI_RET
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-16 17:26:39 +09:00
Hector Martin
5d214606df
m1n1.hv: Add flag to hide the CPU prefix in hv.log()
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-16 17:20:47 +09:00
Hector Martin
06975c8b87
m1n1.hv: Add TraceMode.WSYNC to make writes synchronous, but not reads
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-16 17:20:21 +09:00
Hector Martin
ccbe181d75
m1n1.adt: Improve PMGR props parsing, add to dump_pmgr.py
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-16 17:19:42 +09:00
Hector Martin
0f9c0f5dd3
startup: Add a UART print to the RVBAR entry path
...
This might make it easier to debug CPU sleep modes
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-16 17:18:52 +09:00
Hector Martin
4652ac2098
tools/reg_filter.py: Tool to add IMPDEF sysreg names to a disasm
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-16 17:18:09 +09:00
Hector Martin
ecb6c82e75
kboot: Delete CPU nodes instead of disabling them
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-15 22:48:28 +09:00
Hector Martin
7690fd730c
iodev: Bypass locks on all funcs if no MMU
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-15 22:47:45 +09:00
Hector Martin
257f6443a6
kboot: Fix potential bug handling missing/disabled CPUs
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-15 14:52:10 +09:00
Jean-Francois Bortolotti
0131d16c0a
Fix aic1 reg size
...
Signed-off-by: Jean-Francois Bortolotti <jeff@borto.fr>
2021-11-14 11:14:50 +09:00
Janne Grunau
46c945ac95
usb: use dynamic paths for usb related ADT nodes
...
Adds support for the 3rd USB-C port on 2021 Macbook Pros.
Currently up to 8 USB-C ports are supported which should be sufficient
for expected future devices.
Tested on Macbook Pro 14" and Mac Mini.
Signed-off-by: Janne Grunau <j@jannau.net>
2021-11-12 23:48:32 +09:00
Janne Grunau
b6ec7abc2b
utils: replace sprintf with snprintf
...
Converts all current users.
Signed-off-by: Janne Grunau <j@jannau.net>
2021-11-12 23:48:32 +09:00
Janne Grunau
5064b93b2f
usb: dynamically allocate and register usb iodevs
...
Preparation for devices with more than 2 USB-C ports.
Signed-off-by: Janne Grunau <j@jannau.net>
2021-11-12 23:48:32 +09:00
Janne Grunau
c40ef51084
usb_dwc3: robustness in usb_dwc3_write()
...
Signed-off-by: Janne Grunau <j@jannau.net>
2021-11-12 23:48:32 +09:00
Janne Grunau
91ff1ceb65
iodev: avoid direct access to iodev device array
...
Preparation for dynamically alloced iodevs.
Signed-off-by: Janne Grunau <j@jannau.net>
2021-11-12 23:48:32 +09:00
Janne Grunau
2724d69f4c
iodev: usb: replace secondary usb iodevs with single vuart iodev
...
Signed-off-by: Janne Grunau <j@jannau.net>
2021-11-12 23:48:32 +09:00
Janne Grunau
3a2446c53b
m1n1.proxy: remove trailing whitespace
...
Signed-off-by: Janne Grunau <j@jannau.net>
2021-11-12 23:48:32 +09:00
Hector Martin
c947f6aec3
m1n1.trace.asc: Add support for tracing DARTless ASCs
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-11 15:22:25 +09:00
Hector Martin
b50a489f41
chickens: Update Firestorm chickens & complete t600x
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-11 01:20:03 +09:00
Hector Martin
efca793572
pcie: Only print the port init msg for existing ports
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-11 01:20:03 +09:00
Hector Martin
510dd53175
pcie: Add t6000 support
...
This one seems to need one extra magic poke
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-10 20:43:51 +09:00
Hector Martin
a83d0908e5
pcie: Add t6000 fuse bit map and fix fuse bit application
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-10 20:43:51 +09:00
Hector Martin
94a73a404c
kboot: Disable USB dwc3 devices that are missing in the ADT
...
This passes through the hypervisor USB device disable to Linux, so we no
longer need to hack device trees.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-10 20:43:51 +09:00
Hector Martin
e689ceb263
usb: Add usb_idx_from_address() to find a dev by its MMIO addr
...
This will be used to match up ADT and FDT USB devices, to pass through
enable status.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-10 20:43:51 +09:00
Hector Martin
7e01af5144
kboot: Use _inplace setprop for the CPU release addr
...
This needs to happen in-place for the iterator to not be invalidated.
Explicitly request that and fail if it does not work.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-10 20:43:51 +09:00
Hector Martin
9d2be299a4
tools/smccli.py: Simple shell for an instantiated SMCClient
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-10 20:43:51 +09:00
Hector Martin
eaa72c7a91
m1n1.fw.smc: Improve and add more functions
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-10 20:43:51 +09:00
Hector Martin
198fc24f14
m1n1.adt: Fix ranges prop decoding
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-10 20:43:51 +09:00
Hector Martin
927c12ad53
hv/trace_all.py: Trace all I/O ranges using the arm-io prop
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-10 20:43:51 +09:00
Hector Martin
ae7228f398
m1n1.asm: Fix bad objdump variable
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-10 20:43:51 +09:00
Hector Martin
b9ddd74c02
hv/trace_smc.py: Add SMC tracer
...
Also fix up a bunch of stuff in m1n1.fw.smc, but it's untested as a
client.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-10 20:43:51 +09:00
Vincent Duvert
407663b73d
bootstrap_port: Improve UART baud setting
...
Rework the serial port bootstrap so it works correctly if the target is already
at 1500000 baud.
No baud adjustment is made if the proxy is using the serial-USB interface.
Tested with the Mac-to-Mac serial connection (macvdmtool) and the serial-USB
connection.
Signed-off-by: Vincent Duvert <vincent@duvert.net>
2021-11-10 16:02:44 +09:00
Hector Martin
e763ce3f56
hv: Set SMP mode to WFE
...
This fixes early IRQs getting stuck in idle secondaries and breaking the
guest.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-08 19:57:02 +09:00
Hector Martin
8e0ca1a39c
m1n1.hv: Print diagnostic info when MMIO forwarding fails
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-08 19:55:16 +09:00
Hector Martin
e19e74be8b
m1n1.asm: Make work on macOS/clang
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-08 14:41:24 +09:00
Hector Martin
eb3af7daaf
Makefile: do not use -Wp to pass Makefile dep generation args
...
This doesn't seem to work properly with clang...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-08 13:53:04 +09:00
Hector Martin
84acf60c24
Fix warnings when building/linking with clang/llvm
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-08 13:53:04 +09:00
Hector Martin
1e6c856f5f
Makefile: Make it build out-of-the-box on macOS
...
This requires a few dependencies installed with Homebrew.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-11-08 13:52:59 +09:00