Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp1775638rwb; Tue, 27 Sep 2022 19:01:59 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6ATRUX8B1lF2ca44DOuagys1YEFaNJLYe80dvQbGjUJ0tJnDMe0MDyDiKU4QEB1ncG5Fwc X-Received: by 2002:a63:5916:0:b0:41d:2c8c:7492 with SMTP id n22-20020a635916000000b0041d2c8c7492mr27159131pgb.81.1664330519176; Tue, 27 Sep 2022 19:01:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664330519; cv=none; d=google.com; s=arc-20160816; b=gEiRiKyvrRIu5v8L7G2vtJPQ8nF9XOpBc+igtCX3NweoGKZeTEo9G03+wnIsANMYby 7bBT8s6MP58fOuGj+9N9/eVHAX1UQ5wm+gm4RooIvyMlQ6tgx2Wil/IYJRNAn7QCUH48 WWTURi3C35JKG7KqwNKdSI6O6gWHRzsnkZO1EiB0mRtK5D0uWyQndQwmD3Xrx18jWf5e H2/A+vFfmciHyPjOvc4nQxM64AzPDYmkjrY7LQG+UJ8B8Gmm626fmUGf5qwVvKxCnkbr NOvJJjLTgVZDy/M+PW5PbKZTBlg8+9BbSw8I+4DrfoeOV++2nBVa974DFDsk0fCKesq1 BgfA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:subject:cc:to:from; bh=jsuNddyBPKzABuHxIkwqANnwh6zAjKpLQ7Kuy4FXZkI=; b=mR5ky+uQoIyiIkZNJypWG7VegwEFhyz7vRUOXx/ik8ltZ7oqFi3XIwdqVlumzdqM55 70uISK5SKqysW58sC2U0IlJaMV+RpMITBBt9/wqyiLi3tcQZ8K9DCrBbNj4HwBzhgnwG PHsppOmzBP6SB9JsjpKnBRMeHG52EVbz9jDAeJDRIQ7gvH03xAG+JQurT2/5X06b1N4+ gEiKyEoBQZdlzBAh3AfYzlHi1+/r3SiG3xu36xke4QX3+FGk0Z07aMWcoLN5V+bkzAUU 65CHrMv4CaJ/sbtc/QoS0lArDxugunz//N92kttLO6Ojn3KevYZHnc7uygVHGaArjWHc aL4Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id o10-20020a170902d4ca00b0017280be5a02si4433680plg.589.2022.09.27.19.01.27; Tue, 27 Sep 2022 19:01:59 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232524AbiI1Bpt (ORCPT + 99 others); Tue, 27 Sep 2022 21:45:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57772 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229870AbiI1Bpr (ORCPT ); Tue, 27 Sep 2022 21:45:47 -0400 Received: from mail.nfschina.com (mail.nfschina.com [124.16.136.209]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id E77EB21E3E for ; Tue, 27 Sep 2022 18:45:45 -0700 (PDT) Received: from localhost (unknown [127.0.0.1]) by mail.nfschina.com (Postfix) with ESMTP id 528A11E80D40; Wed, 28 Sep 2022 09:41:29 +0800 (CST) X-Virus-Scanned: amavisd-new at test.com Received: from mail.nfschina.com ([127.0.0.1]) by localhost (mail.nfschina.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 1a6pOUBdVnZH; Wed, 28 Sep 2022 09:41:26 +0800 (CST) Received: from localhost.localdomain (unknown [219.141.250.2]) (Authenticated sender: zhoujie@nfschina.com) by mail.nfschina.com (Postfix) with ESMTPA id 90A9C1E80D33; Wed, 28 Sep 2022 09:41:25 +0800 (CST) From: Zhou jie To: akpm@linux-foundation.org, vbabka@suse.cz, mhiramat@kernel.org, rostedt@goodmis.org, edumazet@google.com, zhoujie@nfschina.com, ahalaney@redhat.com, rdunlap@infradead.org, christophe.leroy@csgroup.eu, rppt@kernel.org, mark-pk.tsai@mediatek.com Cc: linux-kernel@vger.kernel.org Subject: [PATCH] init:Remove unnecessary (void*) conversions Date: Wed, 28 Sep 2022 09:45:39 +0800 Message-Id: <20220928014539.11046-1-zhoujie@nfschina.com> X-Mailer: git-send-email 2.18.2 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The void pointer object can be directly assigned to different structure objects, it does not need to be cast. Signed-off-by: Zhou jie --- init/main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/init/main.c b/init/main.c index 98182c3c2c4b..5494caa24738 100644 --- a/init/main.c +++ b/init/main.c @@ -1239,7 +1239,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(); @@ -1248,7 +1248,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", -- 2.18.2