mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-30 18:47:06 +00:00
1a8218d6e4
This contains the following new bigger changes: * new partition parser which still could lake some features or have bugs * new nand flash driver * using physmap-flash flash driver for parallel flash * some changes to the serial flash driver With these changes OpenWrt starts using more of the mainline flash drivers. SVN-Revision: 35632
30 lines
1.1 KiB
Diff
30 lines
1.1 KiB
Diff
--- a/arch/mips/bcm47xx/sprom.c
|
|
+++ b/arch/mips/bcm47xx/sprom.c
|
|
@@ -71,7 +71,7 @@ static void nvram_read_ ## type (const c
|
|
fallback); \
|
|
if (err < 0) \
|
|
return; \
|
|
- err = kstrto ## type (buf, 0, &var); \
|
|
+ err = kstrto ## type(strim(buf), 0, &var); \
|
|
if (err) { \
|
|
pr_warn("can not parse nvram name %s%s%s with value %s got %i\n", \
|
|
prefix, name, postfix, buf, err); \
|
|
@@ -99,7 +99,7 @@ static void nvram_read_u32_2(const char
|
|
err = get_nvram_var(prefix, NULL, name, buf, sizeof(buf), fallback);
|
|
if (err < 0)
|
|
return;
|
|
- err = kstrtou32(buf, 0, &val);
|
|
+ err = kstrtou32(strim(buf), 0, &val);
|
|
if (err) {
|
|
pr_warn("can not parse nvram name %s%s with value %s got %i\n",
|
|
prefix, name, buf, err);
|
|
@@ -120,7 +120,7 @@ static void nvram_read_leddc(const char
|
|
err = get_nvram_var(prefix, NULL, name, buf, sizeof(buf), fallback);
|
|
if (err < 0)
|
|
return;
|
|
- err = kstrtou32(buf, 0, &val);
|
|
+ err = kstrtou32(strim(buf), 0, &val);
|
|
if (err) {
|
|
pr_warn("can not parse nvram name %s%s with value %s got %i\n",
|
|
prefix, name, buf, err);
|