From patchwork Mon Oct 16 05:47:47 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 13422522 X-Patchwork-Delegate: geert@linux-m68k.org 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 73EC6CDB465 for ; Mon, 16 Oct 2023 05:48:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229841AbjJPFsY (ORCPT ); Mon, 16 Oct 2023 01:48:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33382 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231770AbjJPFsW (ORCPT ); Mon, 16 Oct 2023 01:48:22 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F0CE6E4; Sun, 15 Oct 2023 22:48:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=RPVFtxbF5hQhoqQwe72Q5ekV/Nn+oUkF+V9bnWf8/qY=; b=3s/GQaxhf5T1tV4r1mrt44XKn+ dTjx2MCGBSGDsab9TBZdJjZyROqt2EDb8UGKnk/OXyQRdIoofI0/+NspXKDzFVJtZN7eGmlYUP5HF oa9H2jCtARohOmceDQZqk3T8+lv9SiRnPhQkBOWr9GgXJV2SC2IDlayWLhU2jn/ULNkTDeGwVbs5C +rZT5hmgfahsNr8tVv+s84nnIaLw9HtEfgRsrc+Dk+hlSccNuyhwNF0fPJKdXmlMG4YBSsJSGI+Kj 04hfLqQcgSCNhcTaT/D7aXv9AkF6szmJo08DrcjZ0mupH71J3WElHTdRKEwKyQ6kEG49s+YKRadEw /i1UiYeg==; Received: from 2a02-8389-2341-5b80-39d3-4735-9a3c-88d8.cable.dynamic.v6.surfer.at ([2a02:8389:2341:5b80:39d3:4735:9a3c:88d8] helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.96 #2 (Red Hat Linux)) id 1qsGSZ-008Qjw-0N; Mon, 16 Oct 2023 05:48:11 +0000 From: Christoph Hellwig To: Greg Ungerer , iommu@lists.linux.dev Cc: Paul Walmsley , Palmer Dabbelt , Conor Dooley , Geert Uytterhoeven , Magnus Damm , Robin Murphy , Marek Szyprowski , Geert Uytterhoeven , Wei Fang , Shenwei Wang , Clark Wang , NXP Linux Team , linux-m68k@lists.linux-m68k.org, netdev@vger.kernel.org, linux-riscv@lists.infradead.org, linux-renesas-soc@vger.kernel.org, Jim Quinlan Subject: [PATCH 05/12] dma-direct: add depdenencies to CONFIG_DMA_GLOBAL_POOL Date: Mon, 16 Oct 2023 07:47:47 +0200 Message-Id: <20231016054755.915155-6-hch@lst.de> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231016054755.915155-1-hch@lst.de> References: <20231016054755.915155-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-renesas-soc@vger.kernel.org CONFIG_DMA_GLOBAL_POOL can't be combined with other DMA coherent allocators. Add dependencies to Kconfig to document this, and make kconfig complain about unment dependencies if someone tries. Signed-off-by: Christoph Hellwig Reviewed-by: Robin Murphy Reviewed-by: Lad Prabhakar --- kernel/dma/Kconfig | 2 ++ 1 file changed, 2 insertions(+) diff --git a/kernel/dma/Kconfig b/kernel/dma/Kconfig index f488997b071712..4524db877eba36 100644 --- a/kernel/dma/Kconfig +++ b/kernel/dma/Kconfig @@ -135,6 +135,8 @@ config DMA_COHERENT_POOL config DMA_GLOBAL_POOL select DMA_DECLARE_COHERENT + depends on !ARCH_HAS_DMA_SET_UNCACHED + depends on !DMA_DIRECT_REMAP bool config DMA_DIRECT_REMAP