Received: by 2002:ab2:60d1:0:b0:1f7:5705:b850 with SMTP id i17csp1897774lqm; Fri, 3 May 2024 09:24:24 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUdVY9ncDS92qVN1cToxPPW0XAP+ExmdzvllU7xvnBVU1RDT428IzEVj1mmOMIN/ErrTkc4+1QlshndOkqjzyZNb4WP1KSMxDLQJ+9JGw== X-Google-Smtp-Source: AGHT+IHmFrUGYyzg8nRCF4e5gnAaNIF+UZypBmlOnP7uHvQ+qvG4bQUGadDUgkvLrmR6no8iTgOW X-Received: by 2002:a05:6a20:f3a3:b0:1af:3857:e652 with SMTP id qr35-20020a056a20f3a300b001af3857e652mr3112049pzb.12.1714753463791; Fri, 03 May 2024 09:24:23 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1714753463; cv=pass; d=google.com; s=arc-20160816; b=SQkpfObVESCP5vLKo9c1aInez4xUh7WCaCVyKKxyUWeQp+kKN3jTrJ/sf5uo0JvcuO ZjBu8QFpb9vTHeNN26lR4V/zXWxXsn6dLAq87F6rK+Xk57vs6IESaFzUBs3kYe4WSxmY eHYKOtuFbdgYdEy5kIxOCkAbXTbFh41EYq7h4WUWEXZstrOzpip3HJyqAReJ6673Ljc7 Cy9iX5hLcaoSGnUqLVnfatvMzpqcsn5/vSF0vGjQdfDY+NwZTRyOFFTopJghFQISjQGy tR1epeZNXy5TNJj63wFlL5LfttAmw4LjYCqAhNanj53YM1mCcXs9EVNg4mySZbk4Wtsk fEJA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=YLhEL1VG093YuMIX3HidTiq7V2QCt11NnZ3PJxVhmJY=; fh=q9bCjntz0fvlxppnbIYx+OJTYn8LvERCKK/hFj8jOsU=; b=zvHQi+pTjqzaiy0YAFXlMBOWzc2PC3oisJbo1E0YhxXWmVc7kuVoFfFkwVbxs1TbWT MUSjWTZmzUg0w7Gr7N9j/rpUnD9lqh4BOGzqdBQWHv0DtJ8zNF/77hguSNubxrtIi2rp sR2OykERvAPWOdAgyZdtUH9dlWiIupd3ps9waj42UDanCf/56cPNRAlPQ7XKyQiqSLCr Wu+3H/K99m7oIY5ETq6unZPhZ3wYZhh5OGEE+0RsjX/KbHFBVCo6uQjWPzGWwKJjo42l qVZVu2LTp+6zC4//W3STyPh9yABAXNGpBiLQA+mEIskD7q02qFMkPrmpbCxr60JQqBEo tKeg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=o8Qb7Kok; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-167894-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-167894-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id mc14-20020a1709032b0e00b001e85dc6b450si3208904plb.159.2024.05.03.09.24.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 03 May 2024 09:24:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-167894-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=o8Qb7Kok; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-167894-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-167894-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.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 sy.mirrors.kernel.org (Postfix) with ESMTPS id DD623B22D42 for ; Fri, 3 May 2024 16:21:54 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 65DCF155384; Fri, 3 May 2024 16:21:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="o8Qb7Kok" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 83C86154428; Fri, 3 May 2024 16:21:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714753307; cv=none; b=WREhSFTRIAiC/B3g1sUtlFT78+UWiDMi0J7aZ40swubXhuXKG9YcSUYuvzo9FBPHDt4fyk6jhJ2g2f7yeZY4+Cm9TD13/pYk+yiKZIhr0+vfAHONaz86TED7Y/INtIdNC8Ycwky9rZE/Fu6ams1X33ccQp6i7HrqKaH9nJz3NE8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714753307; c=relaxed/simple; bh=1xspHNPP+TAZ5j87YBguQVSvoCMWV6Hj7z2sBpc6Hfo=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=fzW4jDLqCMQXPh4IXpF7VUzqNnfsp/ho1BwuFmdGZkarC3AuaUoZyBeh5dUN1bmfMz2RJQPXqdl+f2NeYCtHanNA16VbPoxNnXY0SY4JgHyN8pTnyGDPPkuBn8hhjmaS1VUmSTQrZFsmYUEAW/L+RYN9SLuHPhYtkHyjigHumQU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=o8Qb7Kok; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4ECD2C32789; Fri, 3 May 2024 16:21:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1714753306; bh=1xspHNPP+TAZ5j87YBguQVSvoCMWV6Hj7z2sBpc6Hfo=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=o8Qb7Kok9YovhpoYrNxz5FxEMbMUkRFVMkQHsBPD8AB14xyiH5BEBEaXXhLcgyLva 3a+J3KrE2k0Y2f4EJQ8qvf+7B2k5wdW8XVFSmlLwOA09cBtBQojng0v+lpI1UVNdry bF9I6r961mQGpUhMd5pP1HEgtU5Kf1hHTYpqiiKXsyTt8MhxdbJZ3IUYI0/uwzhRCj FmX2JPdPgc66nGFIr0l+AQYknCaBDnP2TGm2lUpjab64QY8rPw278SKNnSyM5DGPdr Ne1hJsF/0AmSojg7Mim/dTvurTJpp924uEvCW2rFnzAy05fIQB8er2EDKpNbc7p93U 96cL6plnyP48g== Date: Fri, 3 May 2024 17:21:41 +0100 From: Conor Dooley To: Christian Marangi Cc: Hauke Mehrtens , =?utf-8?B?UmFmYcWCIE1pxYJlY2tp?= , Thomas Bogendoerfer , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Florian Fainelli , Broadcom internal kernel review list , =?iso-8859-1?Q?=C1lvaro_Fern=E1ndez?= Rojas , linux-mips@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Daniel =?iso-8859-1?Q?Gonz=E1lez?= Cabanelas Subject: Re: [PATCH 3/6] dt-bindings: mips: brcm: Document mips-cbr-reg property Message-ID: <20240503-oncoming-taste-bab71375b67c@spud> References: <20240503135455.966-1-ansuelsmth@gmail.com> <20240503135455.966-4-ansuelsmth@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="LyhWp7dhQDBYJl7Z" Content-Disposition: inline In-Reply-To: <20240503135455.966-4-ansuelsmth@gmail.com> --LyhWp7dhQDBYJl7Z Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, May 03, 2024 at 03:54:03PM +0200, Christian Marangi wrote: > Document mips-cbr-reg and mips-broken-cbr-reg property. >=20 > Some SoC suffer from a BUG where read_c0_brcm_cbr() might return 0 > if called from TP1. The CBR address is always the same on the SoC > hence it can be provided in DT to handle broken case where bootloader > doesn't init it or SMP where read_c0_brcm_cbr() returns 0 from TP1. >=20 > Usage of this property is to give an address also in these broken > configuration/bootloader. >=20 > If the SoC/Bootloader ALWAYS provide a broken CBR address the property > "mips-broken-cbr-reg" can be used to ignore any value already set in the > registers for CBR address. >=20 > Signed-off-by: Christian Marangi > --- > .../devicetree/bindings/mips/brcm/soc.yaml | 32 +++++++++++++++++++ > 1 file changed, 32 insertions(+) >=20 > diff --git a/Documentation/devicetree/bindings/mips/brcm/soc.yaml b/Docum= entation/devicetree/bindings/mips/brcm/soc.yaml > index 975945ca2888..12d394b7e011 100644 > --- a/Documentation/devicetree/bindings/mips/brcm/soc.yaml > +++ b/Documentation/devicetree/bindings/mips/brcm/soc.yaml > @@ -55,6 +55,21 @@ properties: > under the "cpus" node. > $ref: /schemas/types.yaml#/definitions/uint32 > =20 > + mips-broken-cbr-reg: > + description: Declare that the Bootloader init a broken > + CBR address in the registers and the one provided from > + DT should always be used. Why is this property even needed, is it not sufficient to just add the mips-cbr-reg property to the DT for SoCs that need it and use the property when present? > + type: boolean > + > + mips-cbr-reg: Missing a vendor prefix. > + description: Reference address of the CBR. > + Some SoC suffer from a BUG where read_c0_brcm_cbr() might > + return 0 if called from TP1. The CBR address is always the > + same on the SoC hence it can be provided in DT to handle > + broken case where bootloader doesn't init it or SMP where s/init/initialise/ please :) Thanks, Conor. > + read_c0_brcm_cbr() returns 0 from TP1. > + $ref: /schemas/types.yaml#/definitions/uint32 > + > patternProperties: > "^cpu@[0-9]$": > type: object > @@ -64,6 +79,23 @@ properties: > required: > - mips-hpt-frequency > =20 > +dependencies: > + mips-broken-cbr-reg: [ mips-cbr-reg ] > + > +if: > + properties: > + compatible: > + contains: > + anyOf: > + - const: brcm,bcm6358 > + - const: brcm,bcm6368 > + > +then: > + properties: > + cpus: > + required: > + - mips-cbr-reg > + > additionalProperties: true > =20 > examples: > --=20 > 2.43.0 >=20 --LyhWp7dhQDBYJl7Z Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRh246EGq/8RLhDjO14tDGHoIJi0gUCZjUPFQAKCRB4tDGHoIJi 0pNZAP96jyklbklNPKY4YnOx/KmP7ftWMWURZUPZ4jJx+TeBcgEA5ffTEJvJzWNp Msg4JtZu9TUybY2OeU8jwDgGHKilzQQ= =Csss -----END PGP SIGNATURE----- --LyhWp7dhQDBYJl7Z--