PERFORCE change 129920 for review

Hans Petter Selasky hselasky at freebsd.org
Sat Feb 2 13:15:16 PST 2008


On Saturday 02 February 2008, Alfred Perlstein wrote:
> * Hans Petter Selasky <hselasky at freebsd.org> [080201 23:18] wrote:
> > On Saturday 02 February 2008, Alfred Perlstein wrote:
> > > This change makes very little sense.  If xfer->frbuffers is a bare
> > > pointer, then why add 0 to it?  Just pass xfer->frbuffers or use a
> > > macro that explains what you are doing.
> >
> > I can change those to a plain "xfer->frlengths". It was just a reminder
> > for me, because some places we use "xfer->frlengths + 1" and
> > "xfer->frbuffers + 1".
> >
> > I will write a script that converts all of those.
>
> What does '+ 1' mean?  Is it something special like a channel or something?
>
> If so it should be a macro that's more descriptive.

Hi,

"frlengths" and "frbuffers" simply make up an I/O-vector. Usually all elements 
go the same direction, either IN or OUT relative to the USB Host.

The exception is control transfers. These usually have three parts:

<SETUP - OUT> < DATA IN or OUT > < STATUS direction is opposite of DATA stage>

< [frlengths and frbuffers] + 0> < [frlenghts and frbuffers] + 1> < the STATUS 
does not have any frlenghts or frbuffers entry >

--HPS


More information about the p4-projects mailing list