From: ben@decadent.org.uk (Ben Hutchings)
To: linux-arm-kernel@lists.infradead.org
Subject: Bug#782364: linux-image-3.16.0-4-armmp: please configure drivers for both Cubox i4pro real time clocks
Date: Sat, 11 Apr 2015 01:08:50 +0100 [thread overview]
Message-ID: <1428710930.29665.17.camel@decadent.org.uk> (raw)
In-Reply-To: <20150410232854.23367.58862.reportbug@cube.rcthomas.org>
Control: severity -1 important
On Fri, 2015-04-10 at 16:28 -0700, Rick Thomas wrote:
> Package: src:linux
> Version: 3.16.7-ckt7-1
> Severity: wishlist
> Tags: newcomer
>
> Whenever I reset my cubox-i4Pro by disconnecting the power plug, the hardware real-time-clock gets
> reset to midnight UTC, Dec 31, 1970.
> Even though the SolidRun literature says that the i4Pro has a battery backed RTC.
>
> A bit of googling reveals that this is related to the following fact (Quoted from the SolidRun forums)
>
> >There are two RTC inside CuBox-i
> >1. One connected to the SNVS rail (internal i.MX6) which is not battery backed and typically goes to /dev/rtc0
If this RTC is not battery backed, it seems like it ought to be disabled
in this board's device tree.
> >2. Second is NXP PFC8523 based and that one has battery backup (/dev/rtc1)
> >SolidRun Engineering
> >user rabeeh in #cubox on Freenode IRC
> >by rabeeh Sat Jan 25, 2014 7:04 pm
>
> >It's a standard non rechargeable lithium 3.3v coin cell.
> >Available only on the models that has RTC.
> >SolidRun Engineering
> >user rabeeh in #cubox on Freenode IRC
>
> Curiously, when I look at the Debian Jessie system running on the box, I find that there is only one /dev/rtc* device,
> and that seems to be associated with the SNVS clock. The PFC8523 clock is not available
>
> Checking /boot/config-3.16.0-4-armmp, I see what I think is an explanation, because
>
> # CONFIG_RTC_DRV_PCF8523 is not set
>
> and
>
> CONFIG_RTC_DRV_SNVS=y
>
> Other Linux systems (e.g. Arch) appear (according to the above mentioned googling) to have their kernel compiled so as to
> provide both /dev/rtc0 attached to the SNVS clock, and /dev/rtc1 attached to the PFC8523 clock.
>
> Would it be possible to configure the default Debian Jessie kernel to do the same?
Yes, we can do that.
> Ideally, the PFC8523 clock should show up as /dev/rtc0, linked to /dev/rtc,
> so that the battery backed clock is used by default to set the system clock at boot-time.
> Failing that, it may be possible to address this by setting HCTOSYS_DEVICE in /etc/default/hwclock appropriately.
> Or maybe one could tweak a rule in /etc/udev ?
I wonder about that. I think it would make more sense to disable the
useless RTC so there's no need to treat this board specially in
userland.
> Karsten Merker commented via email:
>
> Yes, that should just need enabling the appropriate module.
> The device-tree instantiates the pcf8523 clock chip:
>
> &i2c3 {
> pinctrl-names = "default";
> pinctrl-0 = <&pinctrl_cubox_i_i2c3>;
>
> status = "okay";
>
> rtc: pcf8523 at 68 {
> compatible = "nxp,pcf8523";
> reg = <0x68>;
> };
> };
>
> So if the module is available, it should be loaded automatically.
>
> Please file a wishlist bug against "Source: linux, Version:
> 3.16.7-ckt9-1" so that the kernel maintainers can enable the
> module for the next kernel upload.
Actually we consider missing hardware support as severity 'important'.
Ben.
--
Ben Hutchings
compatible: Gracefully accepts erroneous data from any source
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 811 bytes
Desc: This is a digitally signed message part
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20150411/6fa7f376/attachment-0001.sig>
next parent reply other threads:[~2015-04-11 0:08 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20150410232854.23367.58862.reportbug@cube.rcthomas.org>
2015-04-11 0:08 ` Ben Hutchings [this message]
2015-04-29 3:02 ` Bug#782364: linux-image-3.16.0-4-armmp: please configure drivers for both Cubox i4pro real time clocks Fabio Estevam
2015-04-29 5:46 ` Rick Thomas
2015-04-29 5:48 ` Rick Thomas
2015-04-29 8:57 ` Russell King - ARM Linux
2015-05-02 16:01 ` Ian Campbell
2015-05-02 16:12 ` Russell King - ARM Linux
2015-05-02 16:21 ` Ian Campbell
2015-05-06 8:01 ` Ian Campbell
2015-05-06 10:00 ` Rick Thomas
2015-05-06 10:27 ` Ian Campbell
2015-05-06 10:35 ` Rick Thomas
2015-05-12 8:33 ` Rick Thomas
2015-05-12 9:11 ` Ian Campbell
2015-05-13 4:54 ` Rick Thomas
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=1428710930.29665.17.camel@decadent.org.uk \
--to=ben@decadent.org.uk \
--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 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).