net: devlink: Add missing error check to devlink_resource_put()
authorGavrilov Ilia <Ilia.Gavrilov@infotecs.ru>
Thu, 8 Dec 2022 08:31:39 +0000 (08:31 +0000)
committerJakub Kicinski <kuba@kernel.org>
Sat, 10 Dec 2022 04:04:32 +0000 (20:04 -0800)
commit5fc11a401a8dc491b326d2c916b07d22e7ac8833
treea6a15672c504a2eac494c98f58067b2d1516a953
parentce098da1497c6dee9589fce2c61d1910f4fcf0e7
net: devlink: Add missing error check to devlink_resource_put()

When the resource size changes, the return value of the
'nla_put_u64_64bit' function is not checked. That has been fixed to avoid
rechecking at the next step.

Found by InfoTeCS on behalf of Linux Verification Center
(linuxtesting.org) with SVACE.

Note that this is harmless, we'd error out at the next put().

Signed-off-by: Ilia.Gavrilov <Ilia.Gavrilov@infotecs.ru>
Link: https://lore.kernel.org/r/20221208082821.3927937-1-Ilia.Gavrilov@infotecs.ru
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
net/core/devlink.c