summaryrefslogtreecommitdiff
path: root/include/asm-generic
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-generic')
-rw-r--r--include/asm-generic/global_data.h1
-rw-r--r--include/asm-generic/gpio.h11
2 files changed, 11 insertions, 1 deletions
diff --git a/include/asm-generic/global_data.h b/include/asm-generic/global_data.h
index 74df210033..f61acbc4fc 100644
--- a/include/asm-generic/global_data.h
+++ b/include/asm-generic/global_data.h
@@ -91,6 +91,7 @@ typedef struct global_data {
unsigned long malloc_limit; /* limit address */
unsigned long malloc_ptr; /* current address */
#endif
+ struct udevice *cur_serial_dev; /* current serial device */
struct arch_global_data arch; /* architecture-specific data */
} gd_t;
#endif
diff --git a/include/asm-generic/gpio.h b/include/asm-generic/gpio.h
index f81b51aa30..36a36c64b8 100644
--- a/include/asm-generic/gpio.h
+++ b/include/asm-generic/gpio.h
@@ -257,6 +257,15 @@ const char *gpio_get_bank_info(struct udevice *dev, int *offset_count);
int gpio_lookup_name(const char *name, struct udevice **devp,
unsigned int *offsetp, unsigned int *gpiop);
-int name_to_gpio(const char *name);
+/**
+ * get_gpios() - Turn the values of a list of GPIOs into an integer
+ *
+ * This puts the value of the first GPIO into bit 0, the second into bit 1,
+ * etc. then returns the resulting integer.
+ *
+ * @gpio_list: List of GPIOs to collect
+ * @return resulting integer value
+ */
+unsigned gpio_get_values_as_int(const int *gpio_list);
#endif /* _ASM_GENERIC_GPIO_H_ */