On 23/02/15 21:27, Justin Cormack wrote: > On 23 February 2015 at 21:06, Antti Kantee <[email protected]> wrote: >> On 23/02/15 19:42, Justin Cormack wrote: >>> ok so it eventually has to allocate memory while initialising the >>> sysctl nodes and that is what causes it to reschedule. >> >> The malloc hypercall should never block and therefore never reschedule. >> Blocking, if it is allowed along the callpath, is handled in the rump >> kernel. Here "blocking" of course means blocking in rump kernel virtual >> time. If the malloc() or similar backend routine called by the >> hypercall implementation decides to e.g. do pageout, it will just appear >> like some instructions take a really long time, but, as opposed to >> rescheduling, will not cause incorrect execution in the rump kernel. >> > > No it is not that, I mean this trace back from schedule
Aaah, ic. Yea, that's the correct way to handle it ... apart from the hypercall failing to allocate memory and causing the call to uvm_wait(), of course ;) > #0 schedule () at > /home/justin/frankenlibc/rumpsrc/lib/librumpuser/rumpfiber.c:158 > #1 0x000000000056d61c in wait (msec=msec@entry=0, wh=0x7ffff7ff8350) > at /home/justin/frankenlibc/rumpsrc/lib/librumpuser/rumpfiber.c:645 > #2 0x000000000056e3e3 in rumpuser_cv_wait (cv=0x7ffff7ff8350, > mtx=0x7ffff7ff82d0) > at /home/justin/frankenlibc/rumpsrc/lib/librumpuser/rumpfiber.c:989 > #3 0x0000000000565bcd in docvwait (cv=0x8212b0 <oomwait>, > mtx=0x8212e8 <pdaemonmtx>, ts=0x0) > at /home/justin/frankenlibc/rumpsrc/sys/rump/librump/rumpkern/locks.c:359 > #4 0x0000000000567156 in uvm_wait (msg=<optimised out>) at > /home/justin/frankenlibc/rumpsrc/sys/rump/librump/rumpkern/vm.c:976 > #5 0x0000000000567639 in rump_hypermalloc (howmuch=12288, > alignment=4096, waitok=true, wmsg=0x5a586b "kmalloc") > at /home/justin/frankenlibc/rumpsrc/sys/rump/librump/rumpkern/vm.c:1222 > #6 0x00000000005676b9 in uvm_km_kmem_alloc (vm=<optimised out>, > size=<optimised out>, flags=<optimised out>, addr=0x7fffffffdd58) > at /home/justin/frankenlibc/rumpsrc/sys/rump/librump/rumpkern/vm.c:788 > #7 0x000000000052c6dc in kmem_intr_alloc (requested_size=<optimised > out>, kmflags=1) > at > /home/justin/frankenlibc/rumpsrc/sys/rump/librump/rumpkern/../../../kern/subr_kmem.c:272 > #8 0x000000000056c378 in kern_malloc (size=<optimised out>, flags=4) > at > /home/justin/frankenlibc/rumpsrc/sys/rump/librump/rumpkern/../../../kern/kern_malloc.c:117 > #9 0x000000000054a49f in sysctl_realloc (p=0x7ffff7fa0808) > at > /home/justin/frankenlibc/rumpsrc/sys/rump/librump/rumpkern/../../../kern/kern_sysctl.c:2690 > #10 sysctl_create (name=<optimised out>, namelen=<optimised out>, > oldp=0x7fffffffe060, oldlenp=<optimised out>, > newp=<optimised out>, newlen=<optimised out>, > oname=0x7fffffffdfa0, l=0x0, rnode=0x7ffff7fa0808) > at > /home/justin/frankenlibc/rumpsrc/sys/rump/librump/rumpkern/../../../kern/kern_sysctl.c:1130 > #11 0x000000000054b812 in sysctl_createv (log=0x0, cflags=<optimised > out>, rnode=<optimised out>, cnode=0x7fffffffe198, > flags=16777729, type=1, namep=0x57a6ec "anonportalgo", descr=0x0, > func=0x0, qv=0, newp=0x0, newlen=0) > at > /home/justin/frankenlibc/rumpsrc/sys/rump/librump/rumpkern/../../../kern/kern_sysctl.c:2070 > #12 0x000000000043a8ec in sysctl_net_inet6_ip6_setup (clog=0x0) > at > /home/justin/frankenlibc/rumpsrc/sys/rump/net/lib/libnet/../../../../netinet6/ip6_input.c:1964 > #13 ip6_init () at > /home/justin/frankenlibc/rumpsrc/sys/rump/net/lib/libnet/../../../../netinet6/ip6_input.c:171 > #14 0x000000000049b203 in domain_attach (dp=0x7fd300 <rumpns_inet6domain>) > at > /home/justin/frankenlibc/rumpsrc/sys/rump/librump/rumpnet/../../../kern/uipc_domain.c:141 > #15 0x000000000056b684 in rump_component_init > (type=type@entry=RUMP_COMPONENT_NET) > at /home/justin/frankenlibc/rumpsrc/sys/rump/librump/rumpkern/rump.c:600 > #16 0x000000000048c184 in rumpcompinitRUMP__FACTION_NET () at > /home/justin/frankenlibc/rumpsrc/sys/rump/librump/rumpnet/rump_net.c:54 > #17 0x000000000056b684 in rump_component_init (type=RUMP__FACTION_NET) > at /home/justin/frankenlibc/rumpsrc/sys/rump/librump/rumpkern/rump.c:600 > #18 0x000000000056bb85 in rump_init () at > /home/justin/frankenlibc/rumpsrc/sys/rump/librump/rumpkern/rump.c:446 > #19 0x00000000004014f4 in __libc_start_main (main=0x401540 <main>, > argc=1, argv=0x7fffffffe418, envp=0x7fffffffe428) at crti.c:42 > #20 0x000000000056e64f in __platform_init (main=0x401540 <main>, > argc=1, argv=0x7fffffffe418) at __platform_init.c:15 > #21 0x000000000040146a in _start () > > ------------------------------------------------------------------------------ > Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server > from Actuate! Instantly Supercharge Your Business Reports and Dashboards > with Interactivity, Sharing, Native Excel Exports, App Integration & more > Get technology previously reserved for billion-dollar corporations, FREE > http://pubads.g.doubleclick.net/gampad/clk?id=190641631&iu=/4140/ostg.clktrk > _______________________________________________ > rumpkernel-users mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/rumpkernel-users > ------------------------------------------------------------------------------ Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server from Actuate! Instantly Supercharge Your Business Reports and Dashboards with Interactivity, Sharing, Native Excel Exports, App Integration & more Get technology previously reserved for billion-dollar corporations, FREE http://pubads.g.doubleclick.net/gampad/clk?id=190641631&iu=/4140/ostg.clktrk _______________________________________________ rumpkernel-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/rumpkernel-users
