devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Marc Kleine-Budde <mkl-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
To: Shawn Guo <shawn.guo-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
Cc: Marek Vasut <marex-ynQEQJNshbs@public.gmane.org>,
	Alessandro Zummo
	<a.zummo-BfzFCNDTiLLj+vYz1yj4TQ@public.gmane.org>,
	rtc-linux-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org,
	devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org,
	Rob Herring <rob.herring-bsGFqQB8/DxBDgjK7y7TUQ@public.gmane.org>,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
Subject: Re: [PATCH V2] MXS: Add DT binding support into stmp3xxx-rtc
Date: Fri, 29 Jun 2012 13:08:17 +0200	[thread overview]
Message-ID: <4FED8CA1.5000800@pengutronix.de> (raw)
In-Reply-To: <20120625043711.GA18156-rvtDTF3kK1ictlrPMvKcciBecyulp+rMXqFh9Ls21Oc@public.gmane.org>


[-- Attachment #1.1: Type: text/plain, Size: 4451 bytes --]

On 06/25/2012 06:37 AM, Shawn Guo wrote:
> On Fri, Jun 08, 2012 at 08:56:44PM +0200, Marek Vasut wrote:
>> Add simple binding for the stmp3xxx-rtc.
>>
>> Signed-off-by: Marek Vasut <marex-ynQEQJNshbs@public.gmane.org>
>> Cc: Alessandro Zummo <a.zummo-BfzFCNDTiLLj+vYz1yj4TQ@public.gmane.org>
> 
> Hi Alessandro,
> 
> The patch has some changes on arch/arm/boot/dts/imx28.dtsi, and also we
> need the patch to convert some board files over to device tree.  May I
> have your ack to queue the patch on my tree?

The interrupt numbers are not as the driver expects them..

> 
> Regards,
> Shawn
> 
>> Cc: devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org
>> Cc: Grant Likely <grant.likely-s3s/WqlpOiPyB63q8FvJNQ@public.gmane.org>
>> Cc: Rob Herring <rob.herring-bsGFqQB8/DxBDgjK7y7TUQ@public.gmane.org>
>> Cc: rtc-linux-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
>> Cc: Shawn Guo <shawn.guo-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
>> ---
>>  .../devicetree/bindings/rtc/stmp3xxx-rtc.txt        |   19 +++++++++++++++++++
>>  arch/arm/boot/dts/imx28.dtsi                        |    1 +
>>  drivers/rtc/rtc-stmp3xxx.c                          |    7 +++++++
>>  3 files changed, 27 insertions(+)
>>  create mode 100644 Documentation/devicetree/bindings/rtc/stmp3xxx-rtc.txt
>>
>> V2: Fix typos, remove fsl,imx28-rtc
>>
>> diff --git a/Documentation/devicetree/bindings/rtc/stmp3xxx-rtc.txt b/Documentation/devicetree/bindings/rtc/stmp3xxx-rtc.txt
>> new file mode 100644
>> index 0000000..a7a7de5
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/rtc/stmp3xxx-rtc.txt
>> @@ -0,0 +1,19 @@
>> +* STMP3xxx/i.MX28 Time Clock controller
>> +
>> +Required properties:
>> +- compatible: should be one of the following.
>> +    * "fsl,stmp3xxx-rtc"
>> +- reg: physical base address of the controller and length of memory mapped
>> +  region.
>> +- interrupts: Two interrupt numbers to the cpu should be specified. First
>> +  interrupt number is the rtc tick interrupt and second interrupt number
>> +  is the rtc alarm interrupt. The number of cells representing a interrupt
>> +  depends on the parent interrupt controller.

The driver expects the first interrupt to the the alarm interrupt, the
event interrupt is not use, yet.

>> +
>> +Example:
>> +
>> +	rtc@80056000 {
>> +		compatible = "fsl,stmp3xxx-rtc";
>> +		reg = <0x80056000 2000>;
>> +		interrupts = <28 29>;
>> +	};
>> diff --git a/arch/arm/boot/dts/imx28.dtsi b/arch/arm/boot/dts/imx28.dtsi
>> index cabcce8..5053019 100644
>> --- a/arch/arm/boot/dts/imx28.dtsi
>> +++ b/arch/arm/boot/dts/imx28.dtsi
>> @@ -387,6 +387,7 @@
>>  			};
>>  
>>  			rtc@80056000 {
>> +				compatible = "fsl,imx28-rtc", "fsl,stmp3xxx-rtc";
>>  				reg = <0x80056000 2000>;
>>  				interrupts = <28 29>;

should be:
                                             <29 28>


>>  				status = "disabled";
>> diff --git a/drivers/rtc/rtc-stmp3xxx.c b/drivers/rtc/rtc-stmp3xxx.c
>> index 1028786..3aadb58 100644
>> --- a/drivers/rtc/rtc-stmp3xxx.c
>> +++ b/drivers/rtc/rtc-stmp3xxx.c
>> @@ -25,6 +25,7 @@
>>  #include <linux/interrupt.h>
>>  #include <linux/rtc.h>
>>  #include <linux/slab.h>
>> +#include <linux/of_device.h>
>>  
>>  #include <mach/common.h>
>>  
>> @@ -265,6 +266,11 @@ static int stmp3xxx_rtc_resume(struct platform_device *dev)
>>  #define stmp3xxx_rtc_resume	NULL
>>  #endif
>>  
>> +static const struct of_device_id rtc_dt_ids[] = {
>> +	{ .compatible = "fsl,stmp3xxx-rtc", },
>> +	{ /* sentinel */ }
>> +};
>> +
>>  static struct platform_driver stmp3xxx_rtcdrv = {
>>  	.probe		= stmp3xxx_rtc_probe,
>>  	.remove		= stmp3xxx_rtc_remove,
>> @@ -273,6 +279,7 @@ static struct platform_driver stmp3xxx_rtcdrv = {
>>  	.driver		= {
>>  		.name	= "stmp3xxx-rtc",
>>  		.owner	= THIS_MODULE,
>> +		.of_match_table = rtc_dt_ids,
>>  	},
>>  };
>>  
>> -- 
>> 1.7.10
>>
> 
> 
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

Marc
-- 
Pengutronix e.K.                  | Marc Kleine-Budde           |
Industrial Linux Solutions        | Phone: +49-231-2826-924     |
Vertretung West/Dortmund          | Fax:   +49-5121-206917-5555 |
Amtsgericht Hildesheim, HRA 2686  | http://www.pengutronix.de   |


[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 262 bytes --]

[-- Attachment #2: Type: text/plain, Size: 192 bytes --]

_______________________________________________
devicetree-discuss mailing list
devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org
https://lists.ozlabs.org/listinfo/devicetree-discuss

  parent reply	other threads:[~2012-06-29 11:08 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-08 18:56 [PATCH V2] MXS: Add DT binding support into stmp3xxx-rtc Marek Vasut
     [not found] ` <1339181804-22822-1-git-send-email-marex-ynQEQJNshbs@public.gmane.org>
2012-06-08 18:58   ` Rob Herring
2012-06-11  3:53   ` Shawn Guo
2012-06-25  4:37   ` Shawn Guo
     [not found]     ` <20120625043711.GA18156-rvtDTF3kK1ictlrPMvKcciBecyulp+rMXqFh9Ls21Oc@public.gmane.org>
2012-06-29 11:08       ` Marc Kleine-Budde [this message]
     [not found]         ` <4FED8CA1.5000800-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
2012-06-29 11:30           ` Shawn Guo
     [not found]             ` <20120629113047.GD29197-rvtDTF3kK1ictlrPMvKcciBecyulp+rMXqFh9Ls21Oc@public.gmane.org>
2012-06-29 11:32               ` Marc Kleine-Budde

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=4FED8CA1.5000800@pengutronix.de \
    --to=mkl-bicnvbalz9megne8c9+irq@public.gmane.org \
    --cc=a.zummo-BfzFCNDTiLLj+vYz1yj4TQ@public.gmane.org \
    --cc=devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org \
    --cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
    --cc=marex-ynQEQJNshbs@public.gmane.org \
    --cc=rob.herring-bsGFqQB8/DxBDgjK7y7TUQ@public.gmane.org \
    --cc=rtc-linux-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org \
    --cc=shawn.guo-QSEj5FYQhm4dnm+yROfE0A@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).