Hello,

I have a couple of PCI DMA related questions.


1. 

I intend to use lis_pci_alloc_consistent() function.
I'm naturally interested in the allocated bus address.
Looking into sources I see the following comment:


/*
 * Allocate 'size' bytes and return the CPU pointer to it via return value.
 * Return the DMA address via 'dma_handle'.  <----------------
 */
void    *lis_pci_alloc_consistent(lis_pci_dev_t  *dev,
                                  size_t          size,
                                  lis_dma_addr_t *dma_handle);



Looking into the lis_dma_addr structure I do not see 
any name that looks like bus address


typedef struct lis_dma_addr
{
    unsigned       opaque[8] ;          /* opaque kernel structure */      
    int            size ;               /* saved size */
    void          *vaddr ;              /* cpu virtual addr */
    lis_pci_dev_t *dev ;                /* PCI device */
    int            direction ;          /* for map/unmap single */

} lis_dma_addr_t ;

Where can I get allocated bus address from?

Also, do I have to allocate that structure myself?
If that is the case, what info should I fill into  the lis_dma_addr 
pointed to by the  dma_handle prior calling  lis_pci_alloc_consistent()?  
Size, dev, direction?


2.

I use allocb() to allocate message buffers.
How can I make those message buffers  DMA-able?

On HPUX I could achieve this using wsio_map() function.
Is there an elegant way to do the similar thing on Linux/LiS?

 
thanks for your help,
--
Eugene


__________________________________________________________________
McAfee VirusScan Online from the Netscape Network.
Comprehensive protection for your entire computer. Get your free trial today!
http://channels.netscape.com/ns/computing/mcafee/index.jsp?promo=393397

Get AOL Instant Messenger 5.1 free of charge.  Download Now!
http://aim.aol.com/aimnew/Aim/register.adp?promo=380455

_______________________________________________
Linux-streams mailing list
[EMAIL PROTECTED]
http://gsyc.escet.urjc.es/mailman/listinfo/linux-streams

Reply via email to