Received: by 2002:a05:7412:2a8a:b0:fc:a2b0:25d7 with SMTP id u10csp331318rdh; Wed, 7 Feb 2024 06:12:09 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCVrf4txsbnXvSl3Sl8KgM5yZgGV32g2xtuk/T9tevkBniHRTk+7LsZqeKDr3ytXb6QRHcQYU5niWuG1Qdgyj4+09itGsethefxou2amEA== X-Google-Smtp-Source: AGHT+IE3NNl09vgCsdJIHkFhJCg4MK88TXw6JmbVPspYKT1lQOsgigm8prM7NfkRfPiq+jVJ5Wry X-Received: by 2002:a17:90a:b38f:b0:290:30d:1f8d with SMTP id e15-20020a17090ab38f00b00290030d1f8dmr2436140pjr.49.1707315129136; Wed, 07 Feb 2024 06:12:09 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707315129; cv=pass; d=google.com; s=arc-20160816; b=rF+pDehIMtpUFz6TnFpyOT1FUDZZcv0JSTb5ECUBCvpr3Wj1iwDrRqcg3QdX2zx//X D6gtN5ejg3BKAFDu13fw6AWnXCVDacrgzG/l9MKY6fVXZzc9dG0NLyR0wRx9DVPg3ee1 QCJT1yFOya7Vps+KJ5OoMIQvKfu/PUtt3Kcnzud7a8grSDnut0iSiEYt3Lan6jcplF7g 1MMH4HIYQcK0a3uKB8Fq/BVvIuVzv+HeSj9zdm8jH0GKuX4cPZ06f2P2l7tvbd8Get35 21Ax3ecdO4CyAyAgfUlG8mHcFfuTqQl8D7jVtKP6HlFaZPBn+Fuei+ERom/s9gL/1llW 1Gtg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :dkim-signature; bh=tCe/2EWP6QyZNDgQYAyU30S8OaPYPa61/dD76E0Ooo0=; fh=3PpJ1RY4mFSBR/cxSJSZKq0qjATGH3898aDAIVMwlxQ=; b=wpjTvW4IT3HZ1N8PfwP+0FgG88rpoibdduQZXKCj0Kt5qBZNtrYWHUVFnP5J34qE72 5wkNWtnvfUlIvMVmKWB+/Oy4e8Y5hzWb+zCDpmndSk9rgUleLW95zn+P25WRzik6L6Np xpodG7Oy+S0jQ21zse1F4rG0xfaIpKV5NTld5h4w6i1pJ94u43qbDGvOefrDTcZ2EC+h YrN8TK/4gBLSxOa69FBSB4oDCCaH/ATdc1k44XdDd7Iig4+ALWiVSm2kX+g6FVOZazjl oA42N6VOw/CjR29hwOGXFOALRqOzJ8nqJale8kPTGK3yX5gdhVn/IJCZAwRy3nbR3j8Y jHPQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Uht1RhXR; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-56599-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-56599-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org X-Forwarded-Encrypted: i=2; AJvYcCVPn9cm7BNcUcc9KARzSTijSGEFT2KPYVAzjsJW9A8r/oOVChrP+ph0Zpw+J40pBJ2WSeyRZ14VycBuy0dSGdqXC6h1EEtr9FSxKB+BaQ== Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id gm17-20020a17090b101100b00295d4e9dbf4si1662816pjb.54.2024.02.07.06.12.08 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 06:12:09 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-56599-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Uht1RhXR; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-56599-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-56599-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 9EE22287886 for ; Wed, 7 Feb 2024 14:12:08 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 0442F7C09D; Wed, 7 Feb 2024 14:12:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="Uht1RhXR" Received: from mail-qv1-f51.google.com (mail-qv1-f51.google.com [209.85.219.51]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id F052677658 for ; Wed, 7 Feb 2024 14:11:57 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.219.51 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707315121; cv=none; b=C8WtecDQBU6DNY7bO9+iGEG+YFV/22GUWnLUn2bK98A8k8nSyX1t2EOrCVFni8KcTAxhOQAhsPb2LKflkqzGg1YMJqX8lYkESddtQvKeV7K/h35ccDsqrvR3aZsX2RsWfgjQNJm5NyLfq9XmSyet5IRsK/RszEknyzIPD0WAeDg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707315121; c=relaxed/simple; bh=nzkjMj0bCnuVMEZVy8mkyoMHQ9P0e3IYhsa7ydwwFko=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=CTh0pXG0CDptnfapzn9fBgUJ1JDrF6TpT4x39J8eUeK34pKcViUc854S7aAaKKc0xjLQjE8/2XN5nr+bJsESGntUyDfv3oe3Ckgp1YsCv7OS6tpnKJgzYgX7TaOouV1rV2P5R1aoya2NFHv62fOExEcRdefGbJf6inM5LYX/8Bg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=Uht1RhXR; arc=none smtp.client-ip=209.85.219.51 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-qv1-f51.google.com with SMTP id 6a1803df08f44-68c431c6c91so2626536d6.0 for ; Wed, 07 Feb 2024 06:11:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707315117; x=1707919917; darn=vger.kernel.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=tCe/2EWP6QyZNDgQYAyU30S8OaPYPa61/dD76E0Ooo0=; b=Uht1RhXRiwsbtVHXbQMpR4P4PFoqqKKg6J5ZR+Jnm0fDHA7qYGHcPLtSJglXG2Otyo mP6GIQ/lkSbmbw1FdgKoNoQBoB+jHfTSab1abzrNGTmJJXGFKB4b6qlxgcqlgFPL9DFV U3AUU1XfpPGhmNhl2ONaMLTblYObES5YEvpjooIPssDAOpku4yteaPqsQZtR7f3MmJCP +o0nBAsQgkRQGZS6FqRi6wGHUmcamb3okkFmE51lgoTDlSuUsf4MuxBoQqrbmsfbjtHk qwPiuA6P4zqWkCNzbRKryIl6KajasxEDeXX6vI9xIgHubfBlYHXFsiNT5YGi5PmK19FT o4sQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707315117; x=1707919917; 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=tCe/2EWP6QyZNDgQYAyU30S8OaPYPa61/dD76E0Ooo0=; b=fZvhwHqAMVXEU2KFBXuou1mMF3He94WOVFQ5jeynmO7OjsA7JB9bIN42sWP3wCwXFU ytpD4I/WwZzS2uKZyDGCX/NaL0OZBplAQh9F+seM8mxndayel6YfaE5xT6dEtO+eOOrg yL+Q1rHxGJpvq1d3i8BkLNbhCj/9Ujkkxus5peBMbFhI/GWHvQYlSFEZqZ6PQJQLhV7l voPigeISgb9JHD8milbuaDzhsZ8TVcNg+tZidDbw+5XlyFXfGP7q2wFPvah95bzoNe+A tkh4lZn+qLKBp+JW5hHQ4aGX+su8j63k/cOJTJM4kwtDPTbJ32B+1kEozEowQ+GeQex8 wKIA== X-Forwarded-Encrypted: i=1; AJvYcCUhL5r7vALkS+buSOx20JUb0lIyzZM5ctzf++NRzcX2dStelV0ZsP12ztxD7C1bfwnBj76CHbp8oABr9Tw18k+9+EKn+AJudqFzPWlI X-Gm-Message-State: AOJu0YwwvykSiXZSXqqWhGFTHP3APNLj09ywbf3VwOhsIV5gEeJgCqp3 jhgMKGQv9uV0B8z2zqf8hr3MzSSYR8/EKPV+x5kDdNaGWXGdxnGS6zve8bW3gpHV1RwTEJVLTIY 8hBZeQOoGHBqd91kjniD3WY3Xf+zk9ZgUN2wcYw== X-Received: by 2002:ad4:5943:0:b0:68c:9d2d:6ae9 with SMTP id eo3-20020ad45943000000b0068c9d2d6ae9mr6339727qvb.8.1707315116782; Wed, 07 Feb 2024 06:11:56 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240201172224.574238-1-alexey.klimov@linaro.org> <20240201172224.574238-2-alexey.klimov@linaro.org> In-Reply-To: From: Peter Griffin Date: Wed, 7 Feb 2024 14:11:45 +0000 Message-ID: Subject: Re: [PATCH 2/4] arm64: dts: exynos: gs101: add chipid node To: Krzysztof Kozlowski Cc: Alexey Klimov , alim.akhtar@samsung.com, linux-samsung-soc@vger.kernel.org, semen.protsenko@linaro.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, klimov.linux@gmail.com, kernel-team@android.com, tudor.ambarus@linaro.org, andre.draszik@linaro.org, saravanak@google.com, willmcvicker@google.com, arnd@arndb.de Content-Type: text/plain; charset="UTF-8" Hi Krzysztof, Thanks for your feedback. On Tue, 6 Feb 2024 at 10:10, Krzysztof Kozlowski wrote: > > On 05/02/2024 15:36, Peter Griffin wrote: > > Hi Alexey & Krysztof, > > > > On Thu, 1 Feb 2024 at 17:22, Alexey Klimov wrote: > >> > >> Signed-off-by: Alexey Klimov > >> --- > >> arch/arm64/boot/dts/exynos/google/gs101.dtsi | 5 +++++ > >> 1 file changed, 5 insertions(+) > >> > >> diff --git a/arch/arm64/boot/dts/exynos/google/gs101.dtsi b/arch/arm64/boot/dts/exynos/google/gs101.dtsi > >> index d838e3a7af6e..156fec2575bc 100644 > >> --- a/arch/arm64/boot/dts/exynos/google/gs101.dtsi > >> +++ b/arch/arm64/boot/dts/exynos/google/gs101.dtsi > >> @@ -283,6 +283,11 @@ soc: soc@0 { > >> #size-cells = <1>; > >> ranges = <0x0 0x0 0x0 0x40000000>; > >> > >> + chipid@10000000 { > >> + compatible = "google,gs101-chipid"; > >> + reg = <0x10000000 0xd000>; > >> + }; > >> + > > > > I was wondering about the 0xd000 size here, as most upstream platforms > > use a chipid size of 0x100 or 0x24. I see the downstream gs101 kernel > > also uses 0xd000. Looking a bit more, that is because gs-chipid.c also > > has support for dumping other areas of the OTP SFR bank like asv table > > (offset 0x9000) hpm_asv (offset 0xa000) and hw_tune (0xc000). > > > > I checked Exynos850 and that also has ASV tables at those same offsets > > above, but it currently uses a chipid size of 0x100 upstream. > > Exynos-asv.c driver is part of exynos-chipid.c upstream so it seems > > reasonable to have the increased size including those SFR registers. > > Currently exynos-asv.c driver only supports Exynos5422 upstream. > > > > @Krzysztof - From a process PoV what is the best/correct thing to do > > here? Have the increased size in DT that includes ASV parts of the OTP > > bank from the get-go? > > ChipID so far had only size of 0x30 or something like that. What you > refer to does not look like old ChipID but full blown OTP, which also > includes ChipID. OK so in some previous Exynos SoCs chipid had its own separate memory mapped SFRs as well as being present in the OTP area? > Although I am not entirely sure about that, either. > Depends whether they share clocks, for example. This address is the OTP area, and I can't see chipid regs mentioned anywhere else in the memory map other than OTP. Unfortunately there are lots of separate docs for different IP blocks, so it isn't just a case of searching a giant SoC TRM pdf. e850 though looks to be the same (the address defined in DT is the otp area), that is one large PDF and the chipid regs aren't mentioned anywhere else, Given the chipid reg offset is the same (0x10000000) for exynosautov9.dtsi, exynosautov920.dtsi, exynos850.dtsi, exynos7885 and exynos5433 I suspect this could be the same for all those SoCs as well. > > I don't have any GS101 information so I don't know what's there. It > seems you ask me to give you decision based on guessing... If you have > one block, so if there is OTP, which contains ChipID, then define OTP. I believe there is one block that contains ChipID, therefore based on the above info we should define full OTP size? > Not ChipID+OTP. > > I think Exynos850 DTSI is wrong here. That's OTP block, not ChipID. Yes agreed, and quite possibly the other Exynos SoCs as well. Thanks, Peter.