Re: [PATCH/RFC 1/2] lib: string: Remove duplicated function

2014-09-12 Thread Tejun Heo
Hello, On Fri, Sep 12, 2014 at 11:01:17AM +0200, Rasmus Villemoes wrote: > On Fri, Sep 12 2014, Andrew Morton wrote: > > > On Wed, 27 Aug 2014 09:36:01 +0200 Rasmus Villemoes > > wrote: > >> strncasecmp is the POSIX name for this functionality. So rename the > >> non-broken function to the

Re: [PATCH/RFC 1/2] lib: string: Remove duplicated function

2014-09-12 Thread Joe Perches
On Fri, 2014-09-12 at 11:01 +0200, Rasmus Villemoes wrote: > Would it make sense to add a checkpatch warning to ensure new users > are not introduced, and then remove it when the wrapper is also removed? Generally the rate of introduction is pretty low. Generally, just making sure it's not used

Re: [PATCH/RFC 1/2] lib: string: Remove duplicated function

2014-09-12 Thread Rasmus Villemoes
On Fri, Sep 12 2014, Andrew Morton wrote: > On Wed, 27 Aug 2014 09:36:01 +0200 Rasmus Villemoes > wrote: > >> lib/string.c contains two functions, strnicmp and strncasecmp, which >> do roughly the same thing, namely compare two strings >> case-insensitively up to a given bound. They have

Re: [PATCH/RFC 1/2] lib: string: Remove duplicated function

2014-09-12 Thread Rasmus Villemoes
On Fri, Sep 12 2014, Andrew Morton a...@linux-foundation.org wrote: On Wed, 27 Aug 2014 09:36:01 +0200 Rasmus Villemoes li...@rasmusvillemoes.dk wrote: lib/string.c contains two functions, strnicmp and strncasecmp, which do roughly the same thing, namely compare two strings

Re: [PATCH/RFC 1/2] lib: string: Remove duplicated function

2014-09-12 Thread Joe Perches
On Fri, 2014-09-12 at 11:01 +0200, Rasmus Villemoes wrote: Would it make sense to add a checkpatch warning to ensure new users are not introduced, and then remove it when the wrapper is also removed? shrug Generally the rate of introduction is pretty low. Generally, just making sure it's not

Re: [PATCH/RFC 1/2] lib: string: Remove duplicated function

2014-09-12 Thread Tejun Heo
Hello, On Fri, Sep 12, 2014 at 11:01:17AM +0200, Rasmus Villemoes wrote: On Fri, Sep 12 2014, Andrew Morton a...@linux-foundation.org wrote: On Wed, 27 Aug 2014 09:36:01 +0200 Rasmus Villemoes li...@rasmusvillemoes.dk wrote: strncasecmp is the POSIX name for this functionality. So

Re: [PATCH/RFC 1/2] lib: string: Remove duplicated function

2014-09-11 Thread Andrew Morton
On Wed, 27 Aug 2014 09:36:01 +0200 Rasmus Villemoes wrote: > lib/string.c contains two functions, strnicmp and strncasecmp, which > do roughly the same thing, namely compare two strings > case-insensitively up to a given bound. They have slightly different > implementations, but the only

Re: [PATCH/RFC 1/2] lib: string: Remove duplicated function

2014-09-11 Thread Andrew Morton
On Wed, 27 Aug 2014 09:36:01 +0200 Rasmus Villemoes li...@rasmusvillemoes.dk wrote: lib/string.c contains two functions, strnicmp and strncasecmp, which do roughly the same thing, namely compare two strings case-insensitively up to a given bound. They have slightly different implementations,

[PATCH/RFC 1/2] lib: string: Remove duplicated function

2014-08-27 Thread Rasmus Villemoes
lib/string.c contains two functions, strnicmp and strncasecmp, which do roughly the same thing, namely compare two strings case-insensitively up to a given bound. They have slightly different implementations, but the only important difference is that strncasecmp doesn't handle len==0

[PATCH/RFC 1/2] lib: string: Remove duplicated function

2014-08-27 Thread Rasmus Villemoes
lib/string.c contains two functions, strnicmp and strncasecmp, which do roughly the same thing, namely compare two strings case-insensitively up to a given bound. They have slightly different implementations, but the only important difference is that strncasecmp doesn't handle len==0