Module Name: src Committed By: pooka Date: Wed May 1 06:58:37 UTC 2013
Modified Files: src/sys/rump/net/lib/libshmif: if_shmem.c Log Message: Three cheers for the mighty C type system that doesn't recognize the difference between an enum and an integer. Due to wrong parameter order, the lock backoff routine ended up sleeping 1 million seconds instead of 1ms. On the plus side, we got some sort of idea how often the shmif spinlock backoff routine is hit during a standard test run. To generate a diff of this commit: cvs rdiff -u -r1.53 -r1.54 src/sys/rump/net/lib/libshmif/if_shmem.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/rump/net/lib/libshmif/if_shmem.c diff -u src/sys/rump/net/lib/libshmif/if_shmem.c:1.53 src/sys/rump/net/lib/libshmif/if_shmem.c:1.54 --- src/sys/rump/net/lib/libshmif/if_shmem.c:1.53 Tue Apr 30 00:03:54 2013 +++ src/sys/rump/net/lib/libshmif/if_shmem.c Wed May 1 06:58:36 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: if_shmem.c,v 1.53 2013/04/30 00:03:54 pooka Exp $ */ +/* $NetBSD: if_shmem.c,v 1.54 2013/05/01 06:58:36 pooka Exp $ */ /* * Copyright (c) 2009, 2010 Antti Kantee. All Rights Reserved. @@ -28,7 +28,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: if_shmem.c,v 1.53 2013/04/30 00:03:54 pooka Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_shmem.c,v 1.54 2013/05/01 06:58:36 pooka Exp $"); #include <sys/param.h> #include <sys/atomic.h> @@ -135,8 +135,8 @@ shmif_lockbus(struct shmif_mem *busmem) LOCK_UNLOCKED, LOCK_LOCKED) == LOCK_LOCKED)) { if (__predict_false(++i > LOCK_COOLDOWN)) { /* wait 1ms */ - rumpuser_clock_sleep(0, 1000*1000, - RUMPUSER_CLOCK_RELWALL); + rumpuser_clock_sleep(RUMPUSER_CLOCK_RELWALL, + 0, 1000*1000); i = 0; } continue;