Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

tracing: fprobe: Remove unused local variable

The 'ret' local variable in fprobe_remove_node_in_module() was used
for checking the error state in the loop, but commit dfe0d675df82
("tracing: fprobe: use rhltable for fprobe_ip_table") removed the loop.
So we don't need it anymore.

Link: https://lore.kernel.org/all/175867358989.600222.6175459620045800878.stgit@devnote2/

Fixes: e5a4cc28a052 ("tracing: fprobe: use rhltable for fprobe_ip_table")
Signed-off-by: Masami Hiramatsu (Google) <mhiramat@kernel.org>
Acked-by: Menglong Dong <menglong8.dong@gmail.com>

+1 -4
+1 -4
kernel/trace/fprobe.c
··· 458 458 static void fprobe_remove_node_in_module(struct module *mod, struct fprobe_hlist_node *node, 459 459 struct fprobe_addr_list *alist) 460 460 { 461 - int ret = 0; 462 - 463 461 if (!within_module(node->addr, mod)) 464 462 return; 465 463 if (delete_fprobe_node(node)) ··· 466 468 * If failed to update alist, just continue to update hlist. 467 469 * Therefore, at list user handler will not hit anymore. 468 470 */ 469 - if (!ret) 470 - ret = fprobe_addr_list_add(alist, node->addr); 471 + fprobe_addr_list_add(alist, node->addr); 471 472 } 472 473 473 474 /* Handle module unloading to manage fprobe_ip_table. */