RE: [PATCH v3 2/2] clocksource: Add Intel Keem Bay timer support

From: Sanil, Shruthi
Date: Fri Jun 04 2021 - 05:21:08 EST


Hi Daniel,

> -----Original Message-----
> From: Daniel Lezcano <daniel.lezcano@xxxxxxxxxx>
> Sent: Friday, June 4, 2021 1:37 PM
> To: Sanil, Shruthi <shruthi.sanil@xxxxxxxxx>; tglx@xxxxxxxxxxxxx;
> robh+dt@xxxxxxxxxx; linux-kernel@xxxxxxxxxxxxxxx;
> devicetree@xxxxxxxxxxxxxxx
> Cc: andriy.shevchenko@xxxxxxxxxxxxxxx; kris.pan@xxxxxxxxxxxxxxx;
> mgross@xxxxxxxxxxxxxxx; Thokala, Srikanth <srikanth.thokala@xxxxxxxxx>;
> Raja Subramanian, Lakshmi Bai <lakshmi.bai.raja.subramanian@xxxxxxxxx>;
> Sangannavar, Mallikarjunappa <mallikarjunappa.sangannavar@xxxxxxxxx>
> Subject: Re: [PATCH v3 2/2] clocksource: Add Intel Keem Bay timer support
>
> On 27/05/2021 08:39, shruthi.sanil@xxxxxxxxx wrote:
> > From: Shruthi Sanil <shruthi.sanil@xxxxxxxxx>
> >
> > The Intel Keem Bay timer driver supports clocksource and clockevent
> > features for the timer IP used in Intel Keem Bay SoC.
> > The timer block supports 1 free running counter and 8 timers.
> > The free running counter can be used as a clocksource and the timers
> > can be used as clockevent. Each timer is capable of generating
> > individual interrupt.
> > Both the features are enabled through the timer general config register.
> >
> > Reviewed-by: Andy Shevchenko <andriy.shevchenko@xxxxxxxxx>
> > Signed-off-by: Shruthi Sanil <shruthi.sanil@xxxxxxxxx>
> > ---
> > MAINTAINERS | 5 +
> > drivers/clocksource/Kconfig | 11 ++
> > drivers/clocksource/Makefile | 1 +
> > drivers/clocksource/timer-keembay.c | 255
> > ++++++++++++++++++++++++++++
> > 4 files changed, 272 insertions(+)
> > create mode 100644 drivers/clocksource/timer-keembay.c
> >
> > diff --git a/MAINTAINERS b/MAINTAINERS index
> > 04babfa8fc76..73543ed60e84 100644
> > --- a/MAINTAINERS
> > +++ b/MAINTAINERS
> > @@ -9278,6 +9278,11 @@ F: drivers/crypto/keembay/keembay-ocs-hcu-
> core.c
> > F: drivers/crypto/keembay/ocs-hcu.c
> > F: drivers/crypto/keembay/ocs-hcu.h
> >
> > +INTEL KEEM BAY TIMER SUPPORT
> > +M: Shruthi Sanil <shruthi.sanil@xxxxxxxxx>
> > +S: Maintained
> > +F: drivers/clocksource/timer-keembay.c
> > +
> > INTEL MANAGEMENT ENGINE (mei)
> > M: Tomas Winkler <tomas.winkler@xxxxxxxxx>
> > L: linux-kernel@xxxxxxxxxxxxxxx
> > diff --git a/drivers/clocksource/Kconfig b/drivers/clocksource/Kconfig
> > index 39aa21d01e05..08f491cf7f61 100644
> > --- a/drivers/clocksource/Kconfig
> > +++ b/drivers/clocksource/Kconfig
> > @@ -693,4 +693,15 @@ config MICROCHIP_PIT64B
> > modes and high resolution. It is used as a clocksource
> > and a clockevent.
> >
> > +config KEEMBAY_TIMER
> > + bool "Intel Keem Bay timer"
> > + depends on ARCH_KEEMBAY
> > + select TIMER_OF
>
> Please refer to the other timer option to see how we create silent option. We
> want the Kconfig's platform to select the timer, not the user except for
> compilation coverage or expert mode.

OK, I'll check and update accordingly.

Thanks,
Shruthi

>
> > + help
> > + This option enables the support for the Intel Keem Bay
> > + general purpose timer and free running counter driver.
> > + Each timer can generate an individual interrupt and
> > + supports oneshot and periodic modes.
> > + The 64-bit counter can be used as a clock source.
> > +
> > endmenu
>
> Other than that, LGTM.
>
> Thanks
> -- Daniel
>
>
> --
> <http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs
>
> Follow Linaro: <http://www.facebook.com/pages/Linaro> Facebook |
> <http://twitter.com/#!/linaroorg> Twitter | <http://www.linaro.org/linaro-
> blog/> Blog