From patchwork Tue Jan 11 13:30:05 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gleb Natapov X-Patchwork-Id: 471721 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p0BDUJIi017559 for ; Tue, 11 Jan 2011 13:30:19 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754006Ab1AKNaM (ORCPT ); Tue, 11 Jan 2011 08:30:12 -0500 Received: from mx1.redhat.com ([209.132.183.28]:27554 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754009Ab1AKNaJ (ORCPT ); Tue, 11 Jan 2011 08:30:09 -0500 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id p0BDU8T9017946 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 11 Jan 2011 08:30:09 -0500 Received: from dhcp-1-237.tlv.redhat.com (dhcp-1-237.tlv.redhat.com [10.35.1.237]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id p0BDU8cb026847; Tue, 11 Jan 2011 08:30:08 -0500 Received: by dhcp-1-237.tlv.redhat.com (Postfix, from userid 13519) id 7D166133F76; Tue, 11 Jan 2011 15:30:07 +0200 (IST) From: Gleb Natapov To: avi@redhat.com, mtosatti@redhat.com Cc: kvm@vger.kernel.org Subject: [PATCH unit-tests 1/3] Task stack pointer should point to the end of the page. Date: Tue, 11 Jan 2011 15:30:05 +0200 Message-Id: <1294752607-7920-1-git-send-email-gleb@redhat.com> X-Scanned-By: MIMEDefang 2.67 on 10.5.11.12 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Tue, 11 Jan 2011 13:30:19 +0000 (UTC) diff --git a/lib/x86/desc.c b/lib/x86/desc.c index 1bd4421..11bd2a2 100644 --- a/lib/x86/desc.c +++ b/lib/x86/desc.c @@ -362,7 +362,7 @@ void setup_tss32(void) tss[i].cr3 = read_cr3(); tss[i].ss0 = tss[i].ss1 = tss[i].ss2 = 0x10; tss[i].esp = tss[i].esp0 = tss[i].esp1 = tss[i].esp2 = - (u32)tss_stack[i]; + (u32)tss_stack[i] + 4096; tss[i].cs = 0x08; tss[i].ds = tss[i].es = tss[i].fs = tss[i].gs = tss[i].ss = 0x10; tss[i].iomap_base = (u16)desc_size;