Re: [alsa-devel] [V2 2/2] vgaswitchreoo: set audio client id in vgaswitchreoo enable function

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jul 16, 2018 at 04:47:11PM +0200, Takashi Iwai wrote:
> On Mon, 16 Jul 2018 16:43:42 +0200,
> Lukas Wunner wrote:
> > 
> > On Mon, Jul 16, 2018 at 02:06:35PM +0800, Jim Qu wrote:
> > > +
> > > +	list_for_each_entry(client, &vgasr_priv.clients, list) {
> > > +		if (!client_is_audio(client) || client_id(client) !=
> > > +			VGA_SWITCHEROO_UNKNOWN_ID)
> > 
> > Don't you have to check for
> > 
> >       client_id(client) != VGA_SWITCHEROO_UNKNOWN_ID | ID_BIT_AUDIO
> > 
> > here?  That's the value you assign when the audio client registers,
> > yet you're checking for something else, so you're always skipping
> > over audio clients.  Did you actually test this patch?
> 
> This should be OK, since client_id() is a macro to strip to the core
> id number without ID_BIT_AUDIO.  And client_is_vga() &
> client_is_audio() macros were rewritten along with it, too.

Okay, thanks for the clarification.

Lukas
_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/dri-devel




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux