From: Andi Shyti <andi.shyti@linux.intel.com>
To: Matt Roper <matthew.d.roper@intel.com>
Cc: Abdiel Janulgue <abdiel.janulgue@gmail.com>,
Andi Shyti <andi@etezian.org>,
Tvrtko Ursulin <tvrtko.ursulin@intel.com>,
Intel GFX <intel-gfx@lists.freedesktop.org>,
Lucas De Marchi <lucas.demarchi@intel.com>,
DRI Devel <dri-devel@lists.freedesktop.org>,
Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>,
Matthew Auld <matthew.auld@intel.com>,
Andi Shyti <andi.shyti@linux.intel.com>,
Sujaritha Sundaresan <sujaritha.sundaresan@intel.com>
Subject: Re: [PATCH v2 1/2] drm/i915: Prepare for multiple GTs
Date: Fri, 14 Jan 2022 19:59:54 +0200 [thread overview]
Message-ID: <YeG6GrzU/QYUY1RH@intel.intel> (raw)
In-Reply-To: <YeGq/b6JjJaxSE0z@mdroper-desk1.amr.corp.intel.com>
Hi Matt,
[...]
> > -int intel_uncore_setup_mmio(struct intel_uncore *uncore)
> > +int intel_uncore_setup_mmio(struct intel_uncore *uncore, phys_addr_t phys_addr)
> > {
> > struct drm_i915_private *i915 = uncore->i915;
> > - struct pci_dev *pdev = to_pci_dev(i915->drm.dev);
> > - int mmio_bar;
> > int mmio_size;
> >
> > - mmio_bar = GRAPHICS_VER(i915) == 2 ? 1 : 0;
> > /*
> > * Before gen4, the registers and the GTT are behind different BARs.
> > * However, from gen4 onwards, the registers and the GTT are shared
> > @@ -2044,7 +2041,7 @@ int intel_uncore_setup_mmio(struct intel_uncore *uncore)
> > else
> > mmio_size = 2 * 1024 * 1024;
> >
> > - uncore->regs = pci_iomap(pdev, mmio_bar, mmio_size);
> > + uncore->regs = ioremap(phys_addr, mmio_size);
>
> Is there a specific reason we switch to ioremap() instead of
> pci_iomap_range()? I.e., we could pass 'phys_offset' rather than
> 'phys_addr' and call
>
> pci_iomap_range(pdev, mmio_bar, phys_offset, mmio_size);
>
> Not that it really matters too much either way as far as I can see;
> ioremap()/iounmap() should work fine too.
this was originally changed by Abdiel (I think) and I left as it
is as I tried to change as less as I could from the original
work.
> Reviewed-by: Matt Roper <matthew.d.roper@intel.com>
Thank you!
Andi
next prev parent reply other threads:[~2022-01-14 18:00 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-12 22:20 [PATCH v2 0/2] Introduce multitile support Andi Shyti
2022-01-12 22:20 ` [PATCH v2 1/2] drm/i915: Prepare for multiple GTs Andi Shyti
2022-01-14 16:55 ` Matt Roper
2022-01-14 17:59 ` Andi Shyti [this message]
2022-01-17 18:03 ` Abdiel Janulgue
2022-01-12 22:20 ` [PATCH v2 2/2] drm/i915/gt: make a gt sysfs group and move power management files Andi Shyti
2022-01-12 22:42 ` Sundaresan, Sujaritha
2022-01-14 17:08 ` Matt Roper
2022-01-14 18:20 ` Andi Shyti
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=YeG6GrzU/QYUY1RH@intel.intel \
--to=andi.shyti@linux.intel.com \
--cc=abdiel.janulgue@gmail.com \
--cc=andi@etezian.org \
--cc=daniele.ceraolospurio@intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=lucas.demarchi@intel.com \
--cc=matthew.auld@intel.com \
--cc=matthew.d.roper@intel.com \
--cc=sujaritha.sundaresan@intel.com \
--cc=tvrtko.ursulin@intel.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