Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp1478551rwd; Tue, 13 Jun 2023 09:36:07 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4KwrzLqxVm5opyOBQ9BStAxEyXyIffgRSCEQJ2NYakHM3KOYY0YcCctA1xGyJrjXCPF8ay X-Received: by 2002:a17:90b:891:b0:25c:1b70:50a3 with SMTP id bj17-20020a17090b089100b0025c1b7050a3mr1589282pjb.39.1686674166992; Tue, 13 Jun 2023 09:36:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686674166; cv=none; d=google.com; s=arc-20160816; b=zFc+pVjGzysi5IZb8cibE8ycD7kZgzYQa9sMCKQMjnCu2M4wHPNtTegT4+I4CFH1NO DN9iQkjWwgB4V/Y6XxmDJcrUXH455ivOpBiO0xGEDVOL9kwKYseo9mYWX1N6Svnvk06H AoFGxJHA08PEx4jnM0z4mJoHzER14DjVZzTtlKRX5gKrLUQ08+D98Ls66ScdQ8eQ584a ZTpYaHTfvZJikt2x+pjLOW4OFwzAMCNKShvLN4ATIr+XVM4XPsg9k+wgi6fiv0IDcIFz Bogv3Pd/1ZTtYyAEDbGC0mak3vYJ79X+P6iHuc6+dz4cVvfCosPqzpU5exBks8zF5Cve eGnQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=GQw0wiRGcXa018XfRxaZD8PocHePtgjx9k7inQODNY4=; b=OPBJHFADyTXAT0Y+dI0N+lbHPdqLKeIl/uMpLYa3MYiK9/e46RL7Jb9RQfVN+sDEWv XrlMFctPNb962UdmhT12NXwNbfs1GECFgjCcFzJ5lboLxvc3FcMlAEXP/nmdIAqWuxjd eYOl1doqmpisCip57J9TIizfhSE750H7mOvFkQjWg8j+YyRLrDqM3VJdqgOnidlszU+q niSwhcnb0bx+mVIYDR/PyMCMmE0pD5FWQpXbk+Maa9cO5S/RbuN6iKEg1m/LqkxYNFcb O5PexuRQKr54C3ZKdLKockzxGBvNWfvUgpk0Vk6fVSmYaGobj49Epd9xuitVAO3T6ZiF vc0g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a4-20020a17090a854400b00258cb09c4a8si368052pjw.71.2023.06.13.09.35.54; Tue, 13 Jun 2023 09:36:06 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242847AbjFMPxC (ORCPT + 99 others); Tue, 13 Jun 2023 11:53:02 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33296 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242807AbjFMPxB (ORCPT ); Tue, 13 Jun 2023 11:53:01 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3BEB91BC; Tue, 13 Jun 2023 08:53:00 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id F2FCB61F1E; Tue, 13 Jun 2023 15:52:58 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2F14CC433F0; Tue, 13 Jun 2023 15:52:56 +0000 (UTC) From: Catalin Marinas To: Andrew Morton Cc: Linus Torvalds , Vlastimil Babka , Michael Ellerman , Nicholas Piggin , Christophe Leroy , Michal Simek , Yoshinori Sato , Rich Felker , John Paul Adrian Glaubitz , linuxppc-dev@lists.ozlabs.org, linux-sh@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 3/3] sh: Move the ARCH_DMA_MINALIGN definition to asm/cache.h Date: Tue, 13 Jun 2023 16:52:45 +0100 Message-Id: <20230613155245.1228274-4-catalin.marinas@arm.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230613155245.1228274-1-catalin.marinas@arm.com> References: <20230613155245.1228274-1-catalin.marinas@arm.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-6.7 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,RCVD_IN_DNSWL_HI,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The sh architecture defines ARCH_DMA_MINALIGN in asm/page.h. Move it to asm/cache.h to allow a generic ARCH_DMA_MINALIGN definition in linux/cache.h without redefine errors/warnings. Signed-off-by: Catalin Marinas Cc: Yoshinori Sato Cc: Rich Felker Cc: John Paul Adrian Glaubitz Cc: linux-sh@vger.kernel.org --- arch/sh/include/asm/cache.h | 6 ++++++ arch/sh/include/asm/page.h | 6 ------ 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/arch/sh/include/asm/cache.h b/arch/sh/include/asm/cache.h index 32dfa6b82ec6..b38dbc975581 100644 --- a/arch/sh/include/asm/cache.h +++ b/arch/sh/include/asm/cache.h @@ -14,6 +14,12 @@ #define L1_CACHE_BYTES (1 << L1_CACHE_SHIFT) +/* + * Some drivers need to perform DMA into kmalloc'ed buffers + * and so we have to increase the kmalloc minalign for this. + */ +#define ARCH_DMA_MINALIGN L1_CACHE_BYTES + #define __read_mostly __section(".data..read_mostly") #ifndef __ASSEMBLY__ diff --git a/arch/sh/include/asm/page.h b/arch/sh/include/asm/page.h index 09ac6c7faee0..62f4b9edcb98 100644 --- a/arch/sh/include/asm/page.h +++ b/arch/sh/include/asm/page.h @@ -174,10 +174,4 @@ typedef struct page *pgtable_t; #include #include -/* - * Some drivers need to perform DMA into kmalloc'ed buffers - * and so we have to increase the kmalloc minalign for this. - */ -#define ARCH_DMA_MINALIGN L1_CACHE_BYTES - #endif /* __ASM_SH_PAGE_H */