[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <4C8E4FE7.4080808@codeaurora.org>
Date: Mon, 13 Sep 2010 09:23:03 -0700
From: Gregory Bean <gbean@...eaurora.org>
To: Vasiliy Kulikov <segooon@...il.com>
CC: kernel-janitors@...r.kernel.org,
Andrew Morton <akpm@...ux-foundation.org>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] gpio: sx150x: fix error code value
> err = sx150x_i2c_read(chip->client, reg,&data);
> if (err>= 0)
> - err = (data& mask) != 0 ? 1 : 0;
> + err = (data& mask) != 0 ? -EIO : 0;
>
This doesn't work. The IO pins are gpio data pins, which are used as 0
or 1 data values (see sx150x_gpio_get). Returning -EIO whenever an
attempt is made to gpio_get_value on a non-zero gpio line will break things.
--
Employee of Qualcomm Innovation Center, Inc.
Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.
--
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