<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/net/dsa/bcm_sf2.h, branch linux-rolling-stable</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-rolling-stable</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-rolling-stable'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2024-11-03T18:36:34Z</updated>
<entry>
<title>net: dsa: use ethtool string helpers</title>
<updated>2024-11-03T18:36:34Z</updated>
<author>
<name>Rosen Penev</name>
</author>
<published>2024-10-28T04:48:28Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=f12b363887c706c40611fba645265527a8415832'/>
<id>urn:sha1:f12b363887c706c40611fba645265527a8415832</id>
<content type='text'>
These are the preferred way to copy ethtool strings.

Avoids incrementing pointers all over the place.

Signed-off-by: Rosen Penev &lt;rosenp@gmail.com&gt;
(for hellcreek driver)
Reviewed-by: Kurt Kanzenbach &lt;kurt@linutronix.de&gt;
Link: https://patch.msgid.link/20241028044828.1639668-1-rosenp@gmail.com
Signed-off-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
</content>
</entry>
<entry>
<title>net: dsa: bcm_sf2: fix crossbar port bitwidth logic</title>
<updated>2024-10-04T23:16:15Z</updated>
<author>
<name>Sam Edwards</name>
</author>
<published>2024-10-03T21:23:01Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=41378cfdc47fdbfbf4358b85546f7c2f5f671534'/>
<id>urn:sha1:41378cfdc47fdbfbf4358b85546f7c2f5f671534</id>
<content type='text'>
The SF2 crossbar register is a packed bitfield, giving the index of the
external port selected for each of the internal ports. On BCM4908 (the
only currently-supported switch family with a crossbar), there are 2
internal ports and 3 external ports, so there are 2 bits per internal
port.

The driver currently conflates the "bits per port" and "number of ports"
concepts, lumping both into the `num_crossbar_int_ports` field. Since it
is currently only possible for either of these counts to have a value of
2, there is no behavioral error resulting from this situation for now.

Make the code more readable (and support the future possibility of
larger crossbars) by adding a `num_crossbar_ext_bits` field to represent
the "bits per port" count and relying on this where appropriate instead.

Signed-off-by: Sam Edwards &lt;CFSworks@gmail.com&gt;
Reviewed-by: Florian Fainelli &lt;florian.fainelli@broadcom.com&gt;
Link: https://patch.msgid.link/20241003212301.1339647-1-CFSworks@gmail.com
Signed-off-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
</content>
</entry>
<entry>
<title>net: dsa: bcm_sf2: drop priv-&gt;master_mii_dn</title>
<updated>2024-01-05T11:56:36Z</updated>
<author>
<name>Vladimir Oltean</name>
</author>
<published>2024-01-04T14:00:37Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=45f62ca5cc4861d084744e79642a4969848593eb'/>
<id>urn:sha1:45f62ca5cc4861d084744e79642a4969848593eb</id>
<content type='text'>
There used to be a of_node_put(priv-&gt;master_mii_dn) call in
bcm_sf2_mdio_unregister(), which was accidentally deleted in commit
6ca80638b90c ("net: dsa: Use conduit and user terms").

But it's not needed - we don't need to hold a reference on the
"brcm,unimac-mdio" OF node for that long, since we don't do anything
with it. We can release it as soon as we finish bcm_sf2_mdio_register().

Also reduce "if (err &amp;&amp; dn)" to just "if (err)". We know "dn", aka the
former priv-&gt;master_mii_dn, is non-NULL. Otherwise, of_mdio_find_bus(dn)
would not have been able to find the bus behind "brcm,unimac-mdio".

Signed-off-by: Vladimir Oltean &lt;vladimir.oltean@nxp.com&gt;
Reviewed-by: Alvin Šipraga &lt;alsi@bang-olufsen.dk&gt;
Reviewed-by: Florian Fainelli &lt;florian.fainelli@broadcom.com&gt;
Tested-by: Florian Fainelli &lt;florian.fainelli@broadcom.com&gt;
Reviewed-by: Luiz Angelo Daros de Luca &lt;luizluca@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: dsa: Use conduit and user terms</title>
<updated>2023-10-24T20:08:14Z</updated>
<author>
<name>Florian Fainelli</name>
</author>
<published>2023-10-23T18:17:28Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=6ca80638b90cec66547011ee1ef79e534589989a'/>
<id>urn:sha1:6ca80638b90cec66547011ee1ef79e534589989a</id>
<content type='text'>
Use more inclusive terms throughout the DSA subsystem by moving away
from "master" which is replaced by "conduit" and "slave" which is
replaced by "user". No functional changes.

Acked-by: Rob Herring &lt;robh@kernel.org&gt;
Acked-by: Stephen Hemminger &lt;stephen@networkplumber.org&gt;
Reviewed-by: Vladimir Oltean &lt;vladimir.oltean@nxp.com&gt;
Signed-off-by: Florian Fainelli &lt;florian.fainelli@broadcom.com&gt;
Link: https://lore.kernel.org/r/20231023181729.1191071-2-florian.fainelli@broadcom.com
Signed-off-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
</content>
</entry>
<entry>
<title>net: dsa: bcm_sf2: refactor LED regs access</title>
<updated>2021-12-31T01:28:32Z</updated>
<author>
<name>Rafał Miłecki</name>
</author>
<published>2021-12-29T17:16:42Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=af30f8eaa8fe4ff1987280f716309711997bd979'/>
<id>urn:sha1:af30f8eaa8fe4ff1987280f716309711997bd979</id>
<content type='text'>
1. Define more regs. Some switches (e.g. BCM4908) have up to 6 regs.
2. Add helper for handling non-lineral port &lt;-&gt; reg mappings.
3. Add support for 12 B LED reg blocks on BCM4908 (different layout)

Complete support for LEDs setup will be implemented once Linux receives
a proper design &amp; implementation for "hardware" LEDs.

Signed-off-by: Rafał Miłecki &lt;rafal@milecki.pl&gt;
Acked-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Link: https://lore.kernel.org/r/20211229171642.22942-1-zajec5@gmail.com
Signed-off-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
</content>
</entry>
<entry>
<title>net: dsa: bcm_sf2: setup BCM4908 internal crossbar</title>
<updated>2021-03-13T01:06:37Z</updated>
<author>
<name>Rafał Miłecki</name>
</author>
<published>2021-03-12T10:41:08Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a9349f08ec6c1251d41ef167d27a15cc39bc5b97'/>
<id>urn:sha1:a9349f08ec6c1251d41ef167d27a15cc39bc5b97</id>
<content type='text'>
On some SoCs (e.g. BCM4908, BCM631[345]8) SF2 has an integrated
crossbar. It allows connecting its selected external ports to internal
ports. It's used by vendors to handle custom Ethernet setups.

BCM4908 has following 3x2 crossbar. On Asus GT-AC5300 rgmii is used for
connecting external BCM53134S switch. GPHY4 is usually used for WAN
port. More fancy devices use SerDes for 2.5 Gbps Ethernet.

              ┌──────────┐
SerDes ─── 0 ─┤          │
              │   3x2    ├─ 0 ─── switch port 7
 GPHY4 ─── 1 ─┤          │
              │ crossbar ├─ 1 ─── runner (accelerator)
 rgmii ─── 2 ─┤          │
              └──────────┘

Use setup data based on DT info to configure BCM4908's switch port 7.
Right now only GPHY and rgmii variants are supported. Handling SerDes
can be implemented later.

Signed-off-by: Rafał Miłecki &lt;rafal@milecki.pl&gt;
Acked-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: dsa: bcm_sf2: store PHY interface/mode in port structure</title>
<updated>2021-03-13T01:06:37Z</updated>
<author>
<name>Rafał Miłecki</name>
</author>
<published>2021-03-12T10:41:07Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=01488a0ccd9abe15565bed50a45afcddbb0fe199'/>
<id>urn:sha1:01488a0ccd9abe15565bed50a45afcddbb0fe199</id>
<content type='text'>
It's needed later for proper switch / crossbar setup.

Signed-off-by: Rafał Miłecki &lt;rafal@milecki.pl&gt;
Acked-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: dsa: bcm_sf2: recalculate switch clock rate based on ports</title>
<updated>2020-09-03T22:08:03Z</updated>
<author>
<name>Florian Fainelli</name>
</author>
<published>2020-09-01T22:59:13Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=2ee3adc4aef58087754a03a3774435a7224fd1b4'/>
<id>urn:sha1:2ee3adc4aef58087754a03a3774435a7224fd1b4</id>
<content type='text'>
Whenever a port gets enabled/disabled, recalcultate the required switch
clock rate to make sure it always gets set to the expected rate
targeting our switch use case. This is only done for the BCM7445 switch
as there is no clocking profile available for BCM7278.

Signed-off-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: dsa: bcm_sf2: request and handle clocks</title>
<updated>2020-09-03T22:08:03Z</updated>
<author>
<name>Florian Fainelli</name>
</author>
<published>2020-09-01T22:59:12Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e9ec5c3bd238f2cbe9d9696e994f36d1b249c058'/>
<id>urn:sha1:e9ec5c3bd238f2cbe9d9696e994f36d1b249c058</id>
<content type='text'>
Fetch the corresponding clock resource and enable/disable it during
suspend/resume if and only if we have no ports defined for Wake-on-LAN.

Signed-off-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: dsa: bcm_sf2: Add support for optional reset controller line</title>
<updated>2019-11-06T02:06:38Z</updated>
<author>
<name>Florian Fainelli</name>
</author>
<published>2019-11-04T21:51:39Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=eee87e4377a4b86dc2eea0ade162b0dc33f40576'/>
<id>urn:sha1:eee87e4377a4b86dc2eea0ade162b0dc33f40576</id>
<content type='text'>
Grab an optional and exclusive reset controller line for the switch and
manage it during probe/remove functions accordingly. For 7278 devices we
change bcm_sf2_sw_rst() to use the reset controller line since the
WATCHDOG_CTRL register does not reset the switch contrary to stated
documentation.

Signed-off-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
</feed>
