Skip to content

staging: rtl8723bs: clean up SIZE_PTR usage and remove custom macro

Ashmit Kumar linux-staging lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest3 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3staging: rtl8723bs: use PTR_ALIGN() for pointer alignmentdrivers/staging/rtl8723bs/core/rtw_security.c drivers/staging/rtl8723bs/core/rtw_sta_mgt.c drivers/staging/rtl8723bs/core/rtw_xmit.c+6 -110 replies
2/3staging: rtl8723bs: remove unnecessary pointer-to-integer castsdrivers/staging/rtl8723bs/core/rtw_mlme_ext.c drivers/staging/rtl8723bs/os_dep/xmit_linux.c+5 -50 replies
3/3staging: rtl8723bs: replace SIZE_PTR with uintptr_t and remove definitiondrivers/staging/rtl8723bs/hal/rtl8723bs_recv.c drivers/staging/rtl8723bs/hal/sdio_ops.c drivers/staging/rtl8723bs/include/basic_types.h+9 -100 replies

Reviews trailers per patch

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

Read the v1 thread

Cover letter [PATCH 0/3] staging: rtl8723bs: clean up SIZE_PTR usage and remove custom macro

This patch series cleans up the custom macro SIZE_PTR (__kernel_size_t) across the rtl8723bs driver as part of addressing the TODO item to "convert any remaining unusual variable types".

Instead of a mechanical substitution, each occurrence has been converted to its idiomatic kernel equivalent:
1. Replace open-coded pointer alignments with the standard PTR_ALIGN() macro, removing an unused variable left behind.
2. Remove redundant pointer-to-integer casts where pointer arithmetic or pointer arguments are already sufficient.
3. Replace the remaining pointer-to-integer address casts with uintptr_t, use size_t for alignment offsets, and delete the custom SIZE_PTR macro definition entirely.

Ashmit Kumar (3):
staging: rtl8723bs: use PTR_ALIGN() for pointer alignment
staging: rtl8723bs: remove unnecessary pointer-to-integer casts
staging: rtl8723bs: replace SIZE_PTR with uintptr_t and remove
definition

 drivers/staging/rtl8723bs/core/rtw_mlme_ext.c   |  8 ++++----
 drivers/staging/rtl8723bs/core/rtw_security.c   |  6 +++---
 drivers/staging/rtl8723bs/core/rtw_sta_mgt.c    |  3 +--
 drivers/staging/rtl8723bs/core/rtw_xmit.c       |  8 ++------
 drivers/staging/rtl8723bs/hal/rtl8723bs_recv.c  | 11 ++++++-----
 drivers/staging/rtl8723bs/hal/sdio_ops.c        |  6 +++---
 drivers/staging/rtl8723bs/include/basic_types.h |  2 --
 drivers/staging/rtl8723bs/os_dep/xmit_linux.c   |  2 +-
 8 files changed, 20 insertions(+), 26 deletions(-)
Signature · 1 line
2.43.0