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 1B46BC6379F for ; Tue, 21 Feb 2023 12:46:43 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234810AbjBUMql (ORCPT ); Tue, 21 Feb 2023 07:46:41 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43562 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234816AbjBUMqc (ORCPT ); Tue, 21 Feb 2023 07:46:32 -0500 Received: from wout2-smtp.messagingengine.com (wout2-smtp.messagingengine.com [64.147.123.25]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 277F3298F7; Tue, 21 Feb 2023 04:46:29 -0800 (PST) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.west.internal (Postfix) with ESMTP id C17A53200931; Tue, 21 Feb 2023 07:46:27 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Tue, 21 Feb 2023 07:46:28 -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=1676983587; x=1677069987; bh=13 TjcRtfoBgYUAonSXqop4Xu1irhLU8jxIGd4/dBxmQ=; b=q2idsRBqJazuFn72mE 20jDBSb0qMCAnmvgZQ+5TXd2mmJOmBq7/DJo9wgPMXpfZdkMzC9JY5jjjNJ/aVCC kTlkIVMAdrdBlX0JNhNB3DsN/GUFtqBcoMyWUzi/dYTzzhEReZjdXTPs/SJ9yUsu JdfFov/ubH3yO8fTz+m6l6xa2+HISPeXko9M+6Iwvg+KG24BnkK13hMoZ3ON5Jb5 MXsumUkMEsPSAWiBVtdSUPo15H25awi9wj+17CnsodYAS72xE+p1d600D8xBBiUq wZLjIzbWRevh4Z6tITef2rQlaeOn1Ptlr7/AMXgOCC/BBIkRD2QutXFZnYFqz/TL oT0A== 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=1676983587; x=1677069987; bh=13TjcRtfoBgYU AonSXqop4Xu1irhLU8jxIGd4/dBxmQ=; b=h4uH7u6pzpVpFaAI8C3RnTR87tY7C k8HOnLs5JJ1/43cc3BG9jXbWS9hiwzntd64K1QMa7yXHDub5ue2ppM/sSBW2li0a oTDT7hksncFaYcmYWP3dloIOp1sNpxWn85Mz7Zehhbsl5Fc9JuXDRjaLfj/Iw7cq vaCm2VhXPqs04ypGwzzfJdji1/PVJGLez3bo8RRduhpdgbEWH+whsjFOGyLfsP25 axgoAlmQYaRUmwoq2j4XCRuHjH1IP6g+rkfLdkdEL4SSXSU0sen3NB92zcbY8v3D asWqulMzb9/1AJuLawhhX1BJT+Ab6q7OfU7C0GUA53Icea6xGP62v3ieg== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvhedrudejjedggeefucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpefhvfevufffkffojghfggfgsedtke ertdertddtnecuhfhrohhmpeflihgrgihunhcujggrnhhguceojhhirgiguhhnrdihrghn ghesfhhlhihgohgrthdrtghomheqnecuggftrfgrthhtvghrnhepfeeludefheegvdeuvd dvgeekgfdvtdettdelieeihfegtedugeekhfdvhfejfedtnecuvehluhhsthgvrhfuihii vgeptdenucfrrghrrghmpehmrghilhhfrhhomhepjhhirgiguhhnrdihrghnghesfhhlhi hgohgrthdrtghomh X-ME-Proxy: Feedback-ID: ifd894703:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 21 Feb 2023 07:46:25 -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, Jiaxun Yang Subject: [PATCH 2/7] MIPS: Always select ARCH_HAS_SYNC_DMA_FOR_CPU for noncoherent platforms Date: Tue, 21 Feb 2023 12:46:08 +0000 Message-Id: <20230221124613.2859-3-jiaxun.yang@flygoat.com> X-Mailer: git-send-email 2.37.1 (Apple Git-137.1) In-Reply-To: <20230221124613.2859-1-jiaxun.yang@flygoat.com> References: <20230221124613.2859-1-jiaxun.yang@flygoat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org As now we are telling the necessity of post DMA flush per CPU type, there is no need to select ARCH_HAS_SYNC_DMA_FOR_CPU on per platform bias, just select it unconditionally and we can sort it at runtime. Signed-off-by: Jiaxun Yang --- arch/mips/Kconfig | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig index c6f3ad51f741..8da52863da4e 100644 --- a/arch/mips/Kconfig +++ b/arch/mips/Kconfig @@ -115,7 +115,6 @@ config MACH_INGENIC select SYS_SUPPORTS_LITTLE_ENDIAN select SYS_SUPPORTS_ZBOOT select DMA_NONCOHERENT - select ARCH_HAS_SYNC_DMA_FOR_CPU select IRQ_MIPS_CPU select PINCTRL select GPIOLIB @@ -1089,6 +1088,7 @@ config DMA_NONCOHERENT # select ARCH_HAS_DMA_WRITE_COMBINE select ARCH_HAS_DMA_PREP_COHERENT + select ARCH_HAS_SYNC_DMA_FOR_CPU select ARCH_HAS_SYNC_DMA_FOR_DEVICE select ARCH_HAS_DMA_SET_UNCACHED select ARCH_HAS_SETUP_DMA_OPS @@ -1853,11 +1853,9 @@ config SYS_HAS_CPU_MIPS32_R3_5 config SYS_HAS_CPU_MIPS32_R5 bool - select ARCH_HAS_SYNC_DMA_FOR_CPU if DMA_NONCOHERENT config SYS_HAS_CPU_MIPS32_R6 bool - select ARCH_HAS_SYNC_DMA_FOR_CPU if DMA_NONCOHERENT config SYS_HAS_CPU_MIPS64_R1 bool @@ -1867,15 +1865,12 @@ config SYS_HAS_CPU_MIPS64_R2 config SYS_HAS_CPU_MIPS64_R5 bool - select ARCH_HAS_SYNC_DMA_FOR_CPU if DMA_NONCOHERENT config SYS_HAS_CPU_MIPS64_R6 bool - select ARCH_HAS_SYNC_DMA_FOR_CPU if DMA_NONCOHERENT config SYS_HAS_CPU_P5600 bool - select ARCH_HAS_SYNC_DMA_FOR_CPU if DMA_NONCOHERENT config SYS_HAS_CPU_R3000 bool @@ -1900,7 +1895,6 @@ config SYS_HAS_CPU_NEVADA config SYS_HAS_CPU_R10000 bool - select ARCH_HAS_SYNC_DMA_FOR_CPU if DMA_NONCOHERENT config SYS_HAS_CPU_RM7000 bool @@ -1929,7 +1923,6 @@ config SYS_HAS_CPU_BMIPS4380 config SYS_HAS_CPU_BMIPS5000 bool select SYS_HAS_CPU_BMIPS - select ARCH_HAS_SYNC_DMA_FOR_CPU # # CPU may reorder R->R, R->W, W->R, W->W -- 2.37.1 (Apple Git-137.1)