[9fans] 9VX failure
Not much more than init: starting /bin/rc Segmentation fault from a freshly compiled 9vx or the 9vx.Linux contained in the HG repository on bitbucket.org. I was hoping to try 9vx.tgz from swtch.com which is not 9vx*.bz2, but that does not behave any differently. The platform Linux fangle 2.6.32-24-generic #42-Ubuntu SMP Fri Aug 20 14:24:04 UTC 2010 i686 GNU/Linux Ubuntu Lucid Lynx on an HP Laptop. ++L
Re: [9fans] 9VX failure
On Sat, Sep 11, 2010 at 09:02:36AM +0200, Lucio De Re wrote: I was hoping to try 9vx.tgz from swtch.com which is not 9vx*.bz2, but that does not behave any differently. s/not 9/now 9/ ++L
Re: [9fans] 9VX failure
I am pretty sure Charle's patch will fix this problem ron
Re: [9fans] 9VX failure
On Sat, Sep 11, 2010 at 09:34:20AM -0700, ron minnich wrote: I am pretty sure Charle's patch will fix this problem Is that included in rminnich/vx32, where default compilation fails with a missing pcap.h? What should I be looking for? ++L
Re: [9fans] 9VX failure
On Sat, Sep 11, 2010 at 10:18 AM, Lucio De Re lu...@proxima.alt.za wrote: On Sat, Sep 11, 2010 at 09:34:20AM -0700, ron minnich wrote: I am pretty sure Charle's patch will fix this problem Is that included in rminnich/vx32, where default compilation fails with a missing pcap.h? the pcap.h thing is unrelated and I think I'm going to change it so that it builds default with no pcap support, since I'm not the only person seeing this build error. no, I have to get his patch included. I had a question in to his customer support people about the patch first before i went with the patch :-) ron
Re: [9fans] 9VX failure
On Sat, Sep 11, 2010 at 10:24:05AM -0700, ron minnich wrote: Is that included in rminnich/vx32, where default compilation fails with a missing pcap.h? the pcap.h thing is unrelated and I think I'm going to change it so that it builds default with no pcap support, since I'm not the only person seeing this build error. no, I have to get his patch included. I had a question in to his customer support people about the patch first before i went with the patch :-) That means that there are two patches required here: Charles' adjustment (why have I not seen it, I wonder) and the pcap.h thing. Can you post them here in the interim? I'm not sure I want to know why pcap.h is being included and not found... ++L
Re: [9fans] 9VX failure
pcap is for the virtual ethernet driver to use the native ip stack. there's another one that uses TAP that yiyus finalized from someone else's efforts (I'm not giving due credit here, sorry). If you don't have pcap just don't build etherve.c. --dho 2010/9/11 Lucio De Re lu...@proxima.alt.za: On Sat, Sep 11, 2010 at 10:24:05AM -0700, ron minnich wrote: Is that included in rminnich/vx32, where default compilation fails with a missing pcap.h? the pcap.h thing is unrelated and I think I'm going to change it so that it builds default with no pcap support, since I'm not the only person seeing this build error. no, I have to get his patch included. I had a question in to his customer support people about the patch first before i went with the patch :-) That means that there are two patches required here: Charles' adjustment (why have I not seen it, I wonder) and the pcap.h thing. Can you post them here in the interim? I'm not sure I want to know why pcap.h is being included and not found... ++L
Re: [9fans] 9VX failure
2010/9/11 Lucio De Re lu...@proxima.alt.za: That bit was easy, just move the leading # from nopcap to etherpcap: From now on, this is the default in my 9vx version: http://bitbucket.org/yiyus/vx32/ If anybody thinks pcap should be compiled by default, please let me know. Now, where do I find Charles' fix for the segmentation error? I'm trying to find that one too. -- - yiyus || JGL . 4l77.com
Re: [9fans] 9VX failure
Try 2. sorry. Thanks again to charles for finding that CLD issue. ron hg diff diff -r c7e9b5edb8d4 src/9vx/main.c --- a/src/9vx/main.cSun Dec 27 09:49:22 2009 -0800 +++ b/src/9vx/main.cFri Sep 03 16:58:16 2010 +0100 @@ -55,6 +55,7 @@ static voidbootinit(void); static voidsiginit(void); +static void machkeyinit(void); static char* getuser(void); static char* findroot(void); @@ -80,6 +81,9 @@ char buf[1024]; /* Minimal set up to make print work. */ +#ifndef TLS + machkeyinit(); +#endif setmach(mach0); coherence = nop; quotefmtinstall(); @@ -695,9 +699,6 @@ void mach0init(void) { -#ifndef TLS - machkeyinit(); -#endif conf.nmach = 1; machinit(); /* common per-processor init */ diff -r c7e9b5edb8d4 src/9vx/sched.c --- a/src/9vx/sched.c Sun Dec 27 09:49:22 2009 -0800 +++ b/src/9vx/sched.c Fri Sep 03 16:58:16 2010 +0100 @@ -158,6 +158,8 @@ m-machno, p-pid, p-text, kprocq.n, nrunproc); unlock(kprocq.lk); punlock(run); + while(p-mach != nil) + sched_yield(); return p; } diff -r c7e9b5edb8d4 src/Makefrag --- a/src/Makefrag Sun Dec 27 09:49:22 2009 -0800 +++ b/src/Makefrag Fri Sep 03 16:58:16 2010 +0100 @@ -1,7 +1,7 @@ # Main top-level makefile fragment for the vx32 virtual machine. # Compiler flags common to both host and VX32 environment files. -COMMON_CFLAGS = -g -O3 -MD -std=gnu99 -I. $(CFLAGS) +COMMON_CFLAGS = -g -O2 -MD -std=gnu99 -I. -fno-stack-protector $(CFLAGS) #COMMON_CFLAGS = -g -MD -std=gnu99 -I. $(CFLAGS) COMMON_LDFLAGS = -g -L. $(LDFLAGS) diff -r c7e9b5edb8d4 src/libvx32/run32.S --- a/src/libvx32/run32.S Sun Dec 27 09:49:22 2009 -0800 +++ b/src/libvx32/run32.S Fri Sep 03 16:58:16 2010 +0100 @@ -111,6 +111,7 @@ popl%edi popl%esi popl%ebx + cld ret @@ -128,6 +129,8 @@ // (DS/ES/SS were already restored by vxrun_return.) movwVXEMU_HOST_VS(%eax),VSEG + cld + ret // Don't put anything here!
Re: [9fans] 9VX failure
hg diff diff -r c7e9b5edb8d4 src/9vx/main.c --- a/src/9vx/main.cSun Dec 27 09:49:22 2009 -0800 +++ b/src/9vx/main.cFri Sep 03 16:58:16 2010 +0100 @@ -55,6 +55,7 @@ static voidbootinit(void); static voidsiginit(void); +static void machkeyinit(void); static char* getuser(void); static char* findroot(void); @@ -80,6 +81,9 @@ char buf[1024]; Here you go, thanks Charles! ron /* Minimal set up to make print work. */ +#ifndef TLS + machkeyinit(); +#endif setmach(mach0); coherence = nop; quotefmtinstall(); @@ -695,9 +699,6 @@ void mach0init(void) { -#ifndef TLS - machkeyinit(); -#endif conf.nmach = 1; machinit(); /* common per-processor init */ diff -r c7e9b5edb8d4 src/9vx/sched.c --- a/src/9vx/sched.c Sun Dec 27 09:49:22 2009 -0800 +++ b/src/9vx/sched.c Fri Sep 03 16:58:16 2010 +0100 @@ -158,6 +158,8 @@ m-machno, p-pid, p-text, kprocq.n, nrunproc); unlock(kprocq.lk); punlock(run); + while(p-mach != nil) + sched_yield(); return p; } diff -r c7e9b5edb8d4 src/Makefrag --- a/src/Makefrag Sun Dec 27 09:49:22 2009 -0800 +++ b/src/Makefrag Fri Sep 03 16:58:16 2010 +0100 @@ -1,7 +1,7 @@ # Main top-level makefile fragment for the vx32 virtual machine. # Compiler flags common to both host and VX32 environment files. -COMMON_CFLAGS = -g -O3 -MD -std=gnu99 -I. $(CFLAGS) +COMMON_CFLAGS = -g -O2 -MD -std=gnu99 -I. -fno-stack-protector $(CFLAGS) #COMMON_CFLAGS = -g -MD -std=gnu99 -I. $(CFLAGS) COMMON_LDFLAGS = -g -L. $(LDFLAGS) diff -r c7e9b5edb8d4 src/libvx32/run32.S --- a/src/libvx32/run32.S Sun Dec 27 09:49:22 2009 -0800 +++ b/src/libvx32/run32.S Fri Sep 03 16:58:16 2010 +0100 @@ -111,6 +111,7 @@ popl%edi popl%esi popl%ebx + cld ret @@ -128,6 +129,8 @@ // (DS/ES/SS were already restored by vxrun_return.) movwVXEMU_HOST_VS(%eax),VSEG + cld + ret // Don't put anything here!