System calls parameter restrictions



Hello

Are there any restrictions on the parameters that are passed to a
system call? Is it possible to pass a struct as a parameter to a system
call?

The _syscall1 macro tries to cast the parameter to a ``long''. Does it
mean that a struct or union type cannot be passed by value? Only as a
pointer?

Thank you for your attention
.



Relevant Pages

  • Re: Another spinoza challenge
    ... You should test against the int type's limits: ... typedef struct complex ... a pointer to an integer ... A macro is preferable because it is replaced by inline code, ...
    (comp.lang.c)
  • Re: how to store list of varying types
    ... represent that with those in the struct definitions? ... pointer null, and the second one the CString object. ... then have to finish constructing the packet by copying the two data objects ... start with an upper-case letter (so, I would use DataElement ...
    (microsoft.public.vc.mfc)
  • Re: reinterpret_cast
    ... types were declared using the class keyword or the struct keyword. ... in such cases the C cast is always equivalent to static_cast (which will ... can be performed using the cast notation of explicit type conversion. ... --a pointer to an object of derived class type or an lvalue of derived class ...
    (microsoft.public.win32.programmer.kernel)
  • Re: N1298 - try/finally for C
    ... Do you mean that "struct throwInfo" should be optional? ... that exception handling would be supported only on implementations ... If the standard mandates an integer as throw argument, ... should be an integer wide enough to encode a pointer if necessary. ...
    (comp.std.c)
  • Re: [RFC][PATCH 1/4] cgroup: support per cgroup subsys state ID (CSS ID)
    ... Patch for Per-CSS(Cgroup Subsys State) ID and private hierarchy code. ... This patch attaches unique ID to each css and provides following. ... returns pointer to struct cgroup_subysys_state of id. ... using a pointer introduces no such restriction. ...
    (Linux-Kernel)