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=-10.2 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=ham 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 4FE1CC43381 for ; Wed, 10 Feb 2021 12:13:08 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 19BA464E31 for ; Wed, 10 Feb 2021 12:13:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231445AbhBJMMk (ORCPT ); Wed, 10 Feb 2021 07:12:40 -0500 Received: from mx2.suse.de ([195.135.220.15]:43852 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231599AbhBJMJY (ORCPT ); Wed, 10 Feb 2021 07:09:24 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id 378B0AFBF; Wed, 10 Feb 2021 12:08:40 +0000 (UTC) Date: Wed, 10 Feb 2021 13:08:39 +0100 (CET) From: Miroslav Benes To: Dan Carpenter cc: Jessica Yu , Christoph Hellwig , Petr Mladek , linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: Re: [PATCH] module: potential uninitialized return in module_kallsyms_on_each_symbol() In-Reply-To: Message-ID: References: User-Agent: Alpine 2.21 (LSU 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 10 Feb 2021, Dan Carpenter wrote: > Smatch complains that: > > kernel/module.c:4472 module_kallsyms_on_each_symbol() > error: uninitialized symbol 'ret'. > > This warning looks like it could be correct if the &modules list is > empty. > > Fixes: 013c1667cf78 ("kallsyms: refactor {,module_}kallsyms_on_each_symbol") > Signed-off-by: Dan Carpenter Reviewed-by: Miroslav Benes M From mboxrd@z Thu Jan 1 00:00:00 1970 From: Miroslav Benes Date: Wed, 10 Feb 2021 12:08:39 +0000 Subject: Re: [PATCH] module: potential uninitialized return in module_kallsyms_on_each_symbol() Message-Id: List-Id: References: In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Dan Carpenter Cc: Jessica Yu , Christoph Hellwig , Petr Mladek , linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org On Wed, 10 Feb 2021, Dan Carpenter wrote: > Smatch complains that: > > kernel/module.c:4472 module_kallsyms_on_each_symbol() > error: uninitialized symbol 'ret'. > > This warning looks like it could be correct if the &modules list is > empty. > > Fixes: 013c1667cf78 ("kallsyms: refactor {,module_}kallsyms_on_each_symbol") > Signed-off-by: Dan Carpenter Reviewed-by: Miroslav Benes M