From: Takashi Sakamoto Subject: Re: [PATCH v2 0/5] topology: Enhance support for private data Date: Mon, 18 Jul 2016 12:43:19 +0900 Message-ID: <578C5057.7020708@sakamocchi.jp> References: <578A2F73.8080508@sakamocchi.jp> <578C4352.1040804@linux.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from smtp-proxy001.phy.lolipop.jp (smtp-proxy001.phy.lolipop.jp [157.7.104.42]) by alsa0.perex.cz (Postfix) with ESMTP id EABFA2656F5 for ; Mon, 18 Jul 2016 05:43:24 +0200 (CEST) In-Reply-To: <578C4352.1040804@linux.intel.com> 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: Mengdong Lin , alsa-devel@alsa-project.org, broonie@kernel.org Cc: tiwai@suse.de, mengdong.lin@intel.com, liam.r.girdwood@intel.com, shreyas.nc@intel.com List-Id: alsa-devel@alsa-project.org On Jul 18 2016 11:47, Mengdong Lin wrote: > Thanks for your suggestions. But this tool is not for directly adding > controls from the user space. > > It's for ADSP firmware vendors to describe the controls/widgets/pcms for > a specific version of firmware. Previously, these components are hard > coded in ASoC platforms drivers and not so convenient to share a common > driver for different firmwares. The topology binary generated by this > tool will be loaded by ASoC platform driver with a specific firmware > binary, and so ASoC will create the controls/widgets/pcms that match the > firmware automatically. I know all of what you explained. Therefore, You misunderstand about my suggestion. What I suggested is to drop a support of SNDRV_CTL_ELEM_ACCESS_USER flag from current topology implementation in userspace library, because current implementation of ALSA SoC part doesn't support it. In ALSA SoC part, snd_ctl_new1() is called to add a control element set as a result of parsing binary blob generated by topology implementation. In snd_ctl_new1(), SNDRV_CTL_ELEM_ACCESS_USER flag is dropped, in these lines: http://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/tree/sound/core/control.c#n263 Totally, the flag cannot be supported by current implementation of topology in kernel. Thus, in userspace, we should drop this line to prevent users from confusions: http://git.alsa-project.org/?p=alsa-lib.git;a=blob;f=src/topology/ctl.c;h=b948ac021ceecc116bc1087075743243e4b14055;hb=HEAD#l44 That's all what I mentioned. If something unclear, please tell it to me. Regards Takashi Sakamoto