From: Muli Ben-Yehuda <muli-7z/5BgaJwgfQT0dZR+AlfA@public.gmane.org>
To: Amit Shah <amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org,
linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH 3/8] KVM: PVDMA Guest: Guest-side routines for paravirtualized DMA
Date: Mon, 12 Nov 2007 16:01:55 +0200 [thread overview]
Message-ID: <20071112140155.GL3299@rhun.haifa.ibm.com> (raw)
In-Reply-To: <200711121925.27844.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
On Mon, Nov 12, 2007 at 07:25:27PM +0530, Amit Shah wrote:
> Selectively? What happens in the case when some iommu doesn't want
> to invoke the prev_op, but the mapping depends on it being called
> (eg, the hypercalling op is embedded somewhere in the prev_op chain)
Bad things :-)
There needs to be a hierarchy of dma-ops, e.g., nommu/swiotlb, then a
hardware iommu, then pvdma. Not sure where IB fits in here. The
calling order would be the reverse of the initialization order, so
pvdma->hardare->nommu/swiotlb.
> Hmm, also, a hypercall should be the last operation to be called in
> a few cases, but also the first (and the last) to be called in
> several other cases. For example, in a guest, you can go register
> any number of iotlbs, but you don't actually want to do anything
> there -- you just want to do a hypercall and get the mapping from
> the host.
>
> But in any case, what ensures that the hypercall op always gets
> called and also that it's the last one?
If it gets called first it can ensure that it runs either first or
last, or both, since it controls when to run the other hooks, before
or after it does what it needs to do.
> Also, I'm thinking of implementations where let's say sg_map_free is
> not defined for a particular iotlb, but it was defined in the
> previously registered one. How to handle this?
Good point, this will require all dma ops implementation to provide
stubs that just return prev_ops->op if it's set.
> It seems a small dispatcher which takes care of this seems the
> likely choice here, but avoiding it (or at least caching the
> decisions) is something that needs more thought.
Yeah, I'm not too enthusiastic about it, but we do need such a generic
mechanism or we will each end up implementing our own versions of
it...
Cheers,
Muli
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
next prev parent reply other threads:[~2007-11-12 14:01 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-11-07 14:21 RFC: Paravirtualized DMA accesses for KVM Amit Shah
[not found] ` <d1c72ce6e3a0e73c18993c3f066d1350b147f726.1194445109.git.amit.shah@qumranet.com>
2007-11-07 14:21 ` [PATCH 1/8] KVM: PVDMA Host: Handle reqeusts for guest DMA mappings Amit Shah
[not found] ` <6d486436cf50e269d8914229d10ff60f3d646795.1194445109.git.amit.shah@qumranet.com>
2007-11-07 14:21 ` [PATCH 2/8] KVM: Move #include asm/kvm_para.h outside of __KERNEL__ Amit Shah
[not found] ` <609d5d611a5fb58ab5a7184be7b6d29494023ba0.1194445109.git.amit.shah@qumranet.com>
2007-11-07 14:21 ` [PATCH 3/8] KVM: PVDMA Guest: Guest-side routines for paravirtualized DMA Amit Shah
[not found] ` <218cf425feff1d4daf23d3f25df1eb224108a1a3.1194445109.git.amit.shah@qumranet.com>
2007-11-07 14:21 ` [PATCH 4/8] KVM: PVDMA: Introduce is_pv_device() dma operation Amit Shah
[not found] ` <e2f5f0c08d08cf66a39c8b452410078617e611f7.1194445109.git.amit.shah@qumranet.com>
2007-11-07 14:21 ` [PATCH 5/8] KVM: PVDMA: Update dma_alloc_coherent to make it paravirt-aware Amit Shah
[not found] ` <6bbd61409e4779febab1eaf03796455b22e8ea70.1194445109.git.amit.shah@qumranet.com>
2007-11-07 14:21 ` [PATCH 6/8] KVM: PVDMA Guest: Add Makefile rule Amit Shah
[not found] ` <01dd7657bda537d738ea92330606592fa8aaf3c5.1194445109.git.amit.shah@qumranet.com>
2007-11-07 14:21 ` [PATCH 7/8] PVDMA: Guest: Add Kconfig options to select PVDMA Amit Shah
[not found] ` <fbc5dea9bfdb021ab2d3808583314901799405a0.1194445109.git.amit.shah@qumranet.com>
2007-11-07 14:21 ` [PATCH 8/8] KVM: Update drivers/Makefile to check for CONFIG_VIRTUALIZATION Amit Shah
[not found] ` <1194445269752-git-send-email-amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
[not found] ` <d1c72ce6e3a0e73c18993c3f066d1350b147f726.1194445109.git.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-07 14:21 ` [PATCH 1/8] KVM: PVDMA Host: Handle reqeusts for guest DMA mappings Amit Shah
[not found] ` <6d486436cf50e269d8914229d10ff60f3d646795.1194445109.git.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-07 14:21 ` [PATCH 2/8] KVM: Move #include asm/kvm_para.h outside of __KERNEL__ Amit Shah
[not found] ` <609d5d611a5fb58ab5a7184be7b6d29494023ba0.1194445109.git.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-07 14:21 ` [PATCH 3/8] KVM: PVDMA Guest: Guest-side routines for paravirtualized DMA Amit Shah
2007-11-12 10:50 ` Muli Ben-Yehuda
[not found] ` <20071112105001.GF3299-WD1JZD8MxeCTrf4lBMg6DdBPR1lH4CV8@public.gmane.org>
2007-11-12 11:56 ` Amit Shah
[not found] ` <200711121726.24907.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-12 13:32 ` Muli Ben-Yehuda
[not found] ` <20071112133207.GJ3299-WD1JZD8MxeCTrf4lBMg6DdBPR1lH4CV8@public.gmane.org>
2007-11-12 13:55 ` Amit Shah
[not found] ` <200711121925.27844.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-12 14:01 ` Muli Ben-Yehuda [this message]
2007-11-12 14:53 ` Gerd Hoffmann
2007-11-12 16:00 ` Joerg Roedel
[not found] ` <218cf425feff1d4daf23d3f25df1eb224108a1a3.1194445109.git.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-07 14:21 ` [PATCH 4/8] KVM: PVDMA: Introduce is_pv_device() dma operation Amit Shah
2007-11-12 10:52 ` Muli Ben-Yehuda
[not found] ` <6bbd61409e4779febab1eaf03796455b22e8ea70.1194445109.git.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-07 14:21 ` [PATCH 6/8] KVM: PVDMA Guest: Add Makefile rule Amit Shah
[not found] ` <01dd7657bda537d738ea92330606592fa8aaf3c5.1194445109.git.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-07 14:21 ` [PATCH 7/8] PVDMA: Guest: Add Kconfig options to select PVDMA Amit Shah
[not found] ` <fbc5dea9bfdb021ab2d3808583314901799405a0.1194445109.git.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-07 14:21 ` [PATCH 8/8] KVM: Update drivers/Makefile to check for CONFIG_VIRTUALIZATION Amit Shah
[not found] ` <e2f5f0c08d08cf66a39c8b452410078617e611f7.1194445109.git.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-07 14:21 ` [PATCH 5/8] KVM: PVDMA: Update dma_alloc_coherent to make it paravirt-aware Amit Shah
2007-11-12 10:56 ` Muli Ben-Yehuda
[not found] ` <20071112105637.GH3299-WD1JZD8MxeCTrf4lBMg6DdBPR1lH4CV8@public.gmane.org>
2007-11-12 11:59 ` Amit Shah
2007-11-12 15:55 ` [PATCH 1/8] KVM: PVDMA Host: Handle reqeusts for guest DMA mappings Joerg Roedel
[not found] ` <20071112155522.GF6466-5C7GfCeVMHo@public.gmane.org>
2007-11-12 17:07 ` Amit Shah
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=20071112140155.GL3299@rhun.haifa.ibm.com \
--to=muli-7z/5bgajwgfqt0dzr+alfa@public.gmane.org \
--cc=amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org \
--cc=kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox