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: <20140107114552.GA900@earth.universe>
Date:	Tue, 7 Jan 2014 12:45:53 +0100
From:	Sebastian Reichel <sre@...g0.de>
To:	Satish Patel <satish.patel@...com>
Cc:	Mark Rutland <mark.rutland@....com>,
	"devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
	"arnd@...db.de" <arnd@...db.de>,
	"gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"rob@...dley.net" <rob@...dley.net>,
	"linux-omap@...r.kernel.org" <linux-omap@...r.kernel.org>,
	"linux-arm-kernel@...ts.infradead.org" 
	<linux-arm-kernel@...ts.infradead.org>
Subject: Re: [RFC PATCH v1 2/5] misc: tda8026: Add NXP TDA8026 PHY driver

On Tue, Jan 07, 2014 at 12:06:37PM +0530, Satish Patel wrote:
> >> +       if (pdata->irq == 0) {
> >> +               /* look for the field irq-gpio in DT */
> >> +               irq_gpio = of_get_named_gpio(np, "irq-gpio", 0);
> >> +               if (!gpio_is_valid(irq_gpio)) {
> >> +                       dev_err(dev, "Failed to get irq gpio,\n");
> >> +                       return -EIO;
> >> +               }
> > 
> > This is horrible. If the gpio controller can act as an irq controller
> 
> No it's not true. Let me clarify the signal flow,
> 
> Pins => GPIO => GPIO BANK => Interrupt controller => CPU/MPU

This is done automatically if you use the gpio controller as
interrupt source (here with GPIO line 22 as example):

device-tree-node {
    interrupts-extended = <&gpio1 22>;
};

alternatively, but then the irqs from the normal irq controller
can't be used:

device-tree-node {
    interrupt-parent = <&gpio1>;
    interrupts = <22>;
};

-- Sebastian

Download attachment "signature.asc" of type "application/pgp-signature" (837 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ