Mac Mini with T2 chip



  • Does anyone have any luck backing up Mac Mini with T2 chip (Macmini 8,1 2018, Boot room: 1037.60.58.0.0, iBridge: 17.16.12551.0.0,0) or anything alike? CloneZilla doesn’t load at all. FOG USB drive with latest kernel got to

    loading the kernel 
    loading the virtual hard drive
    booting kernel....
    

    then the screen went dark without doing anything.



  • @george1421 built-in nic can upload/download image just fine. I’m not sure of how to get MAC address from firmware bios on a Mac.


  • Moderator

    @TaTa Ok now that both pick up IP addresses, can you image using the built in nic now as you can with the older hardware?

    On the case of why… I can’t think of a reason why the linux kernel would report a different mac address than the OS. That simply shouldn’t happen. I know windows has a “feature” for wifi that it can/will create a random IP address for security reasons, but that feature is a bit dumb for me.

    I’m speaking out of ignorance here, but does the hardware have some kind of firmware (bios) setup where you can see the mac address the firmware is reporting. I’m thinking the equivalent to the Dell bios screens. Since its apple with a locked ecosystem it might not.



  • @george1421 I took that MAC address and registered. Both nics picked up IP addresses correctly in FOS linux.
    I happen to find another Mac Mini and FOS linux does report a different MAC address than from OS. Weird.


  • Moderator

    @TaTa said in Mac Mini with T2 chip:

    unning /sbin/udhcpc -i enp126s0u2 --now shows correct assigned IP
    /sbin/udhcpc -i enp1s0 --now has no IP assign (MAC address needs to be registered in our database for DHCP to assign an IP)

    So do we know which network adapter is the built in one? And which network adapter is getting the IP address? If we take the mac address for enp1s0 that is shown by FOS Linux and register it with your dhcp server, then reboot into option 6 with a network cable attached to both ethernet ports. Do both nics pick up IP addresses without manual intervention? (there is a known condition where they might not. The test is to see if time will resolve the issue by running the udhcpc command after 30 seconds). I think we might be chasing 2 issues with networking at the same time.



  • @george1421 running /sbin/udhcpc -i enp126s0u2 --now shows correct assigned IP
    /sbin/udhcpc -i enp1s0 --now has no IP assign (MAC address needs to be registered in our database for DHCP to assign an IP)

    running lspci -nn |grep -i net shows

    01:00.0 Ethernet controller [0200]: Device [1d6a:07b1] (rev 02)
    03:00.0 Network controller [0280]: Broadcom Limited Device [14e4:4464] (rev 03)
    

    @Sebastian-Roth said in Mac Mini with T2 chip:

    Please download the latest inits (64 bit, 32 bit) and make sure you update your grub.conf file to use ramdisk_size=275000!!

    I downloaded the new inits and set ramdisk_size to 275000. Then scheduled a new upload. It went to partclone screen and attempt to upload. it lasted for about 3 seconds and went to 100% and goes to update database (sorry I didn’t have a chance to take a picture) and trying to reboot the systems went to this screen Fixing recursive fault but reboot is needed! https://forums.fogproject.org/topic/14073/mac-mini-with-t2-chip/16#


  • Moderator

    @TaTa Well having an unknown nic is a bit strange.

    If you plug a functioning network cable into both the onboard nic and the usb-c nic and then issue these commands can either get an IP address?

    /sbin/udhcpc -i enp126s0u2 --now

    /sbin/udhcpc -i enp1s0 --now

    To understand a bit more about the enp1s0 nic (which sounds like an Intel nic) you can run the following command lspci -nn |grep -i net and it will display the kernel drivers used for both nics. I can tell you from experience if linux doesn’t have a driver for the network device it will not report or show up the nic in the ip addr show command. Now it may pic the wrong driver, but at least FOS Linux has the driver for both nics.



  • @george1421 ip addr show lists network adapters as enp126s0u2 (USB-c to ethernet adapter), enp1s0, and lo. enp1s0 MAC address is not the same as reported in Mac OS or BootCamp for Ethernet adapter nor it’s the same as Wifi MAC address.
    lsusb does show ID for USB-C multimedia adapter: Bus 001 Device 004: ID 05ac:1461


  • Moderator

    Patch linux kernel 5.4.6 (disregard my references to other series 5.x.x kernels in previous posts. I used and compiled against 5.4.6 and not what I thought I was building against 5.4.3 or what ever I said).

    I started with the 5.4.6 base kernel and applied the FOG configurations from FOS Linux 1.5.7 config file. I enabled thunerbolt and usb type-c drivers in the code, plus a bunch of other things I can’t remember at the moment.

    The config file used to build the bzImageT2b is here:
    Config.T2Chip.txt

    The diff from the 1.5.7 kernel loaded into the 5.4.6 kernel config space vs the bzImageT2b config file above is here:
    apple_T2_diff.patch.txt

    Basically these are the changes made from FOS Linux 1.5.7 after they were loaded into the 5.4.6 kernel builder tool and the changes I made enabling what I thought this apple hardware needed.

    Here are the T2 kernel patches that were supplied via the github link https://github.com/MCMrARM/mbp2018-etc/tree/master/applesmc These patches must be applied to the linux 5.4.6 kernel in numeric order.

    0001-applesmc-convert-static-structures-to-drvdata.patch.txt
    0002-applesmc-make-io-port-base-addr-dynamic.patch.txt
    0003-applesmc-switch-to-acpi_device-from-platform.patch.txt
    0004-applesmc-key-interface-wrappers.patch.txt
    0005-applesmc-basic-mmio-interface-implementation.patch.txt
    0006-applesmc-fan-support-on-T2-Macs.patch.txt


  • Moderator

    @TaTa For the network adapter, that driver has been in the linux kernel since 4.12. It is still in the current release and is enabled in the FOS Linux kernel. For the next steps I will need you to boot into debug mode on the usb stick and run a few commands.

    ip addr show
    Confirm that the network adapter doesn’t an ip address. Post the output here so I can see what it looks like, wait 30 seconds after booting then key in
    /sbin/udhcpc -i $iface --now Now you will need to replace the variiable $iface with the kernel name of the network adapter. This kernel name will come from the ip addr show command.
    again run the ip address show to see if time fixes the issue.
    ip addr show

    for the video, I’ll need you to run the lsusb command to see if the kernel sees the driver with the USB ID 05AC:1461


  • Moderator

    @TaTa Ah that is a 10G adapter. The last time I looked not all of the 10G adapters were enabled in FOS Linux

    So for the network adapter I need Aquantia AQtion [1D6A:07B1]

    For the video
    05AC:1461 05ac Apple, Inc.

    Off to search now



  • @george1421 alt text
    alt text

    Keyboard and mouse works on both T2 and T2b.


  • Moderator

    @TaTa OK for both lets see if we can get the hardware IDs of both of them.

    From the USB stick make sure option #6 (debug) uses the new 5.3.4 kernel. Then usb boot using option 6. After several screens of text you need to clear with the enter key. Eventually you will be dropped to a FOS linux command (just a note, if the system will boot with the usb video adapter installed, install it before you boot into option #6). Once at the linux command prompt key in the following lspci -nn | grep -i net Take a clear picture of the output the closer the better. I need the values that look like this [8086:15cd] (totally made up number). But I need the hex values in the squared brackets with the description. The next one is going to be a bit of hunt and pecking to find the right numbers for the usb interlaces. I don’t think that the FOS Linux command gives us as much detail as on a conventional linux distribution. lsusb from there I need to get the hardware numbers of the video adapter.

    Now your MAC OS may provide a better and quicker way to get the hardware ID than booting through FOS linux. The numbers will be constructed similarly. So you might try OSX first. In windows these values are avaialble via the device manager in the form of “vend_id=8086;device_id=15cd”

    Once I have the device ids I can then start tracking back the drivers needed for them.

    Oh one last feedback on the T2b kernel, did the keyboard and mouse work on this one vs just the T2 patches? I just wanted to know the effectiveness of the HID patch.



  • @george1421 Yes. I want to be able to use built-in ethernet card (and usb-c to vga adapter if possible).
    Yes. 5.3.4 with T2 paches worked through HDMI and I was able to upload/download image correctly.


  • Moderator

    @TaTa said in Mac Mini with T2 chip:

    Built-in ethernet are not able to get an IP from DHCP.

    Do you want to work on this error? We can probably fix it.

    Secondly I just want to confirm that 5.3.4 linux kernel with the T2 patches worked and imaged the computer correctly through the T2 chip? I’ll need to write up what I changed for the developers so they can look at adding it to a future release of FOG.


  • Senior Developer

    @Sebastian-Roth The init’s kind of indicate the fix wasn’t in for those files. Notice the Parclone version is still 0.2.89


  • Developer

    @TaTa said:

    Failed to read back partitions (runPartprobe)
       Args Passed: /dev/nvme0n
    

    As far as I know this issue should be fixed in the latest inits already. From what I see in the pictures (partclone v0.2.89, ramdisk_size=127000) you seem to use an older version of the init files.

    Please download the latest inits (64 bit, 32 bit) and make sure you update your grub.conf file to use ramdisk_size=275000!!



  • @george1421 Downloaded successfully but with error below. Rebooted the machine and tested both Mac OS and BootCamp partitions. Everything’s working fine. Thanks a million @george1421 & @Sebastian-Roth
    alt text

    I tried T2b kernel. USB-C to vga adapter still does not work (screen went power saving). Built-in ethernet are not able to get an IP from DHCP.



  • @george1421 Uploaded successfully but getting the error below. I’m downloading it now and will report back.
    alt text



  • @george1421 Thank you. I will try it out once i’m done testing this.
    It’s at 71% now and still going strong. Uploading speed is 6.66GB/min.


Log in to reply
 

443
Online

6.6k
Users

14.0k
Topics

132.4k
Posts