linux-stable/fs/smb
David Disseldorp 49d9f6ad1e ksmbd: avoid duplicate negotiate ctx offset increments
[ Upstream commit a12a07a85a ]

Both pneg_ctxt and ctxt_size change in unison, with each adding the
length of the previously added context, rounded up to an eight byte
boundary.
Drop pneg_ctxt increments and instead use the ctxt_size offset when
passing output pointers to per-context helper functions. This slightly
simplifies offset tracking and shaves off a few text bytes.
Before (x86-64 gcc 7.5):
   text    data     bss     dec     hex filename
 213234    8677     672  222583   36577 ksmbd.ko

After:
   text    data     bss     dec     hex filename
 213218    8677     672  222567   36567 ksmbd.ko

Signed-off-by: David Disseldorp <ddiss@suse.de>
Acked-by: Namjae Jeon <linkinjeon@kernel.org>
Signed-off-by: Steve French <stfrench@microsoft.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-01-05 15:18:29 +01:00
..
client smb: client: fix OOB in smbCalcSize() 2024-01-01 12:39:05 +00:00
common ksmbd: fix wrong name of SMB2_CREATE_ALLOCATION_SIZE 2023-12-20 17:00:21 +01:00
server ksmbd: avoid duplicate negotiate ctx offset increments 2024-01-05 15:18:29 +01:00
Kconfig
Makefile