From patchwork Fri Oct 16 15:33:41 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robin Murphy X-Patchwork-Id: 7417411 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id CC2A39F36A for ; Fri, 16 Oct 2015 15:36:12 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id EE3722062B for ; Fri, 16 Oct 2015 15:36:11 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 10C80205F0 for ; Fri, 16 Oct 2015 15:36:10 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1Zn71c-0002fZ-NB; Fri, 16 Oct 2015 15:34:32 +0000 Received: from eu-smtp-delivery-143.mimecast.com ([146.101.78.143]) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1Zn71R-0002Md-Gg for linux-arm-kernel@lists.infradead.org; Fri, 16 Oct 2015 15:34:22 +0000 Received: from cam-owa2.Emea.Arm.com (fw-tnat.cambridge.arm.com [217.140.96.140]) by eu-smtp-1.mimecast.com with ESMTP id uk-mta-9-i8dol1AcT_OvvPcMMJWJXQ-1; Fri, 16 Oct 2015 16:33:57 +0100 Received: from e104324-lin.cambridge.arm.com ([10.1.2.79]) by cam-owa2.Emea.Arm.com with Microsoft SMTPSVC(6.0.3790.3959); Fri, 16 Oct 2015 16:33:56 +0100 From: Robin Murphy To: catalin.marinas@arm.com, joro@8bytes.org Subject: [PATCH 1/2] arm64: Workaround renaming of __GFP_WAIT Date: Fri, 16 Oct 2015 16:33:41 +0100 Message-Id: X-Mailer: git-send-email 1.9.1 X-OriginalArrivalTime: 16 Oct 2015 15:33:56.0844 (UTC) FILETIME=[124152C0:01D10828] X-MC-Unique: i8dol1AcT_OvvPcMMJWJXQ-1 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20151016_083421_873396_AED5940D X-CRM114-Status: UNSURE ( 7.64 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -5.2 (-----) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: iommu@lists.linux-foundation.org, Mel Gorman , Andrew Morton , linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The imminent renaming of __GFP_WAIT in the mm tree conflicts with its use in the new IOMMU DMA ops; introduce a temporary local version of its replacement to smooth over the transition. This patch should be reverted at 4.4-rc1. CC: Mel Gorman CC: Andrew Morton Reported-by: Sudeep Holla Signed-off-by: Robin Murphy Acked-by: Catalin Marinas --- Sudeep points out that there are pending changes in -next touching arm64 which I hadn't spotted, which end up breaking the build when merged with my changes in the IOMMU tree. Catalin, would you mind acking these fixes so that Joerg can carry them? We should be able to send the revert through arm64 once the dust has settled. Thanks, Robin. --- arch/arm64/mm/dma-mapping.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/arm64/mm/dma-mapping.c b/arch/arm64/mm/dma-mapping.c index 6320361..66444df 100644 --- a/arch/arm64/mm/dma-mapping.c +++ b/arch/arm64/mm/dma-mapping.c @@ -546,6 +546,10 @@ static void flush_page(struct device *dev, const void *virt, phys_addr_t phys) __dma_flush_range(virt, virt + PAGE_SIZE); } +#ifdef __GFP_WAIT +#define gfpflags_allow_blocking(gfp) ((gfp) & __GFP_WAIT) +#endif + static void *__iommu_alloc_attrs(struct device *dev, size_t size, dma_addr_t *handle, gfp_t gfp, struct dma_attrs *attrs)