From patchwork Fri Apr 21 13:41:10 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 9692827 X-Patchwork-Delegate: snitzer@redhat.com 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 A02116037F for ; Fri, 21 Apr 2017 13:42:22 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 91CEB205AB for ; Fri, 21 Apr 2017 13:42:22 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8620B27FA3; Fri, 21 Apr 2017 13:42:22 +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=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 39BDB205AB for ; Fri, 21 Apr 2017 13:42:20 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 2E19E75ED6; Fri, 21 Apr 2017 13:42:19 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 2E19E75ED6 Authentication-Results: ext-mx04.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=arndb.de Authentication-Results: ext-mx04.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=dm-devel-bounces@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 2E19E75ED6 Received: from colo-mx.corp.redhat.com (unknown [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 3C30684CAA; Fri, 21 Apr 2017 13:42:18 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id E8E784E9BB; Fri, 21 Apr 2017 13:42:15 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v3LDgEW1012529 for ; Fri, 21 Apr 2017 09:42:14 -0400 Received: by smtp.corp.redhat.com (Postfix) id 2EBC481DD8; Fri, 21 Apr 2017 13:42:14 +0000 (UTC) Delivered-To: dm-devel@redhat.com Received: from mx1.redhat.com (ext-mx09.extmail.prod.ext.phx2.redhat.com [10.5.110.38]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 3915B81DCE; Fri, 21 Apr 2017 13:42:10 +0000 (UTC) Received: from mout.kundenserver.de (mout.kundenserver.de [217.72.192.73]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 044964DD60; Fri, 21 Apr 2017 13:42:06 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 044964DD60 Authentication-Results: ext-mx09.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=arndb.de Authentication-Results: ext-mx09.extmail.prod.ext.phx2.redhat.com; spf=none smtp.mailfrom=arnd@arndb.de DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 044964DD60 Received: from wuerfel.lan ([78.42.17.5]) by mrelayeu.kundenserver.de (mreue103 [212.227.15.145]) with ESMTPA (Nemesis) id 0MNeGY-1cuQDZ28bK-007DuI; Fri, 21 Apr 2017 15:42:03 +0200 From: Arnd Bergmann To: stable@vger.kernel.org Date: Fri, 21 Apr 2017 15:41:10 +0200 Message-Id: <20170421134212.2727744-1-arnd@arndb.de> X-Provags-ID: V03:K0:JDZSUrwH4Wfu2zBXA0x8grxGIjyCYiFOkrwl+yGi/TC3O22s9Uo jpfKwJFGuUt/7eDeL+XsewrFHo+5wF3geIXrt7n3xB0TF6hR4Iwqd6T/rZclbMlyFw+sQby MmjTHTLvUyix6ocear208eawGeKd2CbhpMIKCBgCFGMXbMdLDRLitxP8igtASwZ81vKrbUh h+geVrxyTUwnbfB0tSl0A== X-UI-Out-Filterresults: notjunk:1; V01:K0:9JJZFIUypvU=:oqPVfuwIlFJG2uM5K8GkBh 0zqOf8eEbewCBwzIGa1bcPueFOMBXQ9LsGjlY4Z2F1/XKu4UlLmuBxlWL9f4Yc8H+glz9DFk5 3EbB+p//ZWgGnzyKXkvQS5R84dYy7W5PWEmUYgHn3KfYTBI4GsB7mvH+ePcu095HDTVfDTqBe /Z4Lla7nFybKN6oaiODh8N00RX5pko5uB4cGZ135Hn8Rtsar/fgBqTJeD2H7uhLekQvGAIsak uNk9ZEGpj1gJV3aelQWHaVm8i9UoPm1rtFxXF7yvqsPrpsTGTAosjvDyDvtETQ9eLAT9Hc7kl BZdK8dHqJ2UqHPD8OrsgOCh0P99BNXc7Yz8JFpaBJZOvfpX0OXPmpvKrqy+5BMfBoP+hRaMx2 kLTniGNhlZKc2IY8QAr6HRbAZexJsBMnQAafeIQfqyN5a/Q/idBlKIEvqQiN0BXfrBZSkfi4g PKCEGE4keh2vIGFoWVqcey5zd/X1ahuTqgOVs84UKCONfsDh+T6j2azSnzYfEbx82Enep68wF tRwfbv15ZC/hFX9kG9vQObTxl1PDDhgqQk1R1kRYxoSiwJwrebIn6fkPC+ljxmkA66DmXyHHW soyOsHNLD9THXwxdSW+fozDBUrc9WvJM3ThHXepb7OyyqsRCaAXhMFEPsYZmiy2MRudALLT8x YfCNCLb/Zk8wu+EW8rYhYwNBCFN34RWZJS8D+X1uint04UcOGb/VEbCvZoD1Jop7T6zs= X-Greylist: Sender passed SPF test, Sender IP whitelisted by DNSRBL, ACL 203 matched, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.38]); Fri, 21 Apr 2017 13:42:07 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.38]); Fri, 21 Apr 2017 13:42:07 +0000 (UTC) for IP:'217.72.192.73' DOMAIN:'mout.kundenserver.de' HELO:'mout.kundenserver.de' FROM:'arnd@arndb.de' RCPT:'' X-RedHat-Spam-Score: -2.01 (BAYES_50, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2) 217.72.192.73 mout.kundenserver.de 217.72.192.73 mout.kundenserver.de X-Scanned-By: MIMEDefang 2.78 on 10.5.110.38 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-loop: dm-devel@redhat.com Cc: Arnd Bergmann , Mike Snitzer , gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org, linux-raid@vger.kernel.org, dm-devel@redhat.com, Alasdair Kergon Subject: [dm-devel] [PATCH 3.18-stable] dm bufio: hide bogus warning X-BeenThere: dm-devel@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: device-mapper development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: dm-devel-bounces@redhat.com Errors-To: dm-devel-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.28]); Fri, 21 Apr 2017 13:42:20 +0000 (UTC) X-Virus-Scanned: ClamAV using ClamSMTP mips-gcc-5.3 warns about correct code on linux-3.18 and earlier: In file included from ../include/linux/blkdev.h:4:0, from ../drivers/md/dm-bufio.h:12, from ../drivers/md/dm-bufio.c:9: ../drivers/md/dm-bufio.c: In function 'alloc_buffer': ../include/linux/sched.h:1975:56: warning: 'noio_flag' may be used uninitialized in this function [-Wmaybe-uninitialized] current->flags = (current->flags & ~PF_MEMALLOC_NOIO) | flags; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~ ../drivers/md/dm-bufio.c:325:11: note: 'noio_flag' was declared here The warning disappeared on later kernels with this commit: be0c37c985ed ("MIPS: Rearrange PTE bits into fixed positions.") I assume this only happened because it changed some inlining decisions. On 3.18.y, we can shut up the warning by adding an extra initialization. Signed-off-by: Arnd Bergmann --- drivers/md/dm-bufio.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/md/dm-bufio.c b/drivers/md/dm-bufio.c index ecbd3ffcf359..91fe43b98c96 100644 --- a/drivers/md/dm-bufio.c +++ b/drivers/md/dm-bufio.c @@ -349,6 +349,7 @@ static void *alloc_buffer_data(struct dm_bufio_client *c, gfp_t gfp_mask, * as if GFP_NOIO was specified. */ + noio_flag = 0; if (gfp_mask & __GFP_NORETRY) noio_flag = memalloc_noio_save();