|
From: | Richard Henderson |
Subject: | Re: [PATCH v3 18/20] bsd-user: Automatically generate syscall_nr.h |
Date: | Wed, 12 Apr 2023 12:10:47 +0200 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.9.0 |
On 4/11/23 19:09, Warner Losh wrote:
+++ b/bsd-user/syscallhdr.sh @@ -0,0 +1,7 @@ +#!/bin/sh + +in="$1" +out="$2" +bsd="$3" + +awk -v bsd="$3" '{sub("SYS_", "TARGET_" bsd "_NR_", $0); print;}' < $in > $out
If the host/guest syscall numbers always match, there's no point in using TARGET_freebsd_NR_foo at all -- just use the original SYS_foo symbol from <sys/syscall.h>.
r~
[Prev in Thread] | Current Thread | [Next in Thread] |