[lkml]   [2004]   [Aug]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: RCU issue with SELinux (Re: SELINUX performance issues)
On Thu, 2004-08-26 at 03:53, Kaigai Kohei wrote:
> In my understanding, your worry about robustness is the execution path
> when kmalloc() returns NULL.


> (But avc_insert() always returns 0, because avc_insert() reclaim a avc_node
> under the spinlock when free_list is empty.)

Yes, this is the point. avc_has_perm could not fail previously from an
out of memory condition, as the cache nodes were preallocated,
maintained on their own freelist, and reclaimed as needed.

> By this method, the decision-making is available irrespective of
> the result of kmalloc(). Is it robustless?
> The original implementation has too many lock contensitons in Big-SMP
> environment. It is more positive to consider the method using RCU.

Yes, that would address my concern. However, I'm still unclear as to
why using RCU mandates that we migrate from preallocated nodes to
dynamic allocation. I certainly agree that the existing global spinlock
doesn't scale.

> Please wait for a patch, thanks.

Thanks for working on this. Could you also supply updated performance
data when you have a newer patch? Thanks.

Stephen Smalley <>
National Security Agency

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 14:05    [from the cache]
©2003-2014 Jasper Spaans. hosted at Digital Ocean