[lkml]   [2002]   [May]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: pci segments/domains
       From: Ivan Kokshaysky <>
    Date: Fri, 17 May 2002 15:39:03 +0400

    What about
    dma_addr_t pci_to_pci_map_single(struct pci_dev *master,
    struct pci_dev *target,
    dma_addr_t tgt_addr, size_t size, int dir)

    Could be implemented without much pain if there is enough interest. :-)

    tgt_addr does not make any sense, we are trying to DMA to a device
    resource, so pass a "struct resource *" and "unsigned long res_offset"
    instead of tgt_addr.

    So, as a (real life) example, suppose you wanted to portably point
    your BTTV card at the framebuffer of a video card, you'd do
    something like:

    res = fb_pdev->resource[1];
    bttv_dma_addr = pci_to_pci_map_single(struct pci_dev *bttv_pdev,
    struct pci_dev *fb_pdev,
    res, res_off, size,

    Note the direction is in terms of the master. The DMA is coming
    "from" the master in this "BTTV capture to framebuffer" case.
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    More majordomo info at
    Please read the FAQ at

     \ /
      Last update: 2005-03-22 13:22    [W:0.040 / U:2.496 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site