[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1403303387.589.359.camel@xylophone>
Date: Fri, 20 Jun 2014 23:29:47 +0100
From: Ben Hutchings <ben.hutchings@...ethink.co.uk>
To: Rob Jones <rob.jones@...ethink.co.uk>
Cc: linus.walleij@...aro.org, gnurou@...il.com, heiko@...ech.de,
linux-kernel@...ethink.co.uk, lgirdwood@...il.com,
linux-kernel@...r.kernel.org, linux-gpio@...r.kernel.org,
broonie@...nel.org
Subject: Re: [PATCH 1/4] drivers/gpio: devres.c: allow gpio
array requests for managed devices
On Thu, 2014-06-19 at 16:46 +0100, Rob Jones wrote:
[...]
> +int devm_gpio_request_array(struct device *dev,
> + const struct gpio *array,
> + size_t num)
> +{
> + int i, err = 0;
> +
> + for (i = 0; i < num; i++, array++) {
> + err = devm_gpio_request_one(dev,
> + array->gpio,
> + array->flags,
> + array->label);
> + if (err) {
> + while (i--)
> + devm_gpio_free(dev, (--array)->gpio);
Missing break here.
> + }
> + }
> +
> + return err;
> +}
> +EXPORT_SYMBOL(devm_gpio_request_array);
[...]
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists