Re: [patch 069/104] lib/string_helpers.c:string_get_size(): remove redundant prefixes

2015-02-13 Thread James Bottomley
On Fri, 2015-02-13 at 17:02 -0800, Andrew Morton wrote: > On Fri, 13 Feb 2015 16:05:54 -0800 James Bottomley > wrote: > > > @@ -42,31 +44,60 @@ void string_get_size(u64 size, const enum > > string_size_units units, > > [STRING_UNITS_2] = 1024, > > }; > > int i, j; > > - u3

Re: [patch 069/104] lib/string_helpers.c:string_get_size(): remove redundant prefixes

2015-02-13 Thread Andrew Morton
On Fri, 13 Feb 2015 16:05:54 -0800 James Bottomley wrote: > @@ -42,31 +44,60 @@ void string_get_size(u64 size, const enum > string_size_units units, > [STRING_UNITS_2] = 1024, > }; > int i, j; > - u32 remainder = 0, sf_cap; > + u32 remainder = 0, sf_cap, exp; >

Re: [patch 069/104] lib/string_helpers.c:string_get_size(): remove redundant prefixes

2015-02-13 Thread James Bottomley
On Thu, 2015-02-12 at 15:55 -0800, Andrew Morton wrote: > On Thu, 12 Feb 2015 15:45:29 -0800 James Bottomley > wrote: > > > ... > > > > > I don't get it. As the man says, this is presently dead code and > > > string_get_size() will need to be changed to work for disks larger than > > > 2^64 byt

Re: [patch 069/104] lib/string_helpers.c:string_get_size(): remove redundant prefixes

2015-02-12 Thread Andrew Morton
On Thu, 12 Feb 2015 15:45:29 -0800 James Bottomley wrote: > ... > > > I don't get it. As the man says, this is presently dead code and > > string_get_size() will need to be changed to work for disks larger than > > 2^64 bytes. That change may be to take a u128 or it may be as you > > suggest:

Re: [patch 069/104] lib/string_helpers.c:string_get_size(): remove redundant prefixes

2015-02-12 Thread James Bottomley
On Thu, 2015-02-12 at 15:40 -0800, Andrew Morton wrote: > On Thu, 12 Feb 2015 15:25:08 -0800 James Bottomley > wrote: > > > On Thu, 2015-02-12 at 15:01 -0800, a...@linux-foundation.org wrote: > > > From: Rasmus Villemoes > > > Subject: lib/string_helpers.c:string_get_size(): remove redundant pr

Re: [patch 069/104] lib/string_helpers.c:string_get_size(): remove redundant prefixes

2015-02-12 Thread Andrew Morton
On Thu, 12 Feb 2015 15:25:08 -0800 James Bottomley wrote: > On Thu, 2015-02-12 at 15:01 -0800, a...@linux-foundation.org wrote: > > From: Rasmus Villemoes > > Subject: lib/string_helpers.c:string_get_size(): remove redundant prefixes > > > > While 3c9f3681d0b4 "[SCSI] lib: add generic helper t

Re: [patch 069/104] lib/string_helpers.c:string_get_size(): remove redundant prefixes

2015-02-12 Thread James Bottomley
On Thu, 2015-02-12 at 15:01 -0800, a...@linux-foundation.org wrote: > From: Rasmus Villemoes > Subject: lib/string_helpers.c:string_get_size(): remove redundant prefixes > > While 3c9f3681d0b4 "[SCSI] lib: add generic helper to print sizes rounded > to the correct SI range" says that Z and Y are