Received: by 2002:a05:6358:f14:b0:e5:3b68:ec04 with SMTP id b20csp2443865rwj; Mon, 19 Dec 2022 04:48:54 -0800 (PST) X-Google-Smtp-Source: AA0mqf5+czWYWEnb8rEPh5CISfPnAaOPxcRJL7CKsXbF2A0zJ+jw9DGVQoVKkEtRYsmPTuNxmUMX X-Received: by 2002:a17:907:3947:b0:7c1:6794:1623 with SMTP id sp7-20020a170907394700b007c167941623mr37278073ejc.58.1671454133773; Mon, 19 Dec 2022 04:48:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671454133; cv=none; d=google.com; s=arc-20160816; b=URhoVpGotjO6m2DsKbDx+P3TWvRny2Vm0622nT4Pjbe8NR5h/fM1sCbU6kW4OOLs/Q hjqA0wt1Mu1s6bKASmkmjf1iUd3lJSGi+/OlxGy2wsMBfQdUt6hT7o1niWqeozIHqeWJ ZNzbb4K95vmeuQROIf36sxOraWNeWdFMnd6m7pU0zSAOBcg8+gdUg5+kfSCkBfqjf3/9 vt2MkFbwfLdyhju4kE+kp/DQghhjFcJdiIA+UyFvF5JVHBB/SZh0i9b7OUf7qqG0uuP/ odZXHGxqe2GLcn39jY8du/IXF4Yb2KpHZt0heiD6gCA0iTbVg8c9FrXlwfcns5K4TLF0 DEmA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=kxV7u7RRZGTufLc/md9pxkp/T9u0Ezh5oQMEVPe6YoE=; b=iRBFO2nvjK8/1dXpqjha35co3d54tJKAfs+U41Q0aasrOfwVyRy6utvIkaSeWTkNuE 1wNRmEeTjKV0IRizJT1TIMRKAMUK4u6A2vPC22VCkG4fboNn3kY/7G5akrWiSqSHWnlR gisFlG1hr/GEBQvamaQ7Fdct90V5nzp9ZhV0qmhUv6U9PnrPIhH2MBv1QkEz69JNBKq6 8wJUK0RqCCg7nhnYpjyxWaC0RqQMPG1Q0uNYZ+xkkRewkSECcQcLonex2oQtUqcGtn3q 7L67h3XsDcWOMiLJHxmORwohP2JV4If4xbvbbtVpfbD4d+5hntcUBvOPGTWO+UK9W9e9 8Oow== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=NXZBQcYC; 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=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id qa17-20020a170907869100b007d6105e0acfsi8990603ejc.501.2022.12.19.04.48.32; Mon, 19 Dec 2022 04:48:53 -0800 (PST) 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; dkim=pass header.i=@gmail.com header.s=20210112 header.b=NXZBQcYC; 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=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232086AbiLSMon (ORCPT + 71 others); Mon, 19 Dec 2022 07:44:43 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52050 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231516AbiLSMoO (ORCPT ); Mon, 19 Dec 2022 07:44:14 -0500 Received: from mail-ej1-x632.google.com (mail-ej1-x632.google.com [IPv6:2a00:1450:4864:20::632]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 12F60E032; Mon, 19 Dec 2022 04:44:12 -0800 (PST) Received: by mail-ej1-x632.google.com with SMTP id n20so21273461ejh.0; Mon, 19 Dec 2022 04:44:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=kxV7u7RRZGTufLc/md9pxkp/T9u0Ezh5oQMEVPe6YoE=; b=NXZBQcYCFN6W7FZJnt2A0RGQ67TR1ahrG9Il9h7nLhG41ek3IlOG5ncHGcpvDsgYYi wGPBvRPnhbbsdeGYPZSE6kp8mwDpreWGjVAv2C/2OwGnYkkVJKGOdp8SZb+vbL/qtyFU Nt6SF2tW0efcm36MpHVmZWcsI6rrkzPPtLEUsdQnn4+6IcLMWnEWtmt1mT8MTjRAPsYZ v3TFOMh8gs/NcWWIZxoHgSKd/vhauHrCBqIG4kzFA2hwG2H0oE29kqpilZR2Pf9qdP9R TXho41ZtENKaJhpNTjGnSoqu2cb70bvgvUqcgB6DEn09XGgHSd0ekPM/TMeT2hJZ5YXe SqiQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=kxV7u7RRZGTufLc/md9pxkp/T9u0Ezh5oQMEVPe6YoE=; b=RzOmVQr2ZBXCxL7g8t+OQXHf7456/j5MY2XAkh5A864kxjukItANP60XQKKbqULHUR zQQOk7cKeRCvNi+0kn0myy9a+xFIlD+N3TRT3k3RTPDNTkmIVnAmIAfBLNtG4LUfQ137 bsqhlgcvB0UH4smEcvx/5SJjoK9e0t50We7z1xrLeqmlKFb8ZrJmx5nBlH1SEvqEjyhT GBsiHC527pmh/xgI87qaGbNviMrw05zeDPrF+EKq/Eu3lOJwFASV1gf3P6OsvnCVxVEQ 1pSZd/bT9lOimFBSiqa5LM9C8w2rCZnWnwiby8fxYQBiwDDC6VjNRU5L/mlxk77X9Hj5 Qwtw== X-Gm-Message-State: ANoB5plkOCycajBhjcev+UXp5sK6hg4HSOo8Ny4feNW3qoNe0vH3SBJS 0WeEx3xEJH/8Qr7HcsRh2CtLt3/JoXkACaWMX7Y= X-Received: by 2002:a17:906:3e41:b0:78d:bc9f:33da with SMTP id t1-20020a1709063e4100b0078dbc9f33damr80689032eji.80.1671453850556; Mon, 19 Dec 2022 04:44:10 -0800 (PST) MIME-Version: 1.0 References: <32cf0901-a4a0-48a7-bf42-f2cdb34d1ee7@app.fastmail.com> In-Reply-To: From: "Lad, Prabhakar" Date: Mon, 19 Dec 2022 12:43:44 +0000 Message-ID: Subject: Re: [PATCH v5 6/6] soc: renesas: Add L2 cache management for RZ/Five SoC To: Conor Dooley Cc: Arnd Bergmann , linux-riscv@lists.infradead.org, Geert Uytterhoeven , soc@kernel.org, Paul Walmsley , Albert Ou , Magnus Damm , =?UTF-8?Q?Heiko_St=C3=BCbner?= , "Conor.Dooley" , Samuel Holland , guoren , Rob Herring , krzysztof.kozlowski+dt@linaro.org, Jisheng Zhang , Atish Patra , Anup Patel , Andrew Jones , Nathan Chancellor , Philipp Tomsich , devicetree@vger.kernel.org, Linux-Renesas , linux-kernel@vger.kernel.org, Biju Das , "Lad, Prabhakar" , Palmer Dabbelt , Christoph Hellwig Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS 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 Hi Conor, On Sat, Dec 17, 2022 at 10:52 PM Conor Dooley wrote: > > On Fri, Dec 16, 2022 at 09:04:20PM +0100, Arnd Bergmann wrote: > > On Fri, Dec 16, 2022, at 17:32, Palmer Dabbelt wrote: > > > On Thu, 15 Dec 2022 23:02:58 PST (-0800), Christoph Hellwig wrote: > > >> On Thu, Dec 15, 2022 at 01:40:30PM -0800, Palmer Dabbelt wrote: > > >>> Given that we already moved the SiFive one out it seems sane to just start > > >>> with the rest in drivers/soc/$VENDOR. Looks like it was Christoph's idea to > > >>> do the move, so I'm adding him in case he's got an opinion (and also the SOC > > >>> alias, as that seems generally relevant). > > >> > > >> Well, it isn't an integral architecture feature, so it doesn't really > > >> beloing into arch. Even the irqchip and timer drivers that are more > > >> less architectural are in drivers/ as they aren't really core > > >> architecture code. > > > > > > That makes sense to me, it just looks like the SiFive ccache is the only > > > one that's in drivers/soc/$VENDOR, the rest are in arch. It looks like > > > mostly older ports that have vendor-specific cache files in arch (ie, > > > arm has it but arm64 doesn't). Maybe that's just because the newer > > > architectures sorted out standard ISA interfaces for these and thus > > > don't need the vendor-specific bits? I think we're likely to end up > > > with quite a few of these vendor-specific cache management schemes on > > > RISC-V. > > > > > > I'm always happy to keep stuff out of arch/riscv, though. So maybe we > > > just buck the trend here and stick to drivers/soc/$VENDOR like we did > > > for the first one? > > > > I don't particularly like drivers/soc/ to become more of a dumping > > ground for random drivers. If there are several SoCs that have the > > same requirement to do a particular thing, the logical step would > > be to put them into a proper subsystem, with a well-defined interface > > to dma-mapping and virtualization frameworks. > > > > The other things we have in drivers/soc/ are usually either > > soc_device drivers for identifying the system, or they export > > interfaces used by soc specific drivers. > > Sounds like that's two "not in my back yard" votes from the maintainers > in question.. > Doing drivers/cache would allow us to co-locate the RISC-V cache > management bits since it is not just going to be the ax45mp l2 driver > that will need to have them. > > Would it be okay to put this driver in soc/andestech for now & then move > it, and the SiFive one, once we've got patches posted for cache > management with that? > I think to start with it would be better if we place the Andes cache driver in the proposed "drivers/cache" folder. We would avoid unnecessary movement of code? Cheers, Prabhakar