On Wed, Jul 5, 2023 at 5:33 PM Philippe Mathieu-Daudé <phi...@linaro.org> wrote:
> qemu_chr_fe_add_watch() can poll for multiple conditions. > It's @cond argument is a combination of all the condition bits. > > Signed-off-by: Philippe Mathieu-Daudé <phi...@linaro.org> > --- > include/chardev/char-fe.h | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/include/chardev/char-fe.h b/include/chardev/char-fe.h > index 8c420fa36e..309960046a 100644 > --- a/include/chardev/char-fe.h > +++ b/include/chardev/char-fe.h > @@ -179,8 +179,8 @@ typedef gboolean (*FEWatchFunc)(void *do_not_use, > GIOCondition condition, void * > > /** > * qemu_chr_fe_add_watch: > - * @cond: the condition to poll for > - * @func: the function to call when the condition happens > + * @cond: bitwise combination of conditions to poll for > + * @func: the function to call when the conditions are satisfied > Not really worth imo, do you want to also fix all the io/ docs for @condition? and probably elsewhere... The rewording of @func isn't much clearer either... "any of the conditions"? > * @user_data: the opaque pointer to pass to @func > * > * If the backend is connected, create and add a #GSource that fires > -- > 2.38.1 > > > -- Marc-André Lureau