All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sebastian Reichel <sre@kernel.org>
To: Sebastian Reichel <sre@kernel.org>,
	Tony Lindgren <tony@atomide.com>,
	Alessandro Zummo <a.zummo@towertech.it>,
	Alexandre Belloni <alexandre.belloni@free-electrons.com>
Cc: rtc-linux@googlegroups.com, linux-kernel@vger.kernel.org
Subject: [rtc-linux] [PATCH 0/1] Motorola CPCAP PMIC RTC
Date: Mon, 20 Feb 2017 08:35:34 +0100	[thread overview]
Message-ID: <20170220073535.27393-1-sre@kernel.org> (raw)

Hi,

Here is a driver for the RTC found inside of the
Motorola Droid 4 based on linux-next 2017021.
I tried to set & get the time using hwclock and
used ./tools/testing/selftests/timers/rtctest.c:

$ ./rtctest 

			RTC Driver Test Example.

Counting 5 update (1/sec) interrupts from reading /dev/rtc0: 1 2 3 4 5
Again, from using select(2) on /dev/rtc: 1 2 3 4 5

Current RTC date/time is 20-2-2017, 07:11:22.
Alarm time now set to 07:11:27.
Waiting 5 seconds for alarm... okay. Alarm rang.

Periodic IRQ rate is 1Hz.
Counting 20 interrupts at:
2Hz:	 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
4Hz:	 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
8Hz:	 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
16Hz:	 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
32Hz:	 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
64Hz:	 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20

			 *** Test complete ***

I did not include a patch for omap4-droid4-xt894.dts,
since the CPCAP DT entry has not yet been added. The
following DT snippet can be used for testing on droid4:

&cpcap {
	cpcap_rtc: rtc {
		compatible = "motorola,cpcap-rtc";

		interrupt-parent = <&cpcap>;
		interrupts = <39 IRQ_TYPE_NONE>, <26 IRQ_TYPE_NONE>;
	};
};

-- Sebastian

Sebastian Reichel (1):
  rtc: cpcap: new rtc driver

 .../devicetree/bindings/rtc/cpcap-rtc.txt          |  13 +
 drivers/rtc/Kconfig                                |   7 +
 drivers/rtc/Makefile                               |   1 +
 drivers/rtc/rtc-cpcap.c                            | 318 +++++++++++++++++++++
 4 files changed, 339 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/rtc/cpcap-rtc.txt
 create mode 100644 drivers/rtc/rtc-cpcap.c

-- 
2.11.0

-- 
You received this message because you are subscribed to "rtc-linux".
Membership options at http://groups.google.com/group/rtc-linux .
Please read http://groups.google.com/group/rtc-linux/web/checklist
before submitting a driver.
--- 
You received this message because you are subscribed to the Google Groups "rtc-linux" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rtc-linux+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

             reply	other threads:[~2017-02-20  7:35 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-20  7:35 Sebastian Reichel [this message]
2017-02-20  7:35 ` [rtc-linux] [PATCH 1/1] rtc: cpcap: new rtc driver Sebastian Reichel
2017-02-20 16:31   ` [rtc-linux] " Tony Lindgren
2017-02-20 16:38     ` Alexandre Belloni
2017-02-20 17:21       ` Tony Lindgren
2017-02-20 17:27         ` Tony Lindgren
2017-02-20 19:35           ` Sebastian Reichel
2017-02-21  6:16 ` [rtc-linux] [PATCHv2] " Sebastian Reichel
2017-02-21 23:52   ` [rtc-linux] " Alexandre Belloni
2017-02-22  1:56     ` Sebastian Reichel
2017-02-22  8:18       ` Alexandre Belloni
2017-02-23  1:03 ` [rtc-linux] [PATCHv3 1/2] dt-bindings: Add vendor prefix for Motorola Sebastian Reichel
2017-02-23  1:03   ` Sebastian Reichel
2017-02-23  1:03   ` [rtc-linux] [PATCHv3 2/2] rtc: cpcap: new rtc driver Sebastian Reichel
2017-02-23  1:03     ` Sebastian Reichel
2017-02-27 23:49     ` [rtc-linux] " Rob Herring
2017-02-27 23:49       ` Rob Herring
2017-02-27 23:48   ` [rtc-linux] Re: [PATCHv3 1/2] dt-bindings: Add vendor prefix for Motorola Rob Herring
2017-02-27 23:48     ` Rob Herring
2017-03-02  0:27 ` [rtc-linux] [PATCHv4 " Sebastian Reichel
2017-03-02  0:27   ` Sebastian Reichel
2017-03-02  0:27   ` [rtc-linux] [PATCHv4 2/2] rtc: cpcap: new rtc driver Sebastian Reichel
2017-03-02  0:27     ` Sebastian Reichel
2017-03-02 14:11     ` [rtc-linux] " Rob Herring
2017-03-02 14:11       ` Rob Herring
2017-03-09  0:34     ` [rtc-linux] " Alexandre Belloni
2017-03-09  0:34       ` Alexandre Belloni
2017-03-09  0:33   ` [rtc-linux] Re: [PATCHv4 1/2] dt-bindings: Add vendor prefix for Motorola Alexandre Belloni
2017-03-09  0:33     ` Alexandre Belloni

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=20170220073535.27393-1-sre@kernel.org \
    --to=sre@kernel.org \
    --cc=a.zummo@towertech.it \
    --cc=alexandre.belloni@free-electrons.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rtc-linux@googlegroups.com \
    --cc=tony@atomide.com \
    /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.