diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-24 10:37:38 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-24 10:37:38 -0400 |
commit | 62a11ae3405b6da2535d28e5facc2de5af4a7e62 (patch) | |
tree | 6b68f0e74fe08c0e87488ec0653d59c653e46745 /drivers/mtd/maps/physmap_of.c | |
parent | cedfb2db7b2d6b2c780999536aa1e2650fadee36 (diff) | |
parent | cf9b59e9d3e008591d1f54830f570982bb307a0d (diff) |
Merge branch 'next-devicetree' of git://git.secretlab.ca/git/linux-2.6
* 'next-devicetree' of git://git.secretlab.ca/git/linux-2.6:
of: change of_match_device to work with struct device
of: Remove duplicate fields from of_platform_driver
drivercore: Add of_match_table to the common device drivers
arch/microblaze: Move dma_mask from of_device into pdev_archdata
arch/powerpc: Move dma_mask from of_device into pdev_archdata
of: eliminate of_device->node and dev_archdata->{of,prom}_node
of: Always use 'struct device.of_node' to get device node pointer.
i2c/of: Allow device node to be passed via i2c_board_info
driver-core: Add device node pointer to struct device
of: protect contents of of_platform.h and of_device.h
of/flattree: Make unflatten_device_tree() safe to call from any arch
of/flattree: make of_fdt.h safe to unconditionally include.
Diffstat (limited to 'drivers/mtd/maps/physmap_of.c')
-rw-r--r-- | drivers/mtd/maps/physmap_of.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/drivers/mtd/maps/physmap_of.c b/drivers/mtd/maps/physmap_of.c index 36dbcee1ac29..ba124baa646d 100644 --- a/drivers/mtd/maps/physmap_of.c +++ b/drivers/mtd/maps/physmap_of.c | |||
@@ -143,7 +143,7 @@ static int of_flash_remove(struct of_device *dev) | |||
143 | static struct mtd_info * __devinit obsolete_probe(struct of_device *dev, | 143 | static struct mtd_info * __devinit obsolete_probe(struct of_device *dev, |
144 | struct map_info *map) | 144 | struct map_info *map) |
145 | { | 145 | { |
146 | struct device_node *dp = dev->node; | 146 | struct device_node *dp = dev->dev.of_node; |
147 | const char *of_probe; | 147 | const char *of_probe; |
148 | struct mtd_info *mtd; | 148 | struct mtd_info *mtd; |
149 | static const char *rom_probe_types[] | 149 | static const char *rom_probe_types[] |
@@ -221,7 +221,7 @@ static int __devinit of_flash_probe(struct of_device *dev, | |||
221 | #ifdef CONFIG_MTD_PARTITIONS | 221 | #ifdef CONFIG_MTD_PARTITIONS |
222 | const char **part_probe_types; | 222 | const char **part_probe_types; |
223 | #endif | 223 | #endif |
224 | struct device_node *dp = dev->node; | 224 | struct device_node *dp = dev->dev.of_node; |
225 | struct resource res; | 225 | struct resource res; |
226 | struct of_flash *info; | 226 | struct of_flash *info; |
227 | const char *probe_type = match->data; | 227 | const char *probe_type = match->data; |
@@ -245,7 +245,7 @@ static int __devinit of_flash_probe(struct of_device *dev, | |||
245 | p = of_get_property(dp, "reg", &count); | 245 | p = of_get_property(dp, "reg", &count); |
246 | if (count % reg_tuple_size != 0) { | 246 | if (count % reg_tuple_size != 0) { |
247 | dev_err(&dev->dev, "Malformed reg property on %s\n", | 247 | dev_err(&dev->dev, "Malformed reg property on %s\n", |
248 | dev->node->full_name); | 248 | dev->dev.of_node->full_name); |
249 | err = -EINVAL; | 249 | err = -EINVAL; |
250 | goto err_flash_remove; | 250 | goto err_flash_remove; |
251 | } | 251 | } |
@@ -418,8 +418,11 @@ static struct of_device_id of_flash_match[] = { | |||
418 | MODULE_DEVICE_TABLE(of, of_flash_match); | 418 | MODULE_DEVICE_TABLE(of, of_flash_match); |
419 | 419 | ||
420 | static struct of_platform_driver of_flash_driver = { | 420 | static struct of_platform_driver of_flash_driver = { |
421 | .name = "of-flash", | 421 | .driver = { |
422 | .match_table = of_flash_match, | 422 | .name = "of-flash", |
423 | .owner = THIS_MODULE, | ||
424 | .of_match_table = of_flash_match, | ||
425 | }, | ||
423 | .probe = of_flash_probe, | 426 | .probe = of_flash_probe, |
424 | .remove = of_flash_remove, | 427 | .remove = of_flash_remove, |
425 | }; | 428 | }; |