Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp295157yba; Wed, 3 Apr 2019 08:53:23 -0700 (PDT) X-Google-Smtp-Source: APXvYqwXBbVTG7COM8Gt/5+M+cxp84wzmIUufIsio1aH7yv10JpQjO+z6u+2sDI0tYgg5E+VcubY X-Received: by 2002:a62:ee17:: with SMTP id e23mr175221pfi.80.1554306803005; Wed, 03 Apr 2019 08:53:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554306802; cv=none; d=google.com; s=arc-20160816; b=MdVl/r+tkWoy3/P6U61kbYIVYaJ1iGp3/YjQeT+zOhK+zA+2eIXTyc/vQgWDlKbA7L xYACLT2spbtJhOP4lpYAHZlb0oj9/N0HlcLep1XrhNqOBuN287X699yeUJSK1VYq/cSw +xdXglRYoD+zTb1E2yn6vcl48A2++PUW54n7+1ohQ7EfISUxNyso8NS9BhYiledg5e2X fhQ4d97jS2bD1a9g1PXEMpBfQAva+6wWxbRl6SqJDmz9QQVD4aMOn6Eus0QhlhsV2VzQ YkvDJM9b1p1z/mrh3zoIokthmi6G/1I6VN0ApwWVnF+ZF/dAsMT/8+Yt6UDArWZFafyJ 98Hw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=NzY1LjUHGXOC4VbRaUK0sk/6i2+TQmErFx9YPp2U7JQ=; b=LhFnXoXJfmA8TnqffckZLAaJfzr5Nrj2urKxSRGINrzjCZLeUmkMcipHp0kzMYW7SD B9MYrhXVTrl+6b/ws/XeM3UUW8uc49tDFLQbhSxUGflgDIvbptWjI6Fv7IpXBxe02ClL C1Uzj8Q0YUGrbTBgsGOSjgwyLVI3m+8dErqwPmSwYf0YN5MRV2hHgh8wpCXQ2xIe5IKT 0KsIZ2uuxl483yo2H83j3JgkDrHZ26Sb0qkc63BGgIJhRKF06Ru7ya/KRdyuaF1GHDGM +lX3KFyv5jOJ/3Okekaku0HT+HUcIaN4VOz/bDFtzuumtNwxmYnR6it5WSa7xeDyoQ/x 1UeQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=iomVU4Oa; 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=QUARANTINE 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 m17si14532194pff.130.2019.04.03.08.53.07; Wed, 03 Apr 2019 08:53:22 -0700 (PDT) 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=iomVU4Oa; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726527AbfDCPt7 (ORCPT + 99 others); Wed, 3 Apr 2019 11:49:59 -0400 Received: from mail-it1-f195.google.com ([209.85.166.195]:39564 "EHLO mail-it1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726084AbfDCPt7 (ORCPT ); Wed, 3 Apr 2019 11:49:59 -0400 Received: by mail-it1-f195.google.com with SMTP id 139so12032690ita.4; Wed, 03 Apr 2019 08:49:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=NzY1LjUHGXOC4VbRaUK0sk/6i2+TQmErFx9YPp2U7JQ=; b=iomVU4OaxvF8q+R0lpHekC9FOOZGz5Bkmrrp8H8yPxok2SXbZzZcuRW2ITXaD1HcCD sI8YALvYVxBh6QUgxMvbdRb4ETvhOqYdyTzNrqAclNnnnUKimqYQZoqbIK3renTPJKFx WfdMd4uyeOXS+UnXBe9EKYT3R+niFR7/FEgtwkJ85qIa3Q/XDlPqr8ZPaijmI+fjng5P WT9YCXmlvHocQmnnfZ1nkTIHrgqZf4f335pAnuvJdJdHBooFbQUslQ4n7QoPpUW4ctmB 4LFjjPNsAeHoytvgKoq3zvYbhpmMo/15TTVDtpH75NH+b9nXK/2q3urv7LSoaQzgDJ4r qKJA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=NzY1LjUHGXOC4VbRaUK0sk/6i2+TQmErFx9YPp2U7JQ=; b=MkSqSrNGQF+nTeQIhShAY1bngbxTUSoevFMDW07r7CsNhbIOeTgtGyyaCrKZ7eiCo0 jVH0eC7QH3ogdj56cxBoN/d13PgpmV9cLeRHpFQeIINrA4negohDwo4RbTswXHdLl6JD UQKtx3bsG5hBAqpEnF7wJwkSaf9GIrZdh1SQVNbfn+Tovh52UD6egscv6Hv8JjIulzXj o6TQzNzHQxfRGSVlrF44lRz7nXS4dI/1GzQEliMHrV2FDFdddOqyLZevdRliYunlzkbE 2n2LwYM7qjMeZjWuHqaq8AR8g3eb3nzosCx60HOf0V2FqYC/Tv5paWsNPk2t+KuOOnpJ +V2g== X-Gm-Message-State: APjAAAVmBrls75kz/TAFeWPT5Ko+aauUtulXihyrs0pqukm9sNlB8A1q fwThjES4LME7NFRSZeMd3nDcuc3Db7ikw8SAAlM= X-Received: by 2002:a24:480e:: with SMTP id p14mr877517ita.61.1554306597901; Wed, 03 Apr 2019 08:49:57 -0700 (PDT) MIME-Version: 1.0 References: <20190322133105.5945-1-brgl@bgdev.pl> <20190322133105.5945-2-brgl@bgdev.pl> In-Reply-To: From: Adam Ford Date: Wed, 3 Apr 2019 10:49:46 -0500 Message-ID: Subject: Re: [PATCH v2 1/4] ARM: davinci: fix cpufreq registration on da850-evm To: Bartosz Golaszewski Cc: Sekhar Nori , Bartosz Golaszewski , Kevin Hilman , Rob Herring , Mark Rutland , David Lechner , devicetree , Linux Kernel Mailing List , arm-soc Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Apr 3, 2019 at 7:50 AM Bartosz Golaszewski wrote: > > =C5=9Br., 27 mar 2019 o 12:14 Sekhar Nori napisa=C5=82(a= ): > > > > Hi Bart, > > > > On 26/03/19 11:21 PM, Bartosz Golaszewski wrote: > > > wt., 26 mar 2019 o 15:00 Adam Ford napisa=C5=82(= a): > > >> > > >> On Fri, Mar 22, 2019 at 8:31 AM Bartosz Golaszewski = wrote: > > >>> > > >>> From: Bartosz Golaszewski > > >>> > > >>> The system_rev variable is never set on davinci and is always 0, so > > >>> we're using the default max operating point of 300MHz. The cvdd sup= ply > > >>> comes from the tps6507 pmic and the voltage can go all the way to 1= .3V > > >>> so the maximum supported rate should be 456MHz. > > >> > > >> My understanding is that only certain revisions of the silicon can g= o > > >> to 456MHz. The L138's Datasheet lists both a 456 and 375 version. = I > > >> cannot find a way to read a register to determine which version of t= he > > >> silicon is available. Maybe Sekhar can confirm. > > >> > > > > > > Commit 28bd2c341120 ("davinci: am18x/da850/omap-l138 evm: add support > > > for higher speed grades") mentions the following: > > > > > > --- > > > U-Boot on the EVM sets up ATAG_REVISION to inform the OS > > > regarding the speed grade supported by the silicon. We use > > > this information to pass on the speed grade information to > > > the SoC code. > > > --- > > > > > > Should the system_rev somehow reflect that revision? Any way I can ch= eck it? > > > > Can you check if the procedure in doc/README.davinci in U-Boot sources > > still works? > > > > Environment Variables > > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > > > The DA850 EVM allows the user to specify the maximum cpu clock allowed = by the > > silicon, in Hz, via an environment variable "maxcpuclk". > > > > The maximum clock rate allowed depends on the silicon populated on the = EVM. > > Please make sure you understand the restrictions placed on this clock i= n the > > device specific datasheet before setting up this variable. This informa= tion is > > passed to the Linux kernel using the ATAG_REVISION atag. > > > > If "maxcpuclk" is not defined, the configuration CONFIG_DA850_EVM_MAX_C= PU_CLK > > is used to obtain this information. > > > > Thanks, > > Sekhar > > Hi Sekhar, > > I built the current upstream u-boot and the get_board_rev() function > for da850-evm doesn't seem to be called at all. For instance the > lego-ev3 platform does this: > > ./lego/ev3/legoev3.c:108: board_rev =3D get_board_rev(); > > but in davinci this function seems to be unused and I don't see it > called from any other core u-boot component. I don't see any commit > that would mention this function but there are a lot of commits > removing get_board_rev() for other boards in git log. Is it possible > it stopped being used at some point? Look for setup_revision_tag in arch/arm/lib/bootm.c The function appears to be called from there. There is a __weak reference in the header file which I think allows people to remove them without breaking bootm. adam > > Bart