#include <dm.h>
#include <asm/gpio.h>
-#ifndef name_to_gpio
-#define name_to_gpio(name) simple_strtoul(name, NULL, 10)
-#endif
+int __weak name_to_gpio(const char *name)
+{
+ return simple_strtoul(name, NULL, 10);
+}
enum gpio_cmd {
GPIO_INPUT,
"unknown",
};
-static void show_gpio(struct device *dev, const char *bank_name, int offset)
+static void show_gpio(struct udevice *dev, const char *bank_name, int offset)
{
struct dm_gpio_ops *ops = gpio_get_ops(dev);
char buf[80];
static int do_gpio_status(const char *gpio_name)
{
- struct device *dev;
+ struct udevice *dev;
int newline = 0;
int ret;