On 27-06-18, 11:15, Daniel Baluta wrote: > On Mi, 2018-06-27 at 15:54 +0530, Vinod wrote: > > On 27-06-18, 10:48, Daniel Baluta wrote: > > > > > > Each compress_start should have a corresponding compress_stop > > > at the end. > > > > > > Also, this gives user a change to cleanup resources that might > > > have been allocated in compress_start. > > I think the assumptions are not quite correct here, resources should > > be > > allocated in .open and cleanup in .free for driver callback. > > > > > > > > > > > Signed-off-by: Daniel Baluta <daniel.baluta@xxxxxxx> > > > --- > > > I'm implementing codec library dynamic loading at runtime and I'm > > > exploring > > > using: > > > * SNDRV_COMPRESS_START -> to load the library > > > * SNDRV_COMPRESS_STOP -> to unload the library > > > > > > This might not be the best idea becasue for example loading > > > the library might introduce some delays, anyhow i still think > > > this that compress_stop is correct thing to add at the end of > > > playback. > > I think you should tie the library load to much earlier in path. Not > > in > > start. > > > > Also, we invoke drain and hence there is no need of stop > > Got your point here. > > Perhaps, > > - use .hw_params to load the codec library. > - add .hw_free (as Liam suggested in a separate email) to unload the codec library. Sure, sounds better design to me > > Thanks we can drop this patch then. Okay -- ~Vinod _______________________________________________ Alsa-devel mailing list Alsa-devel@xxxxxxxxxxxxxxxx http://mailman.alsa-project.org/mailman/listinfo/alsa-devel