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=-9.1 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=ham 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 3499BC47095 for ; Sun, 4 Oct 2020 06:31:07 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id CF4E0206C3 for ; Sun, 4 Oct 2020 06:31:06 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=nvidia.com header.i=@nvidia.com header.b="qoivaNDR" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725862AbgJDGbF (ORCPT ); Sun, 4 Oct 2020 02:31:05 -0400 Received: from hqnvemgate26.nvidia.com ([216.228.121.65]:11143 "EHLO hqnvemgate26.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725819AbgJDGbE (ORCPT ); Sun, 4 Oct 2020 02:31:04 -0400 Received: from hqmail.nvidia.com (Not Verified[216.228.121.13]) by hqnvemgate26.nvidia.com (using TLS: TLSv1.2, AES256-SHA) id ; Sat, 03 Oct 2020 23:30:51 -0700 Received: from [10.21.180.76] (10.124.1.5) by HQMAIL107.nvidia.com (172.20.187.13) with Microsoft SMTP Server (TLS) id 15.0.1473.3; Sun, 4 Oct 2020 06:30:51 +0000 Subject: Re: [PATCH net-next 02/16] devlink: Add reload action option to devlink reload command To: Jiri Pirko , Moshe Shemesh CC: "David S. Miller" , Jakub Kicinski , Jiri Pirko , , References: <1601560759-11030-1-git-send-email-moshe@mellanox.com> <1601560759-11030-3-git-send-email-moshe@mellanox.com> <20201002151943.GB3159@nanopsycho.orion> From: Moshe Shemesh Message-ID: <44621685-5356-c0c2-2947-15013b8f6d13@nvidia.com> Date: Sun, 4 Oct 2020 09:30:48 +0300 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.12.0 MIME-Version: 1.0 In-Reply-To: <20201002151943.GB3159@nanopsycho.orion> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US X-Originating-IP: [10.124.1.5] X-ClientProxiedBy: HQMAIL105.nvidia.com (172.20.187.12) To HQMAIL107.nvidia.com (172.20.187.13) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nvidia.com; s=n1; t=1601793051; bh=uu0CTyBqLF7KdJxyDrjGKEkyAj9kchNDjZPnpEmUIik=; h=Subject:To:CC:References:From:Message-ID:Date:User-Agent: MIME-Version:In-Reply-To:Content-Type:Content-Transfer-Encoding: Content-Language:X-Originating-IP:X-ClientProxiedBy; b=qoivaNDR67uZoGdfMvfOwhmLbAkBL2Fop3XS/Gs2ixEh29/8PQtRE/TRGEWrPPKhP HW5EAU/2foUDWZjrHai+ZdNqyaT4kxnPG4pH5ZAI6Gs47Rg04ALFslApdIMqW3sU8s 9gdi7aiN0qdtH/zlnoUE9XTWupiPT+f/x+STu8i+mVZTdwBYQOPMq54I+xmqXf2m0G 7Sl3KuZ5uhVEXnw7vdqSd9gVlNXUBFN/TTmEVEzyxtKcBpoNNGDB78/fAlPNsYxhSB t4BnVZLhFdf/wuzAIEyE1gZ1FYtFsPINgM7FLh3rAw7dQc/WaA42GBEH59jzQTK596 cRZqc/i4hPFQw== Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/2/2020 6:19 PM, Jiri Pirko wrote: > Thu, Oct 01, 2020 at 03:59:05PM CEST, moshe@mellanox.com wrote: > > [...] > > >> diff --git a/include/net/devlink.h b/include/net/devlink.h >> index 1c286e9a3590..ddba63bce7ad 100644 >> --- a/include/net/devlink.h >> +++ b/include/net/devlink.h >> @@ -1077,10 +1077,11 @@ struct devlink_ops { >> * implemementation. >> */ >> u32 supported_flash_update_params; >> + unsigned long reload_actions; >> int (*reload_down)(struct devlink *devlink, bool netns_change, >> - struct netlink_ext_ack *extack); >> - int (*reload_up)(struct devlink *devlink, >> - struct netlink_ext_ack *extack); >> + enum devlink_reload_action action, struct netlink_ext_ack *extack); >> + int (*reload_up)(struct devlink *devlink, enum devlink_reload_action action, >> + struct netlink_ext_ack *extack, unsigned long *actions_performed); > Nit. Could you please push extack to be the last arg here? It is common > to have extack as the last arg + action and actions_performed are going > to be side by side. Sure. > Otherwise the patch looks fine. > Reviewed-by: Jiri Pirko