i attached it in a previous mail... try again...

--
cinap
--- Begin Message ---
> process1:
>       still in kernel:
>               memmove(buf, ...)
>               *fault*
>               trap()
>                       fault386()
>                               fault() => -1
>                               if(!user){
>                                       panic()
>                                       *panic*
>                               }
>                               ...
>                               postnote()

could you be more specific.  what is your test program,
where is it crashing (if you know), and what is the panic
message, if any?  i must be dense, but i'm confused by
your process diagram.

- erik

--- End Message ---
#include <u.h>
#include <libc.h>

void
main(int argc, char **argv)
{
        char *buf;
        int fd;

        if((fd = open("/dev/zero", OREAD)) < 0)
                sysfatal("open");

        buf = (char*)0x600000;
        segattach(0, "memory", buf, 2*4096);

        switch(rfork(RFPROC|RFMEM)){
        case -1:
                sysfatal("fork");
                break;
        case 0:
                for(;;){
                        read(fd, buf+4096, 4096);
                }
        }
        sleep(1000);
        segbrk(buf, buf+4096);
}

Reply via email to