Re: question about passing physical address to lower level driver in scsi

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

 



hi stefan:
Thanks for your reply.
2011/10/30, Stefan Richter <stefanr@xxxxxxxxxxxxxxxxx>:
> On Oct 30 yoma sophian wrote:
>> in scsi_init_sgtable, we create sgtable, sdb->table.sgl, and get the
>> page from blk_rq_map_sg.
>> But when the dma_address of sdb->table.sgl will be calclated out
>> before send the scsi command down to the lower level driver?
>
> The low level driver, not SCSI core, is responsible to obtain a DMA
> address.

Why I ask this because I found there is no same transformation for
scsi usb subsystem.
Would anyone can let me know where it is?
>
> dma_map_sg() maps the scatter-gather list into DMA memory.  Then you can
> iterate over the list with for_each_sg and obtain DMA handles and lengths
> with sg_dma_address() and sg_dma_len().  E.g.:
>
> http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=blob;f=drivers/firewire/sbp2.c;h=41841a3e3f99c9acd4c4fc72c972626d8dffdcee;hb=02f8c6aee8df3cdc935e9bdd4f2d020306035dbe#l1398
> --
> Stefan Richter
> -=====-==-== =-=- ====-
> http://arcgraph.de/sr/
>
Retards,
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux