Netdev List
 help / color / mirror / Atom feed
* [PATCH net v2 0/4] net: dsa: realtek: use devm_mutex_init
@ 2026-07-27  1:56 Luiz Angelo Daros de Luca
  2026-07-27  1:56 ` [PATCH net v2 1/4] net: dsa: realtek: rtl8365mb: use devm_mutex_init for mib_lock Luiz Angelo Daros de Luca
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Luiz Angelo Daros de Luca @ 2026-07-27  1:56 UTC (permalink / raw)
  To: Linus Walleij, Alvin Šipraga, Andrew Lunn, Vladimir Oltean,
	David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
	Michael Rasmussen, Florian Fainelli, Mieczyslaw Nalewaj
  Cc: Luiz Angelo Daros de Luca, netdev, linux-kernel

This series fixes mutex teardown in the Realtek DSA drivers.

With CONFIG_DEBUG_MUTEXES enabled, mutex_destroy() must be called before
the mutex is discarded. Using devm_mutex_init() lets the driver core
handle that automatically.

The changes are split into individual commits based on the feature that
introduced each lock to allow proper backports to stable trees.

Signed-off-by: Luiz Angelo Daros de Luca <luizluca@gmail.com>
---
Changes in v2:
- Split the commit into individual commits for each mutex_init()
  introduction. 
- Add the error code to the rtl8365mb_stats_setup() error message.
- Link to v1: https://patch.msgid.link/20260718-realtek_mutext-v1-1-1cd7beb20ae6@gmail.com

To: Linus Walleij <linusw@kernel.org>
To: Alvin Šipraga <alsi@bang-olufsen.dk>
To: Andrew Lunn <andrew@lunn.ch>
To: Vladimir Oltean <olteanv@gmail.com>
To: "David S. Miller" <davem@davemloft.net>
To: Eric Dumazet <edumazet@google.com>
To: Jakub Kicinski <kuba@kernel.org>
To: Paolo Abeni <pabeni@redhat.com>
To: Michael Rasmussen <mir@bang-olufsen.dk>
To: Florian Fainelli <f.fainelli@gmail.com>
To: Luiz Angelo Daros de Luca <luizluca@gmail.com>
To: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Cc: netdev@vger.kernel.org
Cc: linux-kernel@vger.kernel.org

---
Luiz Angelo Daros de Luca (4):
      net: dsa: realtek: rtl8365mb: use devm_mutex_init for mib_lock
      net: dsa: realtek: use devm_mutex_init for regmap lock
      net: dsa: realtek: use devm_mutex_init for vlan_lock
      net: dsa: realtek: use devm_mutex_init for l2_lock

 drivers/net/dsa/realtek/rtl8365mb_main.c | 16 +++++++++++++---
 drivers/net/dsa/realtek/rtl83xx.c        | 14 +++++++++++---
 2 files changed, 24 insertions(+), 6 deletions(-)
---
base-commit: 4361bac9a4adf0e97639130c765669b41030e86e
change-id: 20260718-realtek_mutext-41a072e5cd24

Best regards,
--  
Luiz Angelo Daros de Luca <luizluca@gmail.com>


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-07-27  1:56 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-27  1:56 [PATCH net v2 0/4] net: dsa: realtek: use devm_mutex_init Luiz Angelo Daros de Luca
2026-07-27  1:56 ` [PATCH net v2 1/4] net: dsa: realtek: rtl8365mb: use devm_mutex_init for mib_lock Luiz Angelo Daros de Luca
2026-07-27  1:56 ` [PATCH net v2 2/4] net: dsa: realtek: use devm_mutex_init for regmap lock Luiz Angelo Daros de Luca
2026-07-27  1:56 ` [PATCH net v2 3/4] net: dsa: realtek: use devm_mutex_init for vlan_lock Luiz Angelo Daros de Luca
2026-07-27  1:56 ` [PATCH net v2 4/4] net: dsa: realtek: use devm_mutex_init for l2_lock Luiz Angelo Daros de Luca

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox