From: balbi@TI.COM (Felipe Balbi)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 09/11] clocksource: add TI 32.768 Hz counter driver
Date: Tue, 6 Oct 2015 22:07:46 -0500 [thread overview]
Message-ID: <87bncb1im5.fsf@saruman.tx.rr.com> (raw)
In-Reply-To: <56145836.4070304@linaro.org>
Hi,
Daniel Lezcano <daniel.lezcano@linaro.org> writes:
> On 10/06/2015 07:02 PM, Felipe Balbi wrote:
>> Introduce a new clocksource driver for Texas
>> Instruments 32.768 Hz device which is available
>> on most OMAP-like devices.
>>
>> Signed-off-by: Felipe Balbi <balbi@ti.com>
>
> Hi Felipe,
>
> With the couple of nits below fixed, you can my:
>
> Acked-by: Daniel Lezcano <daniel.lezcano@linaro.org>
>
> [ ... ]
>
>> +#define OMAP2_32KSYNCNT_REV_OFF 0x0
>> +#define OMAP2_32KSYNCNT_REV_SCHEME (0x3 << 30)
>> +#define OMAP2_32KSYNCNT_CR_OFF_LOW 0x10
>> +#define OMAP2_32KSYNCNT_CR_OFF_HIGH 0x30
>> +
>> +struct ti_32k {
>> + void __iomem *base;
>> + void __iomem *counter;
>> + struct clocksource cs;
>> +};
>> +#define to_ti_32k(cs) (container_of((cs), struct ti_32k, cs))
>
> Usually a static inline is used instead of a macro for that.
not so true and also completely unnecessary, considering container_of()
already type safety ;-)
Try this:
$ git grep -e "#define.*container_of" | wc -l
no strong feelings though. I tend to prefer a macro to wrap
container_of() but won't go into an argument
--
balbi
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 818 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20151006/9b073e73/attachment.sig>
next prev parent reply other threads:[~2015-10-07 3:07 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-06 17:01 [PATCH 00/11] arm: omap: counter32k rework Felipe Balbi
2015-10-06 17:01 ` [PATCH 01/11] arm: omap2: timer: get rid of obfuscating macros Felipe Balbi
2015-10-06 17:01 ` [PATCH 02/11] arm: omap2: timer: add a gptimer argument to sync32k_timer_init() Felipe Balbi
2015-10-06 17:01 ` [PATCH 03/11] arm: omap2: timer: remove __omap_gptimer_init() Felipe Balbi
2015-10-06 17:02 ` [PATCH 04/11] arm: omap2: timer: provide generic sync32k_timer_init function Felipe Balbi
2015-10-06 18:33 ` Suman Anna
2015-10-06 19:15 ` Felipe Balbi
2015-10-06 17:02 ` [PATCH 05/11] arm: omap2: timer: move realtime_counter_init() around Felipe Balbi
2015-10-06 17:02 ` [PATCH 06/11] arm: omap2: timer: always call clocksource_of_init() when DT Felipe Balbi
2015-10-06 17:02 ` [PATCH 07/11] arm: omap2: timer: remove omap4_local_timer_init Felipe Balbi
2015-10-06 17:02 ` [PATCH 08/11] arm: omap2: timer: rename omap_sync32k_timer_init() Felipe Balbi
2015-10-06 17:02 ` [PATCH 09/11] clocksource: add TI 32.768 Hz counter driver Felipe Balbi
2015-10-06 23:24 ` Daniel Lezcano
2015-10-07 3:07 ` Felipe Balbi [this message]
2015-10-06 17:02 ` [PATCH 10/11] arm: omap2+: select 32k clocksource driver Felipe Balbi
2015-10-06 17:02 ` [PATCH 11/11] arm: omap2: timer: limit hwmod usage to non-DT boots Felipe Balbi
-- strict thread matches above, loose matches on Subject: below --
2015-10-16 16:21 [PATCH 00/11] arm: omap: timer cleanups Felipe Balbi
2015-10-16 16:22 ` [PATCH 09/11] clocksource: add TI 32.768 Hz counter driver Felipe Balbi
2015-10-16 20:49 ` kbuild test robot
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=87bncb1im5.fsf@saruman.tx.rr.com \
--to=balbi@ti.com \
--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).