From: Takashi Iwai <tiwai@suse.de>
To: Giuliano Pochini <pochini@shiny.it>
Cc: alsa-devel@alsa-project.org, Kulikov Vasiliy <segooon@gmail.com>,
kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org,
Julia Lawall <julia@diku.dk>
Subject: Re: [PATCH 11/15] pci: echoaudio: check kmalloc() result
Date: Mon, 19 Jul 2010 18:00:12 +0200 [thread overview]
Message-ID: <s5haapnfomr.wl%tiwai@suse.de> (raw)
In-Reply-To: <20100716211650.4abb6387@Jay>
At Fri, 16 Jul 2010 21:16:50 +0200,
Giuliano Pochini wrote:
>
> On Fri, 16 Jul 2010 20:15:43 +0400
> Kulikov Vasiliy <segooon@gmail.com> wrote:
>
> > If kmalloc() fails exit with -ENOMEM.
> >
> > Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
> > ---
> > sound/pci/echoaudio/echoaudio.c | 2 ++
> > 1 files changed, 2 insertions(+), 0 deletions(-)
> >
> > diff --git a/sound/pci/echoaudio/echoaudio.c b/sound/pci/echoaudio/echoaudio.c
> > index 668a5ec..20763dd 100644
> > --- a/sound/pci/echoaudio/echoaudio.c
> > +++ b/sound/pci/echoaudio/echoaudio.c
> > @@ -2250,6 +2250,8 @@ static int snd_echo_resume(struct pci_dev *pci)
> > DE_INIT(("resume start\n"));
> > pci_restore_state(pci);
> > commpage_bak = kmalloc(sizeof(struct echoaudio), GFP_KERNEL);
> > + if (commpage_bak == NULL)
> > + return -ENOMEM;
> > commpage = chip->comm_page;
> > memcpy(commpage_bak, commpage, sizeof(struct comm_page));
> >
>
> Yes, of course. Thank you.
>
>
> Ack-by: Giuliano Pochini <pochini@shiny.it>
Applied now. Thanks.
Takashi
prev parent reply other threads:[~2010-07-19 16:00 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-16 16:15 [PATCH 11/15] pci: echoaudio: check kmalloc() result Kulikov Vasiliy
2010-07-16 19:16 ` Giuliano Pochini
2010-07-19 16:00 ` Takashi Iwai [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=s5haapnfomr.wl%tiwai@suse.de \
--to=tiwai@suse.de \
--cc=alsa-devel@alsa-project.org \
--cc=julia@diku.dk \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=pochini@shiny.it \
--cc=segooon@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox