obtaining physical address
While in OpenBoot prompt I need to obtain physical address (I have the virtual address). The reference says that this should be done via
address pgmap?
call... but my prom seems to not support this command because when I type 'address pgmap?' I receive 'pgmap? ?' ... so it seems my version of OS does not support this command.. is there any other way to get the physical address?
[404 byte] By [
walkeros] at [2007-11-26 10:55:50]

# 1
While you're in OBP, experiment with ...
show-devs
That should give you a list of your devices as recognized at the firmware level.
You should see actual device paths.
(You can navigate those paths, same as if they were disk directories.)
The Command Reference Manuals for OBP 3.x and for 4.x
can be found at Docs.Sun.Com.They are of great value.
Save the links and also save the downloadable PDF's of them.
http://docs.sun.com/app/docs/coll/1140.3?q=openboot+command+reference
As mentioned in those manuals, whenever you need help with command syntax
you can just use the "HELP" command with it.
For example:
help address <enter>
or
help show <enter>
-
What system are you actually working in ?
OBP 2.x has some commands,
OBP 3.x will have more,
OBP 4.x may have more or different command functionality, and
OBP 5.x has yet a broader subset of command capabilities.
# 2
I am running OpenBoot 4.0 ...
I managed to obtain the physicall address in following way:
ok? show-devs
.... <- paths to the devices
/pci@1f,0/ebus@c/mydevice@fff6a000,fff6a000 <- the desired device
.... <- the rest of the devices
ok? " /pci@1f,0/ebus@c/mydevice@fff6a000,fff6a000" begin-select-dev
ok? pwd
/pci@1f,0/ebus@c/mydevice@fff6a000,fff6a000 <- the current path should change to the the device path
ok? .properties
... <- few lines of output .. one of them is
reg fff6a000 fff6a000 00000000
...
ok? fff6a000 " map-in" $call-parent constant my-vaddr
Insufficient virtual memory <- I ignored this
ok? my-vaddr . <- the "dot" at the and and space between my-vaddr and "dot"
fff3bffc
ok? my-vaddr map?
... <- few lines of output
PA: 1fefffffffc <- here we have the physical address
# 3
My question is how to convert it to the pgmap? compatible output ? ie. how can I retrive the address space and the physical address ftom that output..... or maybe there is similar command to pgmap? in OBP 4.0
# 4
I have never needed to use any page map information,thus have never done what you are attempting to do.I cannot be of additional assistance.Sorry.
# 5
Thanks a lot rukbat, Your advises are very helpful for me!I wonder if, in case of downgrading my OpenBoot to the 3.x version thus enabling the desired pgmap? command I could do any harm to my prom? Maybe there is any way to backup it and restore in case of failure?
# 6
It would be impossible to put an inappropriate firmware onto your system.
OBP 4.x is specific to a class of Sun SPARC computers.
Whereas OBP 3.x was used with a generation of systems
that ran the UltraSPARC-II series of cpu modules, the OBP 4.x
firmware was necessary for many UltraSPARC-III workstations
and entry level server designs.
The Sun Fire Midrange systems and larger systems are of a design
that is so complex that they require OBP 5.x
Your computer is incapable of functioning with an Open Boot PROM version
that is for a completely different generational design.
If this was a PC we were discussing, we would be talking about
mixing and matching inappropriate Northbridge chips with various cpu models.
It's not done. It wouldn't work.