mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andy Whitcroft <apw@shadowen.org>
To: linux-kernel@vger.kernel.org
Cc: akpm@osdl.org, apw@shadowen.org
Subject: [PATCH] fix TRAP_BAD_SYSCALL_EXITS on i386
Date: Fri, 2 Jul 2004 16:05:41 +0100	[thread overview]
Message-ID: <200407021505.i62F5faM002217@voidhawk.shadowen.org> (raw)

Seems that we are not using the right accessor for the preempt
count in entry.S on i386 for the TRAP_BAD_SYSCALL_EXITS checks.
Patch below should fix this.  Complied and booted on -mm5.

-apw

=== 8<===
We are not using the right offset name, nor the right address when checking
for a non-zero preempt count.  Move to TI_preempt_count(%ebp).

Revision: $Rev: 356 $

Signed-off-by: Andy Whitcroft <apw@shadowen.org>

---
 entry.S |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)

diff -X /home/apw/brief/lib/vdiff.excl -rupN reference/arch/i386/kernel/entry.S current/arch/i386/kernel/entry.S
--- reference/arch/i386/kernel/entry.S	2004-07-02 14:00:51.000000000 +0100
+++ current/arch/i386/kernel/entry.S	2004-07-02 16:18:07.000000000 +0100
@@ -314,7 +314,7 @@ restore_all:
 	testl $(VM_MASK | 3), %eax
 	jz resume_kernelX		# returning to kernel or vm86-space
 
-	cmpl $0,TI_PRE_COUNT(%ebx)	# non-zero preempt_count ?
+	cmpl $0,TI_preempt_count(%ebp)  # non-zero preempt_count ?
 	jz resume_kernelX
 
         int $3

                 reply	other threads:[~2004-07-02 15:06 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200407021505.i62F5faM002217@voidhawk.shadowen.org \
    --to=apw@shadowen.org \
    --cc=akpm@osdl.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®