From: Mark Brown <broonie@kernel.org>
To: Jonas Jensen <jonas.jensen@gmail.com>
Cc: rtc-linux@googlegroups.com, a.zummo@towertech.it,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org, arm@kernel.org
Subject: Re: [PATCH v2] rtc: Add MOXA ART RTC driver
Date: Thu, 11 Jul 2013 17:51:16 +0100 [thread overview]
Message-ID: <20130711165116.GT24508@sirena.org.uk> (raw)
In-Reply-To: <1373550711-18828-1-git-send-email-jonas.jensen@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1021 bytes --]
On Thu, Jul 11, 2013 at 03:51:51PM +0200, Jonas Jensen wrote:
> Add RTC driver for MOXA ART SoCs.
Looks good now. A couple more minor nits.
> +void moxart_rtc_write_byte(u8 data)
> +{
> +u8 moxart_rtc_read_byte(void)
> +{
These should be static.
> + gpio_direction_output(GPIO_RTC_DATA, 0);
> + gpio_set_value(GPIO_RTC_RESET, 1);
I guess I'd expect the GPIOs to be configured by platform data in case
of board changes (it's a bit odd that a SoC RTC is being done with
bitbanging, I guess it's on an external chip?).
> + devm_gpio_request(&pdev->dev, GPIO_RTC_DATA, "rtc_data");
> + devm_gpio_request(&pdev->dev, GPIO_RTC_SCLK, "rtc_sclk");
> + devm_gpio_request(&pdev->dev, GPIO_RTC_RESET, "rtc_reset");
Should check the errors from these.
> + gpio_direction_output(GPIO_RTC_RESET, 0);
> + gpio_direction_output(GPIO_RTC_SCLK, 0);
devm_gpio_request_one()? Though it doesn't make much difference and you
do have a nice block of devm_gpio_request() above not all of which have
a direction assigned immediately.
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
next prev parent reply other threads:[~2013-07-11 16:52 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-10 14:00 [PATCH] " Jonas Jensen
2013-07-10 15:47 ` Mark Brown
2013-07-11 13:51 ` [PATCH v2] " Jonas Jensen
2013-07-11 16:51 ` Mark Brown [this message]
2013-07-14 19:58 ` Arnd Bergmann
2013-07-16 12:41 ` [PATCH v3] " Jonas Jensen
2013-07-16 13:13 ` Mark Brown
2013-07-16 14:04 ` Jonas Jensen
2013-07-16 15:57 ` Mark Brown
2013-07-17 9:14 ` [PATCH v4] " Jonas Jensen
2013-07-17 10:09 ` Mark Brown
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=20130711165116.GT24508@sirena.org.uk \
--to=broonie@kernel.org \
--cc=a.zummo@towertech.it \
--cc=arm@kernel.org \
--cc=jonas.jensen@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rtc-linux@googlegroups.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®