lkml.org 
[lkml]   [2014]   [Sep]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/3] i2c: add support for Cypress CYUSBS234 USB-I2C adapter
On Thu, Sep 25, 2014 at 05:46:16AM +0000, Muthu Mani wrote:

> > > +static int cy_i2c_xfer(struct i2c_adapter *adapter,
> > > + struct i2c_msg *msgs, int num) {
> > > + int ret = 0;
> > > + struct cyusbs_i2c *cy_i2c;
> > > + struct cyusbs23x *cyusbs = (struct cyusbs23x
> > > +*)adapter->algo_data;
> > > +
> > > + dev_dbg(&adapter->dev, "%s\n", __func__);
> > > +
> > > + if (num > 1) {
> > > + dev_err(&adapter->dev, "i2c_msg number is > 1\n");
> > > + return -EIO;
> > > + }
> >
> > Why not handle multiple messages?
>
> This iteration of the driver is designed to handle only a single
> message at a time.
> It can be expanded to handle multiple messages in future.

No, please do that now. It's just a matter of adding a for loop.

Thanks,
Johan


\
 
 \ /
  Last update: 2014-09-30 12:41    [W:0.122 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site