From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wm1-f47.google.com (mail-wm1-f47.google.com [209.85.128.47]) (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 7F9E1328B61 for ; Mon, 15 Dec 2025 10:59:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.47 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1765796358; cv=none; b=KxB/dF+rPg5vjdsDOIm0w9LeIPHo0H6dytaVacqohyb9sPn8e21woxW1QO2N6+sjsDwAnqafYZB3Za0frvswV5n75EyP7q2M0d/Tngv/PlCg9oaLnsCPylxpW7OTwGfPVp7EyyJ4lO74oafW56CnI6Ixx7e101dUtUReZv/SuWQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1765796358; c=relaxed/simple; bh=djrbPV7aDjAG4Ht6zJYVPSbYH7m2DhrIo7FgNqH8XGY=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=GChuBnvh4PNuZ27u1Qsq5vFjqo9LZ9lAelr5ZB+1oK8j6Evlz5bXtCXNu6BoE0EwCXD5O7fxl30fbDxAbNjn62VDdCN66nw0KeTjZjxh3lqU4yfWyD9Ln7I9fHVnOOROpS1LclxEYmlYUCd+rAj63Sg21+OSZPVOL0g3rWi0LmA= 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=dq1hSwv7; arc=none smtp.client-ip=209.85.128.47 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 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="dq1hSwv7" Received: by mail-wm1-f47.google.com with SMTP id 5b1f17b1804b1-4779ce2a624so37136115e9.2 for ; Mon, 15 Dec 2025 02:59:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1765796354; x=1766401154; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=oYqXtVKyq57wNwuuGpuKCQcMdBdTV6AFm/yWfAMKePQ=; b=dq1hSwv7Bf7kevWDaBVK2hYzelzZep3k88xx7Es6Cv158rHVW3rFbeqPfMn75fdl8C nL0i5r1lZ32nPCDmdybIuC3hTXvkyjy/VJbCjfJWoq4jy4hfChqzh5KRMbFpuWZ5nZxj qOAuB8Jg2eLInUdJ7cF2vqrE8MNSstrXNd2manO2V6HrWRuXgFBIjwvvVwY1vF6g3Tj8 CXiPKZ8QU0yk7+BQEqZABaq0UBMHILqJZHQiy/8o6B5KmjD3LMVC3rEhKLYhJ4sDIE3w dOnWeV5X+8oyobrbf+c0yZntu+FvTp7Ig79M61biZTJk5ApFlaqZauVh1f1sMdXIGwYG mBNg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1765796354; x=1766401154; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-gg:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=oYqXtVKyq57wNwuuGpuKCQcMdBdTV6AFm/yWfAMKePQ=; b=aCg8E7MGgFIhohjrv54T4Bd/zosNqJZqUjb3sMp3E1UJBlE5LEDzDNU9eTPKItuU2G bVkk9g4ThNkWshxStkWNMJ6OCQTAodBTxjyT1JJ3OGq3jJKzJr05zhRfXBhm9fDqPz2Q 2aEQtPPe9vy+VXqntS2IN2jqxyoXLihAzMXBB09VxmN1rgSWGcDb3zzicWHDy176IAtb rSqlO1RJ3k4ksnbgazRb/EWQOtXTGTTvZ8xWYIm6QY1CRmJWPy7oRroW7F5jN73UJODv x+10L4HLC3I9XNUtVdXRCq31Zr9/5e/NsT781O/ZPR7IME1BSBthXh2qmThOIuF2VAxy bzTA== X-Forwarded-Encrypted: i=1; AJvYcCVhwrzkfIUrkon99eBTQcVeCFxGpTZrL40oIln+L42qCmDHBdmT4gOTqPDVCWWzVqcLxb+4cXv+qmZ81ug=@vger.kernel.org X-Gm-Message-State: AOJu0YylUsOHtzQzSCfZezxiTc81QfmMMBHrE94+IMKtXrW5kE70Qk9C sXydRHEJ0sy+LCCs7SKWuWvan3vdufMyuqIh6XNKjaDyDSCCGcd9INk1LZRl6QA48SU= X-Gm-Gg: AY/fxX5CvGWmie69hI4uH/S/MJrlsgW+3E+S4kHiwYCjM/IuK0MLImIgbWbBuYWc8XS d0S7grh00RoLe0Hy3eWt4nHNLKbTA7lBPCXPMdEJ41P/WLtlSlZVmWjZtl/tB3EVzSGtoCDmkon rT1YGSPtgs7WUb70IApW+wjtoKyIJPOeH5K1580z6em1wDcHEwAIuiZ1skMcjPDmmarmmhSL8ej PlFfvlji8cQ4xn4z02q1P5dx7FHwQNuw5BMsqkKfRWl93cXHnsJL0UqRJC+gUGG9kKUXq24drET YxymUbZuuCC6Z/yuJdQ1Ovu2ry+WH5amv0amBgKhqiH2fpXv8hBfnliRHli7CH5cZn6r3FETGaN qy6zyfonwSY4wjJMRIAn88zilxWzIDRa0w2+kbqtQz8SlQp22eOy3B1trO8cKQg3SdAcANJotWd WpZp5u5tqUsnoYb1zy X-Google-Smtp-Source: AGHT+IHzuHMc+1EqAojQlJLPTccSt6L/oqVylXvWSnMxI2jVuwsY9rZt+YJM1Zn/rmatqjYye/VhgA== X-Received: by 2002:a05:600c:a31a:b0:47a:9165:efc4 with SMTP id 5b1f17b1804b1-47a9165f157mr86631275e9.33.1765796353574; Mon, 15 Dec 2025 02:59:13 -0800 (PST) Received: from localhost ([196.207.164.177]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-47a8f6e5baasm191989945e9.13.2025.12.15.02.59.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 15 Dec 2025 02:59:13 -0800 (PST) Date: Mon, 15 Dec 2025 13:59:09 +0300 From: Dan Carpenter To: Krzysztof Kozlowski Cc: Jan Petrous , s32@nxp.com, Andrew Lunn , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linaro-s32@linaro.org Subject: Re: [PATCH 3/4] dt-bindings: net: nxp,s32-dwmac: Use the GPR syscon Message-ID: References: <333487ea3d23699c7953524cda082813ac4d7be3.1764592300.git.dan.carpenter@linaro.org> <16bb96e9-c632-457c-8179-82c17bd2a685@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: <16bb96e9-c632-457c-8179-82c17bd2a685@kernel.org> On Mon, Dec 01, 2025 at 06:33:07PM +0100, Krzysztof Kozlowski wrote: > On 01/12/2025 14:08, Dan Carpenter wrote: > > The S32 chipset has a GPR region which has a miscellaneous registers > > including the GMAC_0_CTRL_STS register. Originally this code accessed > > that register in a sort of ad-hoc way, but we want to access it using > > the syscon interface. > > > > We still need to maintain the old method of accessing the GMAC register > > but using a syscon will let us access other registers more cleanly. > > > > Signed-off-by: Dan Carpenter > > --- > > Documentation/devicetree/bindings/net/nxp,s32-dwmac.yaml | 6 ++++++ > > 1 file changed, 6 insertions(+) > > > > diff --git a/Documentation/devicetree/bindings/net/nxp,s32-dwmac.yaml b/Documentation/devicetree/bindings/net/nxp,s32-dwmac.yaml > > index 2b8b74c5feec..17f6c50dca03 100644 > > --- a/Documentation/devicetree/bindings/net/nxp,s32-dwmac.yaml > > +++ b/Documentation/devicetree/bindings/net/nxp,s32-dwmac.yaml > > @@ -32,6 +32,11 @@ properties: > > - description: Main GMAC registers > > - description: GMAC PHY mode control register > > > > + phy-sel: > > Missing vendor prefix. > > > + $ref: /schemas/types.yaml#/definitions/phandle-array > > + items: > > + - description: The offset into the s32 GPR syscon > > No, first item is not the offset but the phandle. You need syntax like here: > > https://elixir.bootlin.com/linux/v5.18-rc1/source/Documentation/devicetree/bindings/soc/samsung/exynos-usi.yaml#L42 > > The description of the first item (unlike in example above) should say > what is the purpose, how this device is using GPR region, what is it > needed for. I had to do it a bit differently from the exynos-usi.yaml code. When I tried it that way I got the following warning that the "phy-sel" wasn't a common suffix and it doesn't have a description. $ make dt_binding_check DT_SCHEMA_FILES=net/nxp,s32-dwmac.yaml SCHEMA Documentation/devicetree/bindings/processed-schema.json CHKDT ./Documentation/devicetree/bindings /home/dcarpenter/progs/kernel/nxp_gpr/Documentation/devicetree/bindings/net/nxp,s32-dwmac.yaml: properties:nxp,phy-sel: 'anyOf' conditional failed, one must be fixed: 'description' is a dependency of '$ref' '/schemas/types.yaml#/definitions/phandle-array' does not match '^#/(definitions|\\$defs)/' hint: A vendor property can have a $ref to a a $defs schema hint: Vendor specific properties must have a type and description unless they have a defined, common suffix. from schema $id: http://devicetree.org/meta-schemas/vendor-props.yaml# LINT ./Documentation/devicetree/bindings DTEX Documentation/devicetree/bindings/net/nxp,s32-dwmac.example.dts DTC [C] Documentation/devicetree/bindings/net/nxp,s32-dwmac.example.dtb The exynos-usi.yaml file doesn't generate a warning like that and I wasn't able to figure out why that is. But what worked for me was adding the phandle description like this: nxp,phy-sel: description: phandle to the GPR syscon node $ref: /schemas/types.yaml#/definitions/phandle-array items: - description: offset of PHY selection register regards, dan carpenter