From: Joerg Roedel <Joerg.Roedel-5C7GfCeVMHo@public.gmane.org>
To: Ohad Ben-Cohen <ohad-Ix1uc/W3ht7QT0dZR+AlfA@public.gmane.org>
Cc: iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org,
Fernando Guzman Lugo <fernando.lugo-l0cyMroinI0@public.gmane.org>
Subject: Re: [PATCH] iommu/core: pass user-provided token when handling faults
Date: Mon, 21 May 2012 15:25:17 +0200 [thread overview]
Message-ID: <20120521132517.GE2604@amd.com> (raw)
In-Reply-To: <1337505311-25697-1-git-send-email-ohad-Ix1uc/W3ht7QT0dZR+AlfA@public.gmane.org>
On Sun, May 20, 2012 at 12:15:11PM +0300, Ohad Ben-Cohen wrote:
> Sometimes a single IOMMU user may have to deal with several
> different IOMMU devices (e.g. remoteproc).
>
> When an IOMMU fault happens, such users have to regain their
> context in order to deal with the fault.
>
> Users can't use the private fields of either the iommu_domain or
> the IOMMU device, because those are already used by the IOMMU core
> and low level driver (respectively).
>
> This patch just simply allow users to pass a private token (most
> notably their own context pointer) to iommu_set_fault_handler(),
> and then makes sure it is provided back to the users whenever
> IOMMU faults happen.
>
> Signed-off-by: Ohad Ben-Cohen <ohad-Ix1uc/W3ht7QT0dZR+AlfA@public.gmane.org>
May break compilation for !CONFIG_IOMMU_API. Where is remoteproc
changed? As far as I can see this is the only user of
iommu_set_fault_handler().
Joerg
--
AMD Operating System Research Center
Advanced Micro Devices GmbH Einsteinring 24 85609 Dornach
General Managers: Alberto Bozzo
Registration: Dornach, Landkr. Muenchen; Registerger. Muenchen, HRB Nr. 43632
next prev parent reply other threads:[~2012-05-21 13:25 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-20 9:15 [PATCH] iommu/core: pass user-provided token when handling faults Ohad Ben-Cohen
[not found] ` <1337505311-25697-1-git-send-email-ohad-Ix1uc/W3ht7QT0dZR+AlfA@public.gmane.org>
2012-05-21 13:25 ` Joerg Roedel [this message]
[not found] ` <20120521132517.GE2604-5C7GfCeVMHo@public.gmane.org>
2012-05-21 14:14 ` Ohad Ben-Cohen
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=20120521132517.GE2604@amd.com \
--to=joerg.roedel-5c7gfcevmho@public.gmane.org \
--cc=fernando.lugo-l0cyMroinI0@public.gmane.org \
--cc=iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org \
--cc=ohad-Ix1uc/W3ht7QT0dZR+AlfA@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.