Solved

BIOS and option rom?

Posted on 2003-12-03
15
670 Views
Last Modified: 2013-12-09
Hi,

     I am using sc1200 that can address upto 4GB physical address). My flash memory is 32Mbit. Generally the ROM chip is mapped in hardware to the high physical address (0xFFFFFFFF - 0xFFC00000). My SDRAM is 32MByte. It is mapped in hardware to CPU address (0x00000000 - 1FFFFFF). My Bios program is kept in the flash memory. After the hardware initialization is done and before going with the int 19h interrupt, my bios program scans for option Rom from location 0xC8000h. So when it starts scanning from location 0xC8000, is any hardware remapping that has to be done.
0
Comment
Question by:Johncy
  • 7
  • 6
  • 2
15 Comments
 
LVL 11

Expert Comment

by:dimitry
ID: 9892897
Can you please formulate your question ?
0
 

Author Comment

by:Johncy
ID: 9894168
My bootloader for Flash (ROLO) is kept as option ROM. I am confused with whether the location 0xC8000 is Flash memory location or is the SDRAM location? When it scans for option ROM, does the Flash memory has to be remapped to a different physical address in hardware?
Thanks in advance.
0
 
LVL 11

Accepted Solution

by:
dimitry earned 125 total points
ID: 9895038
x86 CPU can access in Real Mode up to 1 MByte or 0x100000 physical address.
However historically the memory map is usually the next:
0x00000 - 0x9FFFF  - "low" RAM
0xA0000 - 0xC7FFF - video adaptor memory
0xC8000 - 0xDFFFF - memory for expansion cards with BIOS expansions
0xE0000 - 0xFFFFF - BIOS ROM area

Now, generally speaking 0xA0000 - 0xFFFFF can be used as RAM. Moreover BIOS usually copies
itself to "shadowed" RAM from 0xE0000 - 0xFFFFF.
It is convenient to consider that memory arbitrator switches your access to PCI and ISA
when you try to access 0xA0000 - 0xDFFFF and to SDRAM if you access 0x00000 - 0x9FFFF.
0
 

Author Comment

by:Johncy
ID: 9903602
Thanks.
Is my hardware mapping looks right? Should I need a remapping in hardware when it searches for option rom?
0
 
LVL 11

Expert Comment

by:dimitry
ID: 9906577
It may be not "remapping". It is much simpler to connect to DiskOnChip 2 Chip Selects. One for boot:
range 0xFFF80000-0xFFFFFFFF and one for 0x000C8000-0x000DFFFF.
0
 

Author Comment

by:Johncy
ID: 9917562
I use Flash memory to store my bios program, linux OS, filesystem. My bootloader for flash (ROLO) is kept as option ROM.
0
 
LVL 11

Expert Comment

by:dimitry
ID: 9918719
Something wrong here... Do you have NOR flash for boot or you have only DiskOnChip
for boot your BIOS ?
0
Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

 

Author Comment

by:Johncy
ID: 9918730
I have NOR flash.
0
 
LVL 11

Expert Comment

by:dimitry
ID: 9920014
So you DO NOT need to map DiskOnChip to 0xFFFFFFFF. Moreover you can not map both
NOR flash and DiskOnChip to same address.
0
 
LVL 11

Expert Comment

by:dimitry
ID: 9924637
Can you please describe your system again and now with NOR flash ?
0
 

Author Comment

by:Johncy
ID: 9925266
I have NOR Flash. But if I meet some problem with NOR flash I would like to have diskonchip millennium. I would like to make my software and hardware ready for both purposes. I would use any one and not both at the same time.
0
 

Author Comment

by:Johncy
ID: 9969497
If I have to use Flash or DOCM, how the mapping of each one should be at power-on?
0
 
LVL 1

Expert Comment

by:PaulPisces1964
ID: 9980352
Same as my response for your other (related) question "real and protected mode":

The BIOS co-exists in the "same" address space as the SDRAM, much the same way as the BIOS in a PC. The ROM or the SDRAM will be enabled as appropriate.

I am not 100% clear on the option ROM, but that "should" hold true also, i.e. the device should know to enable the rom chip select in that case.

I think the key that will unlock this all for you is to look at the schematics in the National reference design, and see how those match your situation.

My response to your other question was:
----------------------------------------------------------------------------------------
From the National data sheet I found where the core logic module decodes the FFFFFFF0 address (and some others) and passes it to the sub-ISA interface, where the boot ROM needs to physically connect...

Excerpt:
-------------------------------------------------------------------------------
5.2.5.6 ROM Interface
The Core Logic module positively decodes memory
addresses 000F0000h-000FFFFFh (64 KB) and
FFFC0000h-FFFFFFFFh (256 KB) at reset. These memory
cycles cause the Core Logic module to claim the cycle, and
generate an ISA bus memory cycle with ROMCS#
asserted. The Core Logic module can also be configured to
respond to memory addresses FF000000h-FFFFFFFFh
(16 MB) and 000E0000h-000FFFFFh (128 KB).
8- or 16-bit wide ROM is supported. BOOT16 strap determines
the width after reset. MCR[14,3] (Offset 34h) in the
General Configuration Block (see Table 3-2 on page 86 for
bit details) allows program control of the width.
Flash ROM is supported in the Core Logic module by
enabling the ROMCS# signal on write accesses to the
ROM region. Normally only read cycles are passed to the
ISA bus, and the ROMCS# signal is suppressed for write
cycles. When the ROM Write Enable bit (F0 Index 52h[1])
is set, a write access to the ROM address region causes a
write cycle to occur with MEMW#, WR# and ROMCS#
asserted.
-------------------------------------------------------------------------------

I went here:
http://wwwd.national.com/National/developer.nsf/devices/sc1200.htm

and downloaded the data sheet:
http://wwwd.national.com/National/developer.nsf/files/sc1200/$File/sc1200_ds.pdf

and their reference design:
http://wwwd.national.com/National/developer.nsf/files/sc1200/$File/sc1200_ebga_tft_on_parallel.pdf

The boot rom schematic is located on PDF page 9

Also they have an Orcad DSN, if you can make use of it that should shave some time off your project.

Good Luck,
Paul
0
 

Author Comment

by:Johncy
ID: 9982970
This means I can have my Flash memory mapped only to the lower address. Is it correct?
0
 
LVL 1

Expert Comment

by:PaulPisces1964
ID: 9985914
>This means I can have my Flash memory mapped only to the lower address. Is it correct?

Yes, that is correct, addresses connected to AD22..AD0 (assuming you have 4MBx8), /CE connected to /ROMCS, Data connected to AD31..AD24
0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

Suggested Solutions

Hello It is a very old trick to use a ram disk in order to boost PC performances, in the past, when in home environments the fastest common devices were floppy disks a part of the very small ram memory available was used to create a virtual hard …
As you can read I recycle all my old hardware and the time has come that my power supply of 200 Watt cannot provide enough power for my backup server. I have lots of Compaq power supply's laying around, so I figured to use one of these PSU's. I t…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now