Thread (12 messages) 12 messages, 5 authors, 2024-02-23

Re: [PATCH 1/2] dt-bindings: net: Add TI DP83640

From: Conor Dooley <conor@kernel.org>
Date: 2024-01-31 21:18:44
Also in: linux-devicetree, lkml

On Wed, Jan 31, 2024 at 03:05:21PM -0600, Rob Herring wrote:
On Tue, Jan 30, 2024 at 05:56:37PM +0000, Conor Dooley wrote:
quoted
On Tue, Jan 30, 2024 at 09:59:34AM +0100, Bastien Curutchet wrote:
quoted
quoted
+  ti,fiber-mode:
+    $ref: /schemas/types.yaml#/definitions/uint32
+    enum: [0, 1]
+    description: |
+      If present, enables or disables the FX Fiber Mode.
+      Fiber mode support can also be strapped. If the strap pin is not set
+      correctly or not set at all then this can be used to configure it.
+       - 0     = FX Fiber Mode disabled
+       - 1     = FX Fiber Mode enabled
+       - unset = Configured by straps
I don't like these properties that map meanings onto numbers. We can
have enums of strings in bindings that allow you to use something more
meaningful than "0" or "1".
Tristate properties are fairly common pattern where we need 
on/off/default. I've thought about making it a type. I don't think we 
need defines for it.
I think a type would be a good idea. I am not at all a fan of any of the
properties people introduce along these lines.

Attachments

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help