From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755300AbbICOb7 (ORCPT ); Thu, 3 Sep 2015 10:31:59 -0400 Received: from mx0a-00082601.pphosted.com ([67.231.145.42]:64054 "EHLO mx0a-00082601.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753273AbbICObw (ORCPT ); Thu, 3 Sep 2015 10:31:52 -0400 Subject: Re: [GIT PULL] SG changes for 4.3 To: Ming Lin References: <20150902165833.GC14454@kernel.dk> <55E77B00.4040302@fb.com> <55E77D4B.2020604@fb.com> CC: Linus Torvalds , Linux Kernel Mailing List From: Jens Axboe Message-ID: <55E859D1.5030402@fb.com> Date: Thu, 3 Sep 2015 08:31:45 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 8bit X-Originating-IP: [192.168.54.13] X-Proofpoint-Spam-Reason: safe X-FB-Internal: Safe X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:5.14.151,1.0.33,0.0.0000 definitions=2015-09-03_08:2015-09-03,2015-09-03,1970-01-01 signatures=0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 09/02/2015 10:28 PM, Ming Lin wrote: > On Wed, Sep 2, 2015 at 3:50 PM, Jens Axboe wrote: >> On 09/02/2015 04:41 PM, Jens Axboe wrote: >>> >>> On 09/02/2015 04:34 PM, Linus Torvalds wrote: >>>> >>>> Jens, >>>> >>>> On Wed, Sep 2, 2015 at 9:58 AM, Jens Axboe wrote: >>>>> >>>>> >>>>> This pull request contains a set of scatter-gather related changes/fixes >>>>> for 4.3. It contains: >>>> >>>> >>>> This results in several new and annoying warnings. They may all be ok >>>> code, but they are very distracting. Please stop introducing new >>>> warnings to the build, because by now most of the warnings I see come >>>> from the block layer. >>>> >>>> block/blk-merge.c: In function ‘blk_queue_split’: >>>> include/linux/blkdev.h:1368:21: warning: ‘bvprv.bv_offset’ may be >>>> used uninitialized in this function [-Wmaybe-uninitialized] >>>> ((bprv->bv_offset + bprv->bv_len) & queue_virt_boundary(q)); >>>> >>>> (it gives this for bv_len too). The reason seems to be that disgusting >>>> situation where "bvprv" is uninitiatlized unless "split" is true, and >>>> the code looks like it is correct, but the compiler clearly has a hard >>>> time seeing it. It took me a while too, so I can't really blame it. >>>> >>>> Either initialize bvprv to something explicit, or make the code clear >>>> enough that the compiler can see that it is never used uninitialized. >>>> Because those compiler warnings are sometimes real, and we can't just >>>> ignore them. >>>> >>>> There was another type-based warning introduced by your core block >>>> pull (size_t vs unsigned int). >>> >>> >>> I think it's a repeat offender that got reintroduced. I'll fix it up. >> >> >> This seems to make it happier. Will go out later in the merge window. >> >> https://urldefense.proofpoint.com/v1/url?u=http://git.kernel.dk/cgit/linux-block/commit/?h%3Dfor-linus%26id%3D5014c311baa2b21384321fa4a9f617a92e3e56f0&k=ZVNjlDMF0FElm4dQtryO4A%3D%3D%0A&r=3JMVyziIyZtZ5cv9eWNLwQ%3D%3D%0A&m=japm7LD5hS2iGfc2KmNCva0tg%2FTlU%2BypJqbyuKQJk6U%3D%0A&s=dbea685c3231dae01cce41309c39c6c1597bd0dd1b4d6fbe5ee4caae86385fe8 > > Thanks Jens. > > I didn't see these warnings with gcc 4.8.4. > What gcc version did you use or need to turn on some config option to > see the warning? axboe@lenny:~ $ gcc --version gcc (Ubuntu 5.1.0-0ubuntu11~14.04.1) 5.1.0 Looks like gcc is growing dumber. -- Jens Axboe