OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

virtio-dev message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: Re: [PATCH V3] virtio: i2c: Allow zero-length transactions


On Wed, Sep 01 2021, Viresh Kumar <viresh.kumar@linaro.org> wrote:

> The I2C protocol allows zero-length requests with no data, like the
> SMBus Quick command, where the command is inferred based on the
> read/write flag itself.
>
> In order to allow such a request, allocate another bit,
> VIRTIO_I2C_FLAGS_M_RD(1), in the flags to pass the request type, as read
> or write. This was earlier done using the read/write permission to the
> buffer itself.
>
> This still won't work well if multiple buffers are passed for the same
> request, i.e. the write-read requests, as the VIRTIO_I2C_FLAGS_M_RD flag
> can only be used with a single buffer.
>
> Coming back to it, there is no need to send multiple buffers with a
> single request. All we need, is a way to group several requests
> together, which we can already do based on the
> VIRTIO_I2C_FLAGS_FAIL_NEXT flag.
>
> Remove support for multiple buffers within a single request.
>
> Since we are at very early stage of development currently, we can do
> these modifications without addition of new features or versioning of
> the protocol.

I'm a bit worried about this statement. While we have not done a formal
release of the standard since i2c has been added, it still has been out
there already, and this is an incompatible change (even if it is one
that makes sense.)

So, I'm a bit torn between just going with this and adding a feature bit
(that can be mandatory so we don't need to drag the old implementation
around.) But I'm also worried whether there are more incompatible
changes expected in the near future; if there are, I'd be more
comfortable if we could just hold off until everyone agrees things are
stable.



[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]