linux-i2c.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ludovic Desroches <ludovic.desroches-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org>
To: Cyrille Pitchen
	<cyrille.pitchen-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org>
Cc: ludovic.desroches-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org,
	nicolas.ferre-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org,
	linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
Subject: Re: [PATCH 2/3] i2c: at91: print hardware version
Date: Mon, 1 Jun 2015 11:23:22 +0200	[thread overview]
Message-ID: <20150601092322.GJ25118@odux.rfo.atmel.com> (raw)
In-Reply-To: <5d08690d152e10592443224b46b677071196f730.1432907105.git.cyrille.pitchen-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org>

On Fri, May 29, 2015 at 03:50:09PM +0200, Cyrille Pitchen wrote:
> The probe() function now prints the hardware version of the I2C controller
> 
> Signed-off-by: Cyrille Pitchen <cyrille.pitchen-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org>
Acked-by: Ludovic Desroches <ludovic.desroches-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org>

> ---
>  drivers/i2c/busses/i2c-at91.c | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/drivers/i2c/busses/i2c-at91.c b/drivers/i2c/busses/i2c-at91.c
> index b48be58..1549b29 100644
> --- a/drivers/i2c/busses/i2c-at91.c
> +++ b/drivers/i2c/busses/i2c-at91.c
> @@ -85,6 +85,8 @@
>  #define	AT91_TWI_ACR_DATAL(len)	((len) & 0xff)
>  #define	AT91_TWI_ACR_DIR	(1 << 8)
>  
> +#define	AT91_TWI_VER		0x00fc	/* Version Register */
> +
>  struct at91_twi_pdata {
>  	unsigned clk_max_div;
>  	unsigned clk_offset;
> @@ -867,6 +869,8 @@ static int at91_twi_probe(struct platform_device *pdev)
>  			return rc;
>  	}
>  
> +	dev_info(dev->dev, "version: 0x%x\n", at91_twi_read(dev, AT91_TWI_VER));
> +
>  	rc = of_property_read_u32(dev->dev->of_node, "clock-frequency",
>  			&bus_clk_rate);
>  	if (rc)
> -- 
> 1.8.2.2
> 

  parent reply	other threads:[~2015-06-01  9:23 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-29 13:50 [PATCH 0/3] i2c: at91: add support to FIFOs and alternative command Cyrille Pitchen
     [not found] ` <cover.1432907105.git.cyrille.pitchen-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org>
2015-05-29 13:50   ` [PATCH 1/3] i2c: at91: add support for new alternative command mode Cyrille Pitchen
     [not found]     ` <301d33a22f415a6c235a75bd849869bdd06a2ad0.1432907105.git.cyrille.pitchen-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org>
2015-06-01  9:21       ` Ludovic Desroches
2015-05-29 13:50   ` [PATCH 2/3] i2c: at91: print hardware version Cyrille Pitchen
     [not found]     ` <5d08690d152e10592443224b46b677071196f730.1432907105.git.cyrille.pitchen-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org>
2015-06-01  9:23       ` Ludovic Desroches [this message]
2015-05-29 13:50 ` [PATCH 3/3] i2c: at91: add support to FIFOs Cyrille Pitchen
     [not found]   ` <97c1132454eefd44dfb3e097c5a38df139f5100e.1432907105.git.cyrille.pitchen-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org>
2015-06-01  9:44     ` Ludovic Desroches

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=20150601092322.GJ25118@odux.rfo.atmel.com \
    --to=ludovic.desroches-aife0yeh4naavxtiumwx3w@public.gmane.org \
    --cc=cyrille.pitchen-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org \
    --cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
    --cc=linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=nicolas.ferre-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).