diff options
author | Rasmus Villemoes <linux@rasmusvillemoes.dk> | 2014-10-13 18:54:29 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-10-13 20:18:24 -0400 |
commit | 2bebf5cb4ea12164e7b15755baf423651e271146 (patch) | |
tree | 1b66166c17f14517932651f67c9fd77ce8825461 | |
parent | b0bfb63118612e3614cf77b115c00f895a42c96a (diff) |
ARM: replace strnicmp with strncasecmp
The kernel used to contain two functions for length-delimited,
case-insensitive string comparison, strnicmp with correct semantics and
a slightly buggy strncasecmp. The latter is the POSIX name, so strnicmp
was renamed to strncasecmp, and strnicmp made into a wrapper for the new
strncasecmp to avoid breaking existing users.
To allow the compat wrapper strnicmp to be removed at some point in the
future, and to avoid the extra indirection cost, do
s/strnicmp/strncasecmp/g.
Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
Cc: Russell King <linux@arm.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | arch/arm/mach-pxa/lpd270.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/arch/arm/mach-pxa/lpd270.c b/arch/arm/mach-pxa/lpd270.c index 9f6ec167902a..ad777b353bd5 100644 --- a/arch/arm/mach-pxa/lpd270.c +++ b/arch/arm/mach-pxa/lpd270.c | |||
@@ -416,17 +416,17 @@ static struct pxafb_mach_info *lpd270_lcd_to_use; | |||
416 | 416 | ||
417 | static int __init lpd270_set_lcd(char *str) | 417 | static int __init lpd270_set_lcd(char *str) |
418 | { | 418 | { |
419 | if (!strnicmp(str, "lq057q3dc02", 11)) { | 419 | if (!strncasecmp(str, "lq057q3dc02", 11)) { |
420 | lpd270_lcd_to_use = &sharp_lq057q3dc02; | 420 | lpd270_lcd_to_use = &sharp_lq057q3dc02; |
421 | } else if (!strnicmp(str, "lq121s1dg31", 11)) { | 421 | } else if (!strncasecmp(str, "lq121s1dg31", 11)) { |
422 | lpd270_lcd_to_use = &sharp_lq121s1dg31; | 422 | lpd270_lcd_to_use = &sharp_lq121s1dg31; |
423 | } else if (!strnicmp(str, "lq036q1da01", 11)) { | 423 | } else if (!strncasecmp(str, "lq036q1da01", 11)) { |
424 | lpd270_lcd_to_use = &sharp_lq036q1da01; | 424 | lpd270_lcd_to_use = &sharp_lq036q1da01; |
425 | } else if (!strnicmp(str, "lq64d343", 8)) { | 425 | } else if (!strncasecmp(str, "lq64d343", 8)) { |
426 | lpd270_lcd_to_use = &sharp_lq64d343; | 426 | lpd270_lcd_to_use = &sharp_lq64d343; |
427 | } else if (!strnicmp(str, "lq10d368", 8)) { | 427 | } else if (!strncasecmp(str, "lq10d368", 8)) { |
428 | lpd270_lcd_to_use = &sharp_lq10d368; | 428 | lpd270_lcd_to_use = &sharp_lq10d368; |
429 | } else if (!strnicmp(str, "lq035q7db02-20", 14)) { | 429 | } else if (!strncasecmp(str, "lq035q7db02-20", 14)) { |
430 | lpd270_lcd_to_use = &sharp_lq035q7db02_20; | 430 | lpd270_lcd_to_use = &sharp_lq035q7db02_20; |
431 | } else { | 431 | } else { |
432 | printk(KERN_INFO "lpd270: unknown lcd panel [%s]\n", str); | 432 | printk(KERN_INFO "lpd270: unknown lcd panel [%s]\n", str); |