diff options
| author | Dan Carpenter <[email protected]> | 2025-11-25 13:55:19 +0000 |
|---|---|---|
| committer | Thomas Gleixner <[email protected]> | 2025-11-25 16:52:24 +0000 |
| commit | c7418164b463056bf4327b6a2abe638b78250f13 (patch) | |
| tree | 5246c720af7982f3b50af2261b133866dc663e43 /tools/lib/traceevent/plugins/plugin_function.c | |
| parent | Linux 6.18-rc7 (diff) | |
| download | kernel-c7418164b463056bf4327b6a2abe638b78250f13.tar.gz kernel-c7418164b463056bf4327b6a2abe638b78250f13.zip | |
timekeeping: Fix error code in tk_aux_sysfs_init()
If kobject_create_and_add() fails on the first iteration, then the error
code is set to -ENOMEM which is correct. But if it fails in subsequent
iterations then "ret" is zero, which means success, but it should be
-ENOMEM.
Set the error code to -ENOMEM correctly.
Fixes: 7b5ab04f035f ("timekeeping: Fix resource leak in tk_aux_sysfs_init() error paths")
Signed-off-by: Dan Carpenter <[email protected]>
Signed-off-by: Thomas Gleixner <[email protected]>
Reviewed-by: Malaya Kumar Rout <[email protected]>
Link: https://patch.msgid.link/[email protected]
Diffstat (limited to 'tools/lib/traceevent/plugins/plugin_function.c')
0 files changed, 0 insertions, 0 deletions
