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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sun, 15 Jan 2012 21:07:18 -0800
From:	"Kim, Milo" <Milo.Kim@...com>
To:	"Axel Lin" <axel.lin@...il.com>
cc:	"Jeong, Daniel" <Daniel.Jeong@....com>,
	"Anton Vorontsov" <cbouatmailru@...il.com>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: RE: [PATCH] power_supply: Add MODULE_DEVICE_TABLE for lp8727
 charger

> Add MODULE_DEVICE_TABLE to setup modalias for lp8727.

Autoloading this module is not required.
The LP8727 includes a charger function with the micro/mini USB interface.
Charging a battery and detecting which cable is inserted, this kind of job must be started at the beginning of system boot.
So the lp8727 driver should be loaded before an user-space accesses this driver.

Thanks & BR
Milo -

-----Original Message-----
From: Axel Lin [mailto:axel.lin@...il.com] 
Sent: Thursday, January 12, 2012 9:45 PM
To: linux-kernel@...r.kernel.org
Cc: Kim, Milo; Jeong, Daniel; Anton Vorontsov
Subject: [PATCH] power_supply: Add MODULE_DEVICE_TABLE for lp8727 charger

Add MODULE_DEVICE_TABLE to setup modalias for lp8727.
The i2c_device_id table is supposed to be zero-terminated.
Thus add a missing terminate entry for lp8727_ids.

Signed-off-by: Axel Lin <axel.lin@...il.com>
---
 drivers/power/lp8727_charger.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/power/lp8727_charger.c b/drivers/power/lp8727_charger.c
index b15b575..8e901c9 100644
--- a/drivers/power/lp8727_charger.c
+++ b/drivers/power/lp8727_charger.c
@@ -464,7 +464,9 @@ static int __devexit lp8727_remove(struct i2c_client *cl)
 
 static const struct i2c_device_id lp8727_ids[] = {
 	{"lp8727", 0},
+	{ },
 };
+MODULE_DEVICE_TABLE(i2c, lp8727_ids);
 
 static struct i2c_driver lp8727_driver = {
 	.driver = {
-- 
1.7.5.4



Powered by blists - more mailing lists