From mboxrd@z Thu Jan 1 00:00:00 1970 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 080413C5DB0; Wed, 18 Mar 2026 16:38:42 +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=1773851922; cv=none; b=E1/cLNqeypvO/9ACqQYiZN2A7druOc0PR9dQi7cAkBP8f0wckMHXurF5W/TNnBsIUoXPBHJL814jGnWhvshbMl1MHR1d6uSjjYopX4x8CSwJMFsyjqXyKR7SLx7aIa3VWWr8apdSCGGGvF3gKdaeft54QGkXOXfXkWmsHCK+1DY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773851922; c=relaxed/simple; bh=gjHC8nKBbyN/J7nUktQURQT8MLrY5TCbtclmLfjJxcY=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=cktNEwN43b3PJdu0v3OMTnTBQKLrfXIL0cbf+uwHvB0TwXz93iHs9dlCVK3+0HoT3QZwpJY7rKWcjy8UC7xAK+h0nvohx2YILrjN3tSKtniWXV6dByEarO9He7uGij/N9gz1+V2ymmmGSlShv2NAeiBllN9E8i5RmF0KDiccFx4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=S/FKct6+; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="S/FKct6+" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7823DC2BCB2; Wed, 18 Mar 2026 16:38:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1773851921; bh=gjHC8nKBbyN/J7nUktQURQT8MLrY5TCbtclmLfjJxcY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=S/FKct6+uK+T5Tfm5J8abXN6B2PFfJyBjsDFx4A5VbcORHRuI5TwGXnhQhk2Vyfp4 gCSu1s0vr49Y6T6FxWP+l63sxrbo+GlzYbtXmFZLCgU3PQS85P6sjtRKEn6eKnwJnP DeNzS8TcTHDf3pJwsvcd+9rmmM2O7Lk1kcVM3xtHwRvo1nRkd02wCXh9yMe+qd6xmy QHPlwPgxCMeUjLrsFX1c63Xu5MuHmIZQsHz4M/S76YPAdrMjAtpl8tuvOmkbRQP7BQ TIdOq1W/bsnwS/XN71qoM1DrIydNUhRDzmA1FmjRtlKHDzrILTjfjAhmQO6vwmX34i vo2aTjY1Tc27Q== From: Conor Dooley To: netdev@vger.kernel.org Cc: conor@kernel.org, Conor Dooley , Valentina.FernandezAlanis@microchip.com, Andrew Lunn , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Daire McNamara , Paul Walmsley , Palmer Dabbelt , Albert Ou , Alexandre Ghiti , Nicolas Ferre , Claudiu Beznea , Richard Cochran , Samuel Holland , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org, Dave Stevenson , Sean Anderson , Vineeth Karumanchi , Abin Joseph , =?UTF-8?q?Th=C3=A9o=20Lebrun?= , Ryan.Wanner@microchip.com, Krzysztof Kozlowski Subject: [PATCH net-next v4 09/13] dt-bindings: net: macb: add property indicating timer adjust mode Date: Wed, 18 Mar 2026 16:37:40 +0000 Message-ID: <20260318-overdue-rotten-0edf34901a3d@spud> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20260318-surpass-puzzle-f94b46aa8808@spud> References: <20260318-surpass-puzzle-f94b46aa8808@spud> Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=2116; i=conor.dooley@microchip.com; h=from:subject:message-id; bh=g/wRNKNLFPT+82I0uxzexOCw4Xbz/Y2VsmMJeulMEF0=; b=owGbwMvMwCVWscWwfUFT0iXG02pJDJm7rly6LfIuj32O8wEvx7OSbabC1dvdlVOWHsiQ8Fghy qw5+5BaRykLgxgXg6yYIkvi7b4WqfV/XHY497yFmcPKBDKEgYtTACaS4MXwV27HlyWqCYyNx7sL Pk7lz54Xe/nHJ+upqrtFJzZwKa8MP8zwv+7fpGqmvgnnUpNCtgQbNLe3Pwyb5TAp/kVG1pp3E2q 7OQA= X-Developer-Key: i=conor.dooley@microchip.com; a=openpgp; fpr=F9ECA03CF54F12CD01F1655722E2C55B37CF380C Content-Transfer-Encoding: 8bit From: Conor Dooley The GEM IP has two methods for modifying the ptp timer. The first of these, named "increment mode", relies on software controlling the timer by setting tsu_timer_incr and tsu_timer_incr_sub_nsec and performing once-off adjustments via the tsu_timer_adjust register. This is what the macb driver uses. The second mechanism, "timer adjust mode" uses the gem_tsu_inc_ctrl and gem_tsu_ms signals to control the timer. These modes are not intended to be used in parallel, but both can be possible on the same device and which mode is used cannot be determined from the compatible on all devices, because some users of the GEM IP are SoC FPGAs that permit configuring how the IP is wired up. Add a property to indicate that gem_tsu_inc_ctrl and gem_tsu_ms are wired up for timer adjust mode. Reviewed-by: Krzysztof Kozlowski Signed-off-by: Conor Dooley --- .../devicetree/bindings/net/cdns,macb.yaml | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/Documentation/devicetree/bindings/net/cdns,macb.yaml b/Documentation/devicetree/bindings/net/cdns,macb.yaml index f6df793c4af65..b9caa7e5ef328 100644 --- a/Documentation/devicetree/bindings/net/cdns,macb.yaml +++ b/Documentation/devicetree/bindings/net/cdns,macb.yaml @@ -150,6 +150,12 @@ properties: that need to be filled, before the forwarding process is activated. Width of the SRAM is platform dependent, and can be 4, 8 or 16 bytes. + cdns,timer-adjust: + type: boolean + description: + Set when the hardware is operating in timer-adjust mode, where the timer + is controlled by the gem_tsu_inc_ctrl and gem_tsu_ms inputs. + '#address-cells': const: 1 @@ -199,6 +205,15 @@ allOf: properties: reg: maxItems: 1 + - if: + not: + properties: + compatible: + contains: + const: microchip,mpfs-macb + then: + properties: + cdns,timer-adjust: false - if: properties: -- 2.51.0