linux-rtc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jingbao Qiu <qiujingbao.dlmu@gmail.com>
To: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Cc: alexandre.belloni@bootlin.com, robh+dt@kernel.org,
	 krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org,
	chao.wei@sophgo.com,  unicorn_wang@outlook.com,
	paul.walmsley@sifive.com, palmer@dabbelt.com,
	 aou@eecs.berkeley.edu, linux-rtc@vger.kernel.org,
	devicetree@vger.kernel.org,  linux-kernel@vger.kernel.org,
	linux-riscv@lists.infradead.org,  dlan@gentoo.org
Subject: Re: [PATCH v7 2/3] rtc: sophgo: add rtc support for Sophgo CV1800 SoC
Date: Mon, 22 Jan 2024 16:38:51 +0800	[thread overview]
Message-ID: <CAJRtX8SWyUJmiR-z108XcVY77kCXhz7E4=sLE0+gmzsXjipW9w@mail.gmail.com> (raw)
In-Reply-To: <90ae0cad-34a8-4e19-a72f-5e497b72b45c@linaro.org>

On Mon, Jan 22, 2024 at 4:29 PM Krzysztof Kozlowski
<krzysztof.kozlowski@linaro.org> wrote:
>
> On 22/01/2024 09:06, Jingbao Qiu wrote:
> > Implement the RTC driver for CV1800, which able to provide time alarm
> > and calibrate functionality.
> >
> > Signed-off-by: Jingbao Qiu <qiujingbao.dlmu@gmail.com>
> > ---
> >
> > Depends on https://lore.kernel.org/all/IA1PR20MB4953C774D41EDF1EADB6EC18BB6D2@IA1PR20MB4953.namprd20.prod.outlook.com/
> >
>
> Why?
>
> How could a RTC driver depend on clock driver or clock bindings? This
> looks wrong and it prevents your driver being merged via easy path.

Thanks,I will fix it.

>
> > diff --git a/drivers/rtc/rtc-cv1800.c b/drivers/rtc/rtc-cv1800.c
> > new file mode 100644
> > index 000000000000..fbf2e575ea94
> > --- /dev/null
> > +++ b/drivers/rtc/rtc-cv1800.c
> > @@ -0,0 +1,406 @@
> > +// SPDX-License-Identifier: GPL-2.0-only
> > +/*
> > + * rtc-cv1800.c: RTC driver for Sophgo cv1800 RTC
> > + *
> > + * Author: Jingbao Qiu <qiujingbao.dlmu@gmail.com>
> > + */
> > +#include <linux/kernel.h>
> > +#include <linux/clk.h>
> > +#include <linux/module.h>
> > +#include <linux/irq.h>
> > +#include <linux/delay.h>
> > +#include <linux/rtc.h>
> > +#include <linux/platform_device.h>
> > +#include <linux/mfd/syscon.h>
>
> Drop

Thanks, I will do that.

>
> > +#include <linux/regmap.h>
> > +#include <linux/of.h>
>
> Keep the includes sorted, prefferably alphabetically.

Thank you for your suggestion.I will do that.

>
> ...
>
> > +
> > +static int cv1800_rtc_probe(struct platform_device *pdev)
> > +{
> > +     struct cv1800_rtc_priv *rtc;
> > +     uint32_t ctrl_val;
> > +     void __iomem *base;
> > +     int ret;
> > +
> > +     rtc = devm_kzalloc(&pdev->dev, sizeof(struct cv1800_rtc_priv),
>
> sizeof(*)

I will do that.

>
> > +                        GFP_KERNEL);
> > +     if (!rtc)
> > +             return -ENOMEM;
> > +
> > +     base = devm_platform_ioremap_resource(pdev, 0);
> > +     if (IS_ERR(base))
> > +             return PTR_ERR(base);
> > +
> > +     rtc->rtc_map =
>
> Unneeded blank line. Don't wrap at =.

Thanks, I will do that.

Best regards,
Jingbao QIu

      reply	other threads:[~2024-01-22  8:39 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-22  8:06 [PATCH v7 2/3] rtc: sophgo: add rtc support for Sophgo CV1800 SoC Jingbao Qiu
2024-01-22  8:06 ` [PATCH v7 3/3] riscv: dts: sophgo: add rtc dt node for CV1800 Jingbao Qiu
2024-01-22 13:25   ` Emil Renner Berthing
2024-01-23  1:24     ` Jingbao Qiu
2024-01-22  8:17 ` [PATCH v7 2/3] rtc: sophgo: add rtc support for Sophgo CV1800 SoC Alexandre Belloni
2024-01-22  8:34   ` Jingbao Qiu
2024-01-22  8:37     ` Krzysztof Kozlowski
2024-01-22  8:42       ` Jingbao Qiu
2024-01-22  9:15     ` Alexandre Belloni
2024-01-22  9:23       ` Jingbao Qiu
2024-01-22  8:29 ` Krzysztof Kozlowski
2024-01-22  8:38   ` Jingbao Qiu [this message]

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='CAJRtX8SWyUJmiR-z108XcVY77kCXhz7E4=sLE0+gmzsXjipW9w@mail.gmail.com' \
    --to=qiujingbao.dlmu@gmail.com \
    --cc=alexandre.belloni@bootlin.com \
    --cc=aou@eecs.berkeley.edu \
    --cc=chao.wei@sophgo.com \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dlan@gentoo.org \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=krzysztof.kozlowski@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=linux-rtc@vger.kernel.org \
    --cc=palmer@dabbelt.com \
    --cc=paul.walmsley@sifive.com \
    --cc=robh+dt@kernel.org \
    --cc=unicorn_wang@outlook.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;
as well as URLs for NNTP newsgroup(s).