Merge tag 'sound-3.8' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound
[cascardo/linux.git] / drivers / usb / musb / davinci.c
index 959a6d7..b1c01ca 100644 (file)
@@ -504,7 +504,7 @@ static const struct musb_platform_ops davinci_ops = {
 
 static u64 davinci_dmamask = DMA_BIT_MASK(32);
 
-static int __devinit davinci_probe(struct platform_device *pdev)
+static int davinci_probe(struct platform_device *pdev)
 {
        struct musb_hdrc_platform_data  *pdata = pdev->dev.platform_data;
        struct platform_device          *musb;
@@ -512,7 +512,6 @@ static int __devinit davinci_probe(struct platform_device *pdev)
        struct clk                      *clk;
 
        int                             ret = -ENOMEM;
-       int                             musbid;
 
        glue = kzalloc(sizeof(*glue), GFP_KERNEL);
        if (!glue) {
@@ -520,18 +519,10 @@ static int __devinit davinci_probe(struct platform_device *pdev)
                goto err0;
        }
 
-       /* get the musb id */
-       musbid = musb_get_id(&pdev->dev, GFP_KERNEL);
-       if (musbid < 0) {
-               dev_err(&pdev->dev, "failed to allocate musb id\n");
-               ret = -ENOMEM;
-               goto err1;
-       }
-
-       musb = platform_device_alloc("musb-hdrc", musbid);
+       musb = platform_device_alloc("musb-hdrc", PLATFORM_DEVID_AUTO);
        if (!musb) {
                dev_err(&pdev->dev, "failed to allocate musb device\n");
-               goto err2;
+               goto err1;
        }
 
        clk = clk_get(&pdev->dev, "usb");
@@ -547,7 +538,6 @@ static int __devinit davinci_probe(struct platform_device *pdev)
                goto err4;
        }
 
-       musb->id                        = musbid;
        musb->dev.parent                = &pdev->dev;
        musb->dev.dma_mask              = &davinci_dmamask;
        musb->dev.coherent_dma_mask     = davinci_dmamask;
@@ -590,9 +580,6 @@ err4:
 err3:
        platform_device_put(musb);
 
-err2:
-       musb_put_id(&pdev->dev, musbid);
-
 err1:
        kfree(glue);
 
@@ -600,11 +587,10 @@ err0:
        return ret;
 }
 
-static int __devexit davinci_remove(struct platform_device *pdev)
+static int davinci_remove(struct platform_device *pdev)
 {
        struct davinci_glue             *glue = platform_get_drvdata(pdev);
 
-       musb_put_id(&pdev->dev, glue->musb->id);
        platform_device_unregister(glue->musb);
        clk_disable(glue->clk);
        clk_put(glue->clk);
@@ -615,7 +601,7 @@ static int __devexit davinci_remove(struct platform_device *pdev)
 
 static struct platform_driver davinci_driver = {
        .probe          = davinci_probe,
-       .remove         = __devexit_p(davinci_remove),
+       .remove         = davinci_remove,
        .driver         = {
                .name   = "musb-davinci",
        },