-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi all

I'm attaching the patch which should fix both problems. Fix the undefined u8
type and the bitpos selection in currently unused pnp_read_enable function.

Signed-off-by: Rudolf Marek <[EMAIL PROTECTED]>

Thanks,

Rudolf


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHugb83J9wPJqZRNURAlJWAJ9qS3Ash3iTSyruG3hiznZhl8C1wQCcDnKt
PNnRF1Nsh3nGlUmNN4KqOv4=
=JBUL
-----END PGP SIGNATURE-----
Index: pnp_device.c
===================================================================
--- pnp_device.c	(revision 3104)
+++ pnp_device.c	(working copy)
@@ -51,7 +51,7 @@
 
 void pnp_set_enable(device_t dev, int enable)
 {
-	u8 tmp, bitpos;
+	uint8_t tmp, bitpos;
 
 	tmp = pnp_read_config(dev, 0x30);
 	/* handle the virtual devices, which share same LDN register */
@@ -67,11 +67,11 @@
 
 int pnp_read_enable(device_t dev)
 {
-	u8 tmp, bitpos;
+	uint8_t tmp, bitpos;
 	tmp = pnp_read_config(dev, 0x30);
 	/* handle the virtual devices, which share same LDN register */
 	bitpos = (dev->path.u.pnp.device >> 8) & 0x7;
-	return !!(tmp & bitpos);
+	return !!(tmp & (1 << bitpos));
 }
 
 void pnp_set_iobase(device_t dev, unsigned index, unsigned iobase)

Attachment: fixes.patch.sig
Description: Binary data

-- 
coreboot mailing list
[email protected]
http://www.coreboot.org/mailman/listinfo/coreboot

Reply via email to