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] [thread-next>] [day] [month] [year] [list]
Message-ID: <CACRpkdb1rZQWpuUxQoxqg2eYanf4tnm0SmFkQQBwvSuyYV00Gw@mail.gmail.com>
Date:	Thu, 5 Jul 2012 10:55:57 +0200
From:	Linus Walleij <linus.walleij@...aro.org>
To:	Lee Jones <lee.jones@...aro.org>
Cc:	linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
	linus.walleij@...ricsson.com, arnd@...db.de,
	Stephen Warren <swarren@...dotorg.org>,
	Gabriel FERNANDEZ <gabriel.fernandez@...ricsson.com>,
	Loic Pallardy <loic.pallardy@...ricsson.com>,
	Patrice CHOTARD <patrice.chotard@...ricsson.com>
Subject: Re: [PATCH] ARM: ux500: Register pinctrl from platform code until
 it's been DT:ed

On Wed, Jul 4, 2012 at 4:34 PM, Lee Jones <lee.jones@...aro.org> wrote:

> There are some inconsistencies with the way pinctrl devices are named
> when registered from platform code to the ones registered by Device
> Tree. Platform devices look like 'pinctrl-db8500', whereas the ones
> registered from Device Tree look more like 'pinctrl.2'. This leads to
> failure when carrying out name-based searches for known devices.
>
> Until the correct DT bindings have been applied to the pinctrl driver
> it will fail to function correctly. For instance, during a Device
> Tree boot on Snowball no bootlog is visible due to a UART port probe
> failure. Regulators fail in a similar way.

The problem is *NOT* any missing device tree bindings. The place
where the problem appear is in the pin control mapping table, which
uses the string "pinctrl-db8500"

The bindings to pass in the pinctrl mapping from the devcie tree
is generic and already exist:
Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt

The stuff in the file:
arch/arm/mach-ux500/board-mop500-pins.c

Need to be moved over to the device tree. There are plenty of
examples of how to do this in for example:
arch/arm/boot/dts/tegra-seaboard.dts

So what is needed is that someone augment the device tree
with the pinctrl data and disable the registration of the static
maps from the above file if the node exists.

> This patch prevents Device Tree from probing the pinctrl driver and
> ensures registration is completed from platform code instead.
>
> Signed-off-by: Lee Jones <lee.jones@...aro.org>

Is the DT machinery really incapable of specifying
the device name to anything else than the bus name?
Can't you do this with AUX_DATA()? I've seen that done in the
past. For example you do:

OF_DEV_AUXDATA("st,nomadik-gpio", 0x8012e000, "gpio.0", NULL),

Can't you just:
OF_DEV_AUXDATA("stericsson,nmk_pinctrl", 0, "pinctrl-db8500", NULL),

And it will happily assign the "pinctrl-db8500" name to it's instantiated
device?

?

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