Skip to content

Commit

Permalink
usb/isp1760: Let OF bindings depend on general CONFIG_OF instead of P…
Browse files Browse the repository at this point in the history
…PC_OF .

To be able to use the driver on other OF-aware architectures, too.
And add necessary OF related #includes to fix compilation error.

Signed-off-by: Joachim Foerster <joachim.foerster@missinglinkelectronics.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Joachim Foerster authored and Greg Kroah-Hartman committed Oct 18, 2011
1 parent 3687f64 commit 8f5d621
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions drivers/usb/host/isp1760-if.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,18 @@

#include "isp1760-hcd.h"

#ifdef CONFIG_PPC_OF
#ifdef CONFIG_OF
#include <linux/of.h>
#include <linux/of_platform.h>
#include <linux/of_address.h>
#include <linux/of_irq.h>
#endif

#ifdef CONFIG_PCI
#include <linux/pci.h>
#endif

#ifdef CONFIG_PPC_OF
#ifdef CONFIG_OF
static int of_isp1760_probe(struct platform_device *dev)
{
struct usb_hcd *hcd;
Expand Down Expand Up @@ -396,7 +398,7 @@ static int __init isp1760_init(void)
ret = platform_driver_register(&isp1760_plat_driver);
if (!ret)
any_ret = 0;
#ifdef CONFIG_PPC_OF
#ifdef CONFIG_OF
ret = platform_driver_register(&isp1760_of_driver);
if (!ret)
any_ret = 0;
Expand All @@ -416,7 +418,7 @@ module_init(isp1760_init);
static void __exit isp1760_exit(void)
{
platform_driver_unregister(&isp1760_plat_driver);
#ifdef CONFIG_PPC_OF
#ifdef CONFIG_OF
platform_driver_unregister(&isp1760_of_driver);
#endif
#ifdef CONFIG_PCI
Expand Down

0 comments on commit 8f5d621

Please sign in to comment.