This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
Home Products Support Community News


[Xen-devel] Stop the execution of syscall in trap.c

To: "xen-devel@xxxxxxxxxxxxxxxxxxx\"" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] Stop the execution of syscall in trap.c
From: Carlo Maiero <zesster@xxxxxxxxx>
Date: Wed, 13 Oct 2010 15:11:58 +0200
Delivery-date: Wed, 13 Oct 2010 06:13:00 -0700
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:date:message-id :subject:from:to:content-type; bh=HdN2kqr2FrYQ3bHAGf3IcjUOxrFyOiJQYxnQSsMJD8s=; b=NVJhM+V24pq+85i/sfcdopCtsG8HhJAhNs3cppvMRN6T2jv7kVpo6zotqLzQC9Di8S IEkIcuNMw9rTr2Y/aLk4Mjm9Dba5b3+EIOdmdJdR2epY7NwKNGoVLHMIBaAMoKb2RMTQ stpd119J4eVVr/7w/XsbHFoFA61d3F996idUE=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=MA6Qrb+0hExJTHQ2w40AcKjRf/5hYwpAj01ZR8AXEcB0t7RFNu6C3ujQu6ICjT9Sw3 Nno16naIR5qSkokfaYJgMCAfIeLHwYLrJ2UaSSz/3pQBQiyymFIVSrclFMwgi4Ms2zei dLiJhezyzYcIszO6Cxe2/KFpCPy5BCEEh7Vqk=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx

but after the interception I also want to stop some syscall from be executed by the hypervisor.

I intercept the call in the do_guest_trap in trap.c, and i control the (cpu_user_regs regs) regs->eax for the number, and if
the number is some unpermitted syscall as for example (128 for insmod or 129 for rmmod), i want to stop the execution of the syscall.

How can I stop the execution here?(it's possible to stop the execution here?)  or return an error code without a system crush? 
I've tried something but somethings just print the error code, and don't stop the syscall execution, and other things brings to panic.
Xen-devel mailing list
<Prev in Thread] Current Thread [Next in Thread>