[PATCH] powerpc/pseries: Whitelist dtl slub object for copying to userspace
Michael Ellerman
mpe at ellerman.id.au
Fri Jun 21 21:38:41 AEST 2024
Anjali K <anjalik at linux.ibm.com> writes:
> Hi Michael
>
> On 18/06/24 12:41, Michael Ellerman wrote:
>> I guess there isn't a kmem_cache_create_user_readonly() ?
> Thank you for your review.
>
> My understanding of the question is whether there's a way to whitelist a
> region such that it can be copied to userspace, but not written to using
> copy_from_user().
Yes that's what I meant, and I pretty much worked that out from looking
at the implementation, but was hoping Kees would tell me it was there
somewhere, or implement it :) Apologies for being cryptic.
> No, we don't have a function to whitelist only for copy_to_user() and not
> copy_from_user().
Yep. I'll take this patch as-is, I think we've established that it's
pretty low risk to whitelist the whole cache.
cheers
More information about the Linuxppc-dev
mailing list