makesyscall: Simplify a bit emitting syscall declarations
Reviewed by: kevans, imp MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D42168
This commit is contained in:
committed by
Mark Johnston
parent
96f193b290
commit
2f68ae6150
@@ -865,18 +865,15 @@ local function handle_noncompat(sysnum, thr_flag, flags, sysflags, rettype,
|
||||
|
||||
local protoflags = get_mask({"NOPROTO", "NODEF"})
|
||||
if flags & protoflags == 0 then
|
||||
local sys_prefix = "sys_"
|
||||
if funcname == "nosys" or funcname == "lkmnosys" or
|
||||
funcname == "sysarch" or funcname:find("^freebsd") or
|
||||
funcname:find("^linux") then
|
||||
write_line("sysdcl", string.format(
|
||||
"%s\t%s(struct thread *, struct %s *)",
|
||||
rettype, funcname, argalias))
|
||||
else
|
||||
write_line("sysdcl", string.format(
|
||||
"%s\tsys_%s(struct thread *, struct %s *)",
|
||||
rettype, funcname, argalias))
|
||||
sys_prefix = ""
|
||||
end
|
||||
write_line("sysdcl", ";\n")
|
||||
write_line("sysdcl", string.format(
|
||||
"%s\t%s%s(struct thread *, struct %s *);\n",
|
||||
rettype, sys_prefix, funcname, argalias))
|
||||
write_line("sysaue", string.format("#define\t%sAUE_%s\t%s\n",
|
||||
config.syscallprefix, funcalias, auditev))
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user