Hello,

When I test my kernel driver on a Sparc server with limited memory, I find that 
3 of 4 driver instances can be loaded successfully. But the 4th one always 
fails in the attach stage due to dma memory allocation failure:
WARNING: ddi_dma_mem_alloc failed, return value: -1

Then I added several Gig of DDR memory module, however, the failure remains. I 
am thinking whether the dma-able memory per server is limited, no matter what 
the total system memory is? how do I know the limitation? Or, is this related 
to the dma attribute I am using?

ddi_dma_attr_t  dma_attr_rbuf = {
        DMA_ATTR_V0,    /* dma_attr_version */
        0,              /* low DMA address range */
        (uint64_t)0xffffffffffffffffull,        /* high DMA address range */
        (uint64_t)0xffffffff,   /* DMA counter register */
        0x1,            /* DMA address alignment */
        0xfff,          /* DMA burstsizes */
        1,              /* min effective DMA size */
        (uint64_t)0xffffffff,   /* max DMA xfer size */
        (uint64_t)0xffffffff,   /* segment boundary */
        16,             /* s/g list length, i.e no sg list */
        1,              /* granularity of device */
        0       /* DMA transfer flags */
};

Tom
-- 
This message posted from opensolaris.org
_______________________________________________
driver-discuss mailing list
driver-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/driver-discuss

Reply via email to