]> git.baikalelectronics.ru Git - uboot.git/commit
button: add udevice forward declaration
authorNeil Armstrong <narmstrong@baylibre.com>
Fri, 19 Feb 2021 07:31:47 +0000 (08:31 +0100)
committerNeil Armstrong <narmstrong@baylibre.com>
Mon, 22 Feb 2021 10:07:57 +0000 (11:07 +0100)
commit3279a843d5a54c37eaad75aff672bb3d90b3ea3d
tree9d8273bd3ff130be32bc976724ddd3119f1347c0
parentb8d4c31f4aeb755fa7dab1d7f7ae6d8932c9fe12
button: add udevice forward declaration

After a8f86699a83e ("common: Drop asm/global_data.h from common header")
build fails with :

drivers/button/button-uclass.c:13:5: error: conflicting types for 'button_get_by_label'
int button_get_by_label(const char *label, struct udevice **devp)
    ^~~~~~~~~~~~~~~~~~~

Adding struct udevice forward declaration in button.h solves the build error.

Fixes: a8f86699a83e ("common: Drop asm/global_data.h from common header")
Suggested-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
include/button.h