Re: [PATCH 4/8] drm/i915: avoid waking up from PC8 on DP AUX operations

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jul 29, 2013 at 05:48:23PM -0300, Paulo Zanoni wrote:
> From: Paulo Zanoni <paulo.r.zanoni@xxxxxxxxx>
> 
> If we're already allowing PC8, just don't use the IRQs, so we won't
> need to wake from PC8. Waking up from PC8 is a slow thing, so avoid it
> when we can.

This raises the question of why we where holding the power well wake
lock if we weren't using IRQs in the first place. This tells me the 
intel_aux_display_runtime_get() interface is indequate, imo. It would
need to be more expressive of why/what part of aux display runtime you
want. You could even move the state checking there so that GMBUS could
use the same interface:

unsigned long intel_aux_display_runtime_get(dev_priv, want, need)
 {
  if (need) {
     __intel_aux_display_runtime_get();
     return need;
   }

   if (want) {
   	if (hsw_pc8_enabled()) {
     	   __intel_aux_display_runtime_get();
     	   return want;
	}
   }

   return 0;
 }
 
And pass the return value to _put for it to decide if it needs to do
anything (also it can then select its path based on whether or not it
holds a wakeref). Making the caller decide whether or not to act based
on information inside pc8 looks very fragile to me, and easy to break in
future.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux