From nobody Sat Oct 29 15:01:45 2022 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4N02gd5Cqvz4g3D5; Sat, 29 Oct 2022 15:01:49 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Received: from omta002.cacentral1.a.cloudfilter.net (omta002.cacentral1.a.cloudfilter.net [3.97.99.33]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "Client", Issuer "CA" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4N02gd185rz3kRH; Sat, 29 Oct 2022 15:01:49 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Received: from shw-obgw-4001a.ext.cloudfilter.net ([10.228.9.142]) by cmsmtp with ESMTP id okWTouFVcSp39onLHolVfY; Sat, 29 Oct 2022 15:01:47 +0000 Received: from spqr.komquats.com ([70.66.148.124]) by cmsmtp with ESMTPA id onLGouZBlkTFZonLGoD2Qa; Sat, 29 Oct 2022 15:01:47 +0000 X-Authority-Analysis: v=2.4 cv=D8dUl9dj c=1 sm=1 tr=0 ts=635d405b a=Cwc3rblV8FOMdVN/wOAqyQ==:117 a=Cwc3rblV8FOMdVN/wOAqyQ==:17 a=kj9zAlcOel0A:10 a=Qawa6l4ZSaYA:10 a=6I5d2MoRAAAA:8 a=YxBL1-UpAAAA:8 a=EkcXrb_YAAAA:8 a=W3WhOm4UYY_j1uJhRwYA:9 a=CjuIK1q_8ugA:10 a=IjZwj45LgO3ly-622nXo:22 a=Ia-lj3WSrqcvXOmTRaiG:22 a=LK5xJRSDVpKd5WXXoEvA:22 Received: from slippy.cwsent.com (slippy [10.1.1.91]) by spqr.komquats.com (Postfix) with ESMTP id A5693BD; Sat, 29 Oct 2022 08:01:45 -0700 (PDT) Received: by slippy.cwsent.com (Postfix, from userid 1000) id 6BD6713; Sat, 29 Oct 2022 08:01:45 -0700 (PDT) X-Mailer: exmh version 2.9.0 11/07/2018 with nmh-1.7+dev Reply-to: Cy Schubert From: Cy Schubert X-os: FreeBSD X-Sender: cy@cwsent.com X-URL: http://www.cschubert.com/ To: Mitchell Horne cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: 1da65dcb1c57 - main - linux: populate sv_syscallnames in each sysentvec In-reply-to: <202210282133.29SLXqfq064166@gitrepo.freebsd.org> References: <202210282133.29SLXqfq064166@gitrepo.freebsd.org> Comments: In-reply-to Mitchell Horne message dated "Fri, 28 Oct 2022 21:33:52 +0000." List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Sat, 29 Oct 2022 08:01:45 -0700 Message-Id: <20221029150145.6BD6713@slippy.cwsent.com> X-CMAE-Envelope: MS4xfM5YHweV7XR2g0v0Lp9RjhabkVCG22oZ0iA1XkAbL/BnyH+1do5/T8M64l6SebnWFIvzKhhPoOgcAFQv9jpb5bKogFGJLcbiPxgHFktLpIG8gcVEQyi1 4cSoLX9V2atWxXKdLIBiqPxuKXUPhAM6QWb6s4GjLyrpyjCwXhw1xNeMuGnw5IR5R/Z6wpqWsJbnuanAUZlO8uFJ7gJOGlZdGE87W9l4CJ02z0WA1wVwUexb ltM4C5HkLhYKc2QM3Uwk6G9nStMd+EzBiHTsSCAF9nOiik88QsMAUE95FyWlLd1OthU2WeDWLvwX5vYFyFAhjj7zL50Le+cDs1+ilSUA/5A= X-Rspamd-Queue-Id: 4N02gd185rz3kRH X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of cy.schubert@cschubert.com has no SPF policy when checking 3.97.99.33) smtp.mailfrom=cy.schubert@cschubert.com X-Spamd-Result: default: False [-1.60 / 15.00]; AUTH_NA(1.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_SHORT(-1.00)[-0.999]; NEURAL_HAM_LONG(-1.00)[-0.999]; MV_CASE(0.50)[]; MIME_GOOD(-0.10)[text/plain]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; R_SPF_NA(0.00)[no SPF record]; MLMMJ_DEST(0.00)[dev-commits-src-main@freebsd.org,dev-commits-src-all@freebsd.org]; FROM_EQ_ENVFROM(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[3.97.99.33:from]; HAS_REPLYTO(0.00)[Cy.Schubert@cschubert.com]; TO_DN_SOME(0.00)[]; ARC_NA(0.00)[]; REPLYTO_EQ_FROM(0.00)[]; RCVD_COUNT_FIVE(0.00)[5]; RCVD_VIA_SMTP_AUTH(0.00)[]; ASN(0.00)[asn:16509, ipnet:3.96.0.0/15, country:US]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; RCPT_COUNT_THREE(0.00)[4]; DMARC_NA(0.00)[cschubert.com: no valid DMARC record]; RCVD_TLS_LAST(0.00)[] X-ThisMailContainsUnwantedMimeParts: N In message <202210282133.29SLXqfq064166@gitrepo.freebsd.org>, Mitchell Horne wr ites: > The branch main has been updated by mhorne: > > URL: https://cgit.FreeBSD.org/src/commit/?id=1da65dcb1c57fae7be75ddf1bd300ddf > 19ced850 > > commit 1da65dcb1c57fae7be75ddf1bd300ddf19ced850 > Author: Mitchell Horne > AuthorDate: 2022-10-28 21:19:39 +0000 > Commit: Mitchell Horne > CommitDate: 2022-10-28 21:21:08 +0000 > > linux: populate sv_syscallnames in each sysentvec > > This allows the syscallname() function to give a usable result for Linux > ABIs. > > Reported by: jrtc27 > Reviewed by: jrtc27, markj, jhb > MFC after: 1 week > Sponsored by: The FreeBSD Foundation > Differential Revision: https://reviews.freebsd.org/D37199 > --- > sys/amd64/linux/linux_sysvec.c | 3 ++- > sys/amd64/linux32/linux32_sysvec.c | 3 ++- > sys/arm64/linux/linux_sysvec.c | 3 ++- > sys/i386/linux/linux_sysvec.c | 3 ++- > 4 files changed, 8 insertions(+), 4 deletions(-) > > diff --git a/sys/amd64/linux/linux_sysvec.c b/sys/amd64/linux/linux_sysvec.c > index abb498370f79..2a9e4909340b 100644 > --- a/sys/amd64/linux/linux_sysvec.c > +++ b/sys/amd64/linux/linux_sysvec.c > @@ -110,6 +110,7 @@ extern char _binary_linux_vdso_so_o_end; > static vm_offset_t linux_vdso_base; > > extern struct sysent linux_sysent[LINUX_SYS_MAXSYSCALL]; > +extern const char *linux_syscallnames[]; > > SET_DECLARE(linux_ioctl_handler_set, struct linux_ioctl_handler); > > @@ -729,7 +730,7 @@ struct sysentvec elf_linux_sysvec = { > SV_SIG_WAITNDQ | SV_TIMEKEEP, > .sv_set_syscall_retval = linux_set_syscall_retval, > .sv_fetch_syscall_args = linux_fetch_syscall_args, > - .sv_syscallnames = NULL, > + .sv_syscallnames = linux_syscallnames, > .sv_shared_page_base = LINUX_SHAREDPAGE_LA48, > .sv_shared_page_len = PAGE_SIZE, > .sv_schedtail = linux_schedtail, > diff --git a/sys/amd64/linux32/linux32_sysvec.c b/sys/amd64/linux32/linux32_s > ysvec.c > index bd10d659979c..15caa5a2c2cc 100644 > --- a/sys/amd64/linux32/linux32_sysvec.c > +++ b/sys/amd64/linux32/linux32_sysvec.c > @@ -113,6 +113,7 @@ extern char _binary_linux32_vdso_so_o_end; > static vm_offset_t linux_vdso_base; > > extern struct sysent linux32_sysent[LINUX32_SYS_MAXSYSCALL]; > +extern const char *linux32_syscallnames[]; > > SET_DECLARE(linux_ioctl_handler_set, struct linux_ioctl_handler); > > @@ -882,7 +883,7 @@ struct sysentvec elf_linux_sysvec = { > SV_SIG_DISCIGN | SV_SIG_WAITNDQ | SV_TIMEKEEP, > .sv_set_syscall_retval = linux32_set_syscall_retval, > .sv_fetch_syscall_args = linux32_fetch_syscall_args, > - .sv_syscallnames = NULL, > + .sv_syscallnames = linux32_syscallnames, > .sv_shared_page_base = LINUX32_SHAREDPAGE, > .sv_shared_page_len = PAGE_SIZE, > .sv_schedtail = linux_schedtail, > diff --git a/sys/arm64/linux/linux_sysvec.c b/sys/arm64/linux/linux_sysvec.c > index 362917c3de31..41ac2912be29 100644 > --- a/sys/arm64/linux/linux_sysvec.c > +++ b/sys/arm64/linux/linux_sysvec.c > @@ -98,6 +98,7 @@ extern char _binary_linux_vdso_so_o_end; > static vm_offset_t linux_vdso_base; > > extern struct sysent linux_sysent[LINUX_SYS_MAXSYSCALL]; > +extern const char *linux_syscallnames[]; > > SET_DECLARE(linux_ioctl_handler_set, struct linux_ioctl_handler); > > @@ -576,7 +577,7 @@ struct sysentvec elf_linux_sysvec = { > SV_SIG_WAITNDQ | SV_TIMEKEEP, > .sv_set_syscall_retval = linux_set_syscall_retval, > .sv_fetch_syscall_args = linux_fetch_syscall_args, > - .sv_syscallnames = NULL, > + .sv_syscallnames = linux_syscallnames, > .sv_shared_page_base = LINUX_SHAREDPAGE, > .sv_shared_page_len = PAGE_SIZE, > .sv_schedtail = linux_schedtail, > diff --git a/sys/i386/linux/linux_sysvec.c b/sys/i386/linux/linux_sysvec.c > index e964f475a393..f67b19725cdf 100644 > --- a/sys/i386/linux/linux_sysvec.c > +++ b/sys/i386/linux/linux_sysvec.c > @@ -96,6 +96,7 @@ extern char _binary_linux_vdso_so_o_end; > static vm_offset_t linux_vdso_base; > > extern struct sysent linux_sysent[LINUX_SYS_MAXSYSCALL]; > +extern const char *linux_syscallnames[]; > > SET_DECLARE(linux_ioctl_handler_set, struct linux_ioctl_handler); > > @@ -782,7 +783,7 @@ struct sysentvec linux_sysvec = { > SV_SIG_DISCIGN | SV_SIG_WAITNDQ, > .sv_set_syscall_retval = linux_set_syscall_retval, > .sv_fetch_syscall_args = linux_fetch_syscall_args, > - .sv_syscallnames = NULL, > + .sv_syscallnames = linux_syscallnames, > .sv_schedtail = linux_schedtail, > .sv_thread_detach = linux_thread_detach, > .sv_trap = NULL, > This results in the following error: cwsys# nice -20 poudriere bulk -j HEADamd64 -J 4 -p prod -f _bulk-queue kldload: an error occurred while loading module linux. Please check dmesg(8) for more details. [00:00:02] Error: Required kernel module 'linux' not found cwsys# dmesg shows: link_elf_obj: symbol linux32_syscallnames undefined linker_load_file: /boot/kernel/linux.ko - unsupported file type -- Cheers, Cy Schubert FreeBSD UNIX: Web: https://FreeBSD.org NTP: Web: https://nwtime.org e^(i*pi)+1=0