Commit e7c40851 authored by Julian Andres Klode's avatar Julian Andres Klode Committed by Greg Kroah-Hartman

staging: nvec: Introduce nvec_gpio_set_value()

Introduce nvec_gpio_set_value(), which works like
gpio_set_value(), but also creates a debugging
message, if that's enabled.
Signed-off-by: default avatarJulian Andres Klode <jak@jak-linux.org>
Acked-by: default avatarMarc Dietrich <marvin24@gmx.de>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 0b1076c4
......@@ -114,6 +114,13 @@ static void nvec_msg_free(struct nvec_chip *nvec, struct nvec_msg *msg)
atomic_set(&msg->used, 0);
}
static void nvec_gpio_set_value(struct nvec_chip *nvec, int value)
{
dev_dbg(nvec->dev, "GPIO changed from %u to %u\n",
gpio_get_value(nvec->gpio), value);
gpio_set_value(nvec->gpio, value);
}
void nvec_write_async(struct nvec_chip *nvec, const unsigned char *data,
short size)
{
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment