summaryrefslogtreecommitdiff
path: root/init
diff options
context:
space:
mode:
authorZhou jie <zhoujie@nfschina.com>2022-09-28 09:45:39 +0800
committerAndrew Morton <akpm@linux-foundation.org>2022-10-03 14:21:45 -0700
commit374d6cda7946431611c41cbb6e75dc4a25727ea8 (patch)
tree7120655877e6156ef371f5a5b1a88b353226270f /init
parentef1d61781bc6708ccc4a21262cc80a7dad952e04 (diff)
downloadlwn-374d6cda7946431611c41cbb6e75dc4a25727ea8.tar.gz
lwn-374d6cda7946431611c41cbb6e75dc4a25727ea8.zip
init/main.c: remove unnecessary (void*) conversions
The void pointer object can be directly assigned to different structure objects, it does not need to be cast. Link: https://lkml.kernel.org/r/20220928014539.11046-1-zhoujie@nfschina.com Signed-off-by: Zhou jie <zhoujie@nfschina.com> Reviewed-by: Andrew Halaney <ahalaney@redhat.com> Acked-by: Steven Rostedt (Google) <rostedt@goodmis.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'init')
-rw-r--r--init/main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/init/main.c b/init/main.c
index a45f9eca40af..22255723599b 100644
--- a/init/main.c
+++ b/init/main.c
@@ -1237,7 +1237,7 @@ __setup("initcall_blacklist=", initcall_blacklist);
static __init_or_module void
trace_initcall_start_cb(void *data, initcall_t fn)
{
- ktime_t *calltime = (ktime_t *)data;
+ ktime_t *calltime = data;
printk(KERN_DEBUG "calling %pS @ %i\n", fn, task_pid_nr(current));
*calltime = ktime_get();
@@ -1246,7 +1246,7 @@ trace_initcall_start_cb(void *data, initcall_t fn)
static __init_or_module void
trace_initcall_finish_cb(void *data, initcall_t fn, int ret)
{
- ktime_t rettime, *calltime = (ktime_t *)data;
+ ktime_t rettime, *calltime = data;
rettime = ktime_get();
printk(KERN_DEBUG "initcall %pS returned %d after %lld usecs\n",