Received: by 2002:ab2:1149:0:b0:1f3:1f8c:d0c6 with SMTP id z9csp2030481lqz; Tue, 2 Apr 2024 05:30:33 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXz7iuUYeB0yxX6PgvJgidN1mhqWwuV5v7Km/UvHQQBscDsvw5wgkfWcIadaF2VmgZngGfUQuuKb2OqxYqPJc14UTkxeaacQNtk6g5Jdg== X-Google-Smtp-Source: AGHT+IGsEt0nbdXsW6ZT43ZVWvRu3Noe8XM7MFUNuHCZcIeceBeJyHeMiaEjDv1p3SHKu17IXaFl X-Received: by 2002:a17:903:240a:b0:1e2:3767:5203 with SMTP id e10-20020a170903240a00b001e237675203mr13173530plo.7.1712061032861; Tue, 02 Apr 2024 05:30:32 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712061032; cv=pass; d=google.com; s=arc-20160816; b=tSBqeypzGljQ91i8HPcG3myIW1OTlK5nz3qh4UqfcoTJ3yMaDaqfOI30HBo0nop0Zw iz5T4rEXtOxzpkOr3+N7ZApjOUKqfWLKxxoDmjRBULVqkQHhkbPri5bigPl/wEfIZv6t Z4AMXO5SjTGROd/DjtDTmrh0+Hb/NaglrCaf1gmdGjwmq1YUYS4xqNy+mZEU8uzAzQxr 0wzT0Rr5l0NV+Uy4DzJneknJ2fnmcYzT8FVBoyfXfE1WGB+k0ww5KoO+F+GH+NGoQ1El 2OmpoTkK53BYCyQYvdTJLjL2MzOeV5dsOxmAFsd1tdc9jfC7QR3KkU01C99w9P3FDzzM QVAg== 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=rGB3cBxrxbzfkvdRjNadDZ6vfn6sw2z3o275CLvw278=; fh=sD/uw15iivbX1cBMZKTyYikLai4BC6cSn9dY5XZx/oQ=; b=akCVNn+0nmdui0iqIpo+c0NLByEDuPMIx1jUL7WcYwZZBBUfjkeCvbKf4xUGvQPTiQ Z8vrXHH41Nu+Y7rcWFXF8A/zTem1DzV4fCI13tWZohCU15oG7FoK+gWpH22pWKTlX+rf dpDU8Biumjpcd9sBVUo5CbN0flFk6sw1dhM8sWJwTTVDf5p2K4RF18A20pEJyb1uT7q6 HaMp9Qjw/qIVqP6+lWu5MlD8ZcqVBQJQcnqYjnvtJd5vI+RADnelpt6D84eLfSZy3oSM /AbWlv3lUDaFKGFGupt7437Jwmdtd6k/XlKFEi859YtGFYtzf9hNYxQcKucFb4+HtZOG TYjQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b="PC4/IFUe"; arc=pass (i=1 spf=pass spfdomain=ti.com dkim=pass dkdomain=ti.com dmarc=pass fromdomain=ti.com); spf=pass (google.com: domain of linux-kernel+bounces-127936-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-127936-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id ma16-20020a170903095000b001e230863a47si9202441plb.571.2024.04.02.05.30.32 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 02 Apr 2024 05:30:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-127936-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b="PC4/IFUe"; arc=pass (i=1 spf=pass spfdomain=ti.com dkim=pass dkdomain=ti.com dmarc=pass fromdomain=ti.com); spf=pass (google.com: domain of linux-kernel+bounces-127936-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-127936-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com 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 956CF2844F8 for ; Tue, 2 Apr 2024 12:30:31 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 8687E7A140; Tue, 2 Apr 2024 12:30:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="PC4/IFUe" Received: from fllv0015.ext.ti.com (fllv0015.ext.ti.com [198.47.19.141]) (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 C3FC6335A7; Tue, 2 Apr 2024 12:30:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.47.19.141 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712061019; cv=none; b=lViCyPhxAu6dt0EFjghEWld6t4vAWLJn+BvcjEHxxeHvYLRCzEdezm1D2VscHSdWdvWQmFcGrZB3EKOrdfe13qfqXf1brp9X3Acl39rhfQH0tHl8rUv2anYVNRs/ivJEsUL0yIWaLAwNiViA5tGkFDpB2m3fs1gYcdwOLfCqtdc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712061019; c=relaxed/simple; bh=ITCvpKJ5crNKh2Mzg3Vl0P7uLJLninjN71HBR/CKb7c=; h=Date:From:To:CC:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=Ivye3u00YizWjedapZIUwpRXvN7/2lO6Gju7oySV2y0VWfdrOHNhc6uZJUWzwOgCLGmyqXo8LBu7Ci+0aVFjdNlYVdYcfhKf+TVfwr8sxNiOjqMsQXk7zcBfoWVJDCF3Zj5QElJmEkBRMkc6arlC8F7EefM1MRPtFr5Zsm6+DZ4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com; spf=pass smtp.mailfrom=ti.com; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b=PC4/IFUe; arc=none smtp.client-ip=198.47.19.141 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ti.com Received: from lelv0265.itg.ti.com ([10.180.67.224]) by fllv0015.ext.ti.com (8.15.2/8.15.2) with ESMTP id 432CU64D047428; Tue, 2 Apr 2024 07:30:06 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1712061006; bh=rGB3cBxrxbzfkvdRjNadDZ6vfn6sw2z3o275CLvw278=; h=Date:From:To:CC:Subject:References:In-Reply-To; b=PC4/IFUe05AXGx8mHQVVXUvyBHzEtHrFVPtrFW9ScWZJLJ+9tM2V0Nqv1yA7i+JIe FWxt3BBQKqPi88nL0vK0K0HbIJ1M8vjYxj8lPXlTQUbAQPnoxHODwUKJo+daDTvRdY +WtWeiI2TxyvFOyeFm5vc9Zw37ux5gITeIyeu6mg= Received: from DFLE106.ent.ti.com (dfle106.ent.ti.com [10.64.6.27]) by lelv0265.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 432CU2nT025956 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Tue, 2 Apr 2024 07:30:06 -0500 Received: from DFLE109.ent.ti.com (10.64.6.30) by DFLE106.ent.ti.com (10.64.6.27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Tue, 2 Apr 2024 07:30:03 -0500 Received: from lelvsmtp6.itg.ti.com (10.180.75.249) by DFLE109.ent.ti.com (10.64.6.30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Tue, 2 Apr 2024 07:30:03 -0500 Received: from localhost (uda0492258.dhcp.ti.com [172.24.227.9]) by lelvsmtp6.itg.ti.com (8.15.2/8.15.2) with ESMTP id 432CU261087192; Tue, 2 Apr 2024 07:30:03 -0500 Date: Tue, 2 Apr 2024 18:00:02 +0530 From: Siddharth Vadapalli To: Krzysztof Kozlowski CC: Siddharth Vadapalli , , , , , , , , Subject: Re: [PATCH] dt-bindings: mfd: syscon: Add ti,am62p-cpsw-mac-efuse compatible Message-ID: <30065bdc-ccef-4610-b1c1-7661f801b8e9@ti.com> References: <20240402105708.4114146-1-s-vadapalli@ti.com> <2e9b6a91-43d3-4b23-830d-40e607505d8c@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <2e9b6a91-43d3-4b23-830d-40e607505d8c@kernel.org> X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 On Tue, Apr 02, 2024 at 02:08:32PM +0200, Krzysztof Kozlowski wrote: > On 02/04/2024 12:57, Siddharth Vadapalli wrote: > > The CTRLMMR_MAC_IDx registers within the CTRL_MMR space of TI's AM62p SoC > > contain the MAC Address programmed in the eFuse. Add compatible for > > allowing the CPSW driver to obtain a regmap for the CTRLMMR_MAC_IDx > > registers within the System Controller device-tree node. The default MAC > > Address for the interface corresponding to the first MAC port will be set > > to the value programmed in the eFuse. > > > > Signed-off-by: Siddharth Vadapalli > > --- > > > > This patch is based on linux-next tagged next-20240402. > > Where is the DTS using it? The current implementation in the device-tree for older TI K3 SoCs is as follows: cpsw_port1: port@1 { reg = <1>; ti,mac-only; label = "port1"; phys = <&phy_gmii_sel 1>; mac-address = [00 00 00 00 00 00]; ti,syscon-efuse = <&wkup_conf 0x200>; }; The "ti,syscon-efuse" property passes the reference to the System Controller node as well as the offset to the CTRLMMR_MAC_IDx registers within the CTRL_MMR space. This implementation works only when the System Controller node (wkup_conf or its equivalent depending on the SoC) has the compatible "syscon". From AM62p SoC onwards, it was decided that the System Controller nodes have to be modelled as a "simple-bus", due to which the "syscon" based regmapping within the driver that uses the "ti,syscon-efuse" property will no longer work directly. Therefore, with this patch, the upcoming device-tree changes for AM62p will be: 1) Update in the System Controller node to use the newly added compatible for mapping the CTRLMMR_MAC_IDx registers: wkup_conf: bus@43000000 { compatible = "simple-bus"; reg = <0x00 0x43000000 0x00 0x20000>; #address-cells = <1>; #size-cells = <1>; ranges = <0x00 0x00 0x43000000 0x20000>; bootph-all; chipid: chipid@14 { reg = <0x14 0x4>; bootph-all; }; + + cpsw_mac_efuse: cpsw-mac-efuse@200 { + compatible = "ti,am62p-cpsw-mac-efuse", "syscon"; + reg = <0x200 0x8>; + }; }; 2) Update within the cpsw_port1 node for passing the "cpsw_mac_efuse" node: cpsw_port1: port@1 { reg = <1>; ti,mac-only; label = "port1"; phys = <&phy_gmii_sel 1>; mac-address = [00 00 00 00 00 00]; + ti,syscon-efuse = <&cpsw_mac_efuse 0x0>; }; > > Acked-by: Krzysztof Kozlowski Thank you for reviewing and acking this patch. Regards, Siddharth.