Re: RFC: Light sensors, unifying current options?

From: Jean Delvare
Date: Fri Sep 11 2009 - 03:20:57 EST


On Fri, 11 Sep 2009 09:55:01 +0800, Zhang Rui wrote:
> On Thu, 2009-09-10 at 18:05 +0800, Jonathan Cameron wrote:
> > Some sensors, e.g. tsl2561 use an internal clock to do sampling and hence
> > have some predefined period in which the reading taken doesn't change.
> > Perhaps exporting said period would be useful to userspace?
> >
> I don't think so.
> IMO, the tsl2561 driver should handle this, and there is no need to
> annoy the user space.
> i.e. users always assume the content of "illuminance" attribute is
> valid, and it's the driver's job to make this true. We don't need to
> document this.

I agree with Rui on this. Let's not delegate everything to user-space,
otherwise it's pointless to write kernel drivers in the first place.

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