Re: [PATCH v2 2/3] s390/pci: store DMA offset in bus_dma_region

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



>>> +	map->cpu_start = 0;
>>> +	map->dma_start = PAGE_ALIGN(zdev->start_dma);
>>> +	map->size = (u64)virt_to_phys(high_memory);
>>
>> I don't think we should restrict the size here to the size of memory.
>> Instead I think it should be zdev->end_dma - zdev->start_dma.
>>
>> Since we handle the restriction to memory size as reserved regions I
>> think that should be compatible. Also I think otherwise this might
>> break the admittedly odd s390_iommu_aperture=X kernel parameter on
>> LPARs.
> 
> Correction, zdev->end_dma - zdev->start_dma + 1 because zdev->end_dma
> is inclusive ;-)
> 

Forgot about that parameter, thanks...  OK, will change to:

map->size = zdev->end_dma - zdev->start_dma + 1;




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Kernel Development]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Info]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Linux Media]     [Device Mapper]

  Powered by Linux