Re: [PATCH v2 0/3] riscv: rtc: sophgo: add rtc support for CV1800

From: Jingbao Qiu
Date: Mon Dec 18 2023 - 02:12:50 EST


On Mon, Dec 18, 2023 at 1:53 PM Jisheng Zhang <jszhang@xxxxxxxxxx> wrote:
>
> On Sun, Dec 17, 2023 at 07:09:49PM +0800, Jingbao Qiu wrote:
> > This series adds rtc support for Sophgo CV1800.
> >
> > Changes since v1
> > - fix duplicate names in subject
> > - using RTC replace RTC controller
> > - improve the properties of dt-bindings
> > - using `unevaluatedProperties` replace `additionalProperties`
> > - dt-bindings passed the test
> > - using `devm_platform_ioremap_resource()` replace
> > `platform_get_resource()` and `devm_ioremap_resource()`
> > - fix random order of the code
> > - fix wrong wrapping of the `devm_request_irq()` and map the flag with dts
> > - using devm_clk_get_enabled replace `devm_clk_get()` and
> > `clk_prepare_enable()`
> > - fix return style
> > - add rtc clock calibration function
> > - use spinlock when write register on read/set time
> >
> > Jingbao Qiu (3):
> > dt-bindings: rtc: sophgo: add RTC support for Sophgo CV1800 series SoC
> > rtc: sophgo: add rtc support for Sophgo CV1800 SoC
> > riscv: dts: sophgo: add rtc dt node for CV1800
>
> AFAICT, the rtc subsystem supports not only RTC function but also
> power/reboot controller, so modeling the rtc subsystem as RTC only doesn't
> match the HW. I expect a mfd here.
>

Thanks,I will improve it in the next version.

Best regards,
Jingbao Qiu


> >
> > .../bindings/rtc/sophgo,cv1800-rtc.yaml | 47 ++
> > arch/riscv/boot/dts/sophgo/cv1800b.dtsi | 7 +
> > drivers/rtc/Kconfig | 6 +
> > drivers/rtc/Makefile | 1 +
> > drivers/rtc/rtc-cv1800.c | 400 ++++++++++++++++++
> > 5 files changed, 461 insertions(+)
> > create mode 100644 Documentation/devicetree/bindings/rtc/sophgo,cv1800-rtc.yaml
> > create mode 100644 drivers/rtc/rtc-cv1800.c
> >
> > --
> > 2.25.1
> >