Re: [PATCH][SMACK] convert smack rule list to linux list

From: etienne
Date: Sun Feb 22 2009 - 10:18:38 EST


Tetsuo Handa wrote:
> etienne wrote:
>> what's the best way, using a rcu variant for "list_for_each, container_of ...etc" ?
>> (concurrent list insertion are already protected with a mutex, so rcu must the good idea for the read side)
> Read side will need a read lock.
> I think you need to change from "mutex" to "rw_semaphore" (on the assumption
> that SMACK is safe against read locks that may sleep. If not, change from
> "mutex" to "rw_spinlock").
>
> Regards.
>
or a rcu_read_lock?
since it disables preemption it means no user process will be able to change the list while it's read?

regards,
Etienne


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/