summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRegina König2021-04-21 14:47:00 +0200
committerRegina König2021-04-21 14:47:00 +0200
commitdd4f6d9427e2c58872d342cfe215faa86e9e0b31 (patch)
treee7760010728d6a8127418d5fdc631d1ccd0e29d7
parentComplete refactoring of cpuspeed() (diff)
downloadmemtest86-dd4f6d9427e2c58872d342cfe215faa86e9e0b31.tar.gz
memtest86-dd4f6d9427e2c58872d342cfe215faa86e9e0b31.tar.xz
memtest86-dd4f6d9427e2c58872d342cfe215faa86e9e0b31.zip
Delete old display_init()
-rw-r--r--efi_memtest/MemtestEfi.c2
-rw-r--r--efi_memtest/memtest86+/efi/init.c66
2 files changed, 6 insertions, 62 deletions
diff --git a/efi_memtest/MemtestEfi.c b/efi_memtest/MemtestEfi.c
index dcde760..18b7466 100644
--- a/efi_memtest/MemtestEfi.c
+++ b/efi_memtest/MemtestEfi.c
@@ -13,7 +13,7 @@ extern EFI_SYSTEM_TABLE *gST;
short logflag = 1;
short log_fine = 0;
short log_cpuspeed = 0;
-short log_memspeed = 0;
+short log_memspeed = 1;
short log_mem_tbl = 1;
short log_comp_seg = 0;
short log_print_pmap = 0;
diff --git a/efi_memtest/memtest86+/efi/init.c b/efi_memtest/memtest86+/efi/init.c
index 0231af8..458db26 100644
--- a/efi_memtest/memtest86+/efi/init.c
+++ b/efi_memtest/memtest86+/efi/init.c
@@ -212,66 +212,16 @@ void failsafe(int msec, int scs)
}
}
-/*static void display_init(void)
-{
- int i;
- volatile char *pp;
- */
- /* Set HW cursor out of screen boundaries */
- /* __outb(0x0F, 0x03D4);
- __outb(0xFF, 0x03D5);
-
- __outb(0x0E, 0x03D4);
- __outb(0xFF, 0x03D5);
-
-
- serial_echo_init();
- serial_echo_print("INE_SCROLL;24r");*/ /* Set scroll area row 7-23 */
- /* serial_echo_print("");*/ /* Clear Screen */
- /*serial_echo_print("");
- serial_echo_print("");
- serial_echo_print("");*/
-
- /* Clear screen & set background to blue */
- /* for(i=0, pp=(char *)(SCREEN_ADR); i<80*24; i++) {
- *pp++ = ' ';
- *pp++ = 0x17;
- }*/
-
- /* Make the name background green */
- /*for(i=0, pp=(char *)(SCREEN_ADR+1); i<TITLE_WIDTH; i++, pp+=2) {
- *pp = 0x20;
- }
- cprint(0, 0, " Memtest86 5.31b ");
-*/
- /* Set Blinking "+" */
- /* for(i=0, pp=(char *)(SCREEN_ADR+1); i<2; i++, pp+=30) {
- *pp = 0xA4;
- }
- cprint(0, 15, "+");
-*/
- /* Do reverse video for the bottom display line */
- /*for(i=0, pp=(char *)(SCREEN_ADR+1+(24 * 160)); i<80; i++, pp+=2) {
- *pp = 0x71;
- }
-
- serial_echo_print("");
-}
-*/
/*
* Initialize test, setup screen and find out how much memory there is.
*/
-void init(void)
-{
+void init(void) {
outb(0x8, 0x3f2); /* Kill Floppy Motor */
/* Turn on cache */
set_cache(1);
- /* Setup the display */
- // display_init();
-
vv->pass = 0;
vv->msg_line = 0;
vv->ecount = 0;
@@ -1100,26 +1050,20 @@ void cpu_cache_speed() {
/* Print CPU speed */
if ((cpu_speed = cpuspeed()) > 0) {
if (cpu_speed < 999499) {
- cpu_speed += 50; /* for rounding *//*
- cprint(1, off, " . MHz");
- dprint(1, off+1, cpu_speed/1000, 3, 1);
- dprint(1, off+5, (cpu_speed/100)%10, 1, 0);*/
+ cpu_speed += 50; /* for rounding */
} else {
- cpu_speed += 500; /* for rounding *//*
- cprint(1, off, " MHz");
- dprint(1, off, cpu_speed/1000, 5, 0);*/
+ cpu_speed += 500; /* for rounding */
}
extclock = cpu_speed;
}
- if (logflag) {
+ if (logflag && log_cpuspeed) {
char log[38] = "cpu_cache_speed(): speed = ";
int length = 27;
int_to_charr(extclock, log, &length);
print_log(log, length);
}
-
ulong speed;
/* To measure L1 cache speed we use a block size that is 1/4th */
/* of the total L1 cache size since half of it is for instructions */
@@ -1130,7 +1074,7 @@ void cpu_cache_speed() {
}
}
- if (logflag) {
+ if (logflag && log_memspeed) {
char log[38] = "cpu__mem_speed(): speed = ";
int length = 27;
int_to_charr(extclock, log, &length);