By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,199 Members | 1,742 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,199 IT Pros & Developers. It's quick & easy.

Small C program to exclude bad RAM address?

P: n/a
OS: Windows XP Home SP2
CPU/Ram: Mobile AMD Duron 4, 1GHz / 256MB
System Manufacturer: Compaq Presario 730us

Using windiag.exe to test my RAM I get a consistent error for the
following address: 0b5d9270. The system returns the wrong value, e.g.
expects value f7f7f7f7 and instead gets f7f7e7f7. This RAM is on the
motherboard and it's about as expensive to replace it than to buy a
new computer.
Is there any small program that could be written so as to
reserve/exclude this specific RAM address at boot so that it's not
used? Unfortunately I know little programming ...
Somebody suggested an approach via C that may have some of the
following lines (but didn't elaborate more). Does this approach have
any chance of success?
char far *pointer=(char far *) 0x0b5d9270; /* pointer to address*/
or one could point to the previous address 0x0b5d926f

and then try from there (not sure how because the following functions
transfer memory from pre-established places)

#include "malloc.h"
#include "stdlib.h"
#include "stdio.h
void main(void){

char far *pointer=(char far *) 0x0b5d9270; /* pointer to address*/
/* char huge *pointer; - original code that asks from a
pre-established place*/
if ((pointer=halloc(1,128000))==NULL {
printf("allocation error -aborting");
exit(1);
}
/* do not free memory*/
/* hfree(pointer); */

}

Program should be called and left resident as a service or driver
during boot.
THANK YOU very much for your response, I really appreciate it.

Juan
Jul 22 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
JuanPedro wrote:
Using windiag.exe to test my RAM I get a consistent error for the
following address: 0b5d9270. The system returns the wrong value, e.g.
expects value f7f7f7f7 and instead gets f7f7e7f7. This RAM is on the
motherboard and it's about as expensive to replace it than to buy a
new computer.

Use memtest86 which is known to be the best (and free) memory
diagnostics software:
http://www.memtest86.com
In case of memory chip problems it will provide you with the decimal
memory address of the problem.
Then you should change the particular memory chip (and not the whole
memory) of your system.


--
Ioannis Vranos

http://www23.brinkster.com/noicys
Jul 22 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.