]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
smc91x: remove GPIOLIB dependency.
authorYoshinori Sato <ysato@users.sourceforge.jp>
Thu, 26 Dec 2019 09:21:36 +0000 (18:21 +0900)
committerYoshinori Sato <ysato@users.sourceforge.jp>
Thu, 16 Apr 2020 04:43:36 +0000 (13:43 +0900)
Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
drivers/net/ethernet/smsc/Kconfig
drivers/net/ethernet/smsc/smc91x.c

index 9e1c3752b200416c570a346b507852d4c3adf704..64ca1b36b91e067d2109c1b8f4b94b8ac94b7dc0 100644 (file)
@@ -37,7 +37,6 @@ config SMC91X
        tristate "SMC 91C9x/91C1xxx support"
        select CRC32
        select MII
-       depends on !OF || GPIOLIB
        depends on ARM || ARM64 || ATARI_ETHERNAT || COLDFIRE || \
                   MIPS || NIOS2 || SUPERH || XTENSA || H8300
        ---help---
index 90410f9d3b1aaec270b358d5c2c9bdf259e62f62..605dc17290efb857ec3586d67eb0bef0598baa87 100644 (file)
@@ -2190,6 +2190,7 @@ static const struct of_device_id smc91x_match[] = {
 };
 MODULE_DEVICE_TABLE(of, smc91x_match);
 
+#if defined(CONFIG_GPIOLIB)
 /**
  * of_try_set_control_gpio - configure a gpio if it exists
  */
@@ -2214,6 +2215,15 @@ static int try_toggle_control_gpio(struct device *dev,
 
        return 0;
 }
+#else
+static int try_toggle_control_gpio(struct device *dev,
+                                  struct gpio_desc **desc,
+                                  const char *name, int index,
+                                  int value, unsigned int nsdelay)
+{
+       return 0;
+}
+#endif
 #endif
 
 /*