From patchwork Thu Dec 3 11:12:04 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jiri Pirko X-Patchwork-Id: 552180 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 421A81402D2 for ; Thu, 3 Dec 2015 22:14:48 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=resnulli-us.20150623.gappssmtp.com header.i=@resnulli-us.20150623.gappssmtp.com header.b=GcKrw3zX; dkim-atps=neutral Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1759965AbbLCLMm (ORCPT ); Thu, 3 Dec 2015 06:12:42 -0500 Received: from mail-wm0-f50.google.com ([74.125.82.50]:33860 "EHLO mail-wm0-f50.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1759769AbbLCLMk (ORCPT ); Thu, 3 Dec 2015 06:12:40 -0500 Received: by wmvv187 with SMTP id v187so21649016wmv.1 for ; Thu, 03 Dec 2015 03:12:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=resnulli-us.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=jv4/e5BgQFjiQ12sK5RnuzSDQJOgW9RiRDz8YWvR+FQ=; b=GcKrw3zXrJ41N9uovUhK+CFeTokg/TuZaLszh/Sqjz44wFZip7a4SCgHDevoX/q7/L yTL5FpQFXEN5EqPRqkHMY/YfCfID08AerTgn2CHtNCK+YGAiucv28HYO8lw9+rdBKUYZ NHGwsT96cbyW+FzcCr5Zipk3wmsHcjma+MlLNPFckpSyh35U97x33GGE+j4as7PHnRHM 1m06jDTiZ1++fSJgVJn0ULF09wHXAkQcPuimGvVDOixx8aNkEdq9bMOyY6SB9s0kNuOT NNSj/RYSqYkopDrTWhZgTe39bCctC/avTSoNgrNBSy4mDkhiisrc575Mji76Ki423vzu 8TQA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=jv4/e5BgQFjiQ12sK5RnuzSDQJOgW9RiRDz8YWvR+FQ=; b=BFU1g3c36+7jxQXHsHHeM+WKmHmjIHuBwxfJI7cP1kssIe42UPhiNaDoz/M405E3nW 9eOdtUcOfK62jmTzg/0NcECCb3uZtbmwMrnWXee4iL85kHwjnkgZhurxuNK2LXRhCTAW iz53E5EHwdRDJvZKkuu5YN8b2K0urk6wZi64H26ga42vVfokh7OO8Vyb49qj0CwSS5pq x2chPms4KQ8kjPPANwnSuPMu+BTyNI3MaKZHkm3YmBR8DWs6fO+ASUhtro3XZx9l1AW+ 8Wn5Tnr4msWrQNy0WD/9vPCU6rEWt6CE947Capj9d2z9ttcR+jaVpB39/lE0Zz6Vyo11 hNtQ== X-Gm-Message-State: ALoCoQmQ21s1PusrL6iy9jCVOkFDYVWURoU2ydGGkLlb2CK14QNTBgcwZxmVI2+cM0HTlo6jJIFy X-Received: by 10.28.189.5 with SMTP id n5mr12155897wmf.76.1449141159380; Thu, 03 Dec 2015 03:12:39 -0800 (PST) Received: from localhost (ip-94-113-120-24.net.upcbroadband.cz. [94.113.120.24]) by smtp.gmail.com with ESMTPSA id t5sm7459571wmt.1.2015.12.03.03.12.38 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 03 Dec 2015 03:12:38 -0800 (PST) From: Jiri Pirko To: netdev@vger.kernel.org Cc: davem@davemloft.net, idosch@mellanox.com, eladr@mellanox.com, yotamg@mellanox.com, ogerlitz@mellanox.com, j.vosburgh@gmail.com, vfalico@gmail.com, gospo@cumulusnetworks.com, dsa@cumulusnetworks.com, nikolay@cumulusnetworks.com, pjonnala@broadcom.com, f.fainelli@gmail.com, sfeldma@gmail.com, john.fastabend@gmail.com, roopa@cumulusnetworks.com, andrew@lunn.ch Subject: [patch net-next v3 02/28] net: Add support for CHANGEUPPER notifier error injection Date: Thu, 3 Dec 2015 12:12:04 +0100 Message-Id: <1449141150-8172-3-git-send-email-jiri@resnulli.us> X-Mailer: git-send-email 1.9.3 In-Reply-To: <1449141150-8172-1-git-send-email-jiri@resnulli.us> References: <1449141150-8172-1-git-send-email-jiri@resnulli.us> Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org From: Ido Schimmel Since CHANGEUPPER can now fail, add support for it in the newly introduced netdev notifier error injection infrastructure. Signed-off-by: Ido Schimmel Signed-off-by: Jiri Pirko Acked-by: Nikolay Aleksandrov --- v1->v2: -new patch --- Documentation/fault-injection/notifier-error-inject.txt | 1 + lib/netdev-notifier-error-inject.c | 1 + 2 files changed, 2 insertions(+) diff --git a/Documentation/fault-injection/notifier-error-inject.txt b/Documentation/fault-injection/notifier-error-inject.txt index 71e638a..83d3f4e 100644 --- a/Documentation/fault-injection/notifier-error-inject.txt +++ b/Documentation/fault-injection/notifier-error-inject.txt @@ -103,6 +103,7 @@ Netdevice notifier events which can be failed are: * NETDEV_POST_INIT * NETDEV_PRECHANGEMTU * NETDEV_PRECHANGEUPPER + * NETDEV_CHANGEUPPER Example: Inject netdevice mtu change error (-22 == -EINVAL) diff --git a/lib/netdev-notifier-error-inject.c b/lib/netdev-notifier-error-inject.c index b2b8566..13e9c62 100644 --- a/lib/netdev-notifier-error-inject.c +++ b/lib/netdev-notifier-error-inject.c @@ -18,6 +18,7 @@ static struct notifier_err_inject netdev_notifier_err_inject = { { NOTIFIER_ERR_INJECT_ACTION(NETDEV_POST_INIT) }, { NOTIFIER_ERR_INJECT_ACTION(NETDEV_PRECHANGEMTU) }, { NOTIFIER_ERR_INJECT_ACTION(NETDEV_PRECHANGEUPPER) }, + { NOTIFIER_ERR_INJECT_ACTION(NETDEV_CHANGEUPPER) }, {} } };