[patches] Add dmi kernel class support into HAL

Richard Hughes hughsient at gmail.com
Tue May 22 07:06:23 PDT 2007


Lennart has written a patch [1] to the kernel to expose dmi data in
sysfs. This allows HAL to just read out files from sysfs rather than
using a smbios prober and screen-scraping the output.

The patch is being discussed on LKML and will soon be hopefully included
upstream soon. I'm not sure what tree it is in, but should be upstream
soon as it allows us to do some cool stuff with module loading.

The following 3 patches add dmi class support into HAL. Not using the
prober is significantly quicker, and also allows us to clean up some
code.

00-hal-dmi-class-move-chassis-convert.patch

Moves the chassis to formfactor code into a common file for both the
prober and the device to use.

01-hal-dmi-class-use-computer-for-no-parent.patch

We want to add properties to the computer device when no device, and the
current code just supplies NULL. I think this is a bug, and so have
matched the parent device (in TDL or GDL) to computer when one does not
exist. Without this patch the dmi class won't be able to add keys.

02-hal-dmi-class-use-kernel-dmi-class.patch

Use the kernel sysfs interface, rather than screenscrape the output of
dmidecode. If the kernel patch is not installed, it just falls back and
use the prober as we did before.

Please review,

Richard.

[1] http://0pointer.de/public/dmi-id.patch
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 02-hal-dmi-class-use-kernel-dmi-class.patch
Type: text/x-patch
Size: 7591 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/hal/attachments/20070522/c96d6fa9/attachment-0006.bin 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 01-hal-dmi-class-use-computer-for-no-parent.patch
Type: text/x-patch
Size: 1001 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/hal/attachments/20070522/c96d6fa9/attachment-0007.bin 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 00-hal-dmi-class-move-chassis-convert.patch
Type: text/x-patch
Size: 2284 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/hal/attachments/20070522/c96d6fa9/attachment-0008.bin 


More information about the hal mailing list