lkml.org 
[lkml]   [2022]   [Nov]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v6 2/3] random: introduce generic vDSO getrandom() implementation
Hi Florian,

On Thu, Nov 24, 2022 at 06:28:44AM +0100, Florian Weimer wrote:
> > Right? And if you look at the expansion of that glibc macro, it's just:
> >
> > #define INTERNAL_SYSCALL_ERROR_P(val) \
> > ((unsigned long int) (val) > -4096UL)
> >
> > So it looks like the same exact thing?
>
> syscall already does internally (with a translation to -1, not NULL), so
> the caller shouldn't do it again. The userspace syscall function does
> *not* return an error code.

Ahh, okay. Thanks. I'll fix up the example to assume those semantics.

Jason

\
 
 \ /
  Last update: 2022-11-24 12:58    [W:0.129 / U:0.108 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site