Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp3295776pxk; Tue, 15 Sep 2020 15:43:08 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyFvOD1H2lHSiPMy4pMKvaK3jhaLJp6mHLPr071J8HGSU2YqSxNi3QalT9nXRWhamyHQUL/ X-Received: by 2002:a17:907:685:: with SMTP id wn5mr14495423ejb.285.1600209787817; Tue, 15 Sep 2020 15:43:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600209787; cv=none; d=google.com; s=arc-20160816; b=tx5Ao44Ta+Gf2f0adkOqOArzEcV8OGYW3VBYqGe1lcLALD/p2IzqG28S91THfdEioU l3N/WMdAkxs6Kg903AXCkpww4b9hThXvBxBypL9OMYJxiU9aB1yHVgv/TULAXl8lBn48 vtFeMasOI8Ribj25ZbJkOnf6Xygt0JeWg1esqK9MZDpbI4YBwaCZ4GlUxFFFDntTUBPw 5jZNzw4SHibyZ0F59Lzacetdd4wkj1+Q2PgOSPV3OrWo7j36wi+q2Y54sYGJgMNh+GS5 zMcuHP2BR+BRM/4lAqBN5HDh/klDGnLpK8P/wm0m9aeUTLghHRRw9QaV2rHZdB+dQo6Y qgkw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=hwJhky1w1aa986KKGyQQec8VEiyzTJiJkp5IR2AD9rM=; b=sX1x3Lyq3wzdxI0uIaSqmlGCk3TnOH3YqmSzeXBMUISOAY7B6GUkdMM5Bq2I5d5OsH hL3PtD7YoJa03N5dtyKlmA+04f29zvvP3K9DkVPs9uoTD+mDQpQH3VvsS4J8FX/zsMB6 ZMCgL2NETzh1VT/lFJZr3+iejPMkqzB/LL7h2RAJVUmprWrBqbpwEV6ynQroslp37ez+ dBPHa496Aa3lqHC3eWRP6oOkA7pDMf+TdBbiEqn+sf93SJpCU7Iehqze/iIl9ylHKOib +UTjHa/tGIePDX2ldJTinxmL9aDdw3j84Kw57tNbN2t0aSoehccopOJE698tSSoltZHD ugwg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=pQX3ujv7; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v6si10385887edt.456.2020.09.15.15.42.45; Tue, 15 Sep 2020 15:43:07 -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=@kernel.org header.s=default header.b=pQX3ujv7; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727695AbgIOWkG (ORCPT + 99 others); Tue, 15 Sep 2020 18:40:06 -0400 Received: from mail.kernel.org ([198.145.29.99]:56570 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727498AbgIOQKm (ORCPT ); Tue, 15 Sep 2020 12:10:42 -0400 Received: from kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com (unknown [163.114.132.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id C82522074B; Tue, 15 Sep 2020 16:00:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1600185615; bh=HcglYP6i3X/ou3K6aehXVB4kBv5QYxbOuM6aUd5L0tk=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=pQX3ujv7wFa/f3nVynTuYqqaEGWbi5SRTW5Q6IxlmLmQERlv2kVDYsZG0RqjcRwac CDiJKaQRcDC21gYI7x5rlK6pwVXEq72zpOUdxsraJykwYjg9pIb9DxLaf8nFMddW51 r977PG7SW0gEVpEHw8KsdASYmX+YWpSjyAj7c+Zw= Date: Tue, 15 Sep 2020 09:00:13 -0700 From: Jakub Kicinski To: Moshe Shemesh Cc: Moshe Shemesh , "David S. Miller" , Jiri Pirko , , Subject: Re: [PATCH net-next RFC v4 01/15] devlink: Add reload action option to devlink reload command Message-ID: <20200915090013.141163e8@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> In-Reply-To: <777fd1b8-1262-160e-a711-31e5f6e2c37c@nvidia.com> References: <1600063682-17313-1-git-send-email-moshe@mellanox.com> <1600063682-17313-2-git-send-email-moshe@mellanox.com> <20200914143306.4ab0f4c1@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> <777fd1b8-1262-160e-a711-31e5f6e2c37c@nvidia.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 15 Sep 2020 15:56:48 +0300 Moshe Shemesh wrote: > On 9/15/2020 12:33 AM, Jakub Kicinski wrote: > >> + if (err) > >> + return err; > >> + > >> + WARN_ON(!actions_performed); > >> + msg = nlmsg_new(NLMSG_DEFAULT_SIZE, GFP_KERNEL); > >> + if (!msg) > >> + return -ENOMEM; > >> + > >> + err = devlink_nl_reload_actions_performed_fill(msg, devlink, actions_performed, > >> + DEVLINK_CMD_RELOAD, info->snd_portid, > >> + info->snd_seq, 0); > >> + if (err) { > >> + nlmsg_free(msg); > >> + return err; > >> + } > >> + > >> + return genlmsg_reply(msg, info); > > I think generating the reply may break existing users. Only generate > > the reply if request contained DEVLINK_ATTR_RELOAD_ACTION (or any other > > new attribute which existing users can't pass). > > OK, I can do that. But I update stats and generate devlink notification > anyway, that should fine, right ? Yes, that should be fine.