From owner-svn-src-head@FreeBSD.ORG Thu Feb 3 20:59:26 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 89E731065675; Thu, 3 Feb 2011 20:59:26 +0000 (UTC) (envelope-from juli@clockworksquid.com) Received: from mail-yx0-f182.google.com (mail-yx0-f182.google.com [209.85.213.182]) by mx1.freebsd.org (Postfix) with ESMTP id 1A6288FC13; Thu, 3 Feb 2011 20:59:25 +0000 (UTC) Received: by yxh35 with SMTP id 35so686963yxh.13 for ; Thu, 03 Feb 2011 12:59:25 -0800 (PST) Received: by 10.151.108.9 with SMTP id k9mr13788084ybm.83.1296766764990; Thu, 03 Feb 2011 12:59:24 -0800 (PST) MIME-Version: 1.0 Sender: juli@clockworksquid.com Received: by 10.150.196.12 with HTTP; Thu, 3 Feb 2011 12:38:24 -0800 (PST) In-Reply-To: <201102031529.25072.jhb@freebsd.org> References: <201102031922.p13JML8i055697@svn.freebsd.org> <201102031529.25072.jhb@freebsd.org> From: Juli Mallett Date: Thu, 3 Feb 2011 12:38:24 -0800 X-Google-Sender-Auth: i2YXzA7I0QwpeblUfzPbDSHrA2k Message-ID: To: John Baldwin Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: svn-src-head@freebsd.org, Randall Stewart , svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r218232 - head/sys/netinet X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 03 Feb 2011 20:59:26 -0000 On Thu, Feb 3, 2011 at 12:29, John Baldwin wrote: >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 ip =3D mtod(m, struct ip *); >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 offset =3D off + sizeof(*sh); >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 if (SCTP_BUF_LEN(m) < offset) { >> @@ -5944,7 +5947,7 @@ sctp_input(struct mbuf *m, int off) >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 ip =3D mtod(m, struct ip *); >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 } >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 sh =3D (struct sctphdr *)((caddr_t)ip + off)= ; >> - =A0 =A0 =A0 =A0 =A0 =A0 cpu_to_use =3D ntohl(sh->v_tag) % mp_ncpus; >> + =A0 =A0 =A0 =A0 =A0 =A0 cpu_to_use =3D ntohl(sh->v_tag) % mp_maxid; > > Hmmm, this is more complicated. =A0 Can sctp_queue_to_mcore() handle the = fact > that a cpu_to_use value might not be valid? =A0If not you might want to m= aintain > a separate "dense" virtual CPU ID table numbered 0 .. mp_ncpus - 1 that m= aps > to "present" FreeBSD CPU IDs. =A0I think Robert has done something simila= r to > support RSS in TCP. =A0Does that make sense? Plus mp_maxid is inclusive, so rrs probably meant (mp_maxid + 1) not mp_maxid in that modulus.