mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-12 13:55:32 +00:00
net: mana: Set the DMA device max segment size
MANA hardware doesn't have any restrictions on the DMA segment size, set it to the max allowed value. Signed-off-by: Ajay Sharma <sharmaajay@microsoft.com> Reviewed-by: Dexuan Cui <decui@microsoft.com> Signed-off-by: Long Li <longli@microsoft.com> Link: https://lore.kernel.org/r/1667502990-2559-5-git-send-email-longli@linuxonhyperv.com Acked-by: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
This commit is contained in:
parent
b5c1c9855b
commit
6fe254160b
1 changed files with 6 additions and 0 deletions
|
@ -1373,6 +1373,12 @@ static int mana_gd_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
|
|||
if (err)
|
||||
goto release_region;
|
||||
|
||||
err = dma_set_max_seg_size(&pdev->dev, UINT_MAX);
|
||||
if (err) {
|
||||
dev_err(&pdev->dev, "Failed to set dma device segment size\n");
|
||||
goto release_region;
|
||||
}
|
||||
|
||||
err = -ENOMEM;
|
||||
gc = vzalloc(sizeof(*gc));
|
||||
if (!gc)
|
||||
|
|
Loading…
Reference in a new issue