Received: by 10.223.176.5 with SMTP id f5csp3217892wra; Thu, 1 Feb 2018 12:43:48 -0800 (PST) X-Google-Smtp-Source: AH8x224lUts3znhy/8hIyZE4oGkJrJ9cBdGX5Iizqem8j/Bw1UjXxu9tRkwYz5oqZqijINSIk920 X-Received: by 2002:a17:902:66e6:: with SMTP id e93-v6mr32337738plk.173.1517517828640; Thu, 01 Feb 2018 12:43:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517517828; cv=none; d=google.com; s=arc-20160816; b=zChQokI1Ae2ktF26mi18AP3Ej1Y7ATlPMyJlEuq81iCorzqV5BzYWp5uXgNzCRNOBG vtLd5it0zJbyOUWPxTpuH7W4ISJktRn9NVfYJXGyl5KisBzkC36LMVbm8sHC5WrXTgTB AZ/mV5k7H6dzg0w9zByfNYheEQtYhivlHGYPWiJ4NoXBo/9HlY9Ie/n6mkkFXfHmBnDh jezfTcTCHtX5dq/sBD3Y8LL6oOwTQ6xl9CWDz6tMp7XDklYildHzcVSOk2e7rgvLkkOv gPyrrEhe7bnL00J4kSZTxoWN2u410gtvu6NDDfJoaTdlhimYeOqcCZmi5m/7O8hFTAVl a3Fg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:message-id:references :in-reply-to:subject:cc:to:from:date:content-transfer-encoding :mime-version:dkim-signature:dkim-signature :arc-authentication-results; bh=VvZHPlYoUY8nfiQ3zn81b1bq/Qm1fAIIf6P61ze9lPQ=; b=y9tq+QYrpYobVCi611T1a7I9+6j1FrUDEIH1uAaLYgDftLIhWRzfjUYeCBBiPoGchK 4QMY5rs0EEouDZRcD9mNMVbf2sm/4RnJz7Z8X/5MrkDyIasySmnVR674E3Qn+x2RkFvN EP135uB6wIWXiamjQ3sbUeHt5hhb9/t3q595aKxtzql3JG7Cq41bwWZ2N/uIbIGoKYzN PBp5SMvgu615TrrNXz9/Be0hcS9P/WmPmRN+EYbUgazHRoPnxTAKDJbWONPxaSPD1pEB e82qKSGG+vyKxWILSnbsOcawPgl238Ph8VXJYoCW+E+ZOgNbgezJihrmO6w+qSxIEPdc 3hqg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=oaQ3ZlB8; dkim=pass header.i=@codeaurora.org header.s=default header.b=MS3dQnIC; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u5-v6si281347plz.513.2018.02.01.12.43.15; Thu, 01 Feb 2018 12:43:48 -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=@codeaurora.org header.s=default header.b=oaQ3ZlB8; dkim=pass header.i=@codeaurora.org header.s=default header.b=MS3dQnIC; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755136AbeBAUjW (ORCPT + 99 others); Thu, 1 Feb 2018 15:39:22 -0500 Received: from smtp.codeaurora.org ([198.145.29.96]:34244 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755066AbeBAUjK (ORCPT ); Thu, 1 Feb 2018 15:39:10 -0500 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 256F160112; Thu, 1 Feb 2018 20:39:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1517517550; bh=hpgroAX6q46NEa7Mu4sbAaZXg3pMM+mL3KsScihsAg0=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=oaQ3ZlB8jWCJI3K9bKlflUpmY+wFKCB1EP5/amayEW8Uo1eIxtSPzWgAheY8UsR7h Y2Nf7xj1DOm3Eao8M0Dp29kSPCfP6/pLPqLXvWGyDYhZNcQdxAncIQPAqsmSsyUgJm UAPqqsbhTBXLpobIPLODfS6YsFeDb7geWetoT0LU= X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on pdx-caf-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.8 required=2.0 tests=ALL_TRUSTED,BAYES_00, DKIM_SIGNED,T_DKIM_INVALID autolearn=no autolearn_force=no version=3.4.0 Received: from mail.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.codeaurora.org (Postfix) with ESMTP id 37B4F60112; Thu, 1 Feb 2018 20:39:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1517517549; bh=hpgroAX6q46NEa7Mu4sbAaZXg3pMM+mL3KsScihsAg0=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=MS3dQnIClA33yX9qoStClMd3YKuEEwDGv4l7ntkS58UDE3s3XsorwVv+mG4yAD/Rf MBVHoZz2f8psmdPi0JQwM1WpNorUq44xFBefiinkwYb5GdZT8zHKkB3sG9J/TENm6z ABjdeWqpxI9n2gqej37KkJzRUUfeEMGVP0ii8AEw= MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Thu, 01 Feb 2018 12:39:09 -0800 From: Channa To: Mark Rutland Cc: linux-arm-kernel@lists.infradead.org, linux-arm-msm@vger.kernel.org, linux-arm@lists.infradead.org, linux-kernel@vger.kernel.org, tsoni@codeaurora.org, sboyd@codeaurora.org, kyan@codeaurora.org Subject: Re: [PATCH 1/2] dt-bindings: Documentation for qcom,llcc In-Reply-To: <20180201104434.7j27fl2hb4glqd3v@lakrids.cambridge.arm.com> References: <1516924513-20183-1-git-send-email-ckadabi@codeaurora.org> <1516924513-20183-2-git-send-email-ckadabi@codeaurora.org> <20180201104434.7j27fl2hb4glqd3v@lakrids.cambridge.arm.com> Message-ID: X-Sender: ckadabi@codeaurora.org User-Agent: Roundcube Webmail/1.2.5 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2018-02-01 02:44, Mark Rutland wrote: > On Thu, Jan 25, 2018 at 03:55:12PM -0800, Channagoud Kadabi wrote: >> Documentation for last level cache controller device tree bindings, >> client bindings usage examples. >> >> Signed-off-by: Channagoud Kadabi >> --- >> .../devicetree/bindings/arm/msm/qcom,llcc.txt | 93 >> ++++++++++++++++++++++ >> 1 file changed, 93 insertions(+) >> create mode 100644 >> Documentation/devicetree/bindings/arm/msm/qcom,llcc.txt >> >> diff --git a/Documentation/devicetree/bindings/arm/msm/qcom,llcc.txt >> b/Documentation/devicetree/bindings/arm/msm/qcom,llcc.txt >> new file mode 100644 >> index 0000000..d433b0c >> --- /dev/null >> +++ b/Documentation/devicetree/bindings/arm/msm/qcom,llcc.txt >> @@ -0,0 +1,93 @@ >> +* LLCC (Last Level Cache Controller) >> + >> +Properties: >> +- compatible: >> + Usage: required >> + Value type: >> + Definition: must be "qcom,llcc-core" >> + >> +- reg: >> + Usage: required >> + Value Type: >> + Definition: must be addresses and sizes of the LLCC registers >> + >> +- llcc-bank-off: >> + Usage: required >> + Value Type: >> + Definition: Offsets of llcc banks from llcc base address starting >> from >> + LLCC bank0. >> + >> +- llcc-broadcast-off: >> + Usage: required >> + Value Type: >> + Definition: Offset of broadcast register from LLCC bank0 address. > > Please could we use "offset" rather than "off" for both of these? That > way it's obvious these aren't properties for disabling some feature. > > How variable are these offsets in practice? Is the memory map not > fixed? The offsets depends on the number of LLCC HW blocks. These number of HW blocks vary from chipset to chipset and new registers could be added that changes the offset. > >> + >> +- #cache-cells: >> + Usage: required >> + Value Type: >> + Definition: Number of cache cells, must be 1 > > What's this for, and how is it used? This is to obtain the phandle arguments from client devices. Related to cache-slices property. > >> + >> +- max-slices: >> + usage: required >> + Value Type: >> + Definition: Number of cache slices supported by hardware >> + >> +- status: >> + Usage: optional >> + Value type: >> + Definition: Property to enable or disable the driver > > This is a standard property, so I don't think it needs to be described > here. Sure, will remove it. > >> + >> +== llcc amon device == >> + >> +Properties: >> +-qcom,fg-cnt : The value of fine grained counter of activity monitor >> + block. > > Could you elaborate on this? This is counter value programmed in the HW to detect live locks. This parameter is tunable to avoid false positives. > >> + >> +compatible devices: >> + qcom,sdm845-llcc > > Huh? The "qcom,sdm845-llcc" bindings wasn't described above, and it's > not clear what this means. > >> + >> +Example: >> + >> + qcom,system-cache@1300000 { >> + compatible = "qcom,llcc-core", "syscon", "simple-mfd"; > > This looks very wrong. Why do you need syscon and simple-mfd? LLCC HW block has 3 functionalities: System cache core, ECC & AMON drivers for debugging. All three drivers use the same register space for configuration, status etc. In order to avoid remapping the same address region across multiple drivers, I have implemented this driver as a syncon and simple-mfd. > >> + reg = <0x1300000 0x50000>; >> + reg-names = "llcc_base"; >> + >> + llcc: qcom,sdm845-llcc { >> + compatible = "qcom,sdm845-llcc"; > > Why is this a sub-node? qcom,sdm845-llcc: This core driver as mentioned in the list above. > > Why isn't the top-level node just "qcom,sdm845-llcc" ? > >> + #cache-cells = <1>; >> + max-slices = <32>; >> + }; >> + >> + qcom,llcc-ecc { >> + compatible = "qcom,llcc-ecc"; >> + }; qcom,llcc-ecc: Driver #2 for ECC >> + >> + qcom,llcc-amon { >> + compatible = "qcom,llcc-amon"; >> + qcom,fg-cnt = <0x7>; >> + }; >> + qcom,llcc-amon: Driver #3 for AMON >> + }; >> + >> +== Client == >> + >> +Properties: >> +- cache-slice-names: >> + Usage: required >> + Value type: >> + Definition: A set of names that identify the usecase names of a >> client that uses >> + cache slice. These strings are used to look up the cache slice >> + entries by name. >> + >> +- cache-slices: >> + Usage: required >> + Value type: >> + Definition: The tuple has phandle to llcc device as the first >> argument and the >> + second argument is the usecase id of the client. > > What is a "usecase id" ? Usecase id for use case that wants to use system cache for eg: video-encode and video-decode > > Is this meant to align with #cache-cells? It would be best to keep a > common prefix (i.e. call that #cache-slice-cells). Yes. Will update the name. > > Thanks, > Mark. -- -- The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project