Received: by mail.netbsd.org (Postfix, from userid 605) id 9C99F84E35; Mon, 9 Mar 2020 09:55:53 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by mail.netbsd.org (Postfix) with ESMTP id 1FC7E84E34 for ; Mon, 9 Mar 2020 09:55:53 +0000 (UTC) X-Virus-Scanned: amavisd-new at netbsd.org Received: from mail.netbsd.org ([127.0.0.1]) by localhost (mail.netbsd.org [127.0.0.1]) (amavisd-new, port 10025) with ESMTP id X5kvG8xQv4Wj for ; Mon, 9 Mar 2020 09:55:52 +0000 (UTC) Received: from cvs.NetBSD.org (ivanova.netbsd.org [199.233.217.197]) by mail.netbsd.org (Postfix) with ESMTP id B036184E2E for ; Mon, 9 Mar 2020 09:55:52 +0000 (UTC) Received: by cvs.NetBSD.org (Postfix, from userid 500) id A8BF6FB27; Mon, 9 Mar 2020 09:55:52 +0000 (UTC) Content-Disposition: inline Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII" MIME-Version: 1.0 Date: Mon, 9 Mar 2020 09:55:52 +0000 From: "Martin Husemann" Subject: CVS commit: [netbsd-9] src/sys/compat/netbsd32 To: source-changes@NetBSD.org X-Mailer: log_accum Message-Id: <20200309095552.A8BF6FB27@cvs.NetBSD.org> Sender: source-changes-owner@NetBSD.org List-Id: source-changes.NetBSD.org Precedence: bulk Reply-To: source-changes-d@NetBSD.org Mail-Reply-To: "Martin Husemann" Mail-Followup-To: source-changes-d@NetBSD.org List-Unsubscribe: Module Name: src Committed By: martin Date: Mon Mar 9 09:55:52 UTC 2020 Modified Files: src/sys/compat/netbsd32 [netbsd-9]: netbsd32_mod.c Log Message: Pull up following revision(s) (requested by pgoyette in ticket #770): sys/compat/netbsd32/netbsd32_mod.c: revision 1.19 If a syscall requires a module to be autoloaded, the initial invocation of that syscall will return ERESTART. For amd64's netbsd32_syscall() that means we need to back up the PC saved in the trap frame so we can re-issue the syscall instruction. For "normal" syscall traps, we saved the instruction length in the trap frame, but this was missing for the oosyscall/lcall path. Since the PC was not backed up, the kernel-only value ERESTART was returned to userland, causing all sort of grief for old compat_netbsd32 executables! XXX Pullup-9 To generate a diff of this commit: cvs rdiff -u -r1.15.4.2 -r1.15.4.3 src/sys/compat/netbsd32/netbsd32_mod.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.