From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 14DD4A0542; Sun, 9 Oct 2022 19:07:30 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id A3F70400D5; Sun, 9 Oct 2022 19:07:29 +0200 (CEST) Received: from mout.gmx.net (mout.gmx.net [212.227.15.18]) by mails.dpdk.org (Postfix) with ESMTP id 05AF740042 for ; Thu, 6 Oct 2022 20:52:09 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1665082329; bh=NG/DLJG+m7+7SHLmgp33MoYmKgwWhu+0qosMSgOCgTk=; h=X-UI-Sender-Class:From:To:Cc:Subject:Date:In-Reply-To:References; b=ERSzbxcP7igv1iCV67QxrlUOBAxPut7koO72tc/uXlpXwpJfojwNavIs+yEaXEGaj ShnJsTuYuQObOVjHYIPT2ibsR1yl5NF9OUPqAtvqh7Q0roVDUJvwdZ06nVfjKFChE8 kh3tlKsy+xANuVMCIOYdJfJ4fotm/tGVy/B963AE= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from nb-georg.home ([109.104.40.1]) by mail.gmx.net (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1N17Ye-1pLwKB2qsM-012Wfa; Thu, 06 Oct 2022 20:52:09 +0200 From: =?UTF-8?q?Georg=20M=C3=BCller?= To: dev@dpdk.org Cc: =?UTF-8?q?Georg=20M=C3=BCller?= Subject: [PATCH v2] linux/igb_uio: fix build with kernel 5.18+ Date: Thu, 6 Oct 2022 20:51:37 +0200 Message-Id: <20221006185136.1634218-1-georgmueller@gmx.net> X-Mailer: git-send-email 2.37.3 In-Reply-To: <20221006093730.1602342-1-georgmueller@gmx.net> References: <20221006093730.1602342-1-georgmueller@gmx.net> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:fse8ws+lyMC7sHLtVO7qn5Lv3rq6ipdjerC7p5Fp7yXKo8hXzo9 HpkbYsWnhTuRe1RNOt+B2wsFiRx7fubzi3a+QBXs/hPbboLPk1wV2WurN1PO8zIpCSFa9xB zUaOvyjMK/h68MIQjvtZQ/V0TFDf8Vk7fflq+6jfa2OpqKOwQZ6LzNhaeVwSf0ZKSyaZxQP DiAAgLZHOTX90kkW4LLrw== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:IpCtuF8cU1I=:lhjDx3RFc96ayR9F5iyej+ rsD5lgaLwIl747OpqHXj18I9U1GvfS9r172+GyOEBtvjbeKZpBT0dpGUVVMqxoeLTRZnck2yY pR2praFD8++WIk7khOjXAjUBbQAqExNcowzCDm5f3lqsNPkiv8/4geJ2tDp6Su9bMrH9xusAK r377rRLjadmiB40/axcjv2TPTBA9edsUHy9TkZovW9AlDyxa8CLKoNcPEWc32rSffpNKa3PZL pYlux7IcEJWF6le5dXl4ahft4+L9Du+i1ACQb+Jd9r2/SqqKyNd5bx0bqek0UQ44puDfBkxUC tKAsXtF50ipDsHFB5bBR7exef8mY33mEXQFtVLcnuANjkNBUevTjYatFmsexPQlTDkevjSQB/ hgSCjZrWxrJE6kIJPVg00t2iFl/KZV1mzgrYQ0XtpsgiTO1NoPfPawPw1KLz3/VOsDNtagZJr wTvG5h1qCfS7mM0k/LrLUGae/B6dKFPgudJPOl8EfZPj1dNlaqg2GUlR7ycVqustlnUxbCEDv KF0TYEsTA9PiLRQyTgIVT/B+VdR5m4+ZxP6CJJ2Rfu9KT0FGzWkVYTH2FmpP02XjxkBByCClf co6rZrCOfQZa0rWL4v9bKFoSa4FKi0Ls4aVB6wypE+cmK7AZw+g5xDccxgUamtAED57wEZoUG FFYGHA4sEsAfwznsy7n/ZpbjF/AksGSWhV/Mvzd+MIGAt6sesPrd7Vle95D+9g3BHadWfBoix nQVV9Raq8S/xpWmTCPFQX2PV1XUdUkhEkFIFfN2jm3RzvTOaeN3owcXZZ5Thgtaw9yTZOO7nv YjfAKZvwojmaIMdoDFwtfRC3HT8V4VwYGgIe06sQ7ZTD5u7E56dx6hCjSG6l2C229EWzk2t9H Kt9VR3caYFWE62x8J8+hCh/JlnBjvCjnc3aVdQieR0Lb+Z+fPMsGeuMUmtoGYHIYt6S9ulKUb 34V9VaL1S1AlZXItk8NcU4sqwX+s2wDhRyrr6TBP09p80prtlpQt0YZ1Ok1mIqKYdPQtvrm2r CFJuheBpj15zHZwCOK8MjE1K0tV4OBAY9KhfgPjwb1UwaA5t6BbrEisw4GMoOieMkWMsKnczy xLIljEuQ/7UwFhl8T8eShp4cAmmMN6urcX016RsO0jV50VJO2EHyeofML67qNi4KDUhzwOXw8 f3+EYrzW0mMTJxtbaObDSWXAiPZdKkh+9JF1Bdchd4q1vkoEgqzt+FdM9co2EEhUvpW4zzmqr hPUzAgAJ6jeiHNjDH7S6B2k7FPITPbf1+fGsC+4eJ5lKAKd36lZg5vaXNv05R/uWH6/75MX0g ttZ1C4aiJR5/bvunlDiYh8NLvFmEZCJH9qML/CJdbVdYki1Z3/gIoqasn8+LwWbuzsqUyk3XQ mfr2ANo/hHs2GRXuUGcWuZ0EERKUBupM1pp5a1Dn+JPzFC8pHCy9I8HpsByrxlFTyoWUnsJEP fT5jTcyBrMDfESB9Kg3Vb5AshbqGnidpbO+dn2CGU9BBaBrSx8HUXHPByHcwCcu6/yVnNT/Cc WcOi4ssCTlJBYLEs221xN4gIW+B4/oKp6+IQz8BkeatfZ X-Mailman-Approved-At: Sun, 09 Oct 2022 19:07:28 +0200 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org pci_set_dma_mask() and pci_set_consistent_dma_mask() were removed with kernel 5.18. They both were just wrappers for dma_set_mask() and dma_set_coherent_mask(). Instead, use dma_set_mask_and_coherent(), which is a combination of dma_set_mask() and dma_set_coherent_mask(). dma_set_mask_and_coherent() exists since kernel 3.13. Signed-off-by: Georg M=C3=BCller =2D-- v2: - add Signed-off-by =2D-- linux/igb_uio/igb_uio.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/linux/igb_uio/igb_uio.c b/linux/igb_uio/igb_uio.c index 33e0e02..aea67da 100644 =2D-- a/linux/igb_uio/igb_uio.c +++ b/linux/igb_uio/igb_uio.c @@ -512,18 +512,12 @@ igbuio_pci_probe(struct pci_dev *dev, const struct p= ci_device_id *id) goto fail_release_iomem; /* set 64-bit DMA mask */ - err =3D pci_set_dma_mask(dev, DMA_BIT_MASK(64)); + err =3D dma_set_mask_and_coherent(&dev->dev, DMA_BIT_MASK(64)); if (err !=3D 0) { dev_err(&dev->dev, "Cannot set DMA mask\n"); goto fail_release_iomem; } - err =3D pci_set_consistent_dma_mask(dev, DMA_BIT_MASK(64)); - if (err !=3D 0) { - dev_err(&dev->dev, "Cannot set consistent DMA mask\n"); - goto fail_release_iomem; - } - /* fill uio infos */ udev->info.name =3D "igb_uio"; udev->info.version =3D "0.1"; =2D- 2.37.3