Skip to content

Commit

Permalink
Merge tag 'dt-for-linus' of git://git.secretlab.ca/git/linux
Browse files Browse the repository at this point in the history
Pull device tree fixes from Grant Likely:
 "Drivercore bugfixes for v3.15

  This branch contains bug fixes important to get into v3.15.  There is
  a fix for modifying properties seen during early boot, a fix for an
  incorrect prototype when CONFIG_OF=n, and a couple of corrections to
  device tree memory nodes on a few platforms"

* tag 'dt-for-linus' of git://git.secretlab.ca/git/linux:
  mips: dts: Fix missing device_type="memory" property in memory nodes
  arm: dts: Fix missing device_type="memory" for ste-ccu8540
  of: fix CONFIG_OF=n prototype of of_node_full_name()
  of: make of_update_property() usable earlier in the boot process
  • Loading branch information
torvalds committed May 21, 2014
2 parents 60b5f90 + dfc44f8 commit 31a3fca
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 1 deletion.
1 change: 1 addition & 0 deletions arch/arm/boot/dts/ste-ccu8540.dts
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
compatible = "st-ericsson,ccu8540", "st-ericsson,u8540";

memory@0 {
device_type = "memory";
reg = <0x20000000 0x1f000000>, <0xc0000000 0x3f000000>;
};

Expand Down
1 change: 1 addition & 0 deletions arch/mips/lantiq/dts/easy50712.dts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
};

memory@0 {
device_type = "memory";
reg = <0x0 0x2000000>;
};

Expand Down
1 change: 1 addition & 0 deletions arch/mips/ralink/dts/mt7620a_eval.dts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
model = "Ralink MT7620A evaluation board";

memory@0 {
device_type = "memory";
reg = <0x0 0x2000000>;
};

Expand Down
1 change: 1 addition & 0 deletions arch/mips/ralink/dts/rt2880_eval.dts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
model = "Ralink RT2880 evaluation board";

memory@0 {
device_type = "memory";
reg = <0x8000000 0x2000000>;
};

Expand Down
1 change: 1 addition & 0 deletions arch/mips/ralink/dts/rt3052_eval.dts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
model = "Ralink RT3052 evaluation board";

memory@0 {
device_type = "memory";
reg = <0x0 0x2000000>;
};

Expand Down
1 change: 1 addition & 0 deletions arch/mips/ralink/dts/rt3883_eval.dts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
model = "Ralink RT3883 evaluation board";

memory@0 {
device_type = "memory";
reg = <0x0 0x2000000>;
};

Expand Down
4 changes: 4 additions & 0 deletions drivers/of/base.c
Original file line number Diff line number Diff line change
Expand Up @@ -1831,6 +1831,10 @@ int of_update_property(struct device_node *np, struct property *newprop)
if (!found)
return -ENODEV;

/* At early boot, bail out and defer setup to of_init() */
if (!of_kset)
return found ? 0 : -ENODEV;

/* Update the sysfs attribute */
sysfs_remove_bin_file(&np->kobj, &oldprop->attr);
__of_add_property_sysfs(np, newprop);
Expand Down
2 changes: 1 addition & 1 deletion include/linux/of.h
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@ int of_device_is_stdout_path(struct device_node *dn);

#else /* CONFIG_OF */

static inline const char* of_node_full_name(struct device_node *np)
static inline const char* of_node_full_name(const struct device_node *np)
{
return "<no-node>";
}
Expand Down

0 comments on commit 31a3fca

Please sign in to comment.