[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <D6759987A7968C4889FDA6FA91D5CBC801BFEAE0@PGSMSX103.gar.corp.intel.com>
Date: Thu, 2 Jun 2016 09:11:03 +0000
From: "Voon, Weifeng" <weifeng.voon@...el.com>
To: Uwe Kleine-König
<u.kleine-koenig@...gutronix.de>
CC: Wolfram Sang <wsa@...-dreams.de>,
Jarkko Nikula <jarkko.nikula@...ux.intel.com>,
"linux-i2c@...r.kernel.org" <linux-i2c@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
"Tan, Jui Nee" <jui.nee.tan@...el.com>
Subject: RE: [PATCH] i2c: designware: Enable ioctl I2C_TIMEOUT
> From: Uwe Kleine-König [mailto:u.kleine-koenig@...gutronix.de]
> On Thu, Jun 02, 2016 at 03:57:30PM +0800, Weifeng Voon wrote:
> > This allows applications to set the transfer timeout in 10ms
> > increments via ioctl I2C_TIMEOUT.
>
> 10ms is only correct with HZ=100. With higher values of HZ you get a finer
> resolution. I'd write:
>
> Respect the transfer timeout set via the I2C_TIMEOUT ioctl.
>
10ms is correct and regardless of HZ.
>From i2c-dev.c:
client->adapter->timeout = msecs_to_jiffies(arg * 10);
The purpose of putting in the resolution of 10ms is just for the ease of others when
they are using this patch. I am ok to take it out if it is not necessary.
> and not mention the resolution at all. After all your patch doesn't "enable" that
> ioctl, just makes use of the value set by it.
Yes, you are right. I am just using the value set by it. Maybe this may sounds more
relevant:
Set transfer timeout via ioctl I2C_TIMEOUT
Or any other recommendation?
>
> Best regards
> Uwe
>
>
> --
> Pengutronix e.K. | Uwe Kleine-König |
> Industrial Linux Solutions | http://www.pengutronix.de/ |
Powered by blists - more mailing lists