X-Git-Url: http://pilppa.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=drivers%2Fhwmon%2Fvt1211.c;h=12b43590fa53e7a5aa80e325b409437277be8dc1;hb=ee4cd32ee8a68e22081f698602e4315fb4272853;hp=e69416465e6dbbe6fae9295d6fcde620568e26da;hpb=f4921aff5b174349bc36551f142a5dbac782ea3f;p=linux-2.6-omap-h63xx.git diff --git a/drivers/hwmon/vt1211.c b/drivers/hwmon/vt1211.c index e69416465e6..12b43590fa5 100644 --- a/drivers/hwmon/vt1211.c +++ b/drivers/hwmon/vt1211.c @@ -42,6 +42,10 @@ static int int_mode = -1; module_param(int_mode, int, 0); MODULE_PARM_DESC(int_mode, "Force the temperature interrupt mode"); +static unsigned short force_id; +module_param(force_id, ushort, 0); +MODULE_PARM_DESC(force_id, "Override the detected device ID"); + static struct platform_device *pdev; #define DRVNAME "vt1211" @@ -795,7 +799,7 @@ static ssize_t set_pwm_auto_point_pwm(struct device *dev, if ((val < 0) || (val > 255)) { dev_err(dev, "pwm value %ld is out of range. " - "Choose a value between 0 and 255." , val); + "Choose a value between 0 and 255.\n" , val); return -EINVAL; } @@ -1280,10 +1284,12 @@ EXIT: static int __init vt1211_find(int sio_cip, unsigned short *address) { int err = -ENODEV; + int devid; superio_enter(sio_cip); - if (superio_inb(sio_cip, SIO_VT1211_DEVID) != SIO_VT1211_ID) { + devid = force_id ? force_id : superio_inb(sio_cip, SIO_VT1211_DEVID); + if (devid != SIO_VT1211_ID) { goto EXIT; }