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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CACRpkdbx=Ye8xo4wMkyntME45xv15DeyqV32aeCAcSaa+vDpfA@mail.gmail.com>
Date:	Mon, 16 Dec 2013 14:31:53 +0100
From:	Linus Walleij <linus.walleij@...aro.org>
To:	Linus Walleij <linus.walleij@...aro.org>,
	Shubhrajyoti Datta <omaplinuxkernel@...il.com>,
	Carlos Chinea <cch.devel@...il.com>,
	Tony Lindgren <tony@...mide.com>,
	Grant Likely <grant.likely@...aro.org>,
	Rob Herring <rob.herring@...xeda.com>,
	Pawel Moll <pawel.moll@....com>,
	Mark Rutland <mark.rutland@....com>,
	Stephen Warren <swarren@...dotorg.org>,
	Ian Campbell <ijc+devicetree@...lion.org.uk>,
	Rob Landley <rob@...dley.net>,
	Benoît Cousson <bcousson@...libre.com>,
	"devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	Linux-OMAP <linux-omap@...r.kernel.org>,
	Pali Rohár <pali.rohar@...il.com>,
	Ивайло Димитров <freemangordon@....bg>,
	Joni Lapilainen <joni.lapilainen@...il.com>,
	Aaro Koskinen <aaro.koskinen@....fi>
Subject: Re: [RFCv4 06/11] misc: Introduce Nokia CMT driver

On Mon, Dec 16, 2013 at 1:15 PM, Sebastian Reichel <sre@...ian.org> wrote:
> On Mon, Dec 16, 2013 at 10:48:06AM +0100, Linus Walleij wrote:

>> I.e. it doesn't look device-specific at all, just like some
>> generic glue code that could be useful to many such
>> scenarios.
>
> I like the idea.
>
> Probably the remaining gpio exporting code can be converted into
> some generic gpio-sysfs-export driver as well.

I am very reluctant in letting device trees specify exports of GPIOs
to userspace, not so much because it's Linux-specific but for
the fact that people are doing things in userspace that should not
be done in userspace.

Last time it was proposed I asked to the specific usecase,
exactly why userspace needed this handle on a physical
GPIO line, and why it can't use another userspace interface
(example: leds, keys etc.)

> What do you think about the following?
>
> /*
>  * driver, which provides generic reset notifications
>  */
> cmt_reset: reset-notifier {
>     compatible = "linux,reset-notification";
>
>     interrupts = <gpio>;
> };

Looks good to me.

> /*
>  * driver, which exports the specified gpios in sysfs with the
>  * supplied names. The device will be named according to the
>  * label
>  */
> cmt_gpios: gpio-sysfs-export {
>     compatible = "linux,gpio-sysfs-export";
>     label = "nokia-cmt";
>
>     gpios = <A>, <B>, ...;
>     gpio-names = "A", "B", ...;
> };

Please follow the discussion on this topic:
http://marc.info/?l=linux-gpio&m=138201170431416&w=2

>> Why are you using a tasklet rather than a work
>> for this?
>
> No particular reason. I just took this over from Nokia's code.

Can you try to use a work instead?

Yours,
Linus Walleij
--
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