Forgotten patches. Ready to commit?

Richard Hughes hughsient at gmail.com
Fri Oct 7 07:18:56 PDT 2005


On Fri, 2005-10-07 at 10:07 -0400, David Zeuthen wrote:
> On Fri, 2005-10-07 at 08:15 +0100, Richard Hughes wrote:
> > On Thu, 2005-10-06 at 20:11 -0400, Ryan Lortie wrote:
> > > I'd like to commit my patch myself if that's OK.  Gotta use the new CVS
> > > privs for something :)
> > 
> > Lol, okay. You can do the fstab one too if you like. David, unless
> > you've got any objections, Ryan will commit both of those tonight.
> > 
> 
> Go for it. Thanks. Remember the fstab one should go on the
> hal-0_4-stable-branch right?
> 
>  http://cvs.freedesktop.org/hal/hal/?only_with_tag=hal-0_4-stable-branch
> 
> I should probably do a new 0.4.x and 0.5.x release soon. Does anyone
> have anything that needs to be committed before that? Only thing I can
> think of is the dmidecode one - how is that looking Richard?

Well it's a bit of a mess.

A bit of background. dmidecode (old version) outputs a series of tabbed
values, e.g.

Handle 0x0000
        DMI type 0, 20 bytes.
        BIOS Information
                Vendor: TOSHIBA
                Version: Version 1.30
                Release Date: 09/02/2003
                Address: 0xE0000
                Runtime Size: 128 kB
                ROM Size: 512 kB
                Characteristics:
                        ISA is supported
                        PCI is supported
                        PC Card (PCMCIA) is supported
                        PNP is supported
                        APM is supported
                        BIOS is upgradeable

But in new versions, has one less tab space:

Handle 0x0000, DMI type 0, 20 bytes.
BIOS Information
	Vendor: Phoenix Technologies LTD
	Version: 6.00
	Release Date: 02/11/2005
	Address: 0xE7CF0
	Runtime Size: 99088 bytes
	ROM Size: 64 kB
	Characteristics:
		ISA is supported
		PCI is supported
		PC Card (PCMCIA) is supported
		PNP is supported
		APM is supported
		BIOS is upgradeable
		BIOS shadowing is allowed
		ESCD support is available
		USB legacy is supported
		Smart battery is supported
		BIOS boot specification is supported

So the way we are going to have to parse this output varies. We can
either do the sensible thing, and depend on a new version of dmidecode,
or try to keep compatibility with lots of ugly if-else code (I've tried
this, and it ain't pretty)...

My personal perspective is to depend on the newest released dmidecode,
in the same way CVS head depends on a newish dbus.

I can cook up a patch to do this in no time at all.

Opinions?

Richard.



More information about the hal mailing list