mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Renjiang Han <quic_renjiang@quicinc.com>
To: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Cc: Bjorn Andersson <andersson@kernel.org>,
	Michael Turquette <mturquette@baylibre.com>,
	Stephen Boyd <sboyd@kernel.org>,
	Stanimir Varbanov <stanimir.k.varbanov@gmail.com>,
	Vikash Garodia <quic_vgarodia@quicinc.com>,
	Bryan O'Donoghue <bryan.odonoghue@linaro.org>,
	Mauro Carvalho Chehab <mchehab@kernel.org>,
	<linux-arm-msm@vger.kernel.org>, <linux-clk@vger.kernel.org>,
	<linux-kernel@vger.kernel.org>, <linux-media@vger.kernel.org>,
	Taniya Das <quic_tdas@quicinc.com>
Subject: Re: [PATCH v3 0/3] Use APIs in gdsc genpd to switch gdsc mode for venus v4 core
Date: Mon, 17 Feb 2025 18:15:30 +0800	[thread overview]
Message-ID: <dbeace93-ed19-4719-a72e-53be8999b0b3@quicinc.com> (raw)
In-Reply-To: <00449451-d97f-47fe-b0ab-cddb9d2b0e93@quicinc.com>


On 1/17/2025 12:17 PM, Renjiang Han wrote:
>
> On 1/15/2025 5:59 PM, Dmitry Baryshkov wrote:
>>> If only the clock patch or the venus driver patch is merged, the venus
>>> driver will not work properly. Although it does not affect other system
>>> functions, it is still recommended to wait until both the clock patch
>>> and the venus driver patch are reviewed and passed, and then merge them
>>> into the same release by their respective maintainers.
>> NO! This will not work, as both -media and arm-soc branches will be
>> broken. Please read about the git-bisect before making such suggestions.
>>
>> A proper plan would be:
>> - implement a function which allows one to check that hwmode is
>>    supported by the genpd driver
>> - Change Venus to use hwmode for those platforms if it is enabled
>> - Enable HWMODE support in the clock driver. Clearly identify that this
>>    patch should be merged together and after Venus changes if all
>>    maintainers agree with that
>> - Clean up now-dead code.
>>
>> Doing it in any other way would result in the broken kernels.
>  Thanks for your comment. dev_pm_genpd_set_hwmode() has a check function.
>  So I think I can do it like this to add compatibility in venus driver:
>  - 1. the dev_pm_genpd_set_hwmode() is used to switch the GDSC mode by
>  default.
>  - 2. If it fails and dev_pm_genpd_set_hwmode() returns -EOPNOTSUPP, it
>  means that the clock driver uses the HW_CTRL flag. At this time, the
>  GDSC mode is switched by writing the POWER_CONTROL register.
>
>  In addition, the merged code needs to follow this order.
>  - 1. Add compatibility in venus driver.
>  - 2. Use the HW_CTRL_TRIGGER flag in clock driver
>  - 3. Remove the dead code in venus driver.
>
  As internal discussion, in order to merge the patches in the correct order, we
  plan to submit two patch series.
  One patch series uses dev_pm_genpd_set_hwmode() to check if hwmode is supported,
  and the venus driver is compatible with the two methods of switching GDSC mode.
  Then the clock driver enables hwmode.
  The other patch series will clean up the dead code.
  Do you agree to submit two patch series or one?

-- 
Best Regards,
Renjiang


      reply	other threads:[~2025-02-17 10:16 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-15  9:30 Renjiang Han
2025-01-15  9:30 ` [PATCH v3 1/3] clk: qcom: videocc: Use HW_CTRL_TRIGGER flag for video GDSC's Renjiang Han
2025-01-15  9:30 ` [PATCH v3 2/3] venus: pm_helpers: Use dev_pm_genpd_set_hwmode to switch GDSC mode on V4 Renjiang Han
2025-01-15 12:02   ` Bryan O'Donoghue
2025-01-15 20:22     ` Bjorn Andersson
2025-01-15 20:36       ` Bjorn Andersson
2025-01-17  4:19         ` Renjiang Han
2025-01-15  9:30 ` [PATCH v3 3/3] venus: pm_helpers: Remove dead code and simplify power management Renjiang Han
2025-01-15 10:01   ` Dmitry Baryshkov
2025-01-17  4:01     ` Renjiang Han
2025-01-15  9:59 ` [PATCH v3 0/3] Use APIs in gdsc genpd to switch gdsc mode for venus v4 core Dmitry Baryshkov
2025-01-17  4:17   ` Renjiang Han
2025-02-17 10:15     ` Renjiang Han [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=dbeace93-ed19-4719-a72e-53be8999b0b3@quicinc.com \
    --to=quic_renjiang@quicinc.com \
    --cc=andersson@kernel.org \
    --cc=bryan.odonoghue@linaro.org \
    --cc=dmitry.baryshkov@linaro.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@kernel.org \
    --cc=mturquette@baylibre.com \
    --cc=quic_tdas@quicinc.com \
    --cc=quic_vgarodia@quicinc.com \
    --cc=sboyd@kernel.org \
    --cc=stanimir.k.varbanov@gmail.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

all inboxes | Powered by JetHome®