Skip to content

can: bcm: add/fix locking for config updates at runtime

Oliver Hartkopp b4-sent linux-can lkml 3 versions – In review

Get series with b4
b4 am [email protected] change-id 20260218-bcm_spin_lock_init-2518eb8d4501

Versions newest first

  1. v3 Latest3 patches 4 repliesIn review
  2. v22 patches 1 replySuperseded
  3. v11 patch 4 repliesSuperseded

Changes in v3 from the cover letter

- Add a third patch that fixes a KCSAN issue that showed up while testing
patch 2 8-)
- Link to v2: https://patch.msgid.link/[email protected]

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3can: bcm: fix locking for bcm_op runtime updatesnet/can/bcm.c+1 -00 replies
2/3can: bcm: add locking when updating filter and timer valuesnet/can/bcm.c+32 -73 replies
3/3can: statistics: add missing atomic access in hot pathnet/can/af_can.c net/can/af_can.h+3 -31 reply

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v3 yet.

Read the v3 thread

Cover letter [PATCH v3 0/3] can: bcm: add/fix locking for config updates at runtime

Address three locking issues detected by KASAN and KCSAN.

The first patch fixes an unintialized spin_lock in the KASAN fix. The second patch addresses the update of content in bcm_rx_setup(). The third patch adds a missing atomic conversion in can_rcv_filter().

---
Changes in v3:
- Add a third patch that fixes a KCSAN issue that showed up while testing
patch 2 8-)
- Link to v2: https://patch.msgid.link/[email protected]

Changes in v2:
- Add a second patch addressing the KCSAN report
- Link to v1: https://patch.msgid.link/[email protected]

---
Oliver Hartkopp (3):
can: bcm: fix locking for bcm_op runtime updates
can: bcm: add locking when updating filter and timer values
can: statistics: add missing atomic access in hot path

 net/can/af_can.c |  4 ++--
 net/can/af_can.h |  2 +-
 net/can/bcm.c    | 40 +++++++++++++++++++++++++++++++++-------
 3 files changed, 36 insertions(+), 10 deletions(-)

---
base-commit: 2961f841b025fb234860bac26dfb7fa7cb0fb122
change-id: 20260218-bcm_spin_lock_init-2518eb8d4501

Best regards,

Signature · 1 line
Oliver Hartkopp <[email protected]>