[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YV5CJvb2k1/61IU2@lunn.ch>
Date: Thu, 7 Oct 2021 02:41:10 +0200
From: Andrew Lunn <andrew@...n.ch>
To: Ansuel Smith <ansuelsmth@...il.com>
Cc: Vivien Didelot <vivien.didelot@...il.com>,
Florian Fainelli <f.fainelli@...il.com>,
Vladimir Oltean <olteanv@...il.com>,
"David S. Miller" <davem@...emloft.net>,
Jakub Kicinski <kuba@...nel.org>,
Rob Herring <robh+dt@...nel.org>,
Heiner Kallweit <hkallweit1@...il.com>,
Russell King <linux@...linux.org.uk>, netdev@...r.kernel.org,
devicetree@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [net-next PATCH 12/13] drivers: net: dsa: qca8k: add support for
pws config reg
> +static int
> +qca8k_setup_of_pws_reg(struct qca8k_priv *priv)
> +{
> + struct device_node *node = priv->dev->of_node;
> + u32 val = 0;
> +
> + if (priv->switch_id == QCA8K_ID_QCA8327)
> + if (of_property_read_bool(node, "qca,package48"))
> + val |= QCA8327_PWS_PACKAGE48_EN;
What does this actually do? How is PACKAGE48 different to normal mode?
> +
> + if (of_property_read_bool(node, "qca,power-on-sel"))
> + val |= QCA8K_PWS_POWER_ON_SEL;
What happens if you unconditionally do this? Why is a DT property
required?
> +
> + if (of_property_read_bool(node, "qca,led-open-drain"))
> + /* POWER_ON_SEL needs to be set when configuring led to open drain */
> + val |= QCA8K_PWS_LED_OPEN_EN_CSR | QCA8K_PWS_POWER_ON_SEL;
This is getting into territory of adding LED support for PHYs, which
we want to do via the LED subsystem.
Andrew
Powered by blists - more mailing lists