Module Name: src Committed By: ozaki-r Date: Wed Jul 2 07:30:37 UTC 2014
Modified Files: src/sys/net: pktqueue.c Log Message: Restore RPS of pktq_enqueue unless _RUMPKERNEL It's a workaround and would be fixed in rump soon. ok pooka@ To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 src/sys/net/pktqueue.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/net/pktqueue.c diff -u src/sys/net/pktqueue.c:1.6 src/sys/net/pktqueue.c:1.7 --- src/sys/net/pktqueue.c:1.6 Mon Jun 16 00:40:10 2014 +++ src/sys/net/pktqueue.c Wed Jul 2 07:30:37 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: pktqueue.c,v 1.6 2014/06/16 00:40:10 ozaki-r Exp $ */ +/* $NetBSD: pktqueue.c,v 1.7 2014/07/02 07:30:37 ozaki-r Exp $ */ /*- * Copyright (c) 2014 The NetBSD Foundation, Inc. @@ -36,7 +36,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: pktqueue.c,v 1.6 2014/06/16 00:40:10 ozaki-r Exp $"); +__KERNEL_RCSID(0, "$NetBSD: pktqueue.c,v 1.7 2014/07/02 07:30:37 ozaki-r Exp $"); #include <sys/param.h> #include <sys/types.h> @@ -208,7 +208,11 @@ pktq_rps_hash(const struct mbuf *m __unu bool pktq_enqueue(pktqueue_t *pq, struct mbuf *m, const u_int hash __unused) { - const unsigned cpuid = curcpu()->ci_index /* hash % ncpu */; +#ifdef _RUMPKERNEL + const unsigned cpuid = curcpu()->ci_index; +#else + const unsigned cpuid = hash % ncpu; +#endif KASSERT(kpreempt_disabled());