Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 204938
b: refs/heads/master
c: c0dd394
h: refs/heads/master
v: v3
  • Loading branch information
Jonas Bonn authored and Grant Likely committed Jul 24, 2010
1 parent f359ac2 commit 10efd95
Show file tree
Hide file tree
Showing 8 changed files with 29 additions and 82 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c608558407aa64d2b98d58bfc116e95c0afb357e
refs/heads/master: c0dd394ca5e78649b7013c3ce2d6338af9f228f0
2 changes: 1 addition & 1 deletion trunk/arch/microblaze/kernel/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ extra-y := head.o vmlinux.lds

obj-y += dma.o exceptions.o \
hw_exception_handler.o init_task.o intc.o irq.o \
of_platform.o process.o prom.o prom_parse.o ptrace.o \
process.o prom.o prom_parse.o ptrace.o \
setup.o signal.o sys_microblaze.o timer.o traps.o reset.o

obj-y += cpu/
Expand Down
49 changes: 0 additions & 49 deletions trunk/arch/microblaze/kernel/of_platform.c

This file was deleted.

24 changes: 0 additions & 24 deletions trunk/arch/powerpc/kernel/of_platform.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,30 +28,6 @@
#include <asm/ppc-pci.h>
#include <asm/atomic.h>

/*
* The list of OF IDs below is used for matching bus types in the
* system whose devices are to be exposed as of_platform_devices.
*
* This is the default list valid for most platforms. This file provides
* functions who can take an explicit list if necessary though
*
* The search is always performed recursively looking for children of
* the provided device_node and recursively if such a children matches
* a bus type in the list
*/

const struct of_device_id of_default_bus_ids[] = {
{ .type = "soc", },
{ .compatible = "soc", },
{ .type = "spider", },
{ .type = "axon", },
{ .type = "plb5", },
{ .type = "plb4", },
{ .type = "opb", },
{ .type = "ebc", },
{},
};

#ifdef CONFIG_PPC_OF_PLATFORM_PCI

/* The probing of PCI controllers from of_platform is currently
Expand Down
14 changes: 13 additions & 1 deletion trunk/arch/powerpc/platforms/cell/qpace_setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,24 @@ static void qpace_progress(char *s, unsigned short hex)
printk("*** %04x : %s\n", hex, s ? s : "");
}

static const struct of_device_id qpace_bus_ids[] __initdata = {
{ .type = "soc", },
{ .compatible = "soc", },
{ .type = "spider", },
{ .type = "axon", },
{ .type = "plb5", },
{ .type = "plb4", },
{ .type = "opb", },
{ .type = "ebc", },
{},
};

static int __init qpace_publish_devices(void)
{
int node;

/* Publish OF platform devices for southbridge IOs */
of_platform_bus_probe(NULL, NULL, NULL);
of_platform_bus_probe(NULL, qpace_bus_ids, NULL);

/* There is no device for the MIC memory controller, thus we create
* a platform device for it to attach the EDAC driver to.
Expand Down
14 changes: 13 additions & 1 deletion trunk/arch/powerpc/platforms/cell/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -141,14 +141,26 @@ static int __devinit cell_setup_phb(struct pci_controller *phb)
return 0;
}

static const struct of_device_id cell_bus_ids[] __initdata = {
{ .type = "soc", },
{ .compatible = "soc", },
{ .type = "spider", },
{ .type = "axon", },
{ .type = "plb5", },
{ .type = "plb4", },
{ .type = "opb", },
{ .type = "ebc", },
{},
};

static int __init cell_publish_devices(void)
{
struct device_node *root = of_find_node_by_path("/");
struct device_node *np;
int node;

/* Publish OF platform devices for southbridge IOs */
of_platform_bus_probe(NULL, NULL, NULL);
of_platform_bus_probe(NULL, cell_bus_ids, NULL);

/* On spider based blades, we need to manually create the OF
* platform devices for the PCI host bridges
Expand Down
4 changes: 1 addition & 3 deletions trunk/drivers/of/platform.c
Original file line number Diff line number Diff line change
Expand Up @@ -701,9 +701,7 @@ int of_platform_bus_probe(struct device_node *root,
struct platform_device *dev;
int rc = 0;

if (matches == NULL)
matches = of_default_bus_ids;
if (matches == OF_NO_DEEP_PROBE)
if (WARN_ON(!matches || matches == OF_NO_DEEP_PROBE))
return -EINVAL;
if (root == NULL)
root = of_find_node_by_path("/");
Expand Down
2 changes: 0 additions & 2 deletions trunk/include/linux/of_platform.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@
#include <linux/of_device.h>
#include <linux/platform_device.h>

extern const struct of_device_id of_default_bus_ids[];

/*
* An of_platform_driver driver is attached to a basic of_device on
* the "platform bus" (platform_bus_type).
Expand Down

0 comments on commit 10efd95

Please sign in to comment.