aboutsummaryrefslogtreecommitdiffstats
path: root/arch/microblaze/kernel/of_device.c
diff options
context:
space:
mode:
authorGrant Likely <grant.likely@secretlab.ca>2010-04-13 16:12:29 -0700
committerGrant Likely <grant.likely@secretlab.ca>2010-05-18 16:10:44 -0600
commit61c7a080a5a061c976988fd4b844dfb468dda255 (patch)
tree8cb492b73f2755c38a6164d770da34d5af6486a0 /arch/microblaze/kernel/of_device.c
parenti2c/of: Allow device node to be passed via i2c_board_info (diff)
downloadlinux-dev-61c7a080a5a061c976988fd4b844dfb468dda255.tar.xz
linux-dev-61c7a080a5a061c976988fd4b844dfb468dda255.zip
of: Always use 'struct device.of_node' to get device node pointer.
The following structure elements duplicate the information in 'struct device.of_node' and so are being eliminated. This patch makes all readers of these elements use device.of_node instead. (struct of_device *)->node (struct dev_archdata *)->prom_node (sparc) (struct dev_archdata *)->of_node (powerpc & microblaze) Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'arch/microblaze/kernel/of_device.c')
-rw-r--r--arch/microblaze/kernel/of_device.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/arch/microblaze/kernel/of_device.c b/arch/microblaze/kernel/of_device.c
index f6c521898ebf..90d2246e15c0 100644
--- a/arch/microblaze/kernel/of_device.c
+++ b/arch/microblaze/kernel/of_device.c
@@ -12,7 +12,7 @@
void of_device_make_bus_id(struct of_device *dev)
{
static atomic_t bus_no_reg_magic;
- struct device_node *node = dev->node;
+ struct device_node *node = dev->dev.of_node;
const u32 *reg;
u64 addr;
int magic;
@@ -76,17 +76,17 @@ int of_device_uevent(struct device *dev, struct kobj_uevent_env *env)
ofdev = to_of_device(dev);
- if (add_uevent_var(env, "OF_NAME=%s", ofdev->node->name))
+ if (add_uevent_var(env, "OF_NAME=%s", ofdev->dev.of_node->name))
return -ENOMEM;
- if (add_uevent_var(env, "OF_TYPE=%s", ofdev->node->type))
+ if (add_uevent_var(env, "OF_TYPE=%s", ofdev->dev.of_node->type))
return -ENOMEM;
/* Since the compatible field can contain pretty much anything
* it's not really legal to split it out with commas. We split it
* up using a number of environment variables instead. */
- compat = of_get_property(ofdev->node, "compatible", &cplen);
+ compat = of_get_property(ofdev->dev.of_node, "compatible", &cplen);
while (compat && *compat && cplen > 0) {
if (add_uevent_var(env, "OF_COMPATIBLE_%d=%s", seen, compat))
return -ENOMEM;