igc: Make the const read-only array supported_sizes static
Don't populate the const read-only array supported_sizes on the stack at run time, instead make it static. Signed-off-by: Colin Ian King <colin.i.king@gmail.com> Reviewed-by: Alexander Lobakin <aleksander.lobakin@intel.com> Reviewed-by: Vitaly Lifshits <vitaly.lifshits@intel.com>> Link: https://patch.msgid.link/20250618135408.1784120-1-colin.i.king@gmail.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
committed by
Jakub Kicinski
parent
ba28ef3ccf
commit
deb21a6e5b
@@ -431,7 +431,7 @@ static u8 igc_fpe_get_frag_size_mult(const struct igc_fpe_t *fpe)
|
||||
|
||||
u32 igc_fpe_get_supported_frag_size(u32 frag_size)
|
||||
{
|
||||
const u32 supported_sizes[] = {64, 128, 192, 256};
|
||||
static const u32 supported_sizes[] = { 64, 128, 192, 256 };
|
||||
|
||||
/* Find the smallest supported size that is >= frag_size */
|
||||
for (int i = 0; i < ARRAY_SIZE(supported_sizes); i++) {
|
||||
|
||||
Reference in New Issue
Block a user