Ubuntu guru on power management hacks

A sneak preview of Matthew Garrett’s linux.conf.au power management presentation

It was while watching fellow Linux users having to shutdown their laptops in between talks at open source conferences some years ago that Matthew Garrett, now head of the Ubuntu laptop team, was initially alerted to power management issues in Linux systems.

After almost 15 years of hacking, Garrett will attend next week's linux.conf.au, to give a presentation on power management in an effort to fix suspend "for fun and profit".

Aside from working on improving hardware driver issues, Cambridge, U.K.-based Garrett has also worked extensively in Linux development, and was, until his resignation last August, one of the Debian project's most active developers.

Garrett speaks with Liz Tay about working in the open source community, Debian, Ubuntu, and linux.conf.au.

What interests you most about power management? For how long have you been working on power management and what are some experiences you've had?

I started looking at power management in 2002, after discovering that my laptop didn't work too well with the traditional APM support in Linux. At the time, Linux's ACPI support was pretty minimal. By 2004, things were starting to work better. I'd upgraded my laptop, and then spent a couple of weeks working on the kernel. By that summer, I'd worked out most of the kinks and suspend and resume worked reliably for me.

Later on that year, I got invited to the first Ubuntu development meeting. It gave me an opportunity to test how well this worked on other people's laptops. Sadly, it turned out that I was pretty much alone; almost everyone else there who had working power management had the same laptop as me! It was an opportunity though, and by the end of the week we had several more machines working.

Visiting conferences made me realise just how important power management was. Linux users all seemed to assume that they were doomed to spend the rest of their lives turning their laptops off between talks, and, to be honest, it was kind of embarrassing. I was in a position to help do something about it, and so since then I've spent time doing so.

What's the problem with suspend on current Linux systems? How can this be fixed?

Sadly, there's more than one problem. In many cases, the issue is with hardware drivers. Many Linux drivers were written without worrying about power management support, and so machines using these drivers are likely to have problems. In other cases, it's because hardware has only been tested against Windows. Windows and Linux have entirely separate implementations of the ACPI specification, and unsurprisingly the interpretations of the specification vary to some extent.

Finally, the ACPI spec doesn't cover video hardware - it's up to the operating system to reprogram the video card, and Linux often doesn't know how to.

The driver problem is likely to solve itself as more people start expecting power management to work. As bugs get filed, they'll get fixed. In terms of compatibility with Windows, two approaches have been taken.

Firstly, the Linux code has been altered to be more compatible with the Windows implementation - there's no point in being correct if nothing works. Secondly, Intel have released a toolkit that allows vendors to test whether their hardware conforms to the specification or not. With luck, this will become widely used.

The video problem is probably the hardest. There are various workarounds using the video BIOS, but they're not guaranteed to work. The only long-term solution is for X to gain support for reprogramming video cards from scratch, and sadly that's something that may require support from the video hardware manufacturers.

Join the newsletter!

Error: Please check your email address.

More about APMDebianHISIntelMicrosoftPLUS

Show Comments

Market Place