* [PATCH -next] staging: most: fix error return code in audio_probe_channel()
@ 2016-09-25 15:41 Wei Yongjun
2016-09-25 17:26 ` Greg Kroah-Hartman
2016-09-26 7:47 ` Andrey Shvetsov
0 siblings, 2 replies; 4+ messages in thread
From: Wei Yongjun @ 2016-09-25 15:41 UTC (permalink / raw)
To: Greg Kroah-Hartman, Christian Gromm, Andrey Shvetsov, Shraddha Barke
Cc: Wei Yongjun, devel, linux-kernel
From: Wei Yongjun <weiyongjun1@huawei.com>
Fix to return a negative error code from the audio_set_hw_params() error
handling case instead of 0, as done elsewhere in this function.
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
drivers/staging/most/aim-sound/sound.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/staging/most/aim-sound/sound.c b/drivers/staging/most/aim-sound/sound.c
index 3dc625c..00f01c9 100644
--- a/drivers/staging/most/aim-sound/sound.c
+++ b/drivers/staging/most/aim-sound/sound.c
@@ -607,7 +607,8 @@ static int audio_probe_channel(struct most_interface *iface, int channel_id,
channel->id = channel_id;
init_waitqueue_head(&channel->playback_waitq);
- if (audio_set_hw_params(&channel->pcm_hardware, pcm_format, cfg))
+ ret = audio_set_hw_params(&channel->pcm_hardware, pcm_format, cfg);
+ if (ret)
goto err_free_card;
snprintf(card->driver, sizeof(card->driver), "%s", DRIVER_NAME);
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH -next] staging: most: fix error return code in audio_probe_channel()
2016-09-25 15:41 [PATCH -next] staging: most: fix error return code in audio_probe_channel() Wei Yongjun
@ 2016-09-25 17:26 ` Greg Kroah-Hartman
2016-09-26 7:47 ` Andrey Shvetsov
1 sibling, 0 replies; 4+ messages in thread
From: Greg Kroah-Hartman @ 2016-09-25 17:26 UTC (permalink / raw)
To: Wei Yongjun
Cc: Christian Gromm, Andrey Shvetsov, Shraddha Barke, devel,
Wei Yongjun, linux-kernel
On Sun, Sep 25, 2016 at 03:41:11PM +0000, Wei Yongjun wrote:
> From: Wei Yongjun <weiyongjun1@huawei.com>
>
> Fix to return a negative error code from the audio_set_hw_params() error
> handling case instead of 0, as done elsewhere in this function.
>
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> ---
> drivers/staging/most/aim-sound/sound.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/staging/most/aim-sound/sound.c b/drivers/staging/most/aim-sound/sound.c
> index 3dc625c..00f01c9 100644
> --- a/drivers/staging/most/aim-sound/sound.c
> +++ b/drivers/staging/most/aim-sound/sound.c
> @@ -607,7 +607,8 @@ static int audio_probe_channel(struct most_interface *iface, int channel_id,
> channel->id = channel_id;
> init_waitqueue_head(&channel->playback_waitq);
>
> - if (audio_set_hw_params(&channel->pcm_hardware, pcm_format, cfg))
> + ret = audio_set_hw_params(&channel->pcm_hardware, pcm_format, cfg);
> + if (ret)
> goto err_free_card;
Are you sure you want that error value? I need an ack from the driver
maintainers before I can take this...
thanks,
greg k-h
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH -next] staging: most: fix error return code in audio_probe_channel()
2016-09-25 15:41 [PATCH -next] staging: most: fix error return code in audio_probe_channel() Wei Yongjun
2016-09-25 17:26 ` Greg Kroah-Hartman
@ 2016-09-26 7:47 ` Andrey Shvetsov
2016-09-26 8:56 ` Christian Gromm
1 sibling, 1 reply; 4+ messages in thread
From: Andrey Shvetsov @ 2016-09-26 7:47 UTC (permalink / raw)
To: Wei Yongjun
Cc: Greg Kroah-Hartman, Christian Gromm, Shraddha Barke, Wei Yongjun,
devel, linux-kernel
On Sun, Sep 25, 2016 at 03:41:11PM +0000, Wei Yongjun wrote:
> From: Wei Yongjun <weiyongjun1@huawei.com>
>
> Fix to return a negative error code from the audio_set_hw_params() error
> handling case instead of 0, as done elsewhere in this function.
>
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: Andrey Shvetsov <andrey.shvetsov@k2l.de>
> ---
> drivers/staging/most/aim-sound/sound.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/staging/most/aim-sound/sound.c b/drivers/staging/most/aim-sound/sound.c
> index 3dc625c..00f01c9 100644
> --- a/drivers/staging/most/aim-sound/sound.c
> +++ b/drivers/staging/most/aim-sound/sound.c
> @@ -607,7 +607,8 @@ static int audio_probe_channel(struct most_interface *iface, int channel_id,
> channel->id = channel_id;
> init_waitqueue_head(&channel->playback_waitq);
>
> - if (audio_set_hw_params(&channel->pcm_hardware, pcm_format, cfg))
> + ret = audio_set_hw_params(&channel->pcm_hardware, pcm_format, cfg);
> + if (ret)
> goto err_free_card;
>
> snprintf(card->driver, sizeof(card->driver), "%s", DRIVER_NAME);
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH -next] staging: most: fix error return code in audio_probe_channel()
2016-09-26 7:47 ` Andrey Shvetsov
@ 2016-09-26 8:56 ` Christian Gromm
0 siblings, 0 replies; 4+ messages in thread
From: Christian Gromm @ 2016-09-26 8:56 UTC (permalink / raw)
To: Wei Yongjun, Greg Kroah-Hartman
Cc: Andrey Shvetsov, Shraddha Barke, Wei Yongjun, devel, linux-kernel
On Mon, 26 Sep 2016 09:47:19 +0200
Andrey Shvetsov <andrey.shvetsov@k2l.de> wrote:
> On Sun, Sep 25, 2016 at 03:41:11PM +0000, Wei Yongjun wrote:
> > From: Wei Yongjun <weiyongjun1@huawei.com>
> >
> > Fix to return a negative error code from the audio_set_hw_params() error
> > handling case instead of 0, as done elsewhere in this function.
> >
> > Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> Signed-off-by: Andrey Shvetsov <andrey.shvetsov@k2l.de>
Signed-off-by: Christian Gromm <christian.gromm@microchip.com>
>
> > ---
> > drivers/staging/most/aim-sound/sound.c | 3 ++-
> > 1 file changed, 2 insertions(+), 1 deletion(-)
> >
> > diff --git a/drivers/staging/most/aim-sound/sound.c b/drivers/staging/most/aim-sound/sound.c
> > index 3dc625c..00f01c9 100644
> > --- a/drivers/staging/most/aim-sound/sound.c
> > +++ b/drivers/staging/most/aim-sound/sound.c
> > @@ -607,7 +607,8 @@ static int audio_probe_channel(struct most_interface *iface, int channel_id,
> > channel->id = channel_id;
> > init_waitqueue_head(&channel->playback_waitq);
> >
> > - if (audio_set_hw_params(&channel->pcm_hardware, pcm_format, cfg))
> > + ret = audio_set_hw_params(&channel->pcm_hardware, pcm_format, cfg);
> > + if (ret)
> > goto err_free_card;
> >
> > snprintf(card->driver, sizeof(card->driver), "%s", DRIVER_NAME);
> >
>
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2016-09-26 8:56 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-25 15:41 [PATCH -next] staging: most: fix error return code in audio_probe_channel() Wei Yongjun
2016-09-25 17:26 ` Greg Kroah-Hartman
2016-09-26 7:47 ` Andrey Shvetsov
2016-09-26 8:56 ` Christian Gromm
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.