mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Rasmus Villemoes <linux@rasmusvillemoes.dk>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org,
	Rasmus Villemoes <linux@rasmusvillemoes.dk>,
	Russell King <linux@arm.linux.org.uk>,
	linux-arm-kernel@lists.infradead.org
Subject: [PATCH 01/22] ARM: Replace strnicmp with strncasecmp
Date: Tue, 16 Sep 2014 22:51:15 +0200	[thread overview]
Message-ID: <1410900696-6481-2-git-send-email-linux@rasmusvillemoes.dk> (raw)
In-Reply-To: <1410900696-6481-1-git-send-email-linux@rasmusvillemoes.dk>

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.

Cc: Russell King <linux@arm.linux.org.uk>
Cc: linux-arm-kernel@lists.infradead.org
Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
---
 arch/arm/mach-pxa/lpd270.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/arch/arm/mach-pxa/lpd270.c b/arch/arm/mach-pxa/lpd270.c
index 9f6ec16..ad777b3 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;
 
 static int __init lpd270_set_lcd(char *str)
 {
-	if (!strnicmp(str, "lq057q3dc02", 11)) {
+	if (!strncasecmp(str, "lq057q3dc02", 11)) {
 		lpd270_lcd_to_use = &sharp_lq057q3dc02;
-	} else if (!strnicmp(str, "lq121s1dg31", 11)) {
+	} else if (!strncasecmp(str, "lq121s1dg31", 11)) {
 		lpd270_lcd_to_use = &sharp_lq121s1dg31;
-	} else if (!strnicmp(str, "lq036q1da01", 11)) {
+	} else if (!strncasecmp(str, "lq036q1da01", 11)) {
 		lpd270_lcd_to_use = &sharp_lq036q1da01;
-	} else if (!strnicmp(str, "lq64d343", 8)) {
+	} else if (!strncasecmp(str, "lq64d343", 8)) {
 		lpd270_lcd_to_use = &sharp_lq64d343;
-	} else if (!strnicmp(str, "lq10d368", 8)) {
+	} else if (!strncasecmp(str, "lq10d368", 8)) {
 		lpd270_lcd_to_use = &sharp_lq10d368;
-	} else if (!strnicmp(str, "lq035q7db02-20", 14)) {
+	} else if (!strncasecmp(str, "lq035q7db02-20", 14)) {
 		lpd270_lcd_to_use = &sharp_lq035q7db02_20;
 	} else {
 		printk(KERN_INFO "lpd270: unknown lcd panel [%s]\n", str);
-- 
2.0.4


  reply	other threads:[~2014-09-16 20:52 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-16 20:51 [PATCH 00/22] treewide: " Rasmus Villemoes
2014-09-16 20:51 ` Rasmus Villemoes [this message]
2014-09-16 20:51 ` [PATCH 02/22] block: " Rasmus Villemoes
2014-09-16 20:51 ` [PATCH 03/22] netfilter: " Rasmus Villemoes
2014-09-16 20:51 ` [PATCH 04/22] video: fbdev: " Rasmus Villemoes
2014-09-16 20:51 ` [PATCH 05/22] cifs: " Rasmus Villemoes
2014-09-16 20:51 ` [PATCH 06/22] ocfs2: " Rasmus Villemoes
2014-09-16 20:51 ` [PATCH 07/22] isofs: " Rasmus Villemoes
2014-09-16 21:19   ` Jan Kara
2014-09-16 20:51 ` [PATCH 08/22] ALSA: hda - " Rasmus Villemoes
2014-09-17  5:54   ` Takashi Iwai
2014-09-16 20:51 ` [PATCH 09/22] batman-adv: " Rasmus Villemoes
2014-09-17  6:00   ` [B.A.T.M.A.N.] " Antonio Quartulli
2014-09-16 20:51 ` [PATCH 10/22] ACPI / battery: " Rasmus Villemoes
2014-09-25 23:46   ` Rafael J. Wysocki
2014-09-16 20:51 ` [PATCH 11/22] cpufreq: " Rasmus Villemoes
2014-09-16 21:22   ` Viresh Kumar
2014-09-25 23:53     ` Rafael J. Wysocki
2014-09-16 20:51 ` [PATCH 12/22] cpuidle: " Rasmus Villemoes
2014-09-25 23:52   ` Rafael J. Wysocki
2014-09-16 20:51 ` [PATCH 13/22] scsi: " Rasmus Villemoes
2014-09-16 20:51 ` [PATCH 14/22] ib_srpt: " Rasmus Villemoes
2014-09-16 20:51 ` [PATCH 15/22] Input: edt-ft5x06 - " Rasmus Villemoes
2014-09-17 16:26   ` Dmitry Torokhov
2014-09-16 20:51 ` [PATCH 16/22] altera-stapl: " Rasmus Villemoes
2014-09-16 20:51 ` [PATCH 17/22] thinkpad_acpi: " Rasmus Villemoes
2014-09-16 22:08   ` Darren Hart
2014-09-17  8:12     ` Rasmus Villemoes
2014-09-16 20:51 ` [PATCH 18/22] PNP: " Rasmus Villemoes
2014-09-16 20:51 ` [PATCH 19/22] s390/cio: " Rasmus Villemoes
2014-09-16 20:51 ` [PATCH 20/22] staging: r8188eu: " Rasmus Villemoes
2014-09-16 20:51 ` [PATCH 21/22] Thermal: " Rasmus Villemoes
2014-09-18  0:49   ` Zhang Rui
2014-09-16 20:51 ` [PATCH 22/22] kdb: " Rasmus Villemoes
2014-09-16 21:55 ` [PATCH 00/22] treewide: " Theodore Ts'o
2014-09-17  8:23   ` Rasmus Villemoes

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1410900696-6481-2-git-send-email-linux@rasmusvillemoes.dk \
    --to=linux@rasmusvillemoes.dk \
    --cc=akpm@linux-foundation.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@arm.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®