From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753128AbbJFXYm (ORCPT ); Tue, 6 Oct 2015 19:24:42 -0400 Received: from mail-wi0-f180.google.com ([209.85.212.180]:33620 "EHLO mail-wi0-f180.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752397AbbJFXYl (ORCPT ); Tue, 6 Oct 2015 19:24:41 -0400 Subject: Re: [PATCH 09/11] clocksource: add TI 32.768 Hz counter driver To: Felipe Balbi , Tony Lindgren References: <1444150927-14771-1-git-send-email-balbi@ti.com> <1444150927-14771-10-git-send-email-balbi@ti.com> Cc: Linux OMAP Mailing List , Linux ARM Kernel Mailing List , tglx@linutronix.de, Linux Kernel Mailing List From: Daniel Lezcano Message-ID: <56145836.4070304@linaro.org> Date: Wed, 7 Oct 2015 01:24:38 +0200 User-Agent: Mozilla/5.0 (X11; Linux i686; rv:38.0) Gecko/20100101 Thunderbird/38.2.0 MIME-Version: 1.0 In-Reply-To: <1444150927-14771-10-git-send-email-balbi@ti.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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 Hi Felipe, With the couple of nits below fixed, you can my: Acked-by: Daniel Lezcano [ ... ] > +#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. > +static cycle_t ti_32k_read_cycles(struct clocksource *cs) > +{ > + struct ti_32k *ti = to_ti_32k(cs); format -- Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog