Re: [PATCH 02/13] IB/core: allow passing mapping an offset into the SG in ib_map_mr_sg

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

 



> This looks wrong...
>
> The SG offset should not be taken into account in the address
> translation vector that is given to the HW. The sg_offset needs to
> be accounted in the mr->iova:
>
> mr->iova = sg_dma_address(&sgl[0]) + sg_offset;
>
> I think the page mappings should stay as the are.

I looked at this in a bit more detail, and I think we need both.

For PAGE_SIZE or smaller SG entries you're correct, and we don't
need the offset for dma_addr.  But it doesn't harm either.  But
for lager SG entries we need it to calculate the correct
base address.
--
To unsubscribe from this list: send the line "unsubscribe target-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux SCSI]     [Kernel Newbies]     [Linux SCSI Target Infrastructure]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Device Mapper]

  Powered by Linux