From patchwork Mon Jul 4 15:07:45 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 9212881 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 53B6860572 for ; Mon, 4 Jul 2016 15:31:09 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4501628713 for ; Mon, 4 Jul 2016 15:31:09 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 37A4D2873E; Mon, 4 Jul 2016 15:31:09 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 80E2028713 for ; Mon, 4 Jul 2016 15:31:08 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id 84C18265D2B; Mon, 4 Jul 2016 17:31:07 +0200 (CEST) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id AD6CF265DF1; Mon, 4 Jul 2016 17:23:52 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id 0F53C265DF1; Mon, 4 Jul 2016 17:23:51 +0200 (CEST) Received: from mout.kundenserver.de (mout.kundenserver.de [217.72.192.73]) by alsa0.perex.cz (Postfix) with ESMTP id 2FF14266870 for ; Mon, 4 Jul 2016 17:05:04 +0200 (CEST) Received: from wuerfel.lan. ([78.42.132.4]) by mrelayeu.kundenserver.de (mreue104) with ESMTPA (Nemesis) id 0MVuWW-1amxaS1YCG-00X7fn; Mon, 04 Jul 2016 17:04:56 +0200 From: Arnd Bergmann To: Jaroslav Kysela , Takashi Iwai Date: Mon, 4 Jul 2016 17:07:45 +0200 Message-Id: <20160704150759.2909708-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K0:WNKdiQ1GFLlU2oWc487MnzjCl+znJ7YuJSMf5nHrTN9Et0BISLX hBM+q3pmnS1CYvH45J3yFiNI3HHt8CV0LS296QRTbPZp7mQq/4wG77RpP2XEKgsa3hdIja+ yQpUrxYpQbxkc6uIwHEn2BSRXFIIHy7qasRmMp0I++0tn6ycx0Uwaywsg11Xu4tLsNQtVS7 rtePQ8ILDTNO+WWIYCutw== X-UI-Out-Filterresults: notjunk:1; V01:K0:oSMn1LzJiXs=:S24F+ILpNhFaYbK4gdqdB4 YeF53Pq/BX/mkpStSaEgf8XyVtTmzxd834zlYsCFjmFg9PCgP9AinOvYOWCJKjSSqI60miHc/ 0+HpjUul6gmuYYpgazHmJOF/xlNQIYu464jGXrJsjQ9KX8i1/mxY66ewWFTQ2cM6nDws6jOee 5vlRkbDP1qMAgewsA6rsZL/z+ECkBa5/uktZ1m/piSVt+2qzJyPFsg2plIIJaAAoANEgqk82U B/Y50NIRmtVAe79qi60fgIJqKDWy9gTg7LbvRquc5ZYCnXp4WxnwYDGcS2QrR2rQTfeR0ka91 UvzAGTymoZcWaBzDW89DqyhrnFuLpHvR+2tq1oAHlEP1S5i5KotftqLovZVy6UcuSbCkFThKQ +Ms+GW6v2ouWqK7FaDLy5nD8qv6zjRfMplDiMDwYviMY6T+Hb20X3xkRDUZ5yTpqvee8xWKBl PEfNx425+PXduPTO8nd2t5UXJ/ZOOb/EnQ/zQYS6FHoqni5Gw9pFfu9usbG5eKt4pVdNmarf9 qb6OQdnO74pNkN8eE2yDetLcIp7HxfjXf9+JLqG/h4K9AoSgut4nFeQuiT+pVC6zuLOklEtXk 3OiVY0SacI4Sx1evAgi+88G/S7FqBwFSZgwy8OoeWDLwWMxSmVC7wT/uNbrOgf22fd6+uZ6/Z tTHl3CnjgEP27xwmDVKuUwYXIRGkT9vkARcGy7QBRM8xwP9Fh7k2fgcmjgMeJ+AM7Ej8= Cc: alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org, Arnd Bergmann Subject: [alsa-devel] [PATCH] ALSA: ppc/awacs: shut up maybe-uninitialized warning X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP The awacs sound driver produces a false-positive warning in ppc64_defconfig: sound/ppc/awacs.c: In function 'snd_pmac_awacs_init': include/sound/control.h:219:9: warning: 'master_vol' may be used uninitialized in this function [-Wmaybe-uninitialized] I haven't come up with a good way to rewrite the code to avoid the warning, so here is a bad one: I initialize the variable before the conditionall initialization so gcc no longer has to worry about it. Signed-off-by: Arnd Bergmann --- sound/ppc/awacs.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sound/ppc/awacs.c b/sound/ppc/awacs.c index 09da7b52bc2e..1468e4b7bf93 100644 --- a/sound/ppc/awacs.c +++ b/sound/ppc/awacs.c @@ -991,6 +991,7 @@ snd_pmac_awacs_init(struct snd_pmac *chip) if (err < 0) return err; } + master_vol = NULL; if (pm7500) err = build_mixers(chip, ARRAY_SIZE(snd_pmac_awacs_mixers_pmac7500),