From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.0 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5EB25C433ED for ; Wed, 21 Apr 2021 17:30:23 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 3693C61458 for ; Wed, 21 Apr 2021 17:30:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242135AbhDURaz (ORCPT ); Wed, 21 Apr 2021 13:30:55 -0400 Received: from mail.kernel.org ([198.145.29.99]:49364 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244743AbhDURaq (ORCPT ); Wed, 21 Apr 2021 13:30:46 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 394BB61459; Wed, 21 Apr 2021 17:30:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1619026213; bh=fd/ea915xSYvil7Pc9vQEzTo9L1LbRcNFel261FtMlM=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=JkU8I5KkoNG2AiPM8roRsNgbaw9mufrgvrLZ0JN1PggvGlWQGo/5keO+Y+SnfWY+8 WEROCK+OXl7iUHa1wzYTx9hpdPn05DiTIv7FQE2BdOyhAOnrQvhXTesIMVb/Ymn+8r e9JGH1JGgjS6pqetCKtvedCds5oK0IR5PVjraeM0ab54Eh3w0MzycCA0gcoFMVojdn 9OfkNjJKRuGOuQi1LgqIlw6ZnLtUqrrcd6J7xMQvFoXVWsl9qNnVgd9osbRabxX8Sm qONRWeaT2utJBkNJSoDbxdZADYRW5xYdyTXaXRKQtMQQFrPxCbkVyfTpt5z0c3upRc FZAvCjuwDtgZA== Date: Wed, 21 Apr 2021 10:30:12 -0700 From: Jakub Kicinski To: Sunil Kovvuri Cc: Linux Netdev List , Andrew Lunn , Sunil Goutham Subject: Re: How to toggle physical link via ethtool Message-ID: <20210421103012.45a3a64a@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On Wed, 21 Apr 2021 18:12:16 +0530 Sunil Kovvuri wrote: > Hi, > > Have a query on how to bring down physical link (serdes) for a NIC interface. > > I am under assumption that for a SR-IOV NIC, when user executes > "ifconfig eth-pf down", > it should not bring down physical link as there could be virtual > interfaces still active. > Let me know if this assumption itself is wrong. How VFs operate is really implementation specific, so it'd be interesting to hear from the vendors but IIUC bringing PF down should shut down the link. What usually keeps the link up is stuff like NC-SI, but not VFs. > If the assumption is correct and if user wants to intentionally bring > down physical link for > whatever reasons, then I do not see a way to do this. There are no > commands either in > 'ethtool' or 'ip link' to achieve this. > > Would it be okay to add a ethtool command similar to 'ethtool > --identify" to toggle physical link.