lkml.org 
[lkml]   [2014]   [Jul]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 5/5] gpio: move gpio_ensure_requested() into legacy C file
On 07/22/2014 12:47 PM, Alexandre Courbot wrote:

(...)

> + if (WARN(test_and_set_bit(FLAG_REQUESTED, &desc->flags) == 0,
> + "autorequest GPIO-%d\n", desc_to_gpio(desc))) {
> + if (!try_module_get(chip->owner)) {
> + gpiod_err(desc, "%s: module can't be gotten\n",
> + __func__);

Should match open parenthesis '('

gpiod_err(desc, "%s: module can't be gotten\n",
__func__);

> + clear_bit(FLAG_REQUESTED, &desc->flags);
> + /* lose */
> + err = -EIO;
> + goto end;
> + }
> + desc->label = "[auto]";
> + /* caller must chip->request() w/o spinlock */
> + if (chip->request)
> + request = true;
> + }
> +
> +end:
> + spin_unlock_irqrestore(&gpio_lock, flags);
> +
> + if (request) {
> + might_sleep_if(chip->can_sleep);
> + err = chip->request(chip, gpio_chip_hwgpio(desc));
> +
> + if (err < 0) {
> + gpiod_dbg(desc, "%s: chip request fail, %d\n",
> + __func__, err);

Dto..

(...)


--
Regards,
Varka Bhadram.



\
 
 \ /
  Last update: 2014-07-22 11:21    [W:0.143 / U:2.096 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site