All of lore.kernel.org
 help / color / mirror / Atom feed
From: shc_work@mail.ru (Alexander Shiyan)
To: linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 3/7] pinctrl: imx1 core driver
Date: Fri, 02 Aug 2013 14:51:24 +0400	[thread overview]
Message-ID: <1375440684.157419108@f61.mail.ru> (raw)
In-Reply-To: <1375439907-10462-4-git-send-email-mpa@pengutronix.de>

> Signed-off-by: Markus Pargmann <mpa@pengutronix.de>
> ---
[...]
> +++ b/drivers/pinctrl/pinctrl-imx1-core.c
> @@ -0,0 +1,667 @@
> +/*
> + * Core driver for the imx pin controller in imx1/21/27
[...]
> +static void imx1_write_2bit(struct imx1_pinctrl *ipctl, unsigned int pin_id,
> +		u32 value, u32 reg_offset)
> +{
> +	void __iomem *reg = imx1_mem(ipctl, pin_id) + reg_offset;
> +	int shift = (pin_id % 16) * 2;
> +	int mask = ~(0x3 << shift);

0x3.

> +	u32 old_value;
> +
> +	dev_dbg(ipctl->dev, "write: register 0x%p shift %d value 0x%x\n",
> +			reg, shift, value);
> +
> +	if (pin_id % 32 >= 16)
> +		reg += 0x04;
> +
> +	value = (value & 0x11) << shift;

0x11. Is this correct?

[...]

---

  reply	other threads:[~2013-08-02 10:51 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-02 10:38 [PATCH 0/7] ARM: imx27 pinctrl Markus Pargmann
2013-08-02 10:38 ` [PATCH 1/7] gpio: mxc: Support initialization as subdevice Markus Pargmann
2013-08-07 19:03   ` Linus Walleij
2013-08-09 17:56     ` Markus Pargmann
2013-08-02 10:38 ` [PATCH 2/7] pinctrl: imx header, conditional probe functions Markus Pargmann
2013-08-05  5:43   ` Shawn Guo
2013-08-09 13:31     ` Markus Pargmann
2013-08-02 10:38 ` [PATCH 3/7] pinctrl: imx1 core driver Markus Pargmann
2013-08-02 10:51   ` Alexander Shiyan [this message]
2013-08-02 10:54     ` Markus Pargmann
2013-08-05  9:29   ` Sascha Hauer
2013-08-09 18:16     ` Markus Pargmann
2013-08-07 19:25   ` Linus Walleij
2013-08-09 19:33     ` Markus Pargmann
2013-08-02 10:38 ` [PATCH 4/7] pinctrl: imx27: imx27 pincontrol driver Markus Pargmann
2013-08-05  6:12   ` Shawn Guo
2013-08-09 13:46     ` Markus Pargmann
2013-08-02 10:38 ` [PATCH 5/7] ARM: dts: imx27 pin functions Markus Pargmann
2013-08-05  6:14   ` Shawn Guo
2013-08-02 10:38 ` [PATCH 6/7] ARM: dts: imx27 pinctrl Markus Pargmann
2013-08-05  6:18   ` Shawn Guo
2013-08-09 13:54     ` Markus Pargmann
2013-08-02 10:38 ` [PATCH 7/7] ARM: imx27: enable pinctrl Markus Pargmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1375440684.157419108@f61.mail.ru \
    --to=shc_work@mail.ru \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.