From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8FE38C282C2 for ; Thu, 7 Feb 2019 17:54:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 628452083B for ; Thu, 7 Feb 2019 17:54:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727141AbfBGRx6 (ORCPT ); Thu, 7 Feb 2019 12:53:58 -0500 Received: from shards.monkeyblade.net ([23.128.96.9]:50070 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726793AbfBGRx5 (ORCPT ); Thu, 7 Feb 2019 12:53:57 -0500 Received: from localhost (unknown [IPv6:2601:601:9f80:35cd::bf5]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) (Authenticated sender: davem-davemloft) by shards.monkeyblade.net (Postfix) with ESMTPSA id 0778C146D59A9; Thu, 7 Feb 2019 09:53:56 -0800 (PST) Date: Thu, 07 Feb 2019 09:53:56 -0800 (PST) Message-Id: <20190207.095356.712805621945637462.davem@davemloft.net> To: yzhai003@ucr.edu Cc: csong@cs.ucr.edu, zhiyunq@cs.ucr.edu, peppe.cavallaro@st.com, alexandre.torgue@st.com, maxime.ripard@free-electrons.com, wens@csie.org, netdev@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] net: stmmac: Variable "val" in function sun8i_dwmac_set_syscon() could be uninitialized From: David Miller In-Reply-To: References: <20190205221559.17545-1-yzhai003@ucr.edu> <20190206.201736.1146228626076916564.davem@davemloft.net> X-Mailer: Mew version 6.8 on Emacs 26.1 Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Thu, 07 Feb 2019 09:53:57 -0800 (PST) Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org From: Yizhuo Zhai Date: Wed, 6 Feb 2019 21:52:15 -0800 > Thanks, but why initialization matters here? Is performance the main > concern? Code that is unnecessary is hard to audit. People will ask "why" is it initialized? In what situations is the initialized value of "0" ever used? You are wasting people's time and energy by writing unnecessary code.