[PATCH 1/2] dix: Better document Dispatch(), WaitForSomething() and alike
Vignatti Tiago (Nokia-MS/Helsinki)
tiago.vignatti at nokia.com
Wed Aug 4 08:33:24 PDT 2010
On Wed, Aug 04, 2010 at 08:41:11AM +0200, ext Fernando Carrijo wrote:
> Tiago Vignatti <tiago.vignatti at nokia.com> wrote:
>
> > > --- a/dix/dispatch.c
> > > +++ b/dix/dispatch.c
> > > @@ -240,6 +240,20 @@ long SmartLastPrint;
> > > void Dispatch(void);
> > > void InitProcVectors(void);
> > >
> > > +/**
> > > + * Select the next client to be served.
> > > + *
> > > + * The chosen client will be picked up from the array of all clients ready for
> > > + * input and/or output; and will be the one with highest dynamic priority.
> > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> > I don't understand this.
>
> You mean my words or the idea they convey? Or both? Sorry, I really don't know
> how to make it clearer. Anyone who candidate to help me out with my English will
> be more than welcome.
idea they convey. I think if you change "highest dynamic priority" to just
"highest priority" helps a lot.
(I hate when I read complicated things to explain something trivial. KISS
philosophy is rocks! :)
> > > diff --git a/os/connection.c b/os/connection.c
> > > index c143fb6..f89eac5 100644
> > > --- a/os/connection.c
> > > +++ b/os/connection.c
> > > @@ -1054,6 +1054,10 @@ AddGeneralSocket(int fd)
> > > FD_SET(fd, &SavedAllSockets);
> > > }
> > >
> > > +/* Adds the device fd to the set of fds representing enabled devices
> > > + * which will be checked by select() the next time WaitForSomething()
> > > + * loops over it in search of input data.
> > > + */
> >
> > maybe we should change AddEnabledDevice to AddInputDevice or something that
> > says it concerns only input devices.
>
> If I did that, I'd feel tempted to keep the symmetry of the naming scheme by
> also changing all occurrences of EnabledDevice in the server code. And to be
> honest, that sounds to me as deserving its own patch series. I can do that, but
> if you don't mind, I'll leave it for the future. Maybe after _this_ series goes
> upstream and I realize that X folks as a whole do encourage code documentation.
of course. Leave it for the future. Actually AddEnabledDevice is exported to
be used on driver side, so the work would be painful :/
Tiago
More information about the xorg-devel
mailing list