Skip to content

iio: core: New macros and making use of them

Andy Shevchenko dmaengine linux-arm-kernel linux-hardening linux-iio linux-spi lkml netdev 1 version Applied

Status from this message: Applied to for-next/hardening, thanks!

Get series with b4
b4 am [email protected]

Versions newest first

  1. v4 Latest8 patches 29 repliesApplied

Changes in v4 from the cover letter

- dropped applied patches
- refactored macros and code to make them simpler (Jonathan)
- moved (renamed) macros to overflow.h

Patches in v4 Applied

#Subject and filesSizeRepliesApplied
1/8overflow: Use POD in check_shl_overflow()include/linux/overflow.h+1 -13 replies
2/8overflow: Add struct_size_with_data() and struct_data_pointer() helpersinclude/linux/overflow.h+26 -12 replies
3/8iio: core: NULLify private pointer when there is no private datadrivers/iio/industrialio-core.c+6 -23 replies
4/8iio: core: Calculate alloc_size only once in iio_device_alloc()drivers/iio/industrialio-core.c+4 -52 replies
5/8iio: core: Use new helpers from overflow.h in iio_device_alloc()drivers/iio/industrialio-core.c+2 -32 replies
6/8spi: Use new helpers from overflow.h in __spi_alloc_controller()drivers/spi/spi.c+3 -31 reply
7/8net-device: Use new helpers from overflow.h in netdevice APIsinclude/linux/netdevice.h net/core/dev.c+7 -614 replies
8/8dmaengine: ste_dma40: Use new helpers from overflow.hdrivers/dma/ste_dma40.c+6 -62 replies

Reviews trailers per patch

4 of 8 patches have a Reviewed-by or Acked-by.

PatchNuno SaMark BrownKees CookLinus Walleij
1/8A-b
2/8
3/8
4/8
5/8R-b
6/8A-b
7/8
8/8R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 4 reviewers.

Read the v4 thread

Cover letter [PATCH v4 0/8] iio: core: New macros and making use of them

Added new macros to overflow.h and reuse it in IIO. For the sake of examples a few more places were updated (requested by Kees). In case maintainers are okay, tags will be appreciated.

v4:
- dropped applied patches
- refactored macros and code to make them simpler (Jonathan)
- moved (renamed) macros to overflow.h

v3: https://lore.kernel.org/r/[email protected]
- dropped applied patches
- use switch-case for the supported clocks (Jonathan) - redone opaque_struct_size() to be simpler (Uwe)
- dropped wrong hunk for krealloc_array() conversion (Jonathan) - dropped initcall move (Jonathan)

v2:
- sprintf() --> sysfs_emit() (Nuno)
- added tag (Nuno)

Andy Shevchenko (8):
overflow: Use POD in check_shl_overflow()
overflow: Add struct_size_with_data() and struct_data_pointer()
helpers
iio: core: NULLify private pointer when there is no private data
iio: core: Calculate alloc_size only once in iio_device_alloc()
iio: core: Use new helpers from overflow.h in iio_device_alloc()
spi: Use new helpers from overflow.h in __spi_alloc_controller()
net-device: Use new helpers from overflow.h in netdevice APIs
dmaengine: ste_dma40: Use new helpers from overflow.h

 drivers/dma/ste_dma40.c         | 12 ++++++------
 drivers/iio/industrialio-core.c | 16 +++++++++-------
 drivers/spi/spi.c               |  6 +++---
 include/linux/netdevice.h       |  3 ++-
 include/linux/overflow.h        | 29 +++++++++++++++++++++++++++--
 net/core/dev.c                  | 10 +++++-----
 6 files changed, 52 insertions(+), 24 deletions(-)
Signature · 1 line
2.43.0.rc1.1.gbec44491f096