Re: Re: [GIT PULL] sysctl constification changes for v6.14-rc1

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Jan 31, 2025 at 02:57:40PM +0100, Joel Granados wrote:
> From 431abf6c9c11a8b7321842ed0747b3200d43ef34 Mon Sep 17 00:00:00 2001
> From: Joel Granados <joel.granados@xxxxxxxxxx>
> Date: Fri, 31 Jan 2025 14:10:57 +0100
> Subject: [PATCH] csky: Remove the size from alignment_tbl declaration
> 
> Having to synchronize the number of ctl_table array elements with the
> size in the declaration can lead to discrepancies between the two
> values. Since commit d7a76ec87195 ("sysctl: Remove check for sentinel
> element in ctl_table arrays"), the calculation of the ctl_table array
> size is done solely by the ARRAY_SIZE macro removing the need for the
> size in the declaration.
> 
> Remove the size for the aligment_tbl declaration and const qualify the
> array for good measure.
> 
> Signed-off-by: Joel Granados <joel.granados@xxxxxxxxxx>

FWIW, this looks correct to me.

Reviewed-by: Kees Cook <kees@xxxxxxxxxx>

-- 
Kees Cook




[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux