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] [day] [month] [year] [list]
Message-ID: <4DD0E2EE.7010107@cam.ac.uk>
Date:	Mon, 16 May 2011 09:40:14 +0100
From:	Jonathan Cameron <jic23@....ac.uk>
To:	Alan Cox <alan@...rguk.ukuu.org.uk>
CC:	dmitry.torokhov@...il.com, linux-input@...r.kernel.org,
	linux-kernel@...r.kernel.org, Chris Hudson <chudson@...nix.com>
Subject: Re: [PATCH 1/1] input: Add support for Kionix KXTJ9 accelerometer

I'll leave taking a proper look until you have cleared up the issues Alan pointed out.
But as I was taking a quick look...

Firstly I concur entirely with Alan in that most of the sysfs stuff should be
platform data for an input driver.
...
> 
>> +	memcpy(tj9->pdata, client->dev.platform_data, sizeof(*tj9->pdata));
>> +	if (tj9->pdata->init) {
>> +		err = tj9->pdata->init();
>> +		if (err < 0)
>> +			goto err2;
>> +	}
>> +
>> +	tj9->irq = gpio_to_irq(tj9->pdata->gpio);
> 
> What if it's not on a gpio. Probably better any gpio and irq conversion is
> done by the platform callback/init code
Perfectly good irq element in i2c_board_info structure.  This is exactly what
it is normally used for.
> 
> 
> And the sysfs nodes need documentation.
Would be nice to have some docs on that platform data struct as well.
Most of it is fairly obvious, but data_odr_init etc aren't!
> 
> 
> Overall it looks like a lot of input drivers that get posted here
> 
> - Nobody has considered locking between actions and sysfs (or multiple
>   sysfs actions in parallel)
> - Enable/disable is implemented in blissful ignorance of what happens if
>   a disable occurs during a sysfs or other action
> 
> Most of the rest looks like it just needs a good polish.
> --
> To unsubscribe from this list: send the line "unsubscribe linux-input" in
> the body of a message to majordomo@...r.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

--
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