[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-ppc] [PULL 08/14] spapr_pci/spapr_pci_vfio: Support Dynamic DM
From: |
David Gibson |
Subject: |
Re: [Qemu-ppc] [PULL 08/14] spapr_pci/spapr_pci_vfio: Support Dynamic DMA Windows (DDW) |
Date: |
Tue, 12 Jul 2016 15:20:21 +1000 |
User-agent: |
Mutt/1.6.1 (2016-04-27) |
On Mon, Jul 11, 2016 at 04:21:29PM +0200, Paolo Bonzini wrote:
>
>
> On 05/07/2016 07:31, David Gibson wrote:
> >
> > - if (tcet && tcet->nb_table) {
> > - spapr_tce_table_disable(tcet);
> > + if (tcet && tcet->nb_table) {
> > + spapr_tce_table_disable(tcet);
> > + }
> > }
> >
> > /* Register default 32bit DMA window */
> > + tcet = spapr_tce_find_by_liobn(sphb->dma_liobn[0]);
>
> Should the statement below be wrapped by "if (tcet)"?
Not really. That lookup should never fail (if we didn't allocate the
tcet before we would have failed initialization). An assert(tcet)
might be appropriate, but I don't know it's worth adding at this
stage.
> Paolo
>
> > spapr_tce_table_enable(tcet, SPAPR_TCE_PAGE_SHIFT, sphb->dma_win_addr,
> > sphb->dma_win_size >> SPAPR_TCE_PAGE_SHIFT)
>
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
signature.asc
Description: PGP signature
- [Qemu-ppc] [PULL 09/14] ppc: simplify ppc_hash64_hpte_page_shift_noslb(), (continued)
- [Qemu-ppc] [PULL 09/14] ppc: simplify ppc_hash64_hpte_page_shift_noslb(), David Gibson, 2016/07/05
- [Qemu-ppc] [PULL 10/14] target-ppc: Correct page size decoding in ppc_hash64_pteg_search(), David Gibson, 2016/07/05
- [Qemu-ppc] [PULL 04/14] spapr_iommu: Realloc guest visible TCE table when starting/stopping listening, David Gibson, 2016/07/05
- [Qemu-ppc] [PULL 07/14] vfio/spapr: Create DMA window dynamically (SPAPR IOMMU v2), David Gibson, 2016/07/05
- [Qemu-ppc] [PULL 13/14] ppc/hash64: Add proper real mode translation support, David Gibson, 2016/07/05
- [Qemu-ppc] [PULL 05/14] vfio: spapr: Add DMA memory preregistering (SPAPR IOMMU v2), David Gibson, 2016/07/05
- [Qemu-ppc] [PULL 08/14] spapr_pci/spapr_pci_vfio: Support Dynamic DMA Windows (DDW), David Gibson, 2016/07/05
- Re: [Qemu-ppc] [PULL 00/14] ppc-for-2.7 queue 20160705 (v2), Peter Maydell, 2016/07/05