On Mon, Oct 15, 2018 at 06:29:45PM -0700, José Roberto de Souza wrote: > intel_csr_ucode_init() gets a POWER_DOMAIN_INIT reference but it is > only released in csr_load_work_fn() if DMC firmware is present in > filesystem, keeping a reference to POWER_DOMAIN_INIT and every power > well enabled all the times. > > Cc: Imre Deak <imre.deak@xxxxxxxxx> > Signed-off-by: José Roberto de Souza <jose.souza@xxxxxxxxx> > --- > drivers/gpu/drm/i915/intel_csr.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/gpu/drm/i915/intel_csr.c b/drivers/gpu/drm/i915/intel_csr.c > index fc7bd21fa586..7c91a56869e9 100644 > --- a/drivers/gpu/drm/i915/intel_csr.c > +++ b/drivers/gpu/drm/i915/intel_csr.c > @@ -423,8 +423,6 @@ static void csr_load_work_fn(struct work_struct *work) > if (dev_priv->csr.dmc_payload) { > intel_csr_load_program(dev_priv); > > - intel_display_power_put(dev_priv, POWER_DOMAIN_INIT); > - > DRM_INFO("Finished loading DMC firmware %s (v%u.%u)\n", > dev_priv->csr.fw_path, > CSR_VERSION_MAJOR(csr->version), and for the !dmc_payload case below we print: "Failed to load DMC firmware, disabling runtime power management." explaining why we hold on to the reference in that case. > @@ -439,6 +437,8 @@ static void csr_load_work_fn(struct work_struct *work) > } > > release_firmware(fw); > + > + intel_display_power_put(dev_priv, POWER_DOMAIN_INIT); > } > > /** > -- > 2.19.1 > _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx