taskstats: fix struct taskstats breaks backward compatibility since version 15
Problem ======== commit 658eb5ab ("delayacct: add delay max to record delay peak") - adding more fields commit f65c64f3 ("delayacct: add delay min to record delay peak") - adding more fields commit b016d087 ("taskstats: modify taskstats version") - version bump to 15 Since version 15 (TASKSTATS_VERSION=15) the new layout of the structure adds fields in the middle of the structure, rendering all old software incompatible with newer kernels and software compiled against the new kernel headers incompatible with older kernels. Solution ========= move delay max and delay min to the end of taskstat, and bump the version to 16 after the change [wang.yaxin@zte.com.cn: adjust indentation] Link: https://lkml.kernel.org/r/202505192131489882NSciXV4EGd8zzjLuwoOK@zte.com.cn Link: https://lkml.kernel.org/r/20250510155413259V4JNRXxukdDgzsaL0Fo6a@zte.com.cn Fixes: f65c64f3 ("delayacct: add delay min to record delay peak") Signed-off-by:Wang Yaxin <wang.yaxin@zte.com.cn> Signed-off-by:
xu xin <xu.xin16@zte.com.cn> Signed-off-by:
Kun Jiang <jiang.kun2@zte.com.cn> Reviewed-by:
Yang Yang <yang.yang29@zte.com.cn> Cc: Balbir Singh <bsingharora@gmail.com> Cc: <stable@vger.kernel.org> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org>
Loading
Please register or sign in to comment