<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux.git/net/dsa/dsa2.c, branch v5.4</title>
<subtitle>Linux kernel source tree</subtitle>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/'/>
<entry>
<title>net: dsa: fix switch tree list</title>
<updated>2019-10-19T19:19:41+00:00</updated>
<author>
<name>Vivien Didelot</name>
<email>vivien.didelot@gmail.com</email>
</author>
<published>2019-10-18T21:02:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=50c7d2ba9de20f60a2d527ad6928209ef67e4cdd'/>
<id>50c7d2ba9de20f60a2d527ad6928209ef67e4cdd</id>
<content type='text'>
If there are multiple switch trees on the device, only the last one
will be listed, because the arguments of list_add_tail are swapped.

Fixes: 83c0afaec7b7 ("net: dsa: Add new binding implementation")
Signed-off-by: Vivien Didelot &lt;vivien.didelot@gmail.com&gt;
Reviewed-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If there are multiple switch trees on the device, only the last one
will be listed, because the arguments of list_add_tail are swapped.

Fixes: 83c0afaec7b7 ("net: dsa: Add new binding implementation")
Signed-off-by: Vivien Didelot &lt;vivien.didelot@gmail.com&gt;
Reviewed-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge ra.kernel.org:/pub/scm/linux/kernel/git/netdev/net</title>
<updated>2019-09-17T21:51:10+00:00</updated>
<author>
<name>David S. Miller</name>
<email>davem@davemloft.net</email>
</author>
<published>2019-09-17T21:51:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=1bab8d4c488be22d57f9dd09968c90a0ddc413bf'/>
<id>1bab8d4c488be22d57f9dd09968c90a0ddc413bf</id>
<content type='text'>
Pull in bug fixes from 'net' tree for the merge window.

Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Pull in bug fixes from 'net' tree for the merge window.

Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: dsa: Fix load order between DSA drivers and taggers</title>
<updated>2019-09-15T18:49:19+00:00</updated>
<author>
<name>Andrew Lunn</name>
<email>andrew@lunn.ch</email>
</author>
<published>2019-09-12T13:16:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=23426a25e55a417dc104df08781b6eff95e65f3f'/>
<id>23426a25e55a417dc104df08781b6eff95e65f3f</id>
<content type='text'>
The DSA core, DSA taggers and DSA drivers all make use of
module_init(). Hence they get initialised at device_initcall() time.
The ordering is non-deterministic. It can be a DSA driver is bound to
a device before the needed tag driver has been initialised, resulting
in the message:

No tagger for this switch

Rather than have this be fatal, return -EPROBE_DEFER so that it is
tried again later once all the needed drivers have been loaded.

Fixes: d3b8c04988ca ("dsa: Add boilerplate helper to register DSA tag driver modules")
Signed-off-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The DSA core, DSA taggers and DSA drivers all make use of
module_init(). Hence they get initialised at device_initcall() time.
The ordering is non-deterministic. It can be a DSA driver is bound to
a device before the needed tag driver has been initialised, resulting
in the message:

No tagger for this switch

Rather than have this be fatal, return -EPROBE_DEFER so that it is
tried again later once all the needed drivers have been loaded.

Fixes: d3b8c04988ca ("dsa: Add boilerplate helper to register DSA tag driver modules")
Signed-off-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: dsa: Fix off-by-one number of calls to devlink_port_unregister</title>
<updated>2019-09-02T18:59:29+00:00</updated>
<author>
<name>Vladimir Oltean</name>
<email>olteanv@gmail.com</email>
</author>
<published>2019-08-31T12:46:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=4ba0ebbc6cdecb9fad7c551a3d97b172ebc7b2fa'/>
<id>4ba0ebbc6cdecb9fad7c551a3d97b172ebc7b2fa</id>
<content type='text'>
When a function such as dsa_slave_create fails, currently the following
stack trace can be seen:

[    2.038342] sja1105 spi0.1: Probed switch chip: SJA1105T
[    2.054556] sja1105 spi0.1: Reset switch and programmed static config
[    2.063837] sja1105 spi0.1: Enabled switch tagging
[    2.068706] fsl-gianfar soc:ethernet@2d90000 eth2: error -19 setting up slave phy
[    2.076371] ------------[ cut here ]------------
[    2.080973] WARNING: CPU: 1 PID: 21 at net/core/devlink.c:6184 devlink_free+0x1b4/0x1c0
[    2.088954] Modules linked in:
[    2.092005] CPU: 1 PID: 21 Comm: kworker/1:1 Not tainted 5.3.0-rc6-01360-g41b52e38d2b6-dirty #1746
[    2.100912] Hardware name: Freescale LS1021A
[    2.105162] Workqueue: events deferred_probe_work_func
[    2.110287] [&lt;c03133a4&gt;] (unwind_backtrace) from [&lt;c030d8cc&gt;] (show_stack+0x10/0x14)
[    2.117992] [&lt;c030d8cc&gt;] (show_stack) from [&lt;c10b08d8&gt;] (dump_stack+0xb4/0xc8)
[    2.125180] [&lt;c10b08d8&gt;] (dump_stack) from [&lt;c0349d04&gt;] (__warn+0xe0/0xf8)
[    2.132018] [&lt;c0349d04&gt;] (__warn) from [&lt;c0349e34&gt;] (warn_slowpath_null+0x40/0x48)
[    2.139549] [&lt;c0349e34&gt;] (warn_slowpath_null) from [&lt;c0f19d74&gt;] (devlink_free+0x1b4/0x1c0)
[    2.147772] [&lt;c0f19d74&gt;] (devlink_free) from [&lt;c1064fc0&gt;] (dsa_switch_teardown+0x60/0x6c)
[    2.155907] [&lt;c1064fc0&gt;] (dsa_switch_teardown) from [&lt;c1065950&gt;] (dsa_register_switch+0x8e4/0xaa8)
[    2.164821] [&lt;c1065950&gt;] (dsa_register_switch) from [&lt;c0ba7fe4&gt;] (sja1105_probe+0x21c/0x2ec)
[    2.173216] [&lt;c0ba7fe4&gt;] (sja1105_probe) from [&lt;c0b35948&gt;] (spi_drv_probe+0x80/0xa4)
[    2.180920] [&lt;c0b35948&gt;] (spi_drv_probe) from [&lt;c0a4c1cc&gt;] (really_probe+0x108/0x400)
[    2.188711] [&lt;c0a4c1cc&gt;] (really_probe) from [&lt;c0a4c694&gt;] (driver_probe_device+0x78/0x1bc)
[    2.196933] [&lt;c0a4c694&gt;] (driver_probe_device) from [&lt;c0a4a3dc&gt;] (bus_for_each_drv+0x58/0xb8)
[    2.205414] [&lt;c0a4a3dc&gt;] (bus_for_each_drv) from [&lt;c0a4c024&gt;] (__device_attach+0xd0/0x168)
[    2.213637] [&lt;c0a4c024&gt;] (__device_attach) from [&lt;c0a4b1d0&gt;] (bus_probe_device+0x84/0x8c)
[    2.221772] [&lt;c0a4b1d0&gt;] (bus_probe_device) from [&lt;c0a4b72c&gt;] (deferred_probe_work_func+0x84/0xc4)
[    2.230686] [&lt;c0a4b72c&gt;] (deferred_probe_work_func) from [&lt;c03650a4&gt;] (process_one_work+0x218/0x510)
[    2.239772] [&lt;c03650a4&gt;] (process_one_work) from [&lt;c03660d8&gt;] (worker_thread+0x2a8/0x5c0)
[    2.247908] [&lt;c03660d8&gt;] (worker_thread) from [&lt;c036b348&gt;] (kthread+0x148/0x150)
[    2.255265] [&lt;c036b348&gt;] (kthread) from [&lt;c03010e8&gt;] (ret_from_fork+0x14/0x2c)
[    2.262444] Exception stack(0xea965fb0 to 0xea965ff8)
[    2.267466] 5fa0:                                     00000000 00000000 00000000 00000000
[    2.275598] 5fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
[    2.283729] 5fe0: 00000000 00000000 00000000 00000000 00000013 00000000
[    2.290333] ---[ end trace ca5d506728a0581a ]---

devlink_free is complaining right here:

	WARN_ON(!list_empty(&amp;devlink-&gt;port_list));

This happens because devlink_port_unregister is no longer done right
away in dsa_port_setup when a DSA_PORT_TYPE_USER has failed.
Vivien said about this change that:

    Also no need to call devlink_port_unregister from within dsa_port_setup
    as this step is inconditionally handled by dsa_port_teardown on error.

which is not really true. The devlink_port_unregister function _is_
being called unconditionally from within dsa_port_setup, but not for
this port that just failed, just for the previous ones which were set
up.

ports_teardown:
	for (i = 0; i &lt; port; i++)
		dsa_port_teardown(&amp;ds-&gt;ports[i]);

Initially I was tempted to fix this by extending the "for" loop to also
cover the port that failed during setup. But this could have potentially
unforeseen consequences unrelated to devlink_port or even other types of
ports than user ports, which I can't really test for. For example, if
for some reason devlink_port_register itself would fail, then
unconditionally unregistering it in dsa_port_teardown would not be a
smart idea. The list might go on.

So just make dsa_port_setup undo the setup it had done upon failure, and
let the for loop undo the work of setting up the previous ports, which
are guaranteed to be brought up to a consistent state.

Fixes: 955222ca5281 ("net: dsa: use a single switch statement for port setup")
Signed-off-by: Vladimir Oltean &lt;olteanv@gmail.com&gt;
Reviewed-by: Vivien Didelot &lt;vivien.didelot@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When a function such as dsa_slave_create fails, currently the following
stack trace can be seen:

[    2.038342] sja1105 spi0.1: Probed switch chip: SJA1105T
[    2.054556] sja1105 spi0.1: Reset switch and programmed static config
[    2.063837] sja1105 spi0.1: Enabled switch tagging
[    2.068706] fsl-gianfar soc:ethernet@2d90000 eth2: error -19 setting up slave phy
[    2.076371] ------------[ cut here ]------------
[    2.080973] WARNING: CPU: 1 PID: 21 at net/core/devlink.c:6184 devlink_free+0x1b4/0x1c0
[    2.088954] Modules linked in:
[    2.092005] CPU: 1 PID: 21 Comm: kworker/1:1 Not tainted 5.3.0-rc6-01360-g41b52e38d2b6-dirty #1746
[    2.100912] Hardware name: Freescale LS1021A
[    2.105162] Workqueue: events deferred_probe_work_func
[    2.110287] [&lt;c03133a4&gt;] (unwind_backtrace) from [&lt;c030d8cc&gt;] (show_stack+0x10/0x14)
[    2.117992] [&lt;c030d8cc&gt;] (show_stack) from [&lt;c10b08d8&gt;] (dump_stack+0xb4/0xc8)
[    2.125180] [&lt;c10b08d8&gt;] (dump_stack) from [&lt;c0349d04&gt;] (__warn+0xe0/0xf8)
[    2.132018] [&lt;c0349d04&gt;] (__warn) from [&lt;c0349e34&gt;] (warn_slowpath_null+0x40/0x48)
[    2.139549] [&lt;c0349e34&gt;] (warn_slowpath_null) from [&lt;c0f19d74&gt;] (devlink_free+0x1b4/0x1c0)
[    2.147772] [&lt;c0f19d74&gt;] (devlink_free) from [&lt;c1064fc0&gt;] (dsa_switch_teardown+0x60/0x6c)
[    2.155907] [&lt;c1064fc0&gt;] (dsa_switch_teardown) from [&lt;c1065950&gt;] (dsa_register_switch+0x8e4/0xaa8)
[    2.164821] [&lt;c1065950&gt;] (dsa_register_switch) from [&lt;c0ba7fe4&gt;] (sja1105_probe+0x21c/0x2ec)
[    2.173216] [&lt;c0ba7fe4&gt;] (sja1105_probe) from [&lt;c0b35948&gt;] (spi_drv_probe+0x80/0xa4)
[    2.180920] [&lt;c0b35948&gt;] (spi_drv_probe) from [&lt;c0a4c1cc&gt;] (really_probe+0x108/0x400)
[    2.188711] [&lt;c0a4c1cc&gt;] (really_probe) from [&lt;c0a4c694&gt;] (driver_probe_device+0x78/0x1bc)
[    2.196933] [&lt;c0a4c694&gt;] (driver_probe_device) from [&lt;c0a4a3dc&gt;] (bus_for_each_drv+0x58/0xb8)
[    2.205414] [&lt;c0a4a3dc&gt;] (bus_for_each_drv) from [&lt;c0a4c024&gt;] (__device_attach+0xd0/0x168)
[    2.213637] [&lt;c0a4c024&gt;] (__device_attach) from [&lt;c0a4b1d0&gt;] (bus_probe_device+0x84/0x8c)
[    2.221772] [&lt;c0a4b1d0&gt;] (bus_probe_device) from [&lt;c0a4b72c&gt;] (deferred_probe_work_func+0x84/0xc4)
[    2.230686] [&lt;c0a4b72c&gt;] (deferred_probe_work_func) from [&lt;c03650a4&gt;] (process_one_work+0x218/0x510)
[    2.239772] [&lt;c03650a4&gt;] (process_one_work) from [&lt;c03660d8&gt;] (worker_thread+0x2a8/0x5c0)
[    2.247908] [&lt;c03660d8&gt;] (worker_thread) from [&lt;c036b348&gt;] (kthread+0x148/0x150)
[    2.255265] [&lt;c036b348&gt;] (kthread) from [&lt;c03010e8&gt;] (ret_from_fork+0x14/0x2c)
[    2.262444] Exception stack(0xea965fb0 to 0xea965ff8)
[    2.267466] 5fa0:                                     00000000 00000000 00000000 00000000
[    2.275598] 5fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
[    2.283729] 5fe0: 00000000 00000000 00000000 00000000 00000013 00000000
[    2.290333] ---[ end trace ca5d506728a0581a ]---

devlink_free is complaining right here:

	WARN_ON(!list_empty(&amp;devlink-&gt;port_list));

This happens because devlink_port_unregister is no longer done right
away in dsa_port_setup when a DSA_PORT_TYPE_USER has failed.
Vivien said about this change that:

    Also no need to call devlink_port_unregister from within dsa_port_setup
    as this step is inconditionally handled by dsa_port_teardown on error.

which is not really true. The devlink_port_unregister function _is_
being called unconditionally from within dsa_port_setup, but not for
this port that just failed, just for the previous ones which were set
up.

ports_teardown:
	for (i = 0; i &lt; port; i++)
		dsa_port_teardown(&amp;ds-&gt;ports[i]);

Initially I was tempted to fix this by extending the "for" loop to also
cover the port that failed during setup. But this could have potentially
unforeseen consequences unrelated to devlink_port or even other types of
ports than user ports, which I can't really test for. For example, if
for some reason devlink_port_register itself would fail, then
unconditionally unregistering it in dsa_port_teardown would not be a
smart idea. The list might go on.

So just make dsa_port_setup undo the setup it had done upon failure, and
let the for loop undo the work of setting up the previous ports, which
are guaranteed to be brought up to a consistent state.

Fixes: 955222ca5281 ("net: dsa: use a single switch statement for port setup")
Signed-off-by: Vladimir Oltean &lt;olteanv@gmail.com&gt;
Reviewed-by: Vivien Didelot &lt;vivien.didelot@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: dsa: remove bitmap operations</title>
<updated>2019-08-28T03:17:27+00:00</updated>
<author>
<name>Vivien Didelot</name>
<email>vivien.didelot@gmail.com</email>
</author>
<published>2019-08-25T17:25:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=e65d45cc351ac5f1c11e6bac5669e536df753664'/>
<id>e65d45cc351ac5f1c11e6bac5669e536df753664</id>
<content type='text'>
The bitmap operations were introduced to simplify the switch drivers
in the future, since most of them could implement the common VLAN and
MDB operations (add, del, dump) with simple functions taking all target
ports at once, and thus limiting the number of hardware accesses.

Programming an MDB or VLAN this way in a single operation would clearly
simplify the drivers a lot but would require a new get-set interface
in DSA. The usage of such bitmap from the stack also raised concerned
in the past, leading to the dynamic allocation of a new ds-&gt;_bitmap
member in the dsa_switch structure. So let's get rid of them for now.

This commit nicely wraps the ds-&gt;ops-&gt;port_{mdb,vlan}_{prepare,add}
switch operations into new dsa_switch_{mdb,vlan}_{prepare,add}
variants not using any bitmap argument anymore.

New dsa_switch_{mdb,vlan}_match helpers have been introduced to make
clear which local port of a switch must be programmed with the target
object. While the targeted user port is an obvious candidate, the
DSA links must also be programmed, as well as the CPU port for VLANs.

While at it, also remove local variables that are only used once.

Signed-off-by: Vivien Didelot &lt;vivien.didelot@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The bitmap operations were introduced to simplify the switch drivers
in the future, since most of them could implement the common VLAN and
MDB operations (add, del, dump) with simple functions taking all target
ports at once, and thus limiting the number of hardware accesses.

Programming an MDB or VLAN this way in a single operation would clearly
simplify the drivers a lot but would require a new get-set interface
in DSA. The usage of such bitmap from the stack also raised concerned
in the past, leading to the dynamic allocation of a new ds-&gt;_bitmap
member in the dsa_switch structure. So let's get rid of them for now.

This commit nicely wraps the ds-&gt;ops-&gt;port_{mdb,vlan}_{prepare,add}
switch operations into new dsa_switch_{mdb,vlan}_{prepare,add}
variants not using any bitmap argument anymore.

New dsa_switch_{mdb,vlan}_match helpers have been introduced to make
clear which local port of a switch must be programmed with the target
object. While the targeted user port is an obvious candidate, the
DSA links must also be programmed, as well as the CPU port for VLANs.

While at it, also remove local variables that are only used once.

Signed-off-by: Vivien Didelot &lt;vivien.didelot@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: dsa: enable and disable all ports</title>
<updated>2019-08-20T19:33:49+00:00</updated>
<author>
<name>Vivien Didelot</name>
<email>vivien.didelot@gmail.com</email>
</author>
<published>2019-08-19T20:00:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=0394a63acfe2a6e1c08af0eb1a9133ee8650d7bd'/>
<id>0394a63acfe2a6e1c08af0eb1a9133ee8650d7bd</id>
<content type='text'>
Call the .port_enable and .port_disable functions for all ports,
not only the user ports, so that drivers may optimize the power
consumption of all ports after a successful setup.

Unused ports are now disabled on setup. CPU and DSA ports are now
enabled on setup and disabled on teardown. User ports were already
enabled at slave creation and disabled at slave destruction.

Signed-off-by: Vivien Didelot &lt;vivien.didelot@gmail.com&gt;
Reviewed-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Call the .port_enable and .port_disable functions for all ports,
not only the user ports, so that drivers may optimize the power
consumption of all ports after a successful setup.

Unused ports are now disabled on setup. CPU and DSA ports are now
enabled on setup and disabled on teardown. User ports were already
enabled at slave creation and disabled at slave destruction.

Signed-off-by: Vivien Didelot &lt;vivien.didelot@gmail.com&gt;
Reviewed-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: dsa: use a single switch statement for port setup</title>
<updated>2019-08-20T19:33:49+00:00</updated>
<author>
<name>Vivien Didelot</name>
<email>vivien.didelot@gmail.com</email>
</author>
<published>2019-08-19T20:00:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=955222ca5281ee7ded6b899605c055b147a15c73'/>
<id>955222ca5281ee7ded6b899605c055b147a15c73</id>
<content type='text'>
It is currently difficult to read the different steps involved in the
setup and teardown of ports in the DSA code. Keep it simple with a
single switch statement for each port type: UNUSED, CPU, DSA, or USER.

Also no need to call devlink_port_unregister from within dsa_port_setup
as this step is inconditionally handled by dsa_port_teardown on error.

Signed-off-by: Vivien Didelot &lt;vivien.didelot@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It is currently difficult to read the different steps involved in the
setup and teardown of ports in the DSA code. Keep it simple with a
single switch statement for each port type: UNUSED, CPU, DSA, or USER.

Also no need to call devlink_port_unregister from within dsa_port_setup
as this step is inconditionally handled by dsa_port_teardown on error.

Signed-off-by: Vivien Didelot &lt;vivien.didelot@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: dsa: Add teardown callback for drivers</title>
<updated>2019-06-08T22:20:39+00:00</updated>
<author>
<name>Vladimir Oltean</name>
<email>olteanv@gmail.com</email>
</author>
<published>2019-06-08T12:04:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=5e3f847a02aabfecea519d7b2fd48f4d6f551be6'/>
<id>5e3f847a02aabfecea519d7b2fd48f4d6f551be6</id>
<content type='text'>
This is helpful for e.g. draining per-driver (not per-port) tagger
queues.

Signed-off-by: Vladimir Oltean &lt;olteanv@gmail.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Reviewed-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is helpful for e.g. draining per-driver (not per-port) tagger
queues.

Signed-off-by: Vladimir Oltean &lt;olteanv@gmail.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Reviewed-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net</title>
<updated>2019-06-07T18:00:14+00:00</updated>
<author>
<name>David S. Miller</name>
<email>davem@davemloft.net</email>
</author>
<published>2019-06-07T18:00:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=a6cdeeb16bff89c8486324f53577db058cbe81ba'/>
<id>a6cdeeb16bff89c8486324f53577db058cbe81ba</id>
<content type='text'>
Some ISDN files that got removed in net-next had some changes
done in mainline, take the removals.

Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Some ISDN files that got removed in net-next had some changes
done in mainline, take the removals.

Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: dsa: Add error path handling in dsa_tree_setup()</title>
<updated>2019-05-30T21:58:31+00:00</updated>
<author>
<name>Ioana Ciornei</name>
<email>ioana.ciornei@nxp.com</email>
</author>
<published>2019-05-30T06:09:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=e70c7aad7a95f4f9fd3f00caef1a1ceb57a4b5a4'/>
<id>e70c7aad7a95f4f9fd3f00caef1a1ceb57a4b5a4</id>
<content type='text'>
In case a call to dsa_tree_setup() fails, an attempt to cleanup is made
by calling dsa_tree_remove_switch(), which should take care of
removing/unregistering any resources previously allocated. This does not
happen because it is conditioned by dst-&gt;setup being true, which is set
only after _all_ setup steps were performed successfully.

This is especially interesting when the internal MDIO bus is registered
but afterwards, a port setup fails and the mdiobus_unregister() is never
called. This leads to a BUG_ON() complaining about the fact that it's
trying to free an MDIO bus that's still registered.

Add proper error handling in all functions branching from
dsa_tree_setup().

Signed-off-by: Ioana Ciornei &lt;ioana.ciornei@nxp.com&gt;
Reported-by: kernel test robot &lt;rong.a.chen@intel.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In case a call to dsa_tree_setup() fails, an attempt to cleanup is made
by calling dsa_tree_remove_switch(), which should take care of
removing/unregistering any resources previously allocated. This does not
happen because it is conditioned by dst-&gt;setup being true, which is set
only after _all_ setup steps were performed successfully.

This is especially interesting when the internal MDIO bus is registered
but afterwards, a port setup fails and the mdiobus_unregister() is never
called. This leads to a BUG_ON() complaining about the fact that it's
trying to free an MDIO bus that's still registered.

Add proper error handling in all functions branching from
dsa_tree_setup().

Signed-off-by: Ioana Ciornei &lt;ioana.ciornei@nxp.com&gt;
Reported-by: kernel test robot &lt;rong.a.chen@intel.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
</feed>
