lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 23 Mar 2009 00:25:18 +0100
From:	Éric Piel <eric.piel@...mplin-utc.net>
To:	Daniel Mack <daniel@...aq.de>
CC:	linux-kernel@...r.kernel.org, Pavel Machek <pavel@....cz>
Subject: Re: [PATCH 4/5] lis3: solve dependency between core and ACPI

Daniel Mack schreef:
> This solves the dependency between lis3lv02d.[ch] and ACPI specific
> methods. It introduces a ->bus_priv pointer to the device struct which
> is casted to 'struct acpi_device' in the ACIP layer. Changed hp_accel.c
> accordingly.
Sorry for the long delay. Eventually I've found time to test the patch
and fix a bug: the axis conversion was set too late, preventing the
calibration to work.

The attached patch should make your modifications fully working with the
hp laptops :-)
I guess the best is to fold it into your patch and I'll ack the new
version.

Eric

=
Must put the axis info before using it.
---
 drivers/hwmon/hp_accel.c |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/hwmon/hp_accel.c b/drivers/hwmon/hp_accel.c
index 363220b..b6c32c5 100644
--- a/drivers/hwmon/hp_accel.c
+++ b/drivers/hwmon/hp_accel.c
@@ -287,11 +287,6 @@ static int lis3lv02d_add(struct acpi_device *device)
 	/* obtain IRQ number of our device from ACPI */
 	lis3lv02d_enum_resources(device);

-	/* call the core layer do its init */
-	ret = lis3lv02d_init_device(&lis3_dev);
-	if (ret)
-		return ret;
-
 	/* If possible use a "standard" axes order */
 	if (dmi_check_system(lis3lv02d_dmi_ids) == 0) {
 		printk(KERN_INFO DRIVER_NAME ": laptop model unknown, "
@@ -299,6 +294,11 @@ static int lis3lv02d_add(struct acpi_device *device)
 		lis3_dev.ac = lis3lv02d_axis_normal;
 	}

+	/* call the core layer do its init */
+	ret = lis3lv02d_init_device(&lis3_dev);
+	if (ret)
+		return ret;
+
 	INIT_WORK(&hpled_led.work, delayed_set_status_worker);
 	ret = led_classdev_register(NULL, &hpled_led.led_classdev);
 	if (ret) {
-- 
1.6.2.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ