From patchwork Wed Feb 21 19:40:30 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Suren Baghdasaryan X-Patchwork-Id: 13566197 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 43343C5478A for ; Wed, 21 Feb 2024 19:41:47 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 7E15C6B00A9; Wed, 21 Feb 2024 14:41:36 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 6EFA56B00AA; Wed, 21 Feb 2024 14:41:36 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4F04C6B00AB; Wed, 21 Feb 2024 14:41:36 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id 31D3A6B00A9 for ; Wed, 21 Feb 2024 14:41:36 -0500 (EST) Received: from smtpin28.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id 11D09A0E1E for ; Wed, 21 Feb 2024 19:41:36 +0000 (UTC) X-FDA: 81816830592.28.D9CD414 Received: from mail-yw1-f202.google.com (mail-yw1-f202.google.com [209.85.128.202]) by imf01.hostedemail.com (Postfix) with ESMTP id 75C0240006 for ; Wed, 21 Feb 2024 19:41:34 +0000 (UTC) Authentication-Results: imf01.hostedemail.com; dkim=pass header.d=google.com header.s=20230601 header.b=TtLMBXbr; dmarc=pass (policy=reject) header.from=google.com; spf=pass (imf01.hostedemail.com: domain of 37VHWZQYKCCAOQNAJ7CKKCHA.8KIHEJQT-IIGR68G.KNC@flex--surenb.bounces.google.com designates 209.85.128.202 as permitted sender) smtp.mailfrom=37VHWZQYKCCAOQNAJ7CKKCHA.8KIHEJQT-IIGR68G.KNC@flex--surenb.bounces.google.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1708544494; a=rsa-sha256; cv=none; b=gofJvR+atsMMpCsfS6qDiRxKSQETaeJQViU9Jx0wp8xHZg1xZgu6NaIbt0xg9YLqOPenpt WtZZWArxxiCUmESsemtxekcZwG0IEVJ1Sm0uqUGPCmbpK3iKcJxbvcAg8jva4fgSaVa1dR nl3l4OGaPBzXICevHy/NKdf6lMCapKc= ARC-Authentication-Results: i=1; imf01.hostedemail.com; dkim=pass header.d=google.com header.s=20230601 header.b=TtLMBXbr; dmarc=pass (policy=reject) header.from=google.com; spf=pass (imf01.hostedemail.com: domain of 37VHWZQYKCCAOQNAJ7CKKCHA.8KIHEJQT-IIGR68G.KNC@flex--surenb.bounces.google.com designates 209.85.128.202 as permitted sender) smtp.mailfrom=37VHWZQYKCCAOQNAJ7CKKCHA.8KIHEJQT-IIGR68G.KNC@flex--surenb.bounces.google.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1708544494; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=/ICmwOELDDa5gDiXJ0QfSPYNwNSjuLTkQBKISvcVpvE=; b=SDz38ZASuL++DXwfYSmBy8IrBYkL2g4gMnYsoDXnwKxqvOdxAsycFlhRAxJzbyORn+QVUz drPEebgsPyT05QJf5Mzk7J6L/BS/Yajc4kGK4ds9nFFp7WwjRcfgo5ctXeMrVkvWKUQjw8 OrZVxKj7CmF8dgr6E69qZHN2kPyeKh8= Received: by mail-yw1-f202.google.com with SMTP id 00721157ae682-6088fa18619so9940217b3.2 for ; Wed, 21 Feb 2024 11:41:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1708544493; x=1709149293; darn=kvack.org; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:from:to:cc:subject:date:message-id:reply-to; bh=/ICmwOELDDa5gDiXJ0QfSPYNwNSjuLTkQBKISvcVpvE=; b=TtLMBXbrd7N8l7eIMduJcAMJjRTAunAoYwtKB6wzK9PK5vKzxEIZ7md9xi9yDW+AZE H1hJES4gv0DVhI8O8UAOmQABucsqQ1FzY6128rwyV5k1U/IOU3zkkJE5vwP8yuGpIGPo nAYfCF2LiSzu4LQF39QPP/1QIVUvdGYBTjxpwMsC6RW6NtZ8rrwnLyTc6vJkLL5QwGzw FhRh9n2MC2yC9d0/LrJqi7U5Eca6tEZiQ3Zapmc+jfGxXWbSYaRDSUHnipvF7B9M/Q+6 8UGswJW/FIv6Jv9Dl9S5rR1EKPixG2J3SrSniyUH2QkVFSx2OWdKyH/e13ixhvlNcLvU saRA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708544493; x=1709149293; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=/ICmwOELDDa5gDiXJ0QfSPYNwNSjuLTkQBKISvcVpvE=; b=i1ZUCXfatNR+YwNOkPwRSXTtPUE3LZdG4p7NT6CkIV/90bbOlZj5lE+ocyuM/pmyyp cByPdWHKm6JpfRQ3/4oDn77zitTbJm8b+Xa0KnlmPJ7r4GH6bqBy1u9aCTAUdpG98WFL hxsc4rAsIImAn0C1YWRi6sYaRTpaWij3uMD3i0+DR+HptTh7qFv4BqppyN/3ENMQwyL/ wxLs945KEFGhsRBE2nW+mZl94eY8Y59r0u2P+Vnj/xXNWNr6w5NaL6Z5RwNYjwAxrGye Fq0tAZmggd/CSAd07fMOAs/kYPORCQ3COwnh5KjVtE/CBpKA3pFE4jKjStkqW1vM+4aa WsSQ== X-Forwarded-Encrypted: i=1; AJvYcCWKWHQCCOkr9vSpvDe7rS103DPpTN1IvExRXGg2+qDv5AOp99YRBnreKT2VB2XMCzF13YmLYKU40QqqPLjvhuP9eqs= X-Gm-Message-State: AOJu0YwRXj0IbcGMcdfIeExyUbplc4Gbk/A7cvj960Y5X2mHrHApSaxO tpgKsYeylNo73WdLzraTbUfaLSTZbIMHyaqgUZ3yDyBP3Uag4Fd7qGKZ2XjdAFm7IXwUGKmlAJW 0WQ== X-Google-Smtp-Source: AGHT+IFRKkAzXFrqX8FMuNNkdeozK6lGgluj6VzXaaQV6asduSfbKwLn9SW2CaQIMM08vePlCmcgUKW9cG4= X-Received: from surenb-desktop.mtv.corp.google.com ([2620:15c:211:201:953b:9a4e:1e10:3f07]) (user=surenb job=sendgmr) by 2002:a81:ab4c:0:b0:608:2137:27f6 with SMTP id d12-20020a81ab4c000000b00608213727f6mr2122409ywk.5.1708544493446; Wed, 21 Feb 2024 11:41:33 -0800 (PST) Date: Wed, 21 Feb 2024 11:40:30 -0800 In-Reply-To: <20240221194052.927623-1-surenb@google.com> Mime-Version: 1.0 References: <20240221194052.927623-1-surenb@google.com> X-Mailer: git-send-email 2.44.0.rc0.258.g7320e95886-goog Message-ID: <20240221194052.927623-18-surenb@google.com> Subject: [PATCH v4 17/36] change alloc_pages name in dma_map_ops to avoid name conflicts From: Suren Baghdasaryan To: akpm@linux-foundation.org Cc: kent.overstreet@linux.dev, mhocko@suse.com, vbabka@suse.cz, hannes@cmpxchg.org, roman.gushchin@linux.dev, mgorman@suse.de, dave@stgolabs.net, willy@infradead.org, liam.howlett@oracle.com, penguin-kernel@i-love.sakura.ne.jp, corbet@lwn.net, void@manifault.com, peterz@infradead.org, juri.lelli@redhat.com, catalin.marinas@arm.com, will@kernel.org, arnd@arndb.de, tglx@linutronix.de, mingo@redhat.com, dave.hansen@linux.intel.com, x86@kernel.org, peterx@redhat.com, david@redhat.com, axboe@kernel.dk, mcgrof@kernel.org, masahiroy@kernel.org, nathan@kernel.org, dennis@kernel.org, tj@kernel.org, muchun.song@linux.dev, rppt@kernel.org, paulmck@kernel.org, pasha.tatashin@soleen.com, yosryahmed@google.com, yuzhao@google.com, dhowells@redhat.com, hughd@google.com, andreyknvl@gmail.com, keescook@chromium.org, ndesaulniers@google.com, vvvvvv@google.com, gregkh@linuxfoundation.org, ebiggers@google.com, ytcoode@gmail.com, vincent.guittot@linaro.org, dietmar.eggemann@arm.com, rostedt@goodmis.org, bsegall@google.com, bristot@redhat.com, vschneid@redhat.com, cl@linux.com, penberg@kernel.org, iamjoonsoo.kim@lge.com, 42.hyeyoo@gmail.com, glider@google.com, elver@google.com, dvyukov@google.com, shakeelb@google.com, songmuchun@bytedance.com, jbaron@akamai.com, rientjes@google.com, minchan@google.com, kaleshsingh@google.com, surenb@google.com, kernel-team@android.com, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, iommu@lists.linux.dev, linux-arch@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, linux-modules@vger.kernel.org, kasan-dev@googlegroups.com, cgroups@vger.kernel.org X-Rspam-User: X-Rspamd-Server: rspam06 X-Rspamd-Queue-Id: 75C0240006 X-Stat-Signature: r7htdycx6n4ezffygha9yb7p6kqhxij4 X-HE-Tag: 1708544494-540020 X-HE-Meta: U2FsdGVkX18oWemGw1EmYipay/MYPbCYxkdz0xFFK2g1Lbh4I1rGyp89aoYjL6zJL0pGuPib6XLpBdnDtYPMMbGJF/Kmwyncl/4McK10I7gvgrgXAwmfCFeWNBsiKaYTUgex4bq0d7WDrevHkpOslZBgxveceFX8XZPWq+IOMwdG+17a+dQnugk5PaVSnpT5JJJHmRDpgt0RIQF4isYoCNqMWdUnoixWgyaK8PU6DCpn3JmszUufDhltAqaMNq2ZTdkQFt7Bwejt3Q+ZVdD0vOtwCUlk2nNn7snILiv16A67rZu//nHz5SLymXFIHzCJNfibbxm5iK9k+/hYfR5J2cCOU/LfkNkhq2jfoeG3OAZD03NusWr8bEQBqdZGxOclyQrkEAieAxUc84HCRUNhdVFa98b4kmmoRR8tdx7CvBkAfL/lxC2iOtqTkFom/D/Y0cl7FzuYjF/wMCtni0TPP5m0OpmXmJkxnbwhvXbBJWGjclZJTvaKHRsh2NtQKFOVtKDq9VtCOVisG8F9xRFX4w7FI9+YegCLlzoqTIxiC+I0tYvnXngxEWJiRAIf3zAAKoJ4slU/f6p/++u+FU9O7LCgQEt5a7xWdsRQwDBJmu8V0143TRnP1aIEB+fLtgVH2ClWppt6DKSTLw/ArdE8rvA2n5uqJSV86GeT4dh+BJ2UCglPF2ihUg9UwpdMu1j4VCbgLkO3GOM1VwnUcJRR5iL6kK1yqOcA2j+eLeF5m4GdL9sgEvsqZy1Yd28E3vGuU4ew418jwSQnOtRlf9QmExeg4MZWltelBu59gmUJ7pZbU2MIEJ7EUB53gSbtsANF/QvJsM4bTOhdUfcCVIzp4JaOtEyWTpz+cUbhiDThLFxUUzE1kSQk6plhMOmig1507PUGs4YNrHGCO849U/Oej5wZ2ToFu8i4A7NuP97Jivd6Hlib4s1039HxGFLRmdg0IlafAsYgXvolBW0DN9N hHEj8mB6 0svlAtDzvDULn9965uVg0I0vkyy7zXu0rd9vb/QjKPMCDisvnN4HWyR4A8KnDYz9bRLOKlLF3Qf0MQjQlIbFkdQlcbvHFR5stH69Q00UvaqhrKNVWxEL58vIXWUnO7o9j3fXYAeq9omZvOpK0VCwwW9yWzKp7ijFXxvPjc2vAhzUrpXxMmbISV8V2Op0dPE/8psE5NRRIZShi3YelOcFR46dV4MV7ozxEOTOW2f9PZ6Hvphv6PbCoytayi82uQbPivM4F+y8fUIFJX9CWlcejXtsxYp+FZ5S50RhFy5w4lYhTldsua/lcyL3J7OOlNgGMsmFlYe6mzGzo7xMTXAOSuqt9RnFYrvl/3gFiWnAqPwQoyhL14cezT0U/FWEkf1S/si4gd1RkWQFB7/StgokNjuveYFa9qwhOD8Eq7e+Q7prmp3W/OcYZCN2AmHXNLIDQBqCDDJ8aneZLfvvbOqxnTCkLKA== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: After redefining alloc_pages, all uses of that name are being replaced. Change the conflicting names to prevent preprocessor from replacing them when it's not intended. Signed-off-by: Suren Baghdasaryan --- arch/alpha/kernel/pci_iommu.c | 2 +- arch/mips/jazz/jazzdma.c | 2 +- arch/powerpc/kernel/dma-iommu.c | 2 +- arch/powerpc/platforms/ps3/system-bus.c | 4 ++-- arch/powerpc/platforms/pseries/vio.c | 2 +- arch/x86/kernel/amd_gart_64.c | 2 +- drivers/iommu/dma-iommu.c | 2 +- drivers/parisc/ccio-dma.c | 2 +- drivers/parisc/sba_iommu.c | 2 +- drivers/xen/grant-dma-ops.c | 2 +- drivers/xen/swiotlb-xen.c | 2 +- include/linux/dma-map-ops.h | 2 +- kernel/dma/mapping.c | 4 ++-- 13 files changed, 15 insertions(+), 15 deletions(-) diff --git a/arch/alpha/kernel/pci_iommu.c b/arch/alpha/kernel/pci_iommu.c index c81183935e97..7fcf3e9b7103 100644 --- a/arch/alpha/kernel/pci_iommu.c +++ b/arch/alpha/kernel/pci_iommu.c @@ -929,7 +929,7 @@ const struct dma_map_ops alpha_pci_ops = { .dma_supported = alpha_pci_supported, .mmap = dma_common_mmap, .get_sgtable = dma_common_get_sgtable, - .alloc_pages = dma_common_alloc_pages, + .alloc_pages_op = dma_common_alloc_pages, .free_pages = dma_common_free_pages, }; EXPORT_SYMBOL(alpha_pci_ops); diff --git a/arch/mips/jazz/jazzdma.c b/arch/mips/jazz/jazzdma.c index eabddb89d221..c97b089b9902 100644 --- a/arch/mips/jazz/jazzdma.c +++ b/arch/mips/jazz/jazzdma.c @@ -617,7 +617,7 @@ const struct dma_map_ops jazz_dma_ops = { .sync_sg_for_device = jazz_dma_sync_sg_for_device, .mmap = dma_common_mmap, .get_sgtable = dma_common_get_sgtable, - .alloc_pages = dma_common_alloc_pages, + .alloc_pages_op = dma_common_alloc_pages, .free_pages = dma_common_free_pages, }; EXPORT_SYMBOL(jazz_dma_ops); diff --git a/arch/powerpc/kernel/dma-iommu.c b/arch/powerpc/kernel/dma-iommu.c index 8920862ffd79..f0ae39e77e37 100644 --- a/arch/powerpc/kernel/dma-iommu.c +++ b/arch/powerpc/kernel/dma-iommu.c @@ -216,6 +216,6 @@ const struct dma_map_ops dma_iommu_ops = { .get_required_mask = dma_iommu_get_required_mask, .mmap = dma_common_mmap, .get_sgtable = dma_common_get_sgtable, - .alloc_pages = dma_common_alloc_pages, + .alloc_pages_op = dma_common_alloc_pages, .free_pages = dma_common_free_pages, }; diff --git a/arch/powerpc/platforms/ps3/system-bus.c b/arch/powerpc/platforms/ps3/system-bus.c index d6b5f5ecd515..56dc6b29a3e7 100644 --- a/arch/powerpc/platforms/ps3/system-bus.c +++ b/arch/powerpc/platforms/ps3/system-bus.c @@ -695,7 +695,7 @@ static const struct dma_map_ops ps3_sb_dma_ops = { .unmap_page = ps3_unmap_page, .mmap = dma_common_mmap, .get_sgtable = dma_common_get_sgtable, - .alloc_pages = dma_common_alloc_pages, + .alloc_pages_op = dma_common_alloc_pages, .free_pages = dma_common_free_pages, }; @@ -709,7 +709,7 @@ static const struct dma_map_ops ps3_ioc0_dma_ops = { .unmap_page = ps3_unmap_page, .mmap = dma_common_mmap, .get_sgtable = dma_common_get_sgtable, - .alloc_pages = dma_common_alloc_pages, + .alloc_pages_op = dma_common_alloc_pages, .free_pages = dma_common_free_pages, }; diff --git a/arch/powerpc/platforms/pseries/vio.c b/arch/powerpc/platforms/pseries/vio.c index 2dc9cbc4bcd8..0c90fc4c3796 100644 --- a/arch/powerpc/platforms/pseries/vio.c +++ b/arch/powerpc/platforms/pseries/vio.c @@ -611,7 +611,7 @@ static const struct dma_map_ops vio_dma_mapping_ops = { .get_required_mask = dma_iommu_get_required_mask, .mmap = dma_common_mmap, .get_sgtable = dma_common_get_sgtable, - .alloc_pages = dma_common_alloc_pages, + .alloc_pages_op = dma_common_alloc_pages, .free_pages = dma_common_free_pages, }; diff --git a/arch/x86/kernel/amd_gart_64.c b/arch/x86/kernel/amd_gart_64.c index 2ae98f754e59..c884deca839b 100644 --- a/arch/x86/kernel/amd_gart_64.c +++ b/arch/x86/kernel/amd_gart_64.c @@ -676,7 +676,7 @@ static const struct dma_map_ops gart_dma_ops = { .get_sgtable = dma_common_get_sgtable, .dma_supported = dma_direct_supported, .get_required_mask = dma_direct_get_required_mask, - .alloc_pages = dma_direct_alloc_pages, + .alloc_pages_op = dma_direct_alloc_pages, .free_pages = dma_direct_free_pages, }; diff --git a/drivers/iommu/dma-iommu.c b/drivers/iommu/dma-iommu.c index 50ccc4f1ef81..8a1f7f5d1bca 100644 --- a/drivers/iommu/dma-iommu.c +++ b/drivers/iommu/dma-iommu.c @@ -1710,7 +1710,7 @@ static const struct dma_map_ops iommu_dma_ops = { .flags = DMA_F_PCI_P2PDMA_SUPPORTED, .alloc = iommu_dma_alloc, .free = iommu_dma_free, - .alloc_pages = dma_common_alloc_pages, + .alloc_pages_op = dma_common_alloc_pages, .free_pages = dma_common_free_pages, .alloc_noncontiguous = iommu_dma_alloc_noncontiguous, .free_noncontiguous = iommu_dma_free_noncontiguous, diff --git a/drivers/parisc/ccio-dma.c b/drivers/parisc/ccio-dma.c index 9ce0d20a6c58..feef537257d0 100644 --- a/drivers/parisc/ccio-dma.c +++ b/drivers/parisc/ccio-dma.c @@ -1022,7 +1022,7 @@ static const struct dma_map_ops ccio_ops = { .map_sg = ccio_map_sg, .unmap_sg = ccio_unmap_sg, .get_sgtable = dma_common_get_sgtable, - .alloc_pages = dma_common_alloc_pages, + .alloc_pages_op = dma_common_alloc_pages, .free_pages = dma_common_free_pages, }; diff --git a/drivers/parisc/sba_iommu.c b/drivers/parisc/sba_iommu.c index 784037837f65..fc3863c09f83 100644 --- a/drivers/parisc/sba_iommu.c +++ b/drivers/parisc/sba_iommu.c @@ -1090,7 +1090,7 @@ static const struct dma_map_ops sba_ops = { .map_sg = sba_map_sg, .unmap_sg = sba_unmap_sg, .get_sgtable = dma_common_get_sgtable, - .alloc_pages = dma_common_alloc_pages, + .alloc_pages_op = dma_common_alloc_pages, .free_pages = dma_common_free_pages, }; diff --git a/drivers/xen/grant-dma-ops.c b/drivers/xen/grant-dma-ops.c index 76f6f26265a3..29257d2639db 100644 --- a/drivers/xen/grant-dma-ops.c +++ b/drivers/xen/grant-dma-ops.c @@ -282,7 +282,7 @@ static int xen_grant_dma_supported(struct device *dev, u64 mask) static const struct dma_map_ops xen_grant_dma_ops = { .alloc = xen_grant_dma_alloc, .free = xen_grant_dma_free, - .alloc_pages = xen_grant_dma_alloc_pages, + .alloc_pages_op = xen_grant_dma_alloc_pages, .free_pages = xen_grant_dma_free_pages, .mmap = dma_common_mmap, .get_sgtable = dma_common_get_sgtable, diff --git a/drivers/xen/swiotlb-xen.c b/drivers/xen/swiotlb-xen.c index 0e6c6c25d154..1c4ef5111651 100644 --- a/drivers/xen/swiotlb-xen.c +++ b/drivers/xen/swiotlb-xen.c @@ -403,7 +403,7 @@ const struct dma_map_ops xen_swiotlb_dma_ops = { .dma_supported = xen_swiotlb_dma_supported, .mmap = dma_common_mmap, .get_sgtable = dma_common_get_sgtable, - .alloc_pages = dma_common_alloc_pages, + .alloc_pages_op = dma_common_alloc_pages, .free_pages = dma_common_free_pages, .max_mapping_size = swiotlb_max_mapping_size, }; diff --git a/include/linux/dma-map-ops.h b/include/linux/dma-map-ops.h index 4abc60f04209..9ee319851b5f 100644 --- a/include/linux/dma-map-ops.h +++ b/include/linux/dma-map-ops.h @@ -29,7 +29,7 @@ struct dma_map_ops { unsigned long attrs); void (*free)(struct device *dev, size_t size, void *vaddr, dma_addr_t dma_handle, unsigned long attrs); - struct page *(*alloc_pages)(struct device *dev, size_t size, + struct page *(*alloc_pages_op)(struct device *dev, size_t size, dma_addr_t *dma_handle, enum dma_data_direction dir, gfp_t gfp); void (*free_pages)(struct device *dev, size_t size, struct page *vaddr, diff --git a/kernel/dma/mapping.c b/kernel/dma/mapping.c index 58db8fd70471..5e2d51e1cdf6 100644 --- a/kernel/dma/mapping.c +++ b/kernel/dma/mapping.c @@ -570,9 +570,9 @@ static struct page *__dma_alloc_pages(struct device *dev, size_t size, size = PAGE_ALIGN(size); if (dma_alloc_direct(dev, ops)) return dma_direct_alloc_pages(dev, size, dma_handle, dir, gfp); - if (!ops->alloc_pages) + if (!ops->alloc_pages_op) return NULL; - return ops->alloc_pages(dev, size, dma_handle, dir, gfp); + return ops->alloc_pages_op(dev, size, dma_handle, dir, gfp); } struct page *dma_alloc_pages(struct device *dev, size_t size,