summaryrefslogtreecommitdiffstats
path: root/drivers/net/fsl_pq_mdio.c
diff options
context:
space:
mode:
authorLen Brown <len.brown@intel.com>2010-06-01 22:53:36 -0400
committerLen Brown <len.brown@intel.com>2010-06-01 22:53:36 -0400
commitb42f5b0f0fd8c1c442c1b29a3fbcb338e8bd7732 (patch)
tree194e13dfa85d2d2af8bd125acd80a445ee0def62 /drivers/net/fsl_pq_mdio.c
parentfe955682d2153b35dffcf1673dff0491096a3f0a (diff)
parent0a76a34ff0804f1f413807b2e2d12117c2b602ca (diff)
downloadblackbird-op-linux-b42f5b0f0fd8c1c442c1b29a3fbcb338e8bd7732.tar.gz
blackbird-op-linux-b42f5b0f0fd8c1c442c1b29a3fbcb338e8bd7732.zip
Merge branches 'bugzilla-14668' and 'misc-2.6.35' into release
Diffstat (limited to 'drivers/net/fsl_pq_mdio.c')
-rw-r--r--drivers/net/fsl_pq_mdio.c15
1 files changed, 10 insertions, 5 deletions
diff --git a/drivers/net/fsl_pq_mdio.c b/drivers/net/fsl_pq_mdio.c
index 3acac5f930c8..b4c41d72c423 100644
--- a/drivers/net/fsl_pq_mdio.c
+++ b/drivers/net/fsl_pq_mdio.c
@@ -267,7 +267,7 @@ static int get_ucc_id_for_range(u64 start, u64 end, u32 *ucc_id)
static int fsl_pq_mdio_probe(struct of_device *ofdev,
const struct of_device_id *match)
{
- struct device_node *np = ofdev->node;
+ struct device_node *np = ofdev->dev.of_node;
struct device_node *tbi;
struct fsl_pq_mdio_priv *priv;
struct fsl_pq_mdio __iomem *regs = NULL;
@@ -277,15 +277,17 @@ static int fsl_pq_mdio_probe(struct of_device *ofdev,
int tbiaddr = -1;
const u32 *addrp;
u64 addr = 0, size = 0;
- int err = 0;
+ int err;
priv = kzalloc(sizeof(*priv), GFP_KERNEL);
if (!priv)
return -ENOMEM;
new_bus = mdiobus_alloc();
- if (NULL == new_bus)
+ if (!new_bus) {
+ err = -ENOMEM;
goto err_free_priv;
+ }
new_bus->name = "Freescale PowerQUICC MII Bus",
new_bus->read = &fsl_pq_mdio_read,
@@ -469,10 +471,13 @@ static struct of_device_id fsl_pq_mdio_match[] = {
MODULE_DEVICE_TABLE(of, fsl_pq_mdio_match);
static struct of_platform_driver fsl_pq_mdio_driver = {
- .name = "fsl-pq_mdio",
+ .driver = {
+ .name = "fsl-pq_mdio",
+ .owner = THIS_MODULE,
+ .of_match_table = fsl_pq_mdio_match,
+ },
.probe = fsl_pq_mdio_probe,
.remove = fsl_pq_mdio_remove,
- .match_table = fsl_pq_mdio_match,
};
int __init fsl_pq_mdio_init(void)
OpenPOWER on IntegriCloud