From patchwork Thu Feb 23 11:36:43 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jiaxun Yang X-Patchwork-Id: 13150155 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 C0B2FC636D7 for ; Thu, 23 Feb 2023 11:37:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232906AbjBWLh1 (ORCPT ); Thu, 23 Feb 2023 06:37:27 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39706 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233136AbjBWLhY (ORCPT ); Thu, 23 Feb 2023 06:37:24 -0500 Received: from wout2-smtp.messagingengine.com (wout2-smtp.messagingengine.com [64.147.123.25]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 57D484FA9D; Thu, 23 Feb 2023 03:37:16 -0800 (PST) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.west.internal (Postfix) with ESMTP id D315132002FB; Thu, 23 Feb 2023 06:37:14 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Thu, 23 Feb 2023 06:37:15 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=flygoat.com; h= cc:cc:content-transfer-encoding:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:sender :subject:subject:to:to; s=fm2; t=1677152234; x=1677238634; bh=8m UR23YSfnzS5f2Sho2VGrnO7EOIakJTH1aJiVvcX4g=; b=MtlIEOyo2nFTnHdLQp dkn7SHXD1uEN0v6d6tQbepVtWDYYP41xWbaa7BTENRIprcmg2Y2OyC04nCuDQSAG dS6dpm85OOtRiQHFgTAF4AGNgct7Q+Ou71OkGeeqUoifYqITkhieKE1PMA4AX20d lUA2Yl7rIeHvtZGv0QSpBMXe9vuw1tMFX7BwpYrjKAzdOA2Ev7QSA+4oyGw5Zfri +P2wjgdMHKDGoSIZ1zhFQ1ZTwdeNuaS7SY2iaUO21vkVGae3icqRxgcERzg8Vg3v uIawxLTn0DY8Qv4ZVGbG/06Xt7ClH9vSyaQlDfnBQeLaJP7keJklT/BDWSegguDC Wh+A== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:sender:subject :subject:to:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; t=1677152234; x=1677238634; bh=8mUR23YSfnzS5 f2Sho2VGrnO7EOIakJTH1aJiVvcX4g=; b=LQCMTotu/E41oSCGDrRDpZ3Oc5Y8s SF5SbZS5pGNcwFJ8h48MjZmoaJKerIvZxuqQje+r0NITpQTjfNamhBSwZteQSma2 YEf0fz56AzyScFyPkiVcjmvtqr3oqh7yIfKKr+vnxfdDkxQbnA8bb1+QxBBL3DsN hOePbbLm+Qap05ACTHyO1wA3hPzNgZTQl8N9shM5zmxq858iBplLmtWaqkAYUols BQgiMOgdi0Twh/lTZg8e/9w5o5Lfps4rBmijMMKn3yQLX5ij70ZjWOCEsioDR6eF hoL39aUZdj5yEbFSRGCg0R8WAmnxoW+yt/KbXw/aTWY4chK2cmCKpw60Q== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvhedrudekuddgvdelucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpefhvfevufffkffojghfggfgsedtke ertdertddtnecuhfhrohhmpeflihgrgihunhcujggrnhhguceojhhirgiguhhnrdihrghn ghesfhhlhihgohgrthdrtghomheqnecuggftrfgrthhtvghrnhepfeeludefheegvdeuvd dvgeekgfdvtdettdelieeihfegtedugeekhfdvhfejfedtnecuvehluhhsthgvrhfuihii vgepudenucfrrghrrghmpehmrghilhhfrhhomhepjhhirgiguhhnrdihrghnghesfhhlhi hgohgrthdrtghomh X-ME-Proxy: Feedback-ID: ifd894703:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 23 Feb 2023 06:37:12 -0500 (EST) From: Jiaxun Yang To: linux-mips@vger.kernel.org Cc: linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, tsbogend@alpha.franken.de, mpe@ellerman.id.au, paul.walmsley@sifive.com, palmer@dabbelt.com, robh+dt@kernel.org, hch@lst.de, m.szyprowski@samsung.com, robin.murphy@arm.com, linux-riscv@lists.infradead.org, Jiaxun Yang Subject: [PATCH v2 4/5] riscv: Select ARCH_DMA_DEFAULT_COHERENT Date: Thu, 23 Feb 2023 11:36:43 +0000 Message-Id: <20230223113644.23356-5-jiaxun.yang@flygoat.com> X-Mailer: git-send-email 2.37.1 (Apple Git-137.1) In-Reply-To: <20230223113644.23356-1-jiaxun.yang@flygoat.com> References: <20230223113644.23356-1-jiaxun.yang@flygoat.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-mips@vger.kernel.org For riscv our assumption is unless a device states it is non-coherent, we take it to be DMA coherent. Select ARCH_DMA_DEFAULT_COHERENT to ensure dma_default_coherent is always initialized to true. Signed-off-by: Jiaxun Yang Reviewed-by: Palmer Dabbelt Acked-by: Palmer Dabbelt --- arch/riscv/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/riscv/Kconfig b/arch/riscv/Kconfig index 1d46a268ce16..b71ce992c0c0 100644 --- a/arch/riscv/Kconfig +++ b/arch/riscv/Kconfig @@ -233,6 +233,7 @@ config LOCKDEP_SUPPORT config RISCV_DMA_NONCOHERENT bool + select ARCH_DMA_DEFAULT_COHERENT select ARCH_HAS_DMA_PREP_COHERENT select ARCH_HAS_SETUP_DMA_OPS select ARCH_HAS_SYNC_DMA_FOR_CPU