MacBook – Newly installed Debian stuck on loading on MacBook Pro “Core 2 Duo” 2.16

macbook prounix

I made a successful installation of Debian 10.6 32 bits on my 2007 MacBook Pro "Core Duo" 2.16 GHz (T2600). 2007 MacBook Pro 15-Inch "Core 2 Duo" 2.16 2.16 GHz Core 2 Duo (T7400)

Intro. October 24, 2006
Disc. June 5, 2007
Order MA609LL
Model A1211 (EMC 2120)
Family Core 2 Duo/Late 2006
ID MacBookPro2,2
RAM 1 GB (upgraded to 3GB)
VRAM 128 MB

(MacBook Pro model includes an ATI Mobility Radeon X1600 graphics processor with 256 MB 128 MB of GDDR3 video memory and dual-link DVI functionality)

Debian version is: i386/iso-hybrid/debian-live-10.6.0-i386-gnome.iso.

After some fixing such as installing the firmware-linux-nonfree packages,
I now boot and get the following message:

"fb: switching to radeondrmfb from EFI VGA"

Once this message displayed, the system is stuck.

What does this message mean?
Is there something I could do to unblock the situation?

Any help is greatly appreciated.

Best Answer

I also have 2007 MacbookPro2,1 and have found that the Linux Radeon driver does not work.

Without recompiling your kernel your options are extremely limited - you could try an extremely old kernel (before 2009 KMS introduction) which would be hard to find and insecure or try passing nomodeset kernel parameter (which will mean no graphics at all).

To get graphics to work need to do the following:

  1. boot from latest ubuntu live CD (hold alt, or c, at boot)
  2. dump the bios dd if=/dev/mem of=vbios.bin bs=65536 skip=12 count=1
  3. move it to your partition's /lib/firmware/radeon/vbios.bin

Based on this Archlinux forums thread Load custom Radeon firmware for Macbook Pro thread I saved vbios.bin to /usr/lib/firmware/radeon/vbios.bin.

  • Check it as described in link above:

b) You can verify the correctness with: hexdump -C vbios.bin | head -n 1 00000000 55 aa 7d e9 7f 02 00 00 00 00 00 00 00 00 00 00 |U.}.............| the first two bytes must be 55 aa, also later in the dump you see some copyright notices. :-)

  • Patch radeon_bios.c source to read this file and recompile kernel.

This method has worked for me for the last several years. Occasionally radeon_bios.c changes and the patch in the links above is outdated. As of last month (October 2020) the following patch will work with kernel.org kernel. For others you may need to manually adjust it.

--- archlinux-linux/drivers/gpu/drm/radeon/radeon_bios.c.orig   2020-04-08 13:12:37.572725381 +0200
+++ archlinux-linux/drivers/gpu/drm/radeon/radeon_bios.c    2020-04-08 13:26:48.700908967 +0200
@@ -33,6 +33,7 @@
 #include <drm/drm_device.h>

 #include "atom.h"
+#include <linux/firmware.h>
 #include "radeon.h"
 #include "radeon_reg.h"

@@ -60,15 +61,18 @@ static bool igp_read_bios_from_vram(stru
    vram_base = pci_resource_start(rdev->pdev, 0);
    bios = ioremap(vram_base, size);
    if (!bios) {
+       DRM_ERROR("No bios\n");
        return false;
    }

    if (size == 0 || bios[0] != 0x55 || bios[1] != 0xaa) {
+       DRM_ERROR("Invalid bios\n");
        iounmap(bios);
        return false;
    }
    rdev->bios = kmalloc(size, GFP_KERNEL);
    if (rdev->bios == NULL) {
+       DRM_ERROR("alloc fail\n");
        iounmap(bios);
        return false;
    }
@@ -77,6 +81,41 @@ static bool igp_read_bios_from_vram(stru
    return true;
 }

+static bool radeon_read_bios_from_firmware(struct radeon_device *rdev)
+{
+   const uint8_t __iomem *bios;
+   resource_size_t size;
+   const struct firmware *fw = NULL;
+
+   request_firmware(&fw, "radeon/vbios.bin", rdev->dev);
+   if (!fw) {
+           DRM_ERROR("No bios\n");
+           return false;
+   }
+   size = fw->size;
+   bios = fw->data;
+
+   if (!bios) {
+           DRM_ERROR("No bios\n");
+           return false;
+   }
+
+   if (size == 0 || bios[0] != 0x55 || bios[1] != 0xaa) {
+           DRM_ERROR("wrong sig\n");
+           release_firmware(fw);
+           return false;
+   }
+   rdev->bios = kmalloc(size, GFP_KERNEL);
+   if (rdev->bios == NULL) {
+           DRM_ERROR("alloc fail\n");
+           release_firmware(fw);
+           return false;
+   }
+   memcpy(rdev->bios, bios, size);
+   release_firmware(fw);
+   return true;
+}
+
 static bool radeon_read_bios(struct radeon_device *rdev)
 {
    uint8_t __iomem *bios, val1, val2;
@@ -663,7 +702,9 @@ bool radeon_get_bios(struct radeon_devic
    bool r;
    uint16_t tmp;

-   r = radeon_atrm_get_bios(rdev);
+   r = radeon_read_bios_from_firmware(rdev);
+   if (!r)
+       r = radeon_atrm_get_bios(rdev);
    if (!r)
        r = radeon_acpi_vfct_bios(rdev);
    if (!r)