From: Aurelien J. <aur...@au...> - 2007-03-29 22:30:42
|
On Thu, Mar 29, 2007 at 05:08:21PM +0100, Stuart Brady wrote: > On Thu, Mar 29, 2007 at 05:25:47PM +0200, Sunil Amitkumar Janki wrote: > > > About the Alphas, it would be great to run Tru64 on them or for the > > occasional OpenVMS session. I'm looking forward to implementing an > > Alpha target even though I've never seen or used them. You must be > > very lucky to have them at your disposal. > > I've been thinking about Alpha emulation for a while. I'd be happy to > help in any way that I can. > > > And I'm also very much intrigued by a PA-RISC target, not least > > because HP-(S)UX was the platform I learned Autocad and Pro-Engineer > > on. Thankfully I never got to use those on Windows. > > PA-RISC emulation is currently being worked on. > > See http://hppaqemu.sourceforge.net/ > > Please feel free to ask questions about the code on the hppaqemu-devel > list. Patches would be very much appreciated, too! > Oh, that's really nice. I have started to work on HPPA target support a few months ago, but stopped due to lack of time and motivation. I have just compared what I already did, and what has been done in the CVS. Please find below a few patches. The first one adds the hppa binaries to the tarball target. The second one fixes the IOC definitions to make them coherent with the kernel include files. The third one adds a few missing definitions to termbits.h, also taken from the kernel include files. I am not sure they are really useful, but they are present on some other targets. Bye, Aurelien Index: Makefile =================================================================== RCS file: /cvsroot/hppaqemu/hppaqemu/Makefile,v retrieving revision 1.1.1.1 diff -u -d -p -r1.1.1.1 Makefile --- Makefile 23 Feb 2007 21:43:58 -0000 1.1.1.1 +++ Makefile 29 Mar 2007 22:17:30 -0000 @@ -147,6 +147,7 @@ tarbin: $(bindir)/qemu-system-x86_64 \ $(bindir)/qemu-system-mips \ $(bindir)/qemu-system-mipsel \ + $(bindir)/qemu-system-hppa \ $(bindir)/qemu-system-arm \ $(bindir)/qemu-i386 \ $(bindir)/qemu-arm \ @@ -155,6 +156,7 @@ tarbin: $(bindir)/qemu-ppc \ $(bindir)/qemu-mips \ $(bindir)/qemu-mipsel \ + $(bindir)/qemu-hppa \ $(bindir)/qemu-img \ $(datadir)/bios.bin \ $(datadir)/vgabios.bin \ Index: linux-user/syscall_defs.h =================================================================== RCS file: /cvsroot/hppaqemu/hppaqemu/linux-user/syscall_defs.h,v retrieving revision 1.3 diff -u -d -p -r1.3 syscall_defs.h --- linux-user/syscall_defs.h 5 Mar 2007 02:27:42 -0000 1.3 +++ linux-user/syscall_defs.h 29 Mar 2007 22:17:30 -0000 @@ -49,7 +49,7 @@ #define TARGET_IOC_TYPEBITS 8 #if defined(TARGET_I386) || defined(TARGET_ARM) || defined(TARGET_SH4) \ - || defined(TARGET_M68K) || defined(TARGET_HPPA) + || defined(TARGET_M68K) #define TARGET_IOC_SIZEBITS 14 #define TARGET_IOC_DIRBITS 2 @@ -68,6 +68,15 @@ #define TARGET_IOC_READ 2U #define TARGET_IOC_WRITE 4U +#elif defined(TARGET_HPPA) + +#define TARGET_IOC_SIZEBITS 14 +#define TARGET_IOC_DIRBITS 2 + +#define TARGET_IOC_NONE 0U +#define TARGET_IOC_WRITE 1U +#define TARGET_IOC_READ 2U + #else #error unsupported CPU #endif Index: linux-user/hppa/termbits.h =================================================================== RCS file: /cvsroot/hppaqemu/hppaqemu/linux-user/hppa/termbits.h,v retrieving revision 1.2 diff -u -d -p -r1.2 termbits.h --- linux-user/hppa/termbits.h 5 Mar 2007 02:27:42 -0000 1.2 +++ linux-user/hppa/termbits.h 29 Mar 2007 22:17:30 -0000 @@ -217,3 +217,14 @@ struct target_termios { #define TARGET_TIOCSTART 0x5461 #define TARGET_TIOCSTOP 0x5462 #define TARGET_TIOCSLTC 0x5462 + +/* Used for packet mode */ +#define TARGET_TIOCPKT_DATA 0 +#define TARGET_TIOCPKT_FLUSHREAD 1 +#define TARGET_TIOCPKT_FLUSHWRITE 2 +#define TARGET_TIOCPKT_STOP 4 +#define TARGET_TIOCPKT_START 8 +#define TARGET_TIOCPKT_NOSTOP 16 +#define TARGET_TIOCPKT_DOSTOP 32 + +#define TARGET_TIOCSER_TEMT 0x01 /* Transmitter physically empty */ -- .''`. Aurelien Jarno | GPG: 1024D/F1BCDB73 : :' : Debian developer | Electrical Engineer `. `' au...@de... | aur...@au... `- people.debian.org/~aurel32 | www.aurel32.net |