Re: Fw: Badness around put_cred()

From: David Howells
Date: Fri Jan 27 2012 - 13:25:17 EST



One thing you could try doing is making do_notify_resume() check the credential
subscriptions on the process as it's about to resume userspace. The following
assertions both ought to hold:

BUG_ON(current->cred != current->real_cred);
BUG_ON(atomic_read(current->cred->usage) >= 2);

And then set TIF_NOTIFY_RESUME in put_cred() and get_new_cred().

David
--
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/