regmap: cache: Switch to use kmemdup_array()
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Thu, 6 Jun 2024 16:46:24 +0000 (19:46 +0300)
committerMark Brown <broonie@kernel.org>
Fri, 7 Jun 2024 13:28:22 +0000 (14:28 +0100)
commitf755d6955338bc704168629f70b380658a4918df
treef8a75ff977844a36bbd6491852436291245f2e01
parent354662dc66f264b26c3e094162e0fad8715d009f
regmap: cache: Switch to use kmemdup_array()

Let the kememdup_array() take care about multiplication and possible
overflows.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20240606164717.3031107-4-andriy.shevchenko@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/base/regmap/regcache.c