From mboxrd@z Thu Jan 1 00:00:00 1970 From: Takashi Iwai Subject: Re: [PATCH 1/4] ctl: confirm to return all identical information in 'activate' event Date: Sat, 11 Apr 2015 17:40:39 +0200 Message-ID: References: <1428512838-2493-1-git-send-email-o-takashi@sakamocchi.jp> <1428741665-22262-1-git-send-email-o-takashi@sakamocchi.jp> <1428741665-22262-2-git-send-email-o-takashi@sakamocchi.jp> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mx2.suse.de (cantor2.suse.de [195.135.220.15]) by alsa0.perex.cz (Postfix) with ESMTP id 0F6F7260A50 for ; Sat, 11 Apr 2015 17:40:44 +0200 (CEST) In-Reply-To: <1428741665-22262-2-git-send-email-o-takashi@sakamocchi.jp> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org To: Takashi Sakamoto Cc: alsa-devel@alsa-project.org, clemens@ladisch.de List-Id: alsa-devel@alsa-project.org At Sat, 11 Apr 2015 17:41:02 +0900, Takashi Sakamoto wrote: > > When event originator doesn't set numerical ID in identical information, > the event data includes no numerical ID, thus userspace applications > cannot identify the control just by unique ID in event data. > > This commit fix this bug so as the event data includes all of identical > information. > > Signed-off-by: Takashi Sakamoto Applied, thanks. Takashi > --- > sound/core/control.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/sound/core/control.c b/sound/core/control.c > index 00fcaa0..90a9e5d 100644 > --- a/sound/core/control.c > +++ b/sound/core/control.c > @@ -578,6 +578,7 @@ error: > * > * Finds the control instance with the given id, and activate or > * inactivate the control together with notification, if changed. > + * The given ID data is filled with full information. > * > * Return: 0 if unchanged, 1 if changed, or a negative error code on failure. > */ > @@ -607,6 +608,7 @@ int snd_ctl_activate_id(struct snd_card *card, struct snd_ctl_elem_id *id, > goto unlock; > vd->access |= SNDRV_CTL_ELEM_ACCESS_INACTIVE; > } > + snd_ctl_build_ioff(id, kctl, index_offset); > ret = 1; > unlock: > up_write(&card->controls_rwsem); > -- > 2.1.0 >