From: Thomas Monjalon <thomas@monjalon.net>
To: "jiangheng (G)" <jiangheng14@huawei.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>, ferruh.yigit@amd.com
Subject: Re: [[PATCH] ] linux/igb_uio: fix build with Linux 5.18
Date: Sun, 05 Feb 2023 18:34:41 +0100 [thread overview]
Message-ID: <3536984.R56niFO833@thomas> (raw)
In-Reply-To: <8b4953ef939d433f8fe19353e9ed3aa7@huawei.com>
30/01/2023 08:27, jiangheng (G):
> Since commit 7968778914 (PCI: Remove the deprecated "pci-dma-compat.h" API)
> in 5.18, pci_set_dma_mask() and pci_set_consistent_dma_mask() no longer exist
> switch those api to dma_set_mask_and_coherent.
> ---
> linux/igb_uio/igb_uio.c | 8 ++++++++
> 1 file changed, 8 insertions(+)
The patch from Ferruh looks simpler:
https://patches.dpdk.org/project/dpdk/patch/20221216115732.3552650-1-ferruh.yigit@amd.com/
> +#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 18, 0)
> err = pci_set_dma_mask(dev, DMA_BIT_MASK(64));
> +#else
> + err = dma_set_mask_and_coherent(&dev->dev, DMA_BIT_MASK(64));
> +#endif
[...]
> +#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 18, 0)
> err = pci_set_consistent_dma_mask(dev, DMA_BIT_MASK(64));
> +#else
> + err = dma_set_mask_and_coherent(&dev->dev, DMA_BIT_MASK(64));
> +#endif
prev parent reply other threads:[~2023-02-05 17:34 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-01-30 7:27 jiangheng (G)
2023-02-05 17:34 ` Thomas Monjalon [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3536984.R56niFO833@thomas \
--to=thomas@monjalon.net \
--cc=dev@dpdk.org \
--cc=ferruh.yigit@amd.com \
--cc=jiangheng14@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).