Hector Martin
219950235c
fw.dcp.ipc: Define rt_bw_config_t properly
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-30 12:09:36 +09:00
Hector Martin
4df78129aa
m1n1.shell: Fix broken signature thing for some objects
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-29 01:36:27 +09:00
Hector Martin
63547f6fc9
m1n1.fw.asc.mgmt: Print endpoints
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-29 01:36:01 +09:00
Hector Martin
0584200aaf
m1n1.fw.dcp.manager: Make map_buf() work
...
What it needs to do is map the buffer to the disp dart stream 4,
apparently (or maybe the stream varies?)
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-29 01:35:25 +09:00
Hector Martin
43c93af949
m1n1.fw.asc: Handle DARTless ASCs
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-29 01:32:27 +09:00
Hector Martin
eec6bbdeaf
m1n1.hw.dart: Fix dirty cache clobbering on iomap_at()
...
Fixes : #102
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-29 00:03:39 +09:00
Pip Cet
b7ad368158
uart: avoid relying on UTRSTAT_RXD == 1
...
Signed-off-by: Pip Cet <pipcet@gmail.com>
2021-08-24 22:11:19 +09:00
Pip Cet
6a92a3e71a
iodev, usb_dwc3: cosmetic fixes
...
Signed-off-by: Pip Cet <pipcet@gmail.com>
2021-08-24 22:11:19 +09:00
Alyssa Rosenzweig
eb466796d8
fw.dcp: Add some stubs needed for modesetting
...
This isn't enough to set the video mode yet but it gets us further. I
think allocate_memory/map_buf/powerOnDART need real implementations,
otherwise setting a video mode crashes the DCP in an APIODMA interrupt
handler, whatever that is.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
2021-08-24 21:09:35 +09:00
Pip Cet
9a5707889a
hv_vuart: Avoid reporting bytes in the RX buffer when it's empty.
...
Signed-off-by: Pip Cet <pipcet@gmail.com>
2021-08-24 21:07:43 +09:00
Hector Martin
19b16f77d8
startup: Split density field from depth print
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-24 21:00:50 +09:00
Hector Martin
e6d3b6b6c6
m1n1.adt: Handle borked reg properties
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-24 12:20:31 +09:00
Hector Martin
d0731de381
m1n1.hv: Fix pac_mask for linux
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-23 23:10:28 +09:00
Hector Martin
c39fe2fbde
m1n1.fw.asc: Handle syslog/ioreporting buffer size properly
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-23 23:10:28 +09:00
Hector Martin
1666d86d43
fw.asc.mgmt: Handle version negotiation properly
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-23 23:04:23 +09:00
Hector Martin
cc39491863
m1n1.proxy: Allow overriding default timeout with M1N1TIMEOUT
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-23 17:03:20 +09:00
Hector Martin
017f050fff
hv_vuart: Implement RX & enough to support Linux
...
This works to get to a serial shell on Linux, and to use m1n1-as-LV1
proxyclient with M1N1DEVICE=/dev/m1n1-sec
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-23 17:02:28 +09:00
Hector Martin
4b4ae3ab90
aic: Add trivial AIC scaffolding, move regs to aic_regs.h
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-23 17:01:33 +09:00
Hector Martin
18eb02fa92
uart: Add more UART reg defines and use them
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-23 17:00:53 +09:00
Hector Martin
31bf2b5ac9
iodev: Make iodev_can_read() return the queued byte count
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-23 17:00:14 +09:00
Hector Martin
3bdf036161
Revert "cpio: add functions to create cpio images"
...
This reverts commit cd4b563a31
.
2021-08-23 15:27:37 +09:00
Hector Martin
68c1f1c1a6
Revert "kboot: move SEPFW to initrd before booting"
...
We've decided this needs to go via reserved-ranges, not in the
initramfs.
This reverts commit 6afe9ebaf9
.
2021-08-23 15:27:20 +09:00
Hector Martin
c2c6da3df2
fw.dcp.ipc: Remove junk prints
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-14 16:53:32 +09:00
Hector Martin
fa3b1ddcf6
experiments/dcp.py: Add DCP driver example
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-14 16:40:18 +09:00
Hector Martin
de5b5d996c
m1n1.fw.dcp: Add DCP client framework, port tracer to it
...
This also includes an update to the macOS 12.0 beta ABI
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-14 16:39:17 +09:00
Hector Martin
b32aec3786
m1n1.trace.asc: Use shared reg/msg definitions, improve syslog
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-14 16:37:09 +09:00
Hector Martin
27a0a15eee
m1n1.hw/fw.asc: Add basic ASC driver and RTKit handling
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-14 16:36:49 +09:00
Hector Martin
7b01b0525b
m1n1.trace.asc: Be more clear about endpoint number in log
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-14 16:34:24 +09:00
Hector Martin
105b671fb3
m1n1.hw.dart: Add mutation functions (iomap, iowrite)
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-14 16:33:18 +09:00
Hector Martin
fc5ce75c21
m1n1.adt: Add repr()
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-14 16:32:26 +09:00
Hector Martin
fe503a3802
m1n1.proxy: Handle zero-length readmem()
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-14 16:32:07 +09:00
Hector Martin
a96e277b56
m1n1.utils: Add Constant support to Register
...
This allows setting register fields to an expected contant value, e.g.
because they are opcodes for a variable-format register (like a mailbox)
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-14 16:31:10 +09:00
Hector Martin
b00b36620a
m1n1.utils: Add unhex() helper
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-14 16:30:38 +09:00
Hector Martin
f8110dd409
hv_exc: Handle M1RACLES mitigation here due to 12.0 spam
...
macOS 12.0 added a silly ineffective "mitigation" that clears the
register on every context switch. This doesn't actually mitigate
anything, but it does make this sysreg trap performance-critical,
so we have to move its handling into the C side.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-14 16:30:18 +09:00
Hector Martin
a18033e569
main: Add a searchable tag to find the m1n1 version
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-08-12 16:13:33 +09:00
Andrew Worsley
bd5211909e
Fix Exception when no Signature present
...
Signed-off-by: Andrew Worsley <amworsley@gmail.com>
2021-08-03 23:54:23 +09:00
Pip Cet
d709b047d8
proxyclient/m1n1/utils.py: don't compact non-adjacent ranges
...
Signed-off-by: Pip Cet <pipcet@gmail.com>
2021-08-03 13:53:41 +09:00
Andrew Worsley
1d932888f9
Add command categories to reduce command clutter
...
Based on a suggestion from Ludwig Schubert it now uses the inspect class
to generate signatures of the functions for the help messages and
the qualified names which is a big improvement.
Also greatly reduced the clutter by putting the class functions into seperate
categories based on their class name. Now the top level help fits on one
page making it much more readable.
Signed-off-by: Andrew Worsley <amworsley@gmail.com>
2021-08-03 13:52:31 +09:00
Andrew Worsley
ddb6951abb
Fix some review comments, spacing
...
Signed-off-by: Andrew Worsley <amworsley@gmail.com>
2021-08-03 13:52:31 +09:00
Andrew Worsley
255f1bac16
Add some doc string to write/read/mrs/msr
...
Signed-off-by: Andrew Worsley <amworsley@gmail.com>
2021-08-03 13:52:31 +09:00
Andrew Worsley
eab52cc855
Extend help to all commands
...
Also print 1 line summary or full output if called directly on command
Signed-off-by: Andrew Worsley <amworsley@gmail.com>
2021-08-03 13:52:31 +09:00
Andrew Worsley
8ec541ba46
Add a few more temporary files to .gitignore
...
Signed-off-by: Andrew Worsley <amworsley@gmail.com>
2021-08-03 13:52:31 +09:00
Andrew Worsley
bf4f702077
Add some docstrings/help to shell commands
...
Signed-off-by: Andrew Worsley <amworsley@gmail.com>
2021-08-03 13:52:31 +09:00
Andrew Worsley
012ecc07e7
Add simple help command to shell tool
...
Signed-off-by: Andrew Worsley <amworsley@gmail.com>
2021-08-03 13:52:31 +09:00
Andrew Worsley
2ea43e6ff1
Briefly document protocol
...
Signed-off-by: Andrew Worsley <amworsley@gmail.com>
2021-08-03 13:52:31 +09:00
Linear Cannon
fd16d03322
fix type of 'arm-trusted-firmware' in README.md
...
Signed-off-by: Linear Cannon <ky0ko@disroot.org>
2021-08-03 13:48:50 +09:00
Alyssa Rosenzweig
a52330809b
startup: Prettyify video depth dump
...
Use the right unit. for rgb10x2, this prints "30bpp" instead of "0x1E".
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
2021-08-03 13:48:28 +09:00
Hector Martin
63e8d0d48e
m1n1.fw.dcp.ipc: Fix late_init_signal return type
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-07-18 02:28:27 +09:00
Hector Martin
9fae977161
m1n1.fw.dcp.ipc: Add SizedArray/SizedBytes to handle data/len pairs
...
The serialization always uses fixed-length arrays. These wrappers use a
length argument (possibly coming later in the args) to size the fields
so that the arrays are truncated or padded to the right length as
returned to the user.
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-07-18 02:28:26 +09:00
Hector Martin
231aa772fd
m1n1.fw.dcp: Initial DCP log tracing implementation
...
Signed-off-by: Hector Martin <marcan@marcan.st>
2021-07-15 22:29:01 +09:00