All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andy Shevchenko <andy.shevchenko-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: Szabolcs Fruhwald <sfruhwald-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org>
Cc: Platform Driver
	<platform-driver-x86-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
	iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org,
	Stuart Hayes
	<stuart.w.hayes-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	Mario Limonciello
	<Mario.Limonciello-8PEkshWhKlo@public.gmane.org>
Subject: Re: [PATCH] dcdbas: Fix Intel-IOMMU domain allocation failure
Date: Thu, 24 Jan 2019 23:44:29 +0200	[thread overview]
Message-ID: <CAHp75Vc4r=ceP=SOQk2LR2B8fZjmdo33fV3yio3a352WwkMyMA@mail.gmail.com> (raw)
In-Reply-To: <CAKkQkjD=Hdm-3WbmrrqEj4c5df3LH7sMU960rwqHqF0Gf4CU7A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>

On Thu, Jan 24, 2019 at 10:31 PM Szabolcs Fruhwald <sfruhwald-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org> wrote:
>
> (+iommu list for visibility and confirmation of the intended constant
> externalization, see 2nd point below)

> Absolutely, I thought so too. But, since the actual need to force
> id-mapping comes from the lack of support for non-pci buses
> particularly by the intel iommu implementation, it seemed a bit odd to
> move this constant into iommu.h. Other platforms' implementations are
> usually handling and hooking into other buses, eg platform bus.
>
> However, even these other hw platform iommu implementations are using
> ACPI or other (bios related) tables to generate source ids, which
> might still be an issue with drivers like dcdbas, with no real device
> info in these tables. Not to mention that forcing id-mapping might be
> a useful tool in driver developers' hands by other reasons too.
> Therefore, I just came to the conclusion that it is indeed useful to
> have this constant present in the common iommu header file (but with a
> more expressing name).
>
> Especially, as I just found that dcdbas is *not* the first one to
> implement this workaround:
> https://github.com/torvalds/linux/blob/71f3a82fab1b631ae9cb1feb677f498d4ca5007d/drivers/gpu/drm/i915/selftests/mock_gem_device.c#L154

> Let me come up with a v2 patch-set, containing a separate patch
> externalizing this constant from intel_iommu.c to iommu.h and making
> the above code using it too first, followed by this change in dcdbas.

Wait... It sounds to me like a part of arch code where we define
arch_setup_pdev_archdata() and use this dummy domain.
Though dummy domain definition should come from IOMMU framework.

-- 
With Best Regards,
Andy Shevchenko

  parent reply	other threads:[~2019-01-24 21:44 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20190123230131.42094-1-sfruhwald@google.com>
     [not found] ` <c4e7855966a94b0c999a5f4325a27e90@ausx13mpc120.AMER.DELL.COM>
     [not found]   ` <c4e7855966a94b0c999a5f4325a27e90-uCoIPMzyhkt0S+eBbY//XQVY21JRvFwKV6yJEvX+wlw@public.gmane.org>
2019-01-24 20:30     ` [PATCH] dcdbas: Fix Intel-IOMMU domain allocation failure Szabolcs Fruhwald via iommu
     [not found]       ` <CAKkQkjD=Hdm-3WbmrrqEj4c5df3LH7sMU960rwqHqF0Gf4CU7A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2019-01-24 21:44         ` Andy Shevchenko [this message]
     [not found]           ` <CAHp75Vc4r=ceP=SOQk2LR2B8fZjmdo33fV3yio3a352WwkMyMA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2019-01-25  1:50             ` Szabolcs Fruhwald via iommu
     [not found]               ` <CAKkQkjD6WGE2jPSqUQ-BpJmevix2vd4GoSFKK5J312mEJB0Jpg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2019-01-25 11:58                 ` Andy Shevchenko
     [not found]                   ` <CAHp75VdhqGSCxZSPAW2DXq-cFUcDCoOnpW5mqD27LygGoiLMHA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2019-01-25 13:12                     ` Robin Murphy
     [not found]                       ` <7cd81f91-a69e-1561-821f-f21148a3aec0-5wv7dgnIgG8@public.gmane.org>
2019-01-28 23:42                         ` Szabolcs Fruhwald via iommu

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='CAHp75Vc4r=ceP=SOQk2LR2B8fZjmdo33fV3yio3a352WwkMyMA@mail.gmail.com' \
    --to=andy.shevchenko-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
    --cc=Mario.Limonciello-8PEkshWhKlo@public.gmane.org \
    --cc=iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org \
    --cc=platform-driver-x86-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=sfruhwald-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org \
    --cc=stuart.w.hayes-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.