From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932099AbbIJIjl (ORCPT ); Thu, 10 Sep 2015 04:39:41 -0400 Received: from mx1.redhat.com ([209.132.183.28]:38305 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754239AbbIJIjO (ORCPT ); Thu, 10 Sep 2015 04:39:14 -0400 Subject: Re: [PATCH] lib/vsprintf.c: increase the size of the field_width variable To: Joe Perches References: <1441793590-23856-1-git-send-email-mlombard@redhat.com> <1441816432.17219.57.camel@perches.com> <87mvwv4ea2.fsf@rasmusvillemoes.dk> <55F12B94.30503@redhat.com> <1441870684.17219.132.camel@perches.com> Cc: Rasmus Villemoes , akpm@linux-foundation.org, tj@kernel.org, linux-kernel@vger.kernel.org From: Maurizio Lombardi Message-ID: <55F141AE.9030407@redhat.com> Date: Thu, 10 Sep 2015 10:39:10 +0200 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: <1441870684.17219.132.camel@perches.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 09/10/2015 09:38 AM, Joe Perches wrote:ing will be printed. > > Maurizio, did you try the patch I posted? > I think it'll work, but it doesn't fix the > fundamental issue of %*pbl with large bitmaps. I tested your patch, it works for the simple cases where bits are set below the S16_MAX limit, example: # modprobe scsi-debug dev_size_mb=256 lbpu=1 lbpws10=1 # vgcreate tsvg /dev/sdb # cat /sys/bus/pseudo/drivers/scsi_debug/map 0-15 <--- OK! # lvcreate -V200m -l99%FREE -T tsvg/pool -n lv1 --discards ignore # cat /sys/bus/pseudo/drivers/scsi_debug/map 0-31,2048-2055 <---- NO! It should be "0-31,2048-2055,501760-501871"! I think it's misleading. Can I suggest as a temporary solution to restore the old bitmap_scnlistprintf() function? > > Perhaps the thin wrapper conversions in lib/bitmap.c > in that commit for bitmap_scnprintf, bscnl_emit, and > bitmap_scnlistprintf should be reverted. > > Thanks, Maurizio Lombardi