lkml.org 
[lkml]   [2009]   [Dec]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH]PM_QOS-to-use-handle-based-requests-pcm-update 5/5
On Wed, Dec 02, 2009 at 12:38:07PM +0100, Takashi Iwai wrote:
> At Tue, 1 Dec 2009 13:38:40 -0800,
> mark gross wrote:
> >
> > --- a/sound/core/pcm_native.c
> > +++ b/sound/core/pcm_native.c
> (snip)
> > @@ -506,8 +508,8 @@ static int snd_pcm_hw_free(struct snd_pcm_substream *substream)
> > if (substream->ops->hw_free)
> > result = substream->ops->hw_free(substream);
> > runtime->status->state = SNDRV_PCM_STATE_OPEN;
> > - pm_qos_remove_requirement(PM_QOS_CPU_DMA_LATENCY,
> > - substream->latency_id);
> > + pm_qos_remove_request(substream->latency_pm_qos_req);
>
> The NULL check seems needed in the caller side because
> pm_qos_remove_request() doesn't do it.

ouch. Thanks for noticing this.

>
> Or, would you add a NULL check in pm_qos_remove_request()?
> It'd be more handy.

I can make the pm_qos_remove_request null pointer safe, its assumed to
be a slow path so it would be a good thing to do.


I'll add this to the next patch set that the e1000e guys are making me
do against linux-next.

Thanks!

--mgross

>
>
> thanks,
>
> Takashi


\
 
 \ /
  Last update: 2009-12-02 22:53    [W:0.937 / U:1.560 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site