ikwzm / udmabuf

User space mappable dma buffer device driver for Linux.
BSD 2-Clause "Simplified" License
539 stars 165 forks source link

AXI MCDMA support? #109

Closed Livius90 closed 1 year ago

Livius90 commented 1 year ago

Hi,

Is the AXI Multichannel DMA supported to use with u-dma-buf?

The maximum number of DMA buffers that can be allocated using insmod is 8 (udmabuf0/1/2/3/4/5/6/7).

What does it mean? Maximum 8 DMA buffer is limited only, if it is configured via insmod? What is the maximum if they are defined in device-tree nodes instead of insmod?

ikwzm commented 1 year ago

Thank you for the issue.

I am not familiar with AXI MCDMA. u-dma-buf only provides DMA buffers, it does not control DMA. There is probably a dedicated Linux Driver for AXI MCDMA. Please contact AMD for more information.

I'm sorry I couldn't help you.

Livius90 commented 1 year ago

Hi,

I looked after what is the different between AXI DMA and AXI MCDMA, lets see the following:

As i understand your u-dma-buf kernel module, it supports only the "Direct Register Mode" and "Scatter/Gather" is not supported, am i rigth? In this case AXI MCDMA is not usable via u-dma-buf unfortunately. :cry:

Livius90 commented 1 year ago

@ikwzm

The maximum number of DMA buffers that can be allocated using insmod is 8 (udmabuf0/1/2/3/4/5/6/7).

What does it mean? Maximum 8 DMA buffer is limited only, if it is configured via insmod? What is the maximum if they are defined in device-tree nodes instead of insmod?

ikwzm commented 1 year ago

What does it mean? Maximum 8 DMA buffer is limited only, if it is configured via insmod? What is the maximum if they are defined in device-tree nodes instead of insmod?

256

See u-dma-buf.c for details.

Livius90 commented 1 year ago

What does it mean? Maximum 8 DMA buffer is limited only, if it is configured via insmod? What is the maximum if they are defined in device-tree nodes instead of insmod?

256

See u-dma-buf.c for details.

Thanks, i found it in the code: https://github.com/ikwzm/udmabuf/blob/master/u-dma-buf.c#L72

Livius90 commented 1 year ago

Thanks the detailed quick answers, your u-dma-buf is awesome.