Skip to content
Snippets Groups Projects
  1. Nov 27, 2024
    • Bryan O'Donoghue's avatar
      clk: qcom: Support attaching GDSCs to multiple parents · 7247561a
      Bryan O'Donoghue authored
      
      When a clock-controller has multiple power-domains we need to attach
      parent GDSCs in that clock-controller as subdomains of each of the
      power-domains.
      
      Testing on the x1e80100 reference shows that both power-domains need to be
      switched on for the GDSCs in the clock-controller to work. Some open
      questions remain.
      
      1. Should there be a hirearchy of power-domains in the clock-controller.
      2. If there should be no hirearchy should the parent GDSC inside the
         clock-controller attach to each power-domain in the clock-controller.
      3. If there are multiple parent GDSCs in a clock-controller do we attach
         those top-level GDSCs to each controller power-domain.
      4. Finally should performance-states be applied equally across those
         power-domains.
      
      It may be if we see more clock-controllers with multiple power-domains that
      some mixture of these questions will need to be implemented for specific
      hardware. Right now the approach taken here is to attach the
      clock-controller GDSC parent to each clock-controller power-domain.
      
      Signed-off-by: default avatarBryan O'Donoghue <bryan.odonoghue@linaro.org>
    • Bryan O'Donoghue's avatar
      clk: qcom: common: Add support for power-domain attachment · bfbf3bdf
      Bryan O'Donoghue authored
      
      Right now we support one power-domain per clock controller.
      These single power-domains are switched on by the driver platform logic.
      
      However when we have multiple power-domains attached to a clock-controller
      that list of power-domains must be handled outside of driver platform
      logic.
      
      Use devm_pm_domain_attach_list() to automatically hook the list of given
      power-domains in the dtsi for the clock-controller driver.
      
      Signed-off-by: default avatarBryan O'Donoghue <bryan.odonoghue@linaro.org>
      bfbf3bdf
    • Bryan O'Donoghue's avatar
      clk: qcom: gdsc: Capture pm_genpd_add_subdomain result code · 0eac8978
      Bryan O'Donoghue authored
      
      Adding a new clause to this if/else I noticed the existing usage of
      pm_genpd_add_subdomain() wasn't capturing and returning the result code.
      
      pm_genpd_add_subdomain() returns an int and can fail. Capture that result
      code and throw it up the call stack if something goes wrong.
      
      Fixes: 1b771839 ("clk: qcom: gdsc: enable optional power domain support")
      Cc: stable@vger.kernel.org
      Reviewed-by: default avatarBjorn Andersson <andersson@kernel.org>
      Signed-off-by: default avatarBryan O'Donoghue <bryan.odonoghue@linaro.org>
      0eac8978
  2. Nov 15, 2024
Loading