lkml.org 
[lkml]   [2018]   [Mar]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC PATCH for 4.17 02/21] rseq: Introduce restartable sequences system call (v12)
On Wed, Mar 28, 2018 at 02:29:46PM +0200, Peter Zijlstra wrote:
> > +static int rseq_get_rseq_cs(struct task_struct *t,
> > + unsigned long *start_ip,
> > + unsigned long *post_commit_offset,
> > + unsigned long *abort_ip,
> > + uint32_t *cs_flags)
> > +{

>
> > +
> > + *cs_flags = rseq_cs.flags;
> > + *start_ip = rseq_cs.start_ip;
> > + *post_commit_offset = rseq_cs.post_commit_offset;
> > + *abort_ip = rseq_cs.abort_ip;
>
> Then this becomes a straight struct assignment.

I initially suggested passing a structure instead of many arguments, but
then recondidered, mostly because it will be inlined (due to having only
the one caller) anyway. Still, maybe a struct will work better, I dunno.


\
 
 \ /
  Last update: 2018-03-28 14:53    [W:0.216 / U:2.044 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site