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]
Date:	Sun, 1 Jan 2012 15:19:42 +0100
From:	Linus Walleij <linus.walleij@...aro.org>
To:	Haojian Zhuang <haojian.zhuang@...vell.com>
Cc:	swarren@...dia.com, linux-kernel@...r.kernel.org,
	linux-arm-kernel@...ts.infradead.org, eric.y.miao@...il.com,
	linux@....linux.org.uk, arnd@...db.de
Subject: Re: [PATCH v3 2/3] ARM: mmp: enable pinmux in mmp platform

On Thu, Dec 22, 2011 at 9:17 AM, Haojian Zhuang
<haojian.zhuang@...vell.com> wrote:

> Configuring pinmux in brownstone, aspenite & ttc dkb platform. The functions
> of pins are initialized in platform driver.
>
> Signed-off-by: Haojian Zhuang <haojian.zhuang@...vell.com>

Deleting platform data and moving complex stuff to the pinctrl
subsystem where it belongs - great!

>        select CPU_MOHAWK
> +       select PINCTRL
> +       select PINMUX_PXA168

Will need to be renamed PINCTRL_PXA168 etc, sorry for the
painful renaming, just want to keep things consistent.

>        help
>          Select code specific to PXA168
>
>  config CPU_PXA910
>        bool
>        select CPU_MOHAWK
> +       select PINCTRL
> +       select PINMUX_PXA910

Here too.

>        help
>          Select code specific to PXA910
>
>  config CPU_MMP2
>        bool
>        select CPU_PJ4
> +       select PINCTRL
> +       select PINMUX_MMP2

Here too.

> +#define P168_CTRL              "pxa168-pinmux"
> +
> +static struct pinmux_map aspenite_pmx_map[] = {
> +       PINMUX_MAP_SYS_HOG("SSP1 SYSCLK", P168_CTRL, "ac97 sysclk"),
> +       PINMUX_MAP_SYS_HOG("SSP1 RX", P168_CTRL, "ssp1 rx"),
> +       PINMUX_MAP_SYS_HOG("SSP1 TX", P168_CTRL, "ssp1 tx"),
> +       PINMUX_MAP_SYS_HOG("DFIO", P168_CTRL, "dfio"),
> +       PINMUX_MAP_SYS_HOG("SMC CS0", P168_CTRL, "smc cs0"),
> +       PINMUX_MAP_SYS_HOG("SMC CS1", P168_CTRL, "smc cs1"),
> +       PINMUX_MAP_SYS_HOG("SMC RDY", P168_CTRL, "smc rdy"),
> +       PINMUX_MAP_SYS_HOG("SMC", P168_CTRL, "smc"),
> +       PINMUX_MAP_SYS_HOG("LCD", P168_CTRL, "lcd"),
> +       PINMUX_MAP_SYS_HOG("KP MKIN", P168_CTRL, "kpmkin"),
> +       PINMUX_MAP_SYS_HOG("KP MKOUT", P168_CTRL, "kpmkout"),
> +       PINMUX_MAP_SYS_HOG_GROUP("UART1 RX", P168_CTRL, "uart1 rx", "uart1rx-1"),
> +       PINMUX_MAP_SYS_HOG_GROUP("UART1 TX", P168_CTRL, "uart1 tx", "uart1tx-1"),
>  };

Excellent.

> -       mfp_config(ARRAY_AND_SIZE(common_pin_config));
> +       int ret;
> +
> +       ret = pinmux_register_mappings(ARRAY_AND_SIZE(aspenite_pmx_map));
> +       if (ret < 0)
> +               goto out;

Oh I never saw the ARRAY_AND_SIZE() macro before, cool!

Mostly same comments for the other board, thanks!

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