(Was: user namespace: make signal.c respect user namespaces)
Status from this message: NAK!
Get series with b4
b4 am [email protected]Versions newest first
Patches in v1
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | creds: kill __task_cred()->task_is_dead() checkinclude/ kernel/ | +2 | 13 replies | |
| 2/2 | creds: __task_cred(current) doesn't need rcu_read_lock_held()include/ | +2 | 6 replies |
Reviews trailers per patch
1 of 2 patches has a Reviewed-by or Acked-by.
| Patch | David Howells |
|---|---|
| 1/2 | A-b |
| 2/2 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH 0/2] (Was: user namespace: make signal.c respect user namespaces)
Quoted 17 lines · Oleg Nesterov
Quoted 11 lines · Serge E. Hallyn
Quoted 8 lines · Oleg Nesterov
static inline uid_t good_name(struct task_struct *from, struct task_struct *to) { // the caller does rcu_read_lock() if needed const struct cred *from_cred = __task_cred(from); return user_ns_map_uid(task_cred_xxx(to, user_ns), from_cred, from_cred->uid); }Quoted 3 lines
That looks great, thanks. I couldn't think it up myself, but now that I see it in your email, I see this would be very valuable in helping make this code more readable :)
Quoted 8 lines
Damn ;) The problem is, "the caller does
rcu_read_lock()if needed" can't shut up__rcu_dereference_check().current_cred()passes c == true to do this.This reminds me, __task_cred()->task_is_dead() should go away. Probably we can replace it with (
__t== current). Otherwisesend_signal()needsrcu_read_lock()to avoid the warning from lockdep, or the helper needs the unconditionalrcu_read_lock().
IOW, I think we need 2 simple patches first.
The problem is, I have no idea how can I really test these changes ;) David, Paul, may be you can review...
Oleg.