Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp538167pxu; Wed, 7 Oct 2020 09:21:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzocOQF+6P1myONS/WyEZ+SuYb+8zof6l+ZoUt/ZLTwPCDur6NNeYrMtmt+5A0Mr+BJvhBL X-Received: by 2002:a17:906:3a0e:: with SMTP id z14mr4055053eje.192.1602087711520; Wed, 07 Oct 2020 09:21:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1602087711; cv=none; d=google.com; s=arc-20160816; b=Ny9ejrZKi5I434MdHe7AP2jJbzVohWh/oYXYexTcZ3YvjmKNNGl6sHyE8oU4EdxAot JHxxLyVM9zeVMkRKXsnrXEFAA2a4aiLhLMFvmeUGireJm63C0za2pZgflS7KXYiRME5b VyTtxNTmP7Qg6WLIwFDO7Si8OTbHRQ3sdwINiLXgd6OvFqvnHR/d2p+L16ceY9CGITXN Vgc1BhbD4SMWqrfo5qD4gL2Fo5SWtHgi97El/uwUYsZ1Z5s1/soHYlVBYkZZlxVcxstk ged02lEZB8H5IAix+epf9PyUkVfkIjhIChHt2HoKcTEccvpDozXmsU5mLfmLFRCLJ/L2 uTXw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=c+qu2p5G8BrkuES5RNsE8tqXhcZ9P1cBpxl6wwrb658=; b=t+ZCNAxiv1/HMEgYfZkYXctZvEYd5LwU5sgX4Qc2DFcOyqfTWml5GpNzCemRSqOBJU 2RPvXeNlALJWvzbOKEPzNiZ+SrCToFO85kyyez1cHYsndmpNVub+Nx54pCbSvlKE5UKZ hVJEvsxo07Pnle78q3TLd1iRgo0eyuvSc969IvHzMLoFlWOTvvtMwvUyiSgYdLozHb0X KMaZ+14tzih7dEb3GckvNj01ZApliQDS5Wv2mYeMTwCdZQQe6WPQCp332rso8a6t0k6b tctgC7WEnHmCtdraaix7VC4BMn2voLvNjGcdmhLVynMsL7V9wZy4jz30YvJ0GvREKsXH /9TQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@resnulli-us.20150623.gappssmtp.com header.s=20150623 header.b=AN0kvfw6; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id gx5si1778396ejb.393.2020.10.07.09.21.28; Wed, 07 Oct 2020 09:21:51 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@resnulli-us.20150623.gappssmtp.com header.s=20150623 header.b=AN0kvfw6; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728954AbgJGQCD (ORCPT + 99 others); Wed, 7 Oct 2020 12:02:03 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46090 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728289AbgJGQCD (ORCPT ); Wed, 7 Oct 2020 12:02:03 -0400 Received: from mail-wm1-x341.google.com (mail-wm1-x341.google.com [IPv6:2a00:1450:4864:20::341]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D9992C061755 for ; Wed, 7 Oct 2020 09:02:02 -0700 (PDT) Received: by mail-wm1-x341.google.com with SMTP id k18so2969078wmj.5 for ; Wed, 07 Oct 2020 09:02:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=resnulli-us.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=c+qu2p5G8BrkuES5RNsE8tqXhcZ9P1cBpxl6wwrb658=; b=AN0kvfw6vjQ/xf8qVvgSneIvf64UvUcIPMnSoX/UZin+GOgkWJUZmM/J9cT7wqG48p 97+DkF+lsLzXY08L5pO6ukFQVxVgOxKrj3maEw2EE6uM8SRXyjY+rRZhJwj4qxBcuE2T R+OrhBSuLSz3tx2KuTOoyTeDmcyEPv5+CAXefGDKYoBQbniQftqrENGWhBNXeivZtF2Y nUCYieRv8axTO9IeC4A2eDckuHqLwVOs44E2vqm9LAamg/bJXPORnDHqXJcJDNuSPJte wZ6G5TKdw8umeHlH9EfrY4pIqYAg6QQo9fEIsWSpaYhW9UuJHYsnQ+rIAGaAVekpZEg+ SBAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=c+qu2p5G8BrkuES5RNsE8tqXhcZ9P1cBpxl6wwrb658=; b=A0tNQq4d9pJ2Q7FzRPu19tYMNLzT4MmM1pbFMCre0BzTzAd0lN5gsjoMRuaa0UjPQW YMdNi/mq0k40rMSsv5bCZaebFFxIy4pvI52hUJQ610cUa+BLBA8MyvgulXH6tQUxJ6R6 peioZ8OVvaqxvyj1NOGd+dxm5Cppq1Cew22ALSRtjRAbEo1xcJw0SoPU1uBf7O7giBKK Q5ULkEg3jhxO1CYiFJVtmB9C9HC0RKnuuFSxJ+qZKpo5aByn/i5Ofzx7s1j8V+F2nyLi Oyq6uQSOjz5PDYyzQvPrg76BdwP6NPKQw1xi/NN9rZBB+RcUYFMLAzcAeaolHz4AK1ZU C9Rg== X-Gm-Message-State: AOAM533gQSW6O2YjCCAep5Q+bjlX3pQ+zTFlutKMrUxPlcgyScQ26RdZ scmHJXCy50VTpdLu5rRnt16yCA== X-Received: by 2002:a1c:6488:: with SMTP id y130mr3978568wmb.94.1602086521044; Wed, 07 Oct 2020 09:02:01 -0700 (PDT) Received: from localhost ([86.61.181.4]) by smtp.gmail.com with ESMTPSA id j13sm3520769wru.86.2020.10.07.09.02.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Oct 2020 09:02:00 -0700 (PDT) Date: Wed, 7 Oct 2020 18:01:59 +0200 From: Jiri Pirko To: Moshe Shemesh Cc: "David S. Miller" , Jakub Kicinski , Jiri Pirko , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH net-next v2 05/16] devlink: Add remote reload stats Message-ID: <20201007160159.GD3064@nanopsycho> References: <1602050457-21700-1-git-send-email-moshe@mellanox.com> <1602050457-21700-6-git-send-email-moshe@mellanox.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1602050457-21700-6-git-send-email-moshe@mellanox.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Wed, Oct 07, 2020 at 08:00:46AM CEST, moshe@mellanox.com wrote: >Add remote reload stats to hold the history of actions performed due >devlink reload commands initiated by remote host. For example, in case >firmware activation with reset finished successfully but was initiated >by remote host. > >The function devlink_remote_reload_actions_performed() is exported to >enable drivers update on remote reload actions performed as it was not >initiated by their own devlink instance. > >Expose devlink remote reload stats to the user through devlink dev get >command. > >Examples: >$ devlink dev show >pci/0000:82:00.0: > stats: > reload: > driver_reinit 2 fw_activate 1 fw_activate_no_reset 0 > remote_reload: > driver_reinit 0 fw_activate 0 fw_activate_no_reset 0 >pci/0000:82:00.1: > stats: > reload: > driver_reinit 1 fw_activate 0 fw_activate_no_reset 0 > remote_reload: > driver_reinit 1 fw_activate 1 fw_activate_no_reset 0 > >$ devlink dev show -jp >{ > "dev": { > "pci/0000:82:00.0": { > "stats": { > "reload": { > "driver_reinit": 2, > "fw_activate": 1, > "fw_activate_no_reset": 0 > }, > "remote_reload": { > "driver_reinit": 0, > "fw_activate": 0, > "fw_activate_no_reset": 0 > } > } > }, > "pci/0000:82:00.1": { > "stats": { > "reload": { > "driver_reinit": 1, > "fw_activate": 0, > "fw_activate_no_reset": 0 > }, > "remote_reload": { > "driver_reinit": 1, > "fw_activate": 1, > "fw_activate_no_reset": 0 > } > } > } > } >} > >Signed-off-by: Moshe Shemesh >Reviewed-by: Jakub Kicinski Reviewed-by: Jiri Pirko