image ResEx Logo
ResExcellence www : Powered by Google
Cell Phone Themes Icons Mighty Mouse Cursors Software Reviews Widgets & Widgets


Files are in Stuffit 5 or greater format.
Free download.

Tell us about a bad link.

Thank You!


Running
without a restart.

An Interview with Benjamin Herrenschmidt, PPC/Kernel Hacker.
by Michael Coyle

In the early days of PPC/Linux, it was extremely difficult to boot into the alternative OS. It required a three-finger keyboard command to boot into Open Firmware and then typing several lines of cryptic text.

Fortunately, thanks to work the of Benjamin Herrenschmidt and his free BootX Control panel, booting Linux in Old World Macs became much easier. It opened Linux to a large number of average Mac users. Today, several years later, BootX has been replaced by yaboot and Ben has moved on to become a major contributor to the PowerPC branch of the Linux kernel. Running Linux on a Powerbook or iBook with support for power management and accelerated graphics wouldn't be possible without his efforts.

Born in Selestat, France twenty-nine years ago, Ben had his first computer at 8 years old (a ZX81) and by the age of 13 he was enrolled in his first "Technology Class". You wouldn't call him the "Teachers Pet", more likely a "Teachers Pest" since the instructor soon asked young Benjamin run the course for him.

His first exposure to the MacOS came when he ran a Mac emulator on Atari ST and Amiga computers. By college, Ben traded his Amiga computer for his first Mac. At that time, he had no interest in Linux, but enjoyed writing for the lower level bits and bytes. He adds,

"Unlike many other Linux hackers, Unix is a late discovery for me. After I sold my Amiga, I had the chance to have access to a Mac and started learning MacOS programming. I started doing that professionally after spending a couple of years having fun and drinking beer at the university. I quickly became interested specifically in device drivers and other kind of low level programming, and that's probably what led me to Linux."

Benjamin installed MkLinux on his Wallstreet PowerBook, but there was no Sleep support at that time. He contacted the maintainer of the PPC branch of the Linux kernel, Paul Mackerras, and asked permission to use his Linux/PPC PMU (Power Management) source code as the basis for an MkLinux version. Ben never finished the MkLinux version, but this introduction to Paul and PPC/Linux led to his switch from MkLinux to the PPC/Linux kernel where he rolled up his sleeves and dug in, fixing whatever low level drivers got in the way of enjoying Linux on his Powerbook. But what let to the development of BootX?

"At one point, I got fed up of floppy booting and used a code snipped I found on usenet that showed how to switch the CPU into supervisor mode. I used that to write BootX. That's how, slowly, I started using my knowledge of Macs and my MacOS hacking skills to work on improving Linux on Macs. But I've never been a Linux _user_, I'm still learning "newbie" tricks everyday. When it comes to userland, I believe I can't even write moderately complex shell scripts."

One advantage to being a developer on the PPC code base is how quickly your patches are accepted into the official Linux kernel. In the x86 world, there are substantially more developers trying to get their snippet of code added to the kernel, but in the PowerPC world, the pond is a lot smaller and it's easier to be a "Big Fish". While PPC is a smaller community, it's not limited solely to Apple hardware.

"The PPC tree has it's own complexities, mostly because we have to deal with a large set of very different machines and CPUs. From the PowerMacs, PRePs & CHRP, the 4xx and 8xx based embedded platforms, and even IBM pSeries and iSeries servers."

Because the source code is often available for Linux programs, the platform disparity that exists between MacOS and Windows is diminished. If a software developer compiles his project for the x86 architecture, the user of a PPC computer can simply compile the source on his own computer. Unfortunately, there are sometimes problems with the compilation. Are x86 developers reluctant to modify their code to accommodate PPC users; is Linux another OS where PowerPC users are given second-class status?

"Well, except for some rare cases, I've never seen maintainers reluctant to merge in things like endian fixes. It's a bit more difficult when it comes to someone saying, "Hey, add that ugly hack that makes it work for me".

But Benjamin, do you make money writing Open Source software?

"So far, all my Linux work has been spare-time volunteer activity. I have a job in a nice small company where I mostly do MacOS software. Our company is evolving though, and we are now working on some embedded systems using Linux/PPC on IBM 405GP CPU. I do it (Linux/PPC Development) for fun and because I learned a lot of things doing it.

I quite like the concept of Free Software and am happy to put my work under the GPL umbrella. I believe at some point, computer science is like science in general; information and techniques have to be shared to benefit the most people and evolve.

I also feel these technologies have too important a position in our society; too many things depend on them, to safely leave them in the hands of an opaque monopoly. Free Software (or Open Source in this case) is a kind of guarantee that the technology you rely on can be trusted."

It seemed Apple would embrace Linux. There was even a ppclinux.apple.com website for a while, but the site has disappeared as have most mentions of Linux from the Apple site. The boot process for MacOS X seems very similar to what happens in BootX and yaboot for Linux. Did you ever work for Apple? What is your opinion on how they view Linux?

"I did not work for Apple, but I used to (and still) know some Apple engineers. Apple use to have a "Linux technology manager", but I'm not sure I fully figured out what his role was, but he tried hard to get us hardware specifications (and mostly failed).

Apple's BootX and Linux BootX are two completely different things. yaboot is similar, but they were developed independently and share no code. There has been no collaboration here.

It's difficult to decrypt the reasons Apple does things. They didn't open source driver code for some third party hardware, but that is understandable. They might simply not have had the right to do so. Regarding drivers for Apple's own hardware, they did indeed "hide" a couple of them. What comes to my mind right now are the PMU driver (Power Management Unit) and the Firewire controllers driver (OHCI and Lynx chipsets)."

Still, by making Darwin, the core of MacOS X, more open, Apple must be helping the PPC/Linux group, even if inadvertently.

"Darwin code has been incredibly useful for some things. There is no documentation on the various Apple chipsets, so we have to "discover" them by either looking at the OF code (Open Firmware), disassembling MacOS bits, or reading Darwin drivers.

I have not used Darwin as a distribution however. I do use MacOS X at work, and I quite like it. I have a machine running Linux 100% of the time, and one running MacOS (9 or X). In fact, I also run MacOS 9 in MacOnLinux on the Linux machine right now to write this email using CTM software's excellent PowerMail"

PPC/Linux on a new Ti Powerbook
(Click for full image in a new window)
It's possible Apple no longer actively supports Linux because the OS is multi-platform. In the final analysis, Apple is a hardware company. They leverage the MacOS to move CPUs. Since Linux runs on a variety of platforms, most costing less than Apple's hardware, support from Apple for Linux only increases the probability of migration to the x86 platform.

Still, it would be a mistake to think PPC/Linux lags behind the MacOS. It has always been fully multi-threaded and preemptive, features lacking in Classic MacOS, and Linux's hardware support exceeds MacOS X is some areas, PCMCIA and printing are two that come to mind.

Fortunately, the Mac/Linux community has volunteer coders, such as Ben Herrenschmidt, whose efforts keep an inexpensive and open source alternative to the MacOS available on PowerPC hardware.

Cell Phone Themes Icons Mighty Mouse Cursors Software Reviews Widgets & Widgets

Maintained by the Staff of ResExcellence. This entire site ©1997-2006 ResExcellence
Privacy Statement? Sure we gotta Privacy Statement. [an error occurred while processing this directive]