From: Jesper Juhl <jesper.juhl@gmail.com>
To: "Saripalli, Venkata Ramanamurthy (STSD)" <saripalli@hp.com>
Cc: linux-kernel@vger.kernel.org, linux-scsi@vger.kernel.org, axboe@suse.de
Subject: Re: [PATCH 1/2] cpqfc: fix for "Using too much stach" in 2.6 kernel
Date: Thu, 4 Aug 2005 15:53:19 +0200 [thread overview]
Message-ID: <9a87484905080406533ad143f9@mail.gmail.com> (raw)
In-Reply-To: <4221C1B21C20854291E185D1243EA8F302623BCC@bgeexc04.asiapacific.cpqcorp.net>
On 8/4/05, Saripalli, Venkata Ramanamurthy (STSD) <saripalli@hp.com> wrote:
> Patch 1 of 2
>
> This patch fixes the "#error this is too much stack" in 2.6 kernel.
> Using kmalloc to allocate memory to ulFibreFrame.
>
[snip]
> if( fchs->pl[0] == ELS_LILP_FRAME)
> {
> + kfree(ulFibreFrame);
> return 1; // found the LILP frame!
> }
> else
> {
> + kfree(ulFibreFrame);
> // keep looking...
> }
The first thing you do in either branch is to call
kfree(ulFibreFrame); , so instead of having the call in both branches
you might as well just have one call before the if(). Ohh and this
looks like it could do with a CodingStyle cleanup as well.
kfree(ulFibreFrame);
if (fchs->pl[0] == ELS_LILP_FRAME)
return 1; /* found the LILP frame! */
/* keep looking */
--
Jesper Juhl <jesper.juhl@gmail.com>
Don't top-post http://www.catb.org/~esr/jargon/html/T/top-post.html
Plain text mails only, please http://www.expita.com/nomime.html
next prev parent reply other threads:[~2005-08-04 13:53 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-08-04 4:39 [PATCH 1/2] cpqfc: fix for "Using too much stach" in 2.6 kernel Saripalli, Venkata Ramanamurthy (STSD)
2005-08-04 4:39 ` Saripalli, Venkata Ramanamurthy (STSD)
2005-08-04 4:49 ` Dave Jones
2005-08-04 9:38 ` Rolf Eike Beer
2005-08-04 12:13 ` Denis Vlasenko
2005-08-04 15:40 ` Dave Jones
2005-08-04 15:56 ` Rolf Eike Beer
2005-08-04 16:42 ` Dave Jones
2005-08-04 17:11 ` Rolf Eike Beer
2005-08-04 17:38 ` Dave Jones
2005-08-04 13:53 ` Jesper Juhl [this message]
2005-08-06 1:13 ` Jesper Juhl
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=9a87484905080406533ad143f9@mail.gmail.com \
--to=jesper.juhl@gmail.com \
--cc=axboe@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=saripalli@hp.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 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.