From 4d790ba43ecbfc6bd9bc06ad8835d53b25fc08c1 Mon Sep 17 00:00:00 2001 From: Till Straumann Date: Tue, 8 Nov 2005 18:52:00 +0000 Subject: 2005-11-08 Till Straumann PR832/bsps * startup/ldsegs.S: move CPU segment descriptor tables from .text to .data; the CPU modifies the descriptor tables and this could be a problem: a) if text segment is ever write-protected b) rtems-gdb-stub checksums the text segment against the file gdb is using. A checksum mismatch results because of the CPU touching the accessed bit... --- c/src/lib/libbsp/i386/pc386/ChangeLog | 9 +++++++++ c/src/lib/libbsp/i386/pc386/startup/ldsegs.S | 7 +++---- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/c/src/lib/libbsp/i386/pc386/ChangeLog b/c/src/lib/libbsp/i386/pc386/ChangeLog index 3d2c17dedc..06222cb344 100644 --- a/c/src/lib/libbsp/i386/pc386/ChangeLog +++ b/c/src/lib/libbsp/i386/pc386/ChangeLog @@ -1,3 +1,12 @@ +2005-11-08 Till Straumann + + PR832/bsps + * startup/ldsegs.S: move CPU segment descriptor tables from .text to + .data; the CPU modifies the descriptor tables and this could be a + problem: a) if text segment is ever write-protected b) rtems-gdb-stub + checksums the text segment against the file gdb is using. A checksum + mismatch results because of the CPU touching the accessed bit... + 2005-08-23 Karel Gardas > * timer/timer.c: Enhance to use either interupt-based timer diff --git a/c/src/lib/libbsp/i386/pc386/startup/ldsegs.S b/c/src/lib/libbsp/i386/pc386/startup/ldsegs.S index e346d0975e..e25fd013c9 100644 --- a/c/src/lib/libbsp/i386/pc386/startup/ldsegs.S +++ b/c/src/lib/libbsp/i386/pc386/startup/ldsegs.S @@ -187,6 +187,7 @@ SYM (_return_to_monitor): | GDT itself +--------------------------------------------------------------------------*/ +BEGIN_DATA .p2align 4 PUBLIC (_Global_descriptor_table) @@ -216,7 +217,6 @@ SYM (gdtdesc): /*---------------------------------------------------------------------------+ | IDT itself +---------------------------------------------------------------------------*/ -BEGIN_DATA .p2align 4 PUBLIC(Interrupt_descriptor_table) @@ -224,18 +224,17 @@ SYM(Interrupt_descriptor_table): .rept 256 .word 0,0,0,0 .endr -END_DATA /*---------------------------------------------------------------------------+ | Descriptor of IDT +--------------------------------------------------------------------------*/ -BEGIN_CODE + .p2align 4 SYM(idtdesc): .word (256*8 - 1) .long SYM (Interrupt_descriptor_table) -END_CODE +END_DATA .section .m_hdr .long 0x1BADB002 -- cgit v1.2.3