Skip to contentSkip to conversation

hwmon: (asus_atk0110) Do not fail if MBIF is

PATCH Applied Luca Tettamanti 3 participants 3 messages Jan 17, 2010 – Jan 18, 2010

Subsystems (2)
lore
Share & tools
lore

Luca Tettamanti

author maintainer
#0 lore raw

PATCH 1/1 hwmon: (asus_atk0110) Do not fail if MBIF is

MBIF (motherboard identification) is only used to print the name of the board, it's not essential for the driver; do not fail if it's missing. Based on Juan's patch.

---
Juan, can sign off the patch?

 drivers/hwmon/asus_atk0110.c |   19 +++++++++----------
 1 file changed, 9 insertions(+), 10 deletions(-)
drivers/hwmon/asus_atk0110.c +9 -10
index fe4fa29..0729022 100644
@@ -921,17 +921,16 @@ static int atk_add(struct acpi_device *device)
 			&buf, ACPI_TYPE_PACKAGE);
 	if (ret != AE_OK) {
 		dev_dbg(&device->dev, "atk: method MBIF not found\n");
-		err = -ENODEV;
-		goto out;
-	}
-
-	obj = buf.pointer;
-	if (obj->package.count >= 2 &&
-			obj->package.elements[1].type = ACPI_TYPE_STRING) {
-		dev_dbg(&device->dev, "board ID = %s\n",
-				obj->package.elements[1].string.pointer);
+	} else {
+		obj = buf.pointer;
+		if (obj->package.count >= 2) {
+			union acpi_object *id = &obj->package.elements[1];
+			if (id->type = ACPI_TYPE_STRING)
+				dev_dbg(&device->dev, "board ID = %s\n",
+					id->string.pointer);
+		}
+		ACPI_FREE(buf.pointer);
 	}
-	ACPI_FREE(buf.pointer);
 
 	/* Check for hwmon methods: first check "old" style methods; note that
 	 * both may be present: in this case we stick to the old interface;

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

#1 lore raw

Re: [lm-sensors] [PATCH] hwmon: (asus_atk0110) Do not fail if MBIF

Quoted 5 lines · On Sun, 17 Jan 2010 23:05:34 +0100 Luca Tettamanti <[email protected]> wrote:

MBIF (motherboard identification) is only used to print the name of the board, it's not essential for the driver; do not fail if it's missing. Based on Juan's patch.

Cheers.

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

Applied
#2 lore raw

Re: [lm-sensors] [PATCH] hwmon: (asus_atk0110) Do not fail if MBIF

In reply to Luca Tettamanti
Quoted 10 lines · Juan RP
Quoted 5 lines · On Sun, 17 Jan 2010 23:05:34 +0100 Luca Tettamanti <[email protected]> wrote:

MBIF (motherboard identification) is only used to print the name of the board, it's not essential for the driver; do not fail if it's missing. Based on Juan's patch.

Applied, thanks!

Signature · 6 lines
Jean Delvare

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors