From: Max Krasnyansky <maxk@qualcomm.com>
To: Paul Jackson <pj@sgi.com>
Cc: rakib.mullick@gmail.com, menage@google.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] cpuset : Handling improper memory allocation.
Date: Wed, 06 Aug 2008 13:43:56 -0700 [thread overview]
Message-ID: <489A0D0C.1000204@qualcomm.com> (raw)
In-Reply-To: <20080806153700.dc12e5dc.pj@sgi.com>
Paul Jackson wrote:
> Max wrote:
>> partition_sched_domains() can deal with attrs==NULL case. So we do not
>> have to abort domain building.
>
> This might be a good place for a comment, since unchecked kmalloc()
> calls look dangerous:
>
> /* Convert <csn, csa> to <ndoms, doms> */
> doms = kmalloc(ndoms * sizeof(cpumask_t), GFP_KERNEL);
> if (!doms)
> goto rebuild;
> dattr = kmalloc(ndoms * sizeof(struct sched_domain_attr), GFP_KERNEL);
> /* dattr == NULL is ok; partition_sched_domains() can cope with it. */
Makes sense. I'll add it, since I'm touching that area anyway.
Max
prev parent reply other threads:[~2008-08-06 20:44 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-06 17:22 [PATCH] cpuset : Handling improper memory allocation Rakib Mullick
2008-08-06 20:13 ` Max Krasnyansky
2008-08-06 20:37 ` Paul Jackson
2008-08-06 20:43 ` Max Krasnyansky [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=489A0D0C.1000204@qualcomm.com \
--to=maxk@qualcomm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=menage@google.com \
--cc=pj@sgi.com \
--cc=rakib.mullick@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 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.