IOMMU Archive on lore.kernel.org
 help / color / Atom feed
From: Jean-Philippe Brucker <jean-philippe@linaro.org>
To: Jacob Pan <jacob.jun.pan@linux.intel.com>
Cc: "Tian, Kevin" <kevin.tian@intel.com>,
	Raj Ashok <ashok.raj@intel.com>,
	David Woodhouse <dwmw2@infradead.org>,
	iommu@lists.linux-foundation.org,
	LKML <linux-kernel@vger.kernel.org>,
	Alex Williamson <alex.williamson@redhat.com>,
	Jean-Philippe Brucker <jean-philippe@linaro.com>,
	Jonathan Cameron <jic23@kernel.org>
Subject: Re: [PATCH v4 3/4] iommu/ioasid: Add custom allocators
Date: Fri, 4 Oct 2019 19:18:35 +0200
Message-ID: <20191004171835.GB1180125@lophozonia> (raw)
In-Reply-To: <1570045363-24856-4-git-send-email-jacob.jun.pan@linux.intel.com>

On Wed, Oct 02, 2019 at 12:42:42PM -0700, Jacob Pan wrote:
> IOASID allocation may rely on platform specific methods. One use case is
> that when running in the guest, in order to obtain system wide global
> IOASIDs, emulated allocation interface is needed to communicate with the
> host. Here we call these platform specific allocators custom allocators.
> 
> Custom IOASID allocators can be registered at runtime and take precedence
> over the default XArray allocator. They have these attributes:
> 
> - provides platform specific alloc()/free() functions with private data.
> - allocation results lookup are not provided by the allocator, lookup
>   request must be done by the IOASID framework by its own XArray.
> - allocators can be unregistered at runtime, either fallback to the next
>   custom allocator or to the default allocator.
> - custom allocators can share the same set of alloc()/free() helpers, in
>   this case they also share the same IOASID space, thus the same XArray.
> - switching between allocators requires all outstanding IOASIDs to be
>   freed unless the two allocators share the same alloc()/free() helpers.
> 
> Signed-off-by: Jean-Philippe Brucker <jean-philippe@linaro.com>
> Signed-off-by: Jacob Pan <jacob.jun.pan@linux.intel.com>
> Link: https://lkml.org/lkml/2019/4/26/462

Reviewed-by: Jean-Philippe Brucker <jean-philippe@linaro.org>

_______________________________________________
iommu mailing list
iommu@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/iommu

  reply index

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-02 19:42 [PATCH v4 0/4] User API for nested shared virtual address (SVA) Jacob Pan
2019-10-02 19:42 ` [PATCH v4 1/4] iommu: Introduce cache_invalidate API Jacob Pan
2019-10-02 19:42 ` [PATCH v4 2/4] iommu: Add I/O ASID allocator Jacob Pan
2019-10-02 19:42 ` [PATCH v4 3/4] iommu/ioasid: Add custom allocators Jacob Pan
2019-10-04 17:18   ` Jean-Philippe Brucker [this message]
2019-10-02 19:42 ` [PATCH v4 4/4] iommu: Introduce guest PASID bind function Jacob Pan
2019-10-07 19:39 ` [PATCH v4 0/4] User API for nested shared virtual address (SVA) Jacob Pan
2019-10-14 17:14   ` Jacob Pan
2019-10-15  7:56     ` Jean-Philippe Brucker
2019-10-15  8:35 ` Auger Eric
2019-10-15 11:35 ` Joerg Roedel

Reply instructions:

You may reply publically 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=20191004171835.GB1180125@lophozonia \
    --to=jean-philippe@linaro.org \
    --cc=alex.williamson@redhat.com \
    --cc=ashok.raj@intel.com \
    --cc=dwmw2@infradead.org \
    --cc=iommu@lists.linux-foundation.org \
    --cc=jacob.jun.pan@linux.intel.com \
    --cc=jean-philippe@linaro.com \
    --cc=jic23@kernel.org \
    --cc=kevin.tian@intel.com \
    --cc=linux-kernel@vger.kernel.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

IOMMU Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-iommu/0 linux-iommu/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-iommu linux-iommu/ https://lore.kernel.org/linux-iommu \
		iommu@lists.linux-foundation.org
	public-inbox-index linux-iommu

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.linux-foundation.lists.iommu


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git