Received: by 10.223.164.202 with SMTP id h10csp4688506wrb; Wed, 29 Nov 2017 10:11:21 -0800 (PST) X-Google-Smtp-Source: AGs4zMZs3pHsNhoja8yCf7CHo6Zt3jodmwZwqOfi5Hb3h9415susTYTI+n0bF4Bpx9shLgygc6Gv X-Received: by 10.99.55.92 with SMTP id g28mr3651922pgn.293.1511979081700; Wed, 29 Nov 2017 10:11:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1511979081; cv=none; d=google.com; s=arc-20160816; b=CEKSYGt+NP3CGrYU4SDkA7Yt/o8x7VRHS+nWeTo0WHOV+xnMALA7sUWPBybz+WaCWu P+DlQvimJcWW/o6tWgbQFYx6P1C41Hy27LIyxyb2EcOoGv+rvf8fwiEyK9pdsBHibrq+ Wqx7HCsqdCoEuAXsqZStIQuVI2gX4BKmcprlE+ahtDtFtd3BAFZeQnIs7sWTd8lGprRP Xr3NGmdKuc9ON6W3IJHQDXEnEUEEvL8c0WKgBwNNC9uFcFFet8yTZ3cKLXAyuJ1781ws u2hHHg+Y9Qs+k28SYIAtvkUeHYYW2ZadS0HBN/d7wmdb0ruWZwl/+JGFr/q4M4q6h9OM DAKA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature :arc-authentication-results; bh=qL3MA7fMORp337IUOFqAcp9jowB2D98pQ4eppGQVPis=; b=B1f2Yres4EaF8Bi8tJ1dJ+yU4AXWQ5XGwe+Tw2USFQwevYx+m5yRoaZGjvjy29UQGK w0HYPAMyZrtOlR0NQAI2n537lVw/6Zm+iPdUhAK+HNuKTCzeZ6cnriBPbsLozZgk/pJx /GwGoBTBowYlVzcoc6UZKHZxUc1SILWld1AJ2jup/h2zyb79Kfg6b/gFp5lAzVDhBYPt QdE2lt5/ir8va7stiCcZbSluMCqXv/LXWXRBjzd1yA9y6IJCs9Xrj0gLSSViQpWGxsFh EqYDPs3bcv5H2NvUMEpIcH0ZKjDe1knMZrE6d58uq2iBgUTPSGtPu1xkmAlWiU6g0hUL Vujg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=X8Z0qjEk; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t134si1608101pgc.384.2017.11.29.10.11.11; Wed, 29 Nov 2017 10:11:21 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=X8Z0qjEk; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932470AbdK2LyW (ORCPT + 70 others); Wed, 29 Nov 2017 06:54:22 -0500 Received: from mail-vk0-f67.google.com ([209.85.213.67]:45897 "EHLO mail-vk0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752911AbdK2LyT (ORCPT ); Wed, 29 Nov 2017 06:54:19 -0500 Received: by mail-vk0-f67.google.com with SMTP id s141so986790vkb.12; Wed, 29 Nov 2017 03:54:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=qL3MA7fMORp337IUOFqAcp9jowB2D98pQ4eppGQVPis=; b=X8Z0qjEkdJs/IWOJYh3m47OHRzz8+A6zNXEKvMh0a+7fHLHVZVdGjHZV7JuwVaEkIW OGTcc1+BAJu2xM96PPY7dafS2xvWsHNFp9uEEboJxOHPKQWgd2qf8FhbE99lPnZjXOti XuBFtEDlgJ8M9Xs2nskoeNaMlfclsalyBczdqCGBlmvtAHXXG1Gcj4e5omAT7waxrf0B N7PeMdeK7Y4U9+RhsSWkOxZQTfC8IT588FzLvb/LZpJPn3agG0IXm0N/xID1S5sKKc4U 2hWyfAn3JYKcF1+/C3baM6PRC/Q3pktAy9DT1c/YK/KzWu5Rf6MWSyXOkD99h+ojuJSM BReg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=qL3MA7fMORp337IUOFqAcp9jowB2D98pQ4eppGQVPis=; b=sy1Hx7sVLOENvrjZGef5kjsChzZtzwCvYyIhIUTd8EtUndBAhHsexQh5/oQa6eGJDB omzjyU1QyVd7QMWlRJGDduIL0hl7e0me3si+fJ+tnO0mhGjVxtcR8Qp+rWnN9+NJmW93 bglwmdSB4HtOLHttIXl8OYgLUYPZ13/hCcxWKZccAoAiBztU54K1mC5mP/hJz/YHv61C O2Tmcqd62UpzV4QZVJc7mVXgL2wCcY+em9Ld/3PJXaRqf6lYfAa74unBKhhPCG5LIv3v m9AbFb8k3ZxqtvbfsYJZS9j7uXfaOtuhsWLJCSSRJHTjejodXNe46OArWc8IYKv/XSqN 1xAQ== X-Gm-Message-State: AJaThX5DInPEhOLS5ejoTRFX2Sd1318cWLbyJVEjyOdAO1fluiA356ZY 7vZviGL8XE7CDIQIwJ+peiU2TDyVhrNfTLkb93k= X-Received: by 10.31.6.17 with SMTP id 17mr1951758vkg.192.1511956458369; Wed, 29 Nov 2017 03:54:18 -0800 (PST) MIME-Version: 1.0 Received: by 10.176.27.105 with HTTP; Wed, 29 Nov 2017 03:53:37 -0800 (PST) In-Reply-To: References: <380808fe9139e2c3800ae76dfa6aa5cbbbc4894f.1511785528.git.green.hu@gmail.com> From: Greentime Hu Date: Wed, 29 Nov 2017 19:53:37 +0800 Message-ID: Subject: Re: [PATCH v2 19/35] nds32: L2 cache support To: Arnd Bergmann Cc: Greentime , Linux Kernel Mailing List , linux-arch , Thomas Gleixner , Jason Cooper , Marc Zyngier , Rob Herring , Networking , Vincent Chen , DTML , Al Viro , David Howells , Will Deacon , Daniel Lezcano , linux-serial@vger.kernel.org, Vincent Chen Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, Arnd: 2017-11-27 22:33 GMT+08:00 Arnd Bergmann : > On Mon, Nov 27, 2017 at 1:28 PM, Greentime Hu wrote: >> + >> +#define L2C_R_REG(offset) __raw_readl(atl2c_base + offset) >> +#define L2C_W_REG(offset, value) __raw_writel(value, atl2c_base + offset) > > __raw_readl() is generally not endian-safe, and might not have the barriers you > require here. Could you use readl/writel here, and only fall back to > readl_relaxed()/writel_relaxed() when you absolutely must avoid the barriers? Thanks for your suggestions. We will changed it to readl/writel >> diff --git a/arch/nds32/kernel/atl2c.c b/arch/nds32/kernel/atl2c.c >> new file mode 100644 >> index 0000000..dd87fc9 >> --- /dev/null >> +++ b/arch/nds32/kernel/atl2c.c >> +#include >> +#include >> +#include >> +#include >> +#include > > If this is the only file that includes asm/l2_cache.h, then I'd simply > move the entire > contents in here, rather than having a separate file in the global namespace. > arch/nds32/mm/proc.c also includes this file so I will keep it. From 1585230186665060341@xxx Mon Nov 27 14:35:14 +0000 2017 X-GM-THRID: 1585224480017068267 X-Gmail-Labels: Inbox,Category Forums,HistoricalUnread