lkml.org 
[lkml]   [2012]   [Jun]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] uio_pci_generic does not export memory resources
On 2012-06-08 15:03, Michael S. Tsirkin wrote:
>> + /* set master */
>> + pci_set_master(pdev);
>> +
>> + /* set DMA mask */
>> + err = pci_set_dma_mask(pdev, DMA_BIT_MASK(64));
>
> uio currently only supports devices which do not
> do DMA.
>
> DMA from uio controlled devices is a no no unless
> it's behind an IOMMU which can protect us from
> random memory corruptions this could cause.
>
> In the later case it's OK but we need some code
> to check this and program the IOMMU appropriately.

AKA: VFIO. :)

Dominic, maybe you want to have a look at Alex's work:
https://github.com/awilliam/linux-vfio

Jan

--
Siemens AG, Corporate Technology, CT T DE IT 1
Corporate Competence Center Embedded Linux


\
 
 \ /
  Last update: 2012-06-08 16:01    [W:0.094 / U:2.200 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site