From: Greg KH <greg@kroah.com>
To: David Vrabel <david.vrabel@csr.com>
Cc: Jesper Juhl <jj@chaosbits.net>,
linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] UWB: Return UWB_RSV_ALLOC_NOT_FOUND rather than crashing on NULL dereference if kzalloc fails
Date: Mon, 8 Nov 2010 08:41:25 -0800 [thread overview]
Message-ID: <20101108164125.GC10892@kroah.com> (raw)
In-Reply-To: <4CD7F056.6080405@csr.com>
On Mon, Nov 08, 2010 at 12:43:02PM +0000, David Vrabel wrote:
> Jesper Juhl wrote:
> > Hi,
> >
> > Crashing on a null pointer deref is never a nice thing to do. It seems to
> > me that it's better to simply return UWB_RSV_ALLOC_NOT_FOUND if kzalloc()
> > fails in uwb_rsv_find_best_allocation().
>
> This is fine.
>
> struct uwb_rsv_alloc_info is not that large (about 414 bytes I think) so
> it could possibly go on the stack and avoid the allocation.
>
> Acked-by: David Vrabel <david.vrabel@csr.com>
>
> Greg, seeing as I'm not maintaining the UWB subsystem any more do you
> want to pick this (and future) UWB patches?
Yes, I can do that, and will take this one.
thanks,
greg k-h
prev parent reply other threads:[~2010-11-08 16:42 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-07 21:04 [PATCH] UWB: Return UWB_RSV_ALLOC_NOT_FOUND rather than crashing on NULL dereference if kzalloc fails Jesper Juhl
2010-11-08 12:43 ` David Vrabel
2010-11-08 16:41 ` Greg KH [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=20101108164125.GC10892@kroah.com \
--to=greg@kroah.com \
--cc=david.vrabel@csr.com \
--cc=jj@chaosbits.net \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
/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