From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ua0-f195.google.com ([209.85.217.195]:36047 "EHLO mail-ua0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1424959AbeCBOV5 (ORCPT ); Fri, 2 Mar 2018 09:21:57 -0500 Received: by mail-ua0-f195.google.com with SMTP id i15so6144467uak.3 for ; Fri, 02 Mar 2018 06:21:57 -0800 (PST) MIME-Version: 1.0 In-Reply-To: <20180302083756.GE2099@nanopsycho> References: <20180228094507.22354-1-jiri@resnulli.us> <20180228094507.22354-10-jiri@resnulli.us> <20180301194840.79a9a923@cakuba.netronome.com> <20180302083756.GE2099@nanopsycho> From: Alexander Aring Date: Fri, 2 Mar 2018 09:21:56 -0500 Message-ID: Subject: Re: [patch net-next 09/10] net: sch: prio: Add offload ability for grafting a child To: Jiri Pirko Cc: Jakub Kicinski , netdev@vger.kernel.org, nogahf@mellanox.com, yuvalm@mellanox.com, David Miller , idosch@mellanox.com, mlxsw@mellanox.com, Jamal Hadi Salim , Cong Wang , kernel@mojatatu.com Content-Type: text/plain; charset="UTF-8" Sender: netdev-owner@vger.kernel.org List-ID: Hi, On Fri, Mar 2, 2018 at 3:37 AM, Jiri Pirko wrote: > Fri, Mar 02, 2018 at 04:48:40AM CET, kubakici@wp.pl wrote: >>On Thu, 1 Mar 2018 22:38:50 -0500, Alexander Aring wrote: >>> I guess to make extack working, you need to return an errno if failed. >> >>AFAIK extack is printed as a warning if operation did not fail. > > Yes, I checked this and it is printed as warning. ouch, so far I know extack it allows only one messages delivered back to the user space. If we introduce a warning in the successful path here, it could be that in the callpath (after "successful" part of this callback), that somebody else want to add a warning and overwrites actually your warning (even, he is not aware that this warning was set - okay I suppose you can do another check on NULL and set a warning, that somebody overwrites a warning :-D). If extack messages get's append and is some kind of for_each_nested string in netlink -> we have no problem, but I guess this not how it's working. :-/ - Alex