[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20071024115034.GA5797@kos.to>
Date: Wed, 24 Oct 2007 14:50:34 +0300
From: Riku Voipio <riku.voipio@....fi>
To: Jean Delvare <khali@...ux-fr.org>
Cc: "Mark M. Hoffman" <mhoffman@...htlink.com>,
Adrian Bunk <bunk@...nel.org>, linux-kernel@...r.kernel.org,
lm-sensors@...sensors.org
Subject: Re: [lm-sensors] hwmon/f75375s.c: buggy if()
On Fri, Oct 19, 2007 at 02:37:54PM +0200, Jean Delvare wrote:
> Riku, can you please submit a patch fixing this? The attribute should
> be declared read-only, and then you can use sysfs_chmod_file() to
> change it to read-write where supported.
Thanks, this was good suggestion. Patch attached.
> Take a look at the w83781d
> driver for an example.
Btw, I think your example code has a indentation bug:
if (kind != w83781d)
err = sysfs_chmod_file(&dev->kobj,
&sensor_dev_attr_temp3_alarm.dev_attr.attr,
S_IRUGO | S_IWUSR);
if (err)
return err;
--
"rm -rf" only sounds scary if you don't have backups
-
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