summaryrefslogtreecommitdiffstats
path: root/drivers/spi/spi-mtk-snfi.c
diff options
context:
space:
mode:
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>2023-07-14 11:17:48 +0200
committerMark Brown <broonie@kernel.org>2023-07-14 15:44:39 +0200
commit75e308ffc4f0d36b895f1110ece8b77d4116fdb1 (patch)
tree3c3f612b0c248bcc5740b0376fc6effed9081fe8 /drivers/spi/spi-mtk-snfi.c
parentspi: Use BITS_TO_BYTES() (diff)
downloadlinux-75e308ffc4f0d36b895f1110ece8b77d4116fdb1.tar.xz
linux-75e308ffc4f0d36b895f1110ece8b77d4116fdb1.zip
spi: Use struct_size() helper
The Documentation/process/deprecated.rst suggests to use flexible array members to provide a way to declare having a dynamically sized set of trailing elements in a structure.This makes code robust agains bunch of the issues described in the documentation, main of which is about the correctness of the sizeof() calculation for this data structure. Due to above, prefer struct_size() over open-coded versions. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20230714091748.89681-5-andriy.shevchenko@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/spi/spi-mtk-snfi.c')
0 files changed, 0 insertions, 0 deletions