Re: [PATCH 2/3] lib: Optionally initialize mmio register access without forcewake

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

 



On Fri, Aug 28, 2015 at 05:51:46PM +0300, Mika Kuoppala wrote:
> Sometimes it is beneficial to debug the forcewake registers
> themselves or registers that don't need or are interfered by
> forcewake. Add parameter to intel_register_access_init()
> to optionally avoid forcewake dance around register access.
> 
> Signed-off-by: Mika Kuoppala <mika.kuoppala@xxxxxxxxx>
> ---
>  debugger/debug_rdata.c       |  2 +-
>  debugger/eudb.c              |  2 +-
>  lib/intel_io.h               |  2 +-
>  lib/intel_mmio.c             |  9 +++++++--
>  tests/gem_workarounds.c      |  2 +-
>  tests/pm_lpsp.c              |  2 +-
>  tools/intel_display_poller.c |  2 +-
>  tools/intel_forcewaked.c     |  4 ++--
>  tools/intel_gpu_top.c        |  2 +-
>  tools/intel_infoframes.c     |  2 +-
>  tools/intel_l3_parity.c      |  2 +-
>  tools/intel_panel_fitter.c   |  2 +-
>  tools/intel_perf_counters.c  |  2 +-
>  tools/intel_reg.c            |  6 +++---
>  tools/intel_watermark.c      | 14 +++++++-------
>  tools/quick_dump/chipset.i   |  4 ++--
>  16 files changed, 32 insertions(+), 27 deletions(-)
> 
> diff --git a/debugger/debug_rdata.c b/debugger/debug_rdata.c
> index 61d82d9..2643581 100644
> --- a/debugger/debug_rdata.c
> +++ b/debugger/debug_rdata.c
<snip>  
> @@ -187,7 +188,11 @@ intel_register_access_init(struct pci_device *pci_dev, int safe)
>  	/* Find where the forcewake lock is. Forcewake doesn't exist
>  	 * gen < 6, but the debugfs should do the right things for us.
>  	 */
> -	ret = igt_open_forcewake_handle();
> +	if (nofw)
> +		ret = -1;
> +	else
> +		ret = igt_open_forcewake_handle();

IGT_NO_FORCEWAKE is handled in igt_open_forcewake_handle(). Maybe pull
it out so that all ways to disable forcewake are handled in the same
place?

-- 
Ville Syrjälä
Intel OTC
_______________________________________________
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