]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/commit
MFC r312882, r321983 and r321984:
authorhselasky <hselasky@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Mon, 7 Aug 2017 12:49:30 +0000 (12:49 +0000)
committerhselasky <hselasky@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Mon, 7 Aug 2017 12:49:30 +0000 (12:49 +0000)
commit1997876e4c5bc0172a6cb7c56deae48ba6b33768
treea2eacbfcf357bbd826c3a26a54c60a99c64a67c8
parent8f6818b7e92e3aab567174caf194690c80479d22
MFC r312882, r321983 and r321984:
Use the busdma API to allocate all DMA-able memory.

The MLX5 driver has four different types of DMA allocations which are
now allocated using busdma:

1) The 4K firmware DMA-able blocks. One busdma object per 4K allocation.
2) Data for firmware commands use the 4K firmware blocks split into four 1K blocks.
3) The 4K firmware blocks are also used for doorbell pages.
4) The RQ-, SQ- and CQ- DMA rings. One busdma object per allocation.

After this patch the mlx5en driver can be used with DMAR enabled in
the FreeBSD kernel.

Sponsored by: Mellanox Technologies

git-svn-id: svn://svn.freebsd.org/base/stable/10@322151 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
sys/dev/mlx5/device.h
sys/dev/mlx5/driver.h
sys/dev/mlx5/mlx5_core/mlx5_alloc.c
sys/dev/mlx5/mlx5_core/mlx5_cmd.c
sys/dev/mlx5/mlx5_core/mlx5_pagealloc.c