From owner-freebsd-net@freebsd.org Thu Oct 1 17:57:04 2020 Return-Path: Delivered-To: freebsd-net@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 01E9042F688 for ; Thu, 1 Oct 2020 17:57:04 +0000 (UTC) (envelope-from olivier@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4C2LRg6JWCz4Swq for ; Thu, 1 Oct 2020 17:57:03 +0000 (UTC) (envelope-from olivier@freebsd.org) Received: from mail-qt1-f180.google.com (mail-qt1-f180.google.com [209.85.160.180]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) (Authenticated sender: olivier/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id B3DCF17044 for ; Thu, 1 Oct 2020 17:57:03 +0000 (UTC) (envelope-from olivier@freebsd.org) Received: by mail-qt1-f180.google.com with SMTP id y11so5293373qtn.9 for ; Thu, 01 Oct 2020 10:57:03 -0700 (PDT) X-Gm-Message-State: AOAM5310veVsaDV9zhM2R3W41EO4yjOAq4Vi2h+JoFTdtuhZj2zKtWxG dXQVoQ/IX3R8n4/79Jzv2SvZYyngBzNTn6D2CbA= X-Google-Smtp-Source: ABdhPJzCQMfe/tgd68atY+nq7hCy+/E4oB4/cc03rO5c/X3fWeRW433nQ7h+uQcB0USUDsSPgsyGnzXxGFLVnMzO2v4= X-Received: by 2002:aed:3edd:: with SMTP id o29mr8654932qtf.214.1601575023290; Thu, 01 Oct 2020 10:57:03 -0700 (PDT) MIME-Version: 1.0 References: <0aa09fcc-dfcc-005e-8834-2a758ba6a03f@microwave.sk> <94978a05-94c6-cc55-229c-5a3c5352b29a@selasky.org> <3c64095f-8a45-0fb4-4835-7486bbd84663@microwave.sk> <32dbe3be-4b0a-6a94-d368-c5943d688bc6@selasky.org> In-Reply-To: <32dbe3be-4b0a-6a94-d368-c5943d688bc6@selasky.org> From: =?UTF-8?Q?Olivier_Cochard=2DLabb=C3=A9?= Date: Thu, 1 Oct 2020 19:56:51 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: mlx5 irq To: Hans Petter Selasky Cc: =?UTF-8?Q?Michal_Van=C4=8Do?= , freebsd-net@freebsd.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.33 X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 01 Oct 2020 17:57:04 -0000 On Thu, Oct 1, 2020 at 12:28 PM Hans Petter Selasky wrote= : > On 2020-10-01 11:13, Michal Van=C4=8Do via freebsd-net wrote: > > On 01/10/2020 10:52, Hans Petter Selasky wrote: > >> On 2020-10-01 10:24, Michal Van=C4=8Do wrote: > >>> But why is the actual number of IRQ lines bigger than number of CPU > >>> cores? > >> > >> There are some dedicated IRQ's used for firmware management. > >> > >> Else the driver will use the number of online CPU's by default as the > >> number of rings, if the hardware supports it. > > > > Thanks for clarification. Is there any way to optimize this? In my case > > I have 2 CPU sockets with 8 cores each (SMT is disabled). NIC is > > connected via PCIe to the first CPU socket (numa domain 0). In this > > case, wouldn't it be better if all interrupts were firing only on cores > > of first socket? > > > > Hi, > > You can use "cpuset" to bind those IRQ threads to the right core. > > > You could try this RC script to bind them: https://github.com/ocochard/BSDRP/blob/master/BSDRP/Files/usr/local/etc/rc.= d/mlx5en_affinity Regards, Olivier