qemu Makefile.target vl.h hw/cuda.c hw/grackle_...
CVSROOT: /sources/qemu
Module name: qemu
Changes by: Jocelyn Mayer <j_mayer> 07/10/28 23:42:18
Modified files:
. : Makefile.target vl.h
hw : cuda.c grackle_pci.c heathrow_pic.c ppc.c
ppc_chrp.c ppc_prep.c
Added files:
hw : mac_dbdma.c mac_nvram.c macio.c ppc_mac.h
ppc_oldworld.c
Log message:
* sort the PowerPC target object files
* make PowerPC NVRAM accessors generic to be able to use a MacIO NVRAM instead of the M48T59 one
* split PowerMac targets code:
- move all PowerMac related definitions and prototypes into hw/ppc_mac.h
- add hw/mac_dbdma.c, hw/mac_nvram.c and macio.c
which implements shared PowerMac devices
- define the g3bw machine in a new hw/ppc_oldworld.c file
* Fix the g3bw target:
- fix the Grackle host PCI device
- connect the Heathrow PIC to the PowerPC 6xx bus pins
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/qemu/Makefile.target?cvsroot=qemu&r1=1.212&r2=1.213
http://cvs.savannah.gnu.org/viewcvs/qemu/vl.h?cvsroot=qemu&r1=1.280&r2=1.281
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/cuda.c?cvsroot=qemu&r1=1.16&r2=1.17
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/grackle_pci.c?cvsroot=qemu&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/heathrow_pic.c?cvsroot=qemu&r1=1.5&r2=1.6
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc.c?cvsroot=qemu&r1=1.34&r2=1.35
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_chrp.c?cvsroot=qemu&r1=1.44&r2=1.45
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_prep.c?cvsroot=qemu&r1=1.47&r2=1.48
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_dbdma.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_nvram.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/macio.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_mac.h?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_oldworld.c?cvsroot=qemu&rev=1.1
Quoted 3 lines · Jocelyn Mayer
* Fix the g3bw target:
- fix the Grackle host PCI device
- connect the Heathrow PIC to the PowerPC 6xx bus pins
Cool! With this, the Debian 3.1 install CD boots again! :)
Signature · 1 line
Stuart Brady
Quoted 6 lines · Stuart Brady
Quoted 3 lines · Jocelyn Mayer
* Fix the g3bw target:
- fix the Grackle host PCI device
- connect the Heathrow PIC to the PowerPC 6xx bus pinsCool! With this, the Debian 3.1 install CD boots again! :)
Yes, I did not have time to update the PowerPC status file, but the g3bw machine should be able to boot again. I guess all the long pending regression for the PowerPC targets have been solved.
Note that this may need a firmware update in order to boot properly. I'm working on a cleanup of the hacked OHW firmware (with a lot of traces...) I worked with in order to debug and find the g3bw regressions. As I also did find some bugs and added new features in order to support more CPUs (including the (in)famous PowerPC 601...) and more boot scripts, I will commit and publish a new version soon (I hope !).
Signature · 2 lines
J. Mayer <[email protected]> Never organized
Quoted 25 lines · Jocelyn Mayer
CVSROOT: /sources/qemu Module name: qemu Changes by: Jocelyn Mayer <j_mayer> 07/10/28 23:42:18Modified files:
. : Makefile.targetvl.h
hw :cuda.cgrackle_pci.cheathrow_pic.cppc.c
ppc_chrp.cppc_prep.c
Added files:
hw :mac_dbdma.cmac_nvram.cmacio.cppc_mac.h
ppc_oldworld.cLog message:
* sort the PowerPC target object files
* make PowerPC NVRAM accessors generic to be able to use a MacIO NVRAM instead of the M48T59 one
* split PowerMac targets code:
- move all PowerMac related definitions and prototypes intohw/ppc_mac.h
- addhw/mac_dbdma.c,hw/mac_nvram.candmacio.c
which implements shared PowerMac devices
- define the g3bw machine in a newhw/ppc_oldworld.cfile
* Fix the g3bw target:
- fix the Grackle host PCI device
- connect the Heathrow PIC to the PowerPC 6xx bus pins
Quoted 14 lines
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/qemu/Makefile.target?cvsroot=qemu&r1=1.212&r2=1.213
http://cvs.savannah.gnu.org/viewcvs/qemu/vl.h?cvsroot=qemu&r1=1.280&r2=1.281
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/cuda.c?cvsroot=qemu&r1=1.16&r2=1.17
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/grackle_pci.c?cvsroot=qemu&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/heathrow_pic.c?cvsroot=qemu&r1=1.5&r2=1.6
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc.c?cvsroot=qemu&r1=1.34&r2=1.35
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_chrp.c?cvsroot=qemu&r1=1.44&r2=1.45
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_prep.c?cvsroot=qemu&r1=1.47&r2=1.48
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_dbdma.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_nvram.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/macio.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_mac.h?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_oldworld.c?cvsroot=qemu&rev=1.1
You broke sparc64-softmmu build with this patch.
Quoted 41 lines · Blue Swirl
Quoted 25 lines · Jocelyn Mayer
CVSROOT: /sources/qemu Module name: qemu Changes by: Jocelyn Mayer <j_mayer> 07/10/28 23:42:18Modified files:
. : Makefile.targetvl.h
hw :cuda.cgrackle_pci.cheathrow_pic.cppc.c
ppc_chrp.cppc_prep.c
Added files:
hw :mac_dbdma.cmac_nvram.cmacio.cppc_mac.h
ppc_oldworld.cLog message:
* sort the PowerPC target object files
* make PowerPC NVRAM accessors generic to be able to use a MacIO NVRAM instead of the M48T59 one
* split PowerMac targets code:
- move all PowerMac related definitions and prototypes intohw/ppc_mac.h
- addhw/mac_dbdma.c,hw/mac_nvram.candmacio.c
which implements shared PowerMac devices
- define the g3bw machine in a newhw/ppc_oldworld.cfile
* Fix the g3bw target:
- fix the Grackle host PCI device
- connect the Heathrow PIC to the PowerPC 6xx bus pinsQuoted 14 lines
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/qemu/Makefile.target?cvsroot=qemu&r1=1.212&r2=1.213
http://cvs.savannah.gnu.org/viewcvs/qemu/vl.h?cvsroot=qemu&r1=1.280&r2=1.281
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/cuda.c?cvsroot=qemu&r1=1.16&r2=1.17
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/grackle_pci.c?cvsroot=qemu&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/heathrow_pic.c?cvsroot=qemu&r1=1.5&r2=1.6
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc.c?cvsroot=qemu&r1=1.34&r2=1.35
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_chrp.c?cvsroot=qemu&r1=1.44&r2=1.45
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_prep.c?cvsroot=qemu&r1=1.47&r2=1.48
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_dbdma.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_nvram.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/macio.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_mac.h?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_oldworld.c?cvsroot=qemu&rev=1.1
Quoted 1 line
You broke sparc64-softmmu build with this patch.
I think the best solution to fix this is to put the nvram helpers to m48t59.h as inline functions instead of duplicating the code in several places.
Quoted 42 lines · Blue Swirl
Quoted 41 lines · Blue Swirl
Quoted 39 lines · Jocelyn Mayer
CVSROOT: /sources/qemu Module name: qemu Changes by: Jocelyn Mayer <j_mayer> 07/10/28 23:42:18Modified files:
. : Makefile.targetvl.h
hw :cuda.cgrackle_pci.cheathrow_pic.cppc.c
ppc_chrp.cppc_prep.c
Added files:
hw :mac_dbdma.cmac_nvram.cmacio.cppc_mac.h
ppc_oldworld.cLog message:
* sort the PowerPC target object files
* make PowerPC NVRAM accessors generic to be able to use a MacIO NVRAM instead of the M48T59 one
* split PowerMac targets code:
- move all PowerMac related definitions and prototypes intohw/ppc_mac.h
- addhw/mac_dbdma.c,hw/mac_nvram.candmacio.c
which implements shared PowerMac devices
- define the g3bw machine in a newhw/ppc_oldworld.cfile
* Fix the g3bw target:
- fix the Grackle host PCI device
- connect the Heathrow PIC to the PowerPC 6xx bus pinsCVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/qemu/Makefile.target?cvsroot=qemu&r1=1.212&r2=1.213
http://cvs.savannah.gnu.org/viewcvs/qemu/vl.h?cvsroot=qemu&r1=1.280&r2=1.281
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/cuda.c?cvsroot=qemu&r1=1.16&r2=1.17
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/grackle_pci.c?cvsroot=qemu&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/heathrow_pic.c?cvsroot=qemu&r1=1.5&r2=1.6
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc.c?cvsroot=qemu&r1=1.34&r2=1.35
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_chrp.c?cvsroot=qemu&r1=1.44&r2=1.45
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_prep.c?cvsroot=qemu&r1=1.47&r2=1.48
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_dbdma.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_nvram.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/macio.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_mac.h?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_oldworld.c?cvsroot=qemu&rev=1.1
Quoted 1 line
Quoted 1 line
You broke sparc64-softmmu build with this patch.
I am missing something ? I rebuilt all available targets before commiting... but I now see sparc64-softmmu seems not to be in the available targets, which could explain I cannot check if it compiles or not... As it been removed by mistake ?
Quoted 3 lines
I think the best solution to fix this is to put the nvram helpers to
m48t59.has inline functions instead of duplicating the code in several places.
You mean the NVRAM_set / get_xxx ? I was to remove the definitions from vl.h, I have to say, because those are supposed to be PowerPC (in fact OpenHack'Ware) related hacks.
Those functions will never go in m48t59.h as they are not related with m48t59. Apple machine don't have such a device (even if Qemu pretend it has, this is to be removed in the days to come) but need those functions to pass arguments to the firmware. What I needed to do (and that what I did commit) is make those routines independant from m48t59 so I can remove this device from ppc_chrp.c and ppc_oldworld.c and use the real Mac nvram instead (but ppc_prep.c still uses m48t59...).
Whatever, I'll try to fix the sparc64 case as I broke it (if I found the code ;-) ).
Signature · 2 lines
J. Mayer <[email protected]> Never organized
Quoted 65 lines · J. Mayer
Quoted 42 lines · Blue Swirl
Quoted 41 lines · Blue Swirl
Quoted 39 lines · Jocelyn Mayer
CVSROOT: /sources/qemu Module name: qemu Changes by: Jocelyn Mayer <j_mayer> 07/10/28 23:42:18Modified files:
. : Makefile.targetvl.h
hw :cuda.cgrackle_pci.cheathrow_pic.cppc.c
ppc_chrp.cppc_prep.c
Added files:
hw :mac_dbdma.cmac_nvram.cmacio.cppc_mac.h
ppc_oldworld.cLog message:
* sort the PowerPC target object files
* make PowerPC NVRAM accessors generic to be able to use a MacIO NVRAM instead of the M48T59 one
* split PowerMac targets code:
- move all PowerMac related definitions and prototypes intohw/ppc_mac.h
- addhw/mac_dbdma.c,hw/mac_nvram.candmacio.c
which implements shared PowerMac devices
- define the g3bw machine in a newhw/ppc_oldworld.cfile
* Fix the g3bw target:
- fix the Grackle host PCI device
- connect the Heathrow PIC to the PowerPC 6xx bus pinsCVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/qemu/Makefile.target?cvsroot=qemu&r1=1.212&r2=1.213
http://cvs.savannah.gnu.org/viewcvs/qemu/vl.h?cvsroot=qemu&r1=1.280&r2=1.281
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/cuda.c?cvsroot=qemu&r1=1.16&r2=1.17
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/grackle_pci.c?cvsroot=qemu&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/heathrow_pic.c?cvsroot=qemu&r1=1.5&r2=1.6
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc.c?cvsroot=qemu&r1=1.34&r2=1.35
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_chrp.c?cvsroot=qemu&r1=1.44&r2=1.45
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_prep.c?cvsroot=qemu&r1=1.47&r2=1.48
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_dbdma.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_nvram.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/macio.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_mac.h?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_oldworld.c?cvsroot=qemu&rev=1.1Quoted 1 line
Quoted 1 line
You broke sparc64-softmmu build with this patch.
I am missing something ? I rebuilt all available targets before commiting... but I now see sparc64-softmmu seems not to be in the available targets, which could explain I cannot check if it compiles or not... As it been removed by mistake ?
Quoted 3 lines
I think the best solution to fix this is to put the nvram helpers to
m48t59.has inline functions instead of duplicating the code in several places.You mean the
NVRAM_set/get_xxx? I was to remove the definitions fromvl.h, I have to say, because those are supposed to be PowerPC (in fact OpenHack'Ware) related hacks.
Those functions will never go inm48t59.has they are not related with m48t59. Apple machine don't have such a device (even if Qemu pretend it has, this is to be removed in the days to come) but need those functions to pass arguments to the firmware. What I needed to do (and that what I did commit) is make those routines independant from m48t59 so I can remove this device fromppc_chrp.candppc_oldworld.cand use the real Mac nvram instead (butppc_prep.cstill uses m48t59...).
Quoted 2 lines
Whatever, I'll try to fix the sparc64 case as I broke it (if I found the code ;-) ).
This patch seems to fix the Sparc64 compilation. I cannot test that it works, but the PowerPC counterparts is OK. I also fixed a bug in the NVRAM_set_string function.
Tell me what you feel about it, if you're OK, I'll commit it. This code could be shared, but it should be independant of the NVRAM model implementation. As I would not like to put this code in vl.c, maybe we need a c file in the hw subdirectory to put those kind of functions, which are part of the hw library but hardware implementation independant...
Signature · 2 lines
J. Mayer <[email protected]> Never organized
Index: vl.h
===================================================================
RCS file: /sources/qemu/qemu/vl.h,v
retrieving revision 1.285
vl.h +10 -0
@@ -1328,6 +1328,16 @@ typedef struct nvram_t {nvram_write_t write_fn; } nvram_t; +static inline uint32_t nvram_ll_read (nvram_t *nvram,uint32_t addr) +{ +return (*nvram->read_fn)(nvram->opaque, addr);; +} + +static inline void nvram_ll_write (nvram_t *nvram,uint32_t addr,uint32_t val) +{ + (*nvram->write_fn)(nvram->opaque, addr, val); +} +#include "hw/m48t59.h" void NVRAM_set_byte (nvram_t *nvram,uint32_t addr,uint8_t value);
Index: hw/ppc.c
===================================================================
RCS file: /sources/qemu/qemu/hw/ppc.c,v
retrieving revision 1.36
ppc.c +18 -27
86 lines not on this page · raw message
Index: hw/sun4u.c
===================================================================
RCS file: /sources/qemu/qemu/hw/sun4u.c,v
retrieving revision 1.24
sun4u.c +43 -37
180 lines not on this page · raw message
Quoted 56 lines · J. Mayer
Quoted 54 lines · J. Mayer
Quoted 42 lines · Blue Swirl
Quoted 41 lines · Blue Swirl
Quoted 39 lines · Jocelyn Mayer
CVSROOT: /sources/qemu Module name: qemu Changes by: Jocelyn Mayer <j_mayer> 07/10/28 23:42:18Modified files:
. : Makefile.targetvl.h
hw :cuda.cgrackle_pci.cheathrow_pic.cppc.c
ppc_chrp.cppc_prep.c
Added files:
hw :mac_dbdma.cmac_nvram.cmacio.cppc_mac.h
ppc_oldworld.cLog message:
* sort the PowerPC target object files
* make PowerPC NVRAM accessors generic to be able to use a MacIO NVRAM instead of the M48T59 one
* split PowerMac targets code:
- move all PowerMac related definitions and prototypes intohw/ppc_mac.h
- addhw/mac_dbdma.c,hw/mac_nvram.candmacio.c
which implements shared PowerMac devices
- define the g3bw machine in a newhw/ppc_oldworld.cfile
* Fix the g3bw target:
- fix the Grackle host PCI device
- connect the Heathrow PIC to the PowerPC 6xx bus pinsCVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/qemu/Makefile.target?cvsroot=qemu&r1=1.212&r2=1.213
http://cvs.savannah.gnu.org/viewcvs/qemu/vl.h?cvsroot=qemu&r1=1.280&r2=1.281
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/cuda.c?cvsroot=qemu&r1=1.16&r2=1.17
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/grackle_pci.c?cvsroot=qemu&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/heathrow_pic.c?cvsroot=qemu&r1=1.5&r2=1.6
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc.c?cvsroot=qemu&r1=1.34&r2=1.35
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_chrp.c?cvsroot=qemu&r1=1.44&r2=1.45
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_prep.c?cvsroot=qemu&r1=1.47&r2=1.48
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_dbdma.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_nvram.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/macio.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_mac.h?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_oldworld.c?cvsroot=qemu&rev=1.1Quoted 1 line
Quoted 1 line
You broke sparc64-softmmu build with this patch.
I am missing something ? I rebuilt all available targets before commiting... but I now see sparc64-softmmu seems not to be in the available targets, which could explain I cannot check if it compiles or not... As it been removed by mistake ?
Quoted 3 lines
I think the best solution to fix this is to put the nvram helpers to
m48t59.has inline functions instead of duplicating the code in several places.
Quoted 10 lines
Quoted 10 lines
You mean the
NVRAM_set/get_xxx? I was to remove the definitions fromvl.h, I have to say, because those are supposed to be PowerPC (in fact OpenHack'Ware) related hacks.
Those functions will never go inm48t59.has they are not related with m48t59. Apple machine don't have such a device (even if Qemu pretend it has, this is to be removed in the days to come) but need those functions to pass arguments to the firmware. What I needed to do (and that what I did commit) is make those routines independant from m48t59 so I can remove this device fromppc_chrp.candppc_oldworld.cand use the real Mac nvram instead (butppc_prep.cstill uses m48t59...).
I see. Should sun4m use these functions too? On the other hand, there is no need to be too independent on Sparc, because I think all Sun4u machines use m48t59 and sun4m machines have either m48t08 or older m48t02 (not supported yet). So if you prefer, sun4u could use the same approach as sun4m and not use these functions?
Quoted 12 lines
Quoted 2 lines
Whatever, I'll try to fix the sparc64 case as I broke it (if I found the code ;-) ).
This patch seems to fix the Sparc64 compilation. I cannot test that it works, but the PowerPC counterparts is OK. I also fixed a bug in the
NVRAM_set_stringfunction.
Tell me what you feel about it, if you're OK, I'll commit it. This code could be shared, but it should be independant of the NVRAM model implementation. As I would not like to put this code invl.c, maybe we need a c file in the hw subdirectory to put those kind of functions, which are part of the hw library but hardware implementation independant...
Works fine here, thanks.
Quoted 68 lines · Blue Swirl
Quoted 56 lines · J. Mayer
Quoted 54 lines · J. Mayer
Quoted 42 lines · Blue Swirl
Quoted 41 lines · Blue Swirl
Quoted 39 lines · Jocelyn Mayer
CVSROOT: /sources/qemu Module name: qemu Changes by: Jocelyn Mayer <j_mayer> 07/10/28 23:42:18Modified files:
. : Makefile.targetvl.h
hw :cuda.cgrackle_pci.cheathrow_pic.cppc.c
ppc_chrp.cppc_prep.c
Added files:
hw :mac_dbdma.cmac_nvram.cmacio.cppc_mac.h
ppc_oldworld.cLog message:
* sort the PowerPC target object files
* make PowerPC NVRAM accessors generic to be able to use a MacIO NVRAM instead of the M48T59 one
* split PowerMac targets code:
- move all PowerMac related definitions and prototypes intohw/ppc_mac.h
- addhw/mac_dbdma.c,hw/mac_nvram.candmacio.c
which implements shared PowerMac devices
- define the g3bw machine in a newhw/ppc_oldworld.cfile
* Fix the g3bw target:
- fix the Grackle host PCI device
- connect the Heathrow PIC to the PowerPC 6xx bus pinsCVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/qemu/Makefile.target?cvsroot=qemu&r1=1.212&r2=1.213
http://cvs.savannah.gnu.org/viewcvs/qemu/vl.h?cvsroot=qemu&r1=1.280&r2=1.281
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/cuda.c?cvsroot=qemu&r1=1.16&r2=1.17
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/grackle_pci.c?cvsroot=qemu&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/heathrow_pic.c?cvsroot=qemu&r1=1.5&r2=1.6
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc.c?cvsroot=qemu&r1=1.34&r2=1.35
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_chrp.c?cvsroot=qemu&r1=1.44&r2=1.45
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_prep.c?cvsroot=qemu&r1=1.47&r2=1.48
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_dbdma.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_nvram.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/macio.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_mac.h?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_oldworld.c?cvsroot=qemu&rev=1.1Quoted 1 line
Quoted 1 line
You broke sparc64-softmmu build with this patch.
I am missing something ? I rebuilt all available targets before commiting... but I now see sparc64-softmmu seems not to be in the available targets, which could explain I cannot check if it compiles or not... As it been removed by mistake ?
Quoted 3 lines
I think the best solution to fix this is to put the nvram helpers to
m48t59.has inline functions instead of duplicating the code in several places.Quoted 10 lines
Quoted 10 lines
You mean the
NVRAM_set/get_xxx? I was to remove the definitions fromvl.h, I have to say, because those are supposed to be PowerPC (in fact OpenHack'Ware) related hacks.
Those functions will never go inm48t59.has they are not related with m48t59. Apple machine don't have such a device (even if Qemu pretend it has, this is to be removed in the days to come) but need those functions to pass arguments to the firmware. What I needed to do (and that what I did commit) is make those routines independant from m48t59 so I can remove this device fromppc_chrp.candppc_oldworld.cand use the real Mac nvram instead (butppc_prep.cstill uses m48t59...).
Quoted 5 lines
I see. Should sun4m use these functions too? On the other hand, there is no need to be too independent on Sparc, because I think all Sun4u machines use m48t59 and sun4m machines have either m48t08 or older m48t02 (not supported yet). So if you prefer, sun4u could use the same approach as sun4m and not use these functions?
Depends on how you feel about it...
If there is a real need to have a generic devices registers and/or internal memory accessor used during the target machine initialisation (the model I propose could be used not only for NVRAM...), then the code should be made more generic (ie renaming the nvram_t type with a more generic name) and only one implementation should be kept. If this is only useful for the PowerPC target initialisation, then you should keep using the m48t59 only implementation you have now for Sparc64 and the PowerPC NVRAM_xxx functions should not be declared in vl.h. I would say that having a generic accessor for devices during machine init can be useful and the implementation I provided may be sufficient for most usages. But it may also be not so useful ? ...
[...]
Signature · 1 line
Jocelyn Mayer <[email protected]>
Quoted 76 lines · Jocelyn Mayer
Quoted 68 lines · Blue Swirl
Quoted 56 lines · J. Mayer
Quoted 54 lines · J. Mayer
Quoted 42 lines · Blue Swirl
Quoted 41 lines · Blue Swirl
Quoted 39 lines · Jocelyn Mayer
CVSROOT: /sources/qemu Module name: qemu Changes by: Jocelyn Mayer <j_mayer> 07/10/28 23:42:18Modified files:
. : Makefile.targetvl.h
hw :cuda.cgrackle_pci.cheathrow_pic.cppc.c
ppc_chrp.cppc_prep.c
Added files:
hw :mac_dbdma.cmac_nvram.cmacio.cppc_mac.h
ppc_oldworld.cLog message:
* sort the PowerPC target object files
* make PowerPC NVRAM accessors generic to be able to use a MacIO NVRAM instead of the M48T59 one
* split PowerMac targets code:
- move all PowerMac related definitions and prototypes intohw/ppc_mac.h
- addhw/mac_dbdma.c,hw/mac_nvram.candmacio.c
which implements shared PowerMac devices
- define the g3bw machine in a newhw/ppc_oldworld.cfile
* Fix the g3bw target:
- fix the Grackle host PCI device
- connect the Heathrow PIC to the PowerPC 6xx bus pinsCVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/qemu/Makefile.target?cvsroot=qemu&r1=1.212&r2=1.213
http://cvs.savannah.gnu.org/viewcvs/qemu/vl.h?cvsroot=qemu&r1=1.280&r2=1.281
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/cuda.c?cvsroot=qemu&r1=1.16&r2=1.17
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/grackle_pci.c?cvsroot=qemu&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/heathrow_pic.c?cvsroot=qemu&r1=1.5&r2=1.6
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc.c?cvsroot=qemu&r1=1.34&r2=1.35
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_chrp.c?cvsroot=qemu&r1=1.44&r2=1.45
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_prep.c?cvsroot=qemu&r1=1.47&r2=1.48
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_dbdma.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_nvram.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/macio.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_mac.h?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_oldworld.c?cvsroot=qemu&rev=1.1Quoted 1 line
Quoted 1 line
You broke sparc64-softmmu build with this patch.
I am missing something ? I rebuilt all available targets before commiting... but I now see sparc64-softmmu seems not to be in the available targets, which could explain I cannot check if it compiles or not... As it been removed by mistake ?
Quoted 3 lines
I think the best solution to fix this is to put the nvram helpers to
m48t59.has inline functions instead of duplicating the code in several places.Quoted 10 lines
Quoted 10 lines
You mean the
NVRAM_set/get_xxx? I was to remove the definitions fromvl.h, I have to say, because those are supposed to be PowerPC (in fact OpenHack'Ware) related hacks.
Those functions will never go inm48t59.has they are not related with m48t59. Apple machine don't have such a device (even if Qemu pretend it has, this is to be removed in the days to come) but need those functions to pass arguments to the firmware. What I needed to do (and that what I did commit) is make those routines independant from m48t59 so I can remove this device fromppc_chrp.candppc_oldworld.cand use the real Mac nvram instead (butppc_prep.cstill uses m48t59...).Quoted 5 lines
I see. Should sun4m use these functions too? On the other hand, there is no need to be too independent on Sparc, because I think all Sun4u machines use m48t59 and sun4m machines have either m48t08 or older m48t02 (not supported yet). So if you prefer, sun4u could use the same approach as sun4m and not use these functions?
Quoted 12 lines
Depends on how you feel about it...
If there is a real need to have a generic devices registers and/or internal memory accessor used during the target machine initialisation (the model I propose could be used not only for NVRAM...), then the code should be made more generic (ie renaming thenvram_ttype with a more generic name) and only one implementation should be kept. If this is only useful for the PowerPC target initialisation, then you should keep using the m48t59 only implementation you have now for Sparc64 and the PowerPCNVRAM_xxxfunctions should not be declared invl.h. I would say that having a generic accessor for devices during machine init can be useful and the implementation I provided may be sufficient for most usages. But it may also be not so useful ? ...
Well, I'd find common higher level routines more useful, like filling OHW nvram structure v1 (used by Sun4m, Sun4u, PPC) or setting up OpenBIOS variable partition using data from prom_env (Sun4m, Sun4u). Or lower: write a 32 bit BE value to a location. Maybe these would be more widely useful if they used generic access routines that are not dependent on the type.
Quoted 90 lines · Blue Swirl
Quoted 76 lines · Jocelyn Mayer
Quoted 68 lines · Blue Swirl
Quoted 56 lines · J. Mayer
Quoted 54 lines · J. Mayer
Quoted 42 lines · Blue Swirl
Quoted 41 lines · Blue Swirl
Quoted 39 lines · Jocelyn Mayer
CVSROOT: /sources/qemu Module name: qemu Changes by: Jocelyn Mayer <j_mayer> 07/10/28 23:42:18Modified files:
. : Makefile.targetvl.h
hw :cuda.cgrackle_pci.cheathrow_pic.cppc.c
ppc_chrp.cppc_prep.c
Added files:
hw :mac_dbdma.cmac_nvram.cmacio.cppc_mac.h
ppc_oldworld.cLog message:
* sort the PowerPC target object files
* make PowerPC NVRAM accessors generic to be able to use a MacIO NVRAM instead of the M48T59 one
* split PowerMac targets code:
- move all PowerMac related definitions and prototypes intohw/ppc_mac.h
- addhw/mac_dbdma.c,hw/mac_nvram.candmacio.c
which implements shared PowerMac devices
- define the g3bw machine in a newhw/ppc_oldworld.cfile
* Fix the g3bw target:
- fix the Grackle host PCI device
- connect the Heathrow PIC to the PowerPC 6xx bus pinsCVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/qemu/Makefile.target?cvsroot=qemu&r1=1.212&r2=1.213
http://cvs.savannah.gnu.org/viewcvs/qemu/vl.h?cvsroot=qemu&r1=1.280&r2=1.281
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/cuda.c?cvsroot=qemu&r1=1.16&r2=1.17
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/grackle_pci.c?cvsroot=qemu&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/heathrow_pic.c?cvsroot=qemu&r1=1.5&r2=1.6
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc.c?cvsroot=qemu&r1=1.34&r2=1.35
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_chrp.c?cvsroot=qemu&r1=1.44&r2=1.45
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_prep.c?cvsroot=qemu&r1=1.47&r2=1.48
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_dbdma.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/mac_nvram.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/macio.c?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_mac.h?cvsroot=qemu&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/ppc_oldworld.c?cvsroot=qemu&rev=1.1Quoted 1 line
Quoted 1 line
You broke sparc64-softmmu build with this patch.
I am missing something ? I rebuilt all available targets before commiting... but I now see sparc64-softmmu seems not to be in the available targets, which could explain I cannot check if it compiles or not... As it been removed by mistake ?
Quoted 3 lines
I think the best solution to fix this is to put the nvram helpers to
m48t59.has inline functions instead of duplicating the code in several places.Quoted 10 lines
Quoted 10 lines
You mean the
NVRAM_set/get_xxx? I was to remove the definitions fromvl.h, I have to say, because those are supposed to be PowerPC (in fact OpenHack'Ware) related hacks.
Those functions will never go inm48t59.has they are not related with m48t59. Apple machine don't have such a device (even if Qemu pretend it has, this is to be removed in the days to come) but need those functions to pass arguments to the firmware. What I needed to do (and that what I did commit) is make those routines independant from m48t59 so I can remove this device fromppc_chrp.candppc_oldworld.cand use the real Mac nvram instead (butppc_prep.cstill uses m48t59...).Quoted 5 lines
I see. Should sun4m use these functions too? On the other hand, there is no need to be too independent on Sparc, because I think all Sun4u machines use m48t59 and sun4m machines have either m48t08 or older m48t02 (not supported yet). So if you prefer, sun4u could use the same approach as sun4m and not use these functions?
Quoted 12 lines
Depends on how you feel about it...
If there is a real need to have a generic devices registers and/or internal memory accessor used during the target machine initialisation (the model I propose could be used not only for NVRAM...), then the code should be made more generic (ie renaming thenvram_ttype with a more generic name) and only one implementation should be kept. If this is only useful for the PowerPC target initialisation, then you should keep using the m48t59 only implementation you have now for Sparc64 and the PowerPCNVRAM_xxxfunctions should not be declared invl.h. I would say that having a generic accessor for devices during machine init can be useful and the implementation I provided may be sufficient for most usages. But it may also be not so useful ? ...
Quoted 6 lines
Well, I'd find common higher level routines more useful, like filling OHW nvram structure v1 (used by Sun4m, Sun4u, PPC) or setting up OpenBIOS variable partition using data from
prom_env(Sun4m, Sun4u). Or lower: write a 32 bit BE value to a location. Maybe these would be more widely useful if they used generic access routines that are not dependent on the type.
The higher level routine need the low-level ones in the PowerPC case, as they can be used on any kind of NVRAM device (or RAM, flash, ROM, ...). Then I cannot have this high-levle routine without some specific helpers at a lower level.
Accessing directly to the destination location would lead to hardcode the physical hardware destination, and may not be possible if we want to write something that might be (re)located, or need to be enabled before usage, like a PCI device or the PowerPC 405 internal SRAM (which is not visible in the physical address space at reset time).
Then, at a level or another, I need some low-level devices accessors. For me the question is: is it useful to make those routines generic, usable by any target to access any device, or is it to be a PowerPC specific hack ? In the later case, I just have to remove the functions prototypes from vl.h and not change your code to make the Sparc64 target compile again.
Signature · 2 lines
J. Mayer <[email protected]> Never organized