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

x86/ftrace: Make enable parameter bool where applicable

The code modification functions have an "enable" parameter that is an "int"
but used as a boolean. Switch its type to "bool" to remove the ambiguity
that "int" causes.

Link: http://lkml.kernel.org/r/e1429923d9eda92a3cf5ee9e33c7eacce539781d.1558115654.git.naveen.n.rao@linux.vnet.ibm.com

Reported-by: "Naveen N. Rao" <naveen.n.rao@linux.vnet.ibm.com>
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>

+3 -3
+3 -3
arch/x86/kernel/ftrace.c
··· 370 370 return add_break(rec->ip, old); 371 371 } 372 372 373 - static int add_breakpoints(struct dyn_ftrace *rec, int enable) 373 + static int add_breakpoints(struct dyn_ftrace *rec, bool enable) 374 374 { 375 375 unsigned long ftrace_addr; 376 376 int ret; ··· 478 478 return add_update_code(ip, new); 479 479 } 480 480 481 - static int add_update(struct dyn_ftrace *rec, int enable) 481 + static int add_update(struct dyn_ftrace *rec, bool enable) 482 482 { 483 483 unsigned long ftrace_addr; 484 484 int ret; ··· 524 524 return ftrace_write(ip, new, 1); 525 525 } 526 526 527 - static int finish_update(struct dyn_ftrace *rec, int enable) 527 + static int finish_update(struct dyn_ftrace *rec, bool enable) 528 528 { 529 529 unsigned long ftrace_addr; 530 530 int ret;