lkml.org 
[lkml]   [2023]   [Mar]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v7 33/41] x86/shstk: Introduce map_shadow_stack syscall
On Fri, Mar 10, 2023 at 05:12:40PM +0000, Edgecombe, Rick P wrote:
> > Can we use distinct negative retvals in each case so that it is clear
> > to
> > userspace where it fails, *if* it fails?
>
> Good idea, I think maybe ERANGE.

For those two, right?

/* If there isn't space for a token */
if (set_tok && size < 8)
return -EINVAL;

if (addr && addr <= 0xFFFFFFFF)
return -EINVAL;

They are kinda range-checking of sorts. A wider range but still
similar...

--
Regards/Gruss,
Boris.

https://people.kernel.org/tglx/notes-about-netiquette

\
 
 \ /
  Last update: 2023-03-27 00:53    [W:0.089 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site