-
Notifications
You must be signed in to change notification settings - Fork 412
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for M1-enabled devices #406
Conversation
80d42ac to
e5c0ead
Compare
Align the size of sent packets on the ASR_PAYLOAD_CHUNK_SIZE.
This file will be needed later by the stage 1 boot process.
- Local policy (non persistent) - recoveryOS - recoveryOS Local policy (persistent) The local policy TSS request differs slightly between the one for the restore process and the recoveryOS. The one for the restore process is meant to be used only once, and the one for the recovery os is meant to be loaded from disk, and thus has a different request. See the Ap,LocalBoot parameter.
src/restore.c
Outdated
| } | ||
|
|
||
| int extract_macos_variant(plist_t build_identity, char** output) { | ||
| // Get the device class from the build identity. `image_name` should look like 'j293ap' at the end. |
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Drop this comment, I guess.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done ✔️
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This comment is still here :)
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oops, fixed :)
|
I did address all of your comments, I'll let you resolve the conversations if you're happy with the changes 👍 |
|
Awesome work! I'm happy to test this on an M1 Macbook Pro and Macbook Air if you want :) (at least for SFR/1TR restore, not sure I want to reinstall everything right now :-)) |
|
@marcan I'm not sure about what you mean, but I think you're talking about doing an "Update" (restore behavior) instead of an "Erase", so that only the macOS system is rewritten ? If yes, I haven't tested this behavior. But if you want to help test macbooks, i'll first make sure it works for mac minis 😄 Just to try to minimize the risk 🙏 (Btw, thanks for the awesome macvdmtool and more generally your work on asahilinux, it helped us a lot in the beginning ❤️ ) |
|
I think Apple calls it "Revive Device", and it's supposed to install 1TR/NAND stuff without touching any macOS installs; either way, I can probably figure out how to take a backup of the macOS stuff (can you tell I'm not a macOS user normally? :)). I use the two laptops right now as general purpose remote terminals on macOS and as testing machines for Linux, but wouldn't normally expect to do full wipes, just wipes of the Linux partition, so I want to back up the macOS bit if I can. If it's lost though, it's not a big deal; there's no data there, it just means it'd take me some time to set things up again. I'm also interested in the process for any potential tricks I might use to help do Asahi Linux installs, if there are any. It's tricky enumerating exactly what we can and cannot do, and some of Apple's flows are actually buggy, so learning more about the intricacies is always good. |
|
Hi I am trying to restore my M1 MacbookPro and it fails with all firmwares: |
|
@rnagy can you open a ticket for this? Please run with -d since it seems like TSS doesn't like the request. |
Hello !
This is finally it ! After hundreds of hours of hard work, I can finally submit this merge request that adds all the missing pieces to restore M1 devices.
I know this is not the best code ever, but it works on m1 mac minis. I'd be happy to modify it :)
PS: The code might not work for M1 macbooks, but i'm not a mac user so i won't have any m1 laptop for the foreseeable future.