From: Shubhrajyoti Datta <shubhrajyoti.datta@gmail.com>
To: Zhengxun Li <zhengxunli.mxic@gmail.com>
Cc: devel@driverdev.osuosl.org,
"open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS"
<devicetree@vger.kernel.org>,
slwu@mxic.com.tw, Stephen Boyd <sboyd@kernel.org>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Mike Turquette <mturquette@baylibre.com>,
Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>,
Julien Su <juliensu@mxic.com.tw>,
Rob Herring <robh+dt@kernel.org>,
git@xilinx.com, Miquel Raynal <miquel.raynal@bootlin.com>,
linux-clk@vger.kernel.org, zhengxunli@mxic.com.tw
Subject: Re: [PATCH v10 5/9] staging: clocking-wizard: Add support for dynamic reconfiguration
Date: Thu, 18 Mar 2021 11:11:57 +0530 [thread overview]
Message-ID: <CAKfKVtF+9XyOXq2aLoEyMFr9ZsvHOsqPaAPu79ziUtF-VeMnWw@mail.gmail.com> (raw)
In-Reply-To: <CACY_kjSRbgSWsfo+JTyQdqorQ+wcy8OqAtKSbJt6tL4t-AUciw@mail.gmail.com>
On Mon, Mar 15, 2021 at 12:37 PM Zhengxun Li <zhengxunli.mxic@gmail.com> wrote:
>
> Hi Shubhrajyoti,
>
> My name is Zhengxun and I am the engineer from Macronix. We are
> using the platform PicoZed 7015/7030 SOM (System On Module),
> which is based on Xilinx Zynq®-7000 All Programmable (AP) SoC to
> verify our Flash driver. Of course, we are also using your clock
> wizard, our version seems to be v5.2, but something went wrong.
>
> +static int clk_wzrd_dynamic_reconfig(struct clk_hw *hw, unsigned long rate,
> + unsigned long parent_rate)
> +{
> + int err;
> + u32 value;
> + unsigned long flags = 0;
> + struct clk_wzrd_divider *divider = to_clk_wzrd_divider(hw);
> + void __iomem *div_addr = divider->base + divider->offset;
> +
> + if (divider->lock)
> + spin_lock_irqsave(divider->lock, flags);
> + else
> + __acquire(divider->lock);
> +
> + value = DIV_ROUND_CLOSEST(parent_rate, rate);
> +
> + /* Cap the value to max */
> + min_t(u32, value, WZRD_DR_MAX_INT_DIV_VALUE);
> +
> + /* Set divisor and clear phase offset */
> + writel(value, div_addr);
> + writel(0x00, div_addr + WZRD_DR_DIV_TO_PHASE_OFFSET);
>
> Why phase always set to zero? We want to support DTR operation in
> Flash driver. Can you add a set_phase function to adjust the phase?
>
The phase setting is a separate feature will address in a separate series.
>
_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
next prev parent reply other threads:[~2021-03-18 5:42 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-15 7:07 [PATCH v10 5/9] staging: clocking-wizard: Add support for dynamic reconfiguration Zhengxun Li
2021-03-15 8:32 ` Shubhrajyoti Datta
2021-03-18 5:41 ` Shubhrajyoti Datta [this message]
-- strict thread matches above, loose matches on Subject: below --
2021-03-08 6:59 zhengxunli
2021-03-08 7:07 ` Greg KH
2021-02-24 13:10 [PATCH v10 0/9] clk: clocking-wizard: driver updates Shubhrajyoti Datta
2021-02-24 13:10 ` [PATCH v10 5/9] staging: clocking-wizard: Add support for dynamic reconfiguration Shubhrajyoti Datta
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=CAKfKVtF+9XyOXq2aLoEyMFr9ZsvHOsqPaAPu79ziUtF-VeMnWw@mail.gmail.com \
--to=shubhrajyoti.datta@gmail.com \
--cc=devel@driverdev.osuosl.org \
--cc=devicetree@vger.kernel.org \
--cc=git@xilinx.com \
--cc=gregkh@linuxfoundation.org \
--cc=juliensu@mxic.com.tw \
--cc=linux-clk@vger.kernel.org \
--cc=miquel.raynal@bootlin.com \
--cc=mturquette@baylibre.com \
--cc=robh+dt@kernel.org \
--cc=sboyd@kernel.org \
--cc=shubhrajyoti.datta@xilinx.com \
--cc=slwu@mxic.com.tw \
--cc=zhengxunli.mxic@gmail.com \
--cc=zhengxunli@mxic.com.tw \
/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).