Re: [PATCH v3] ASoC: SOF: ipc3-topology: Correct get_control_data for non bytes payload

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

 



On (22/04/27 22:13), Sergey Senozhatsky wrote:
> > @@ -784,16 +785,26 @@ static int sof_get_control_data(struct snd_soc_component *scomp,
> >  		}
> >  
> >  		cdata = wdata[i].control->ipc_control_data;
> > -		wdata[i].pdata = cdata->data;
> > -		if (!wdata[i].pdata)
> > -			return -EINVAL;
> >  
> >  		/* make sure data is valid - data can be updated at runtime */
> 
> A silly nit: does this comment belong to SOF_ABI_MAGIC check below?

I mean something like this?

---
 
 		cdata = wdata[i].control->ipc_control_data;
 
-		/* make sure data is valid - data can be updated at runtime */
 		if (widget->dobj.widget.kcontrol_type[i] == SND_SOC_TPLG_TYPE_BYTES) {
+			/*
+			 * make sure data is valid - data can be updated at
+			 * runtime
+			 */
 			if (cdata->data->magic != SOF_ABI_MAGIC)
 				return -EINVAL;
 



[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Pulse Audio]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux