From patchwork Tue Mar 10 02:15:05 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jakub Kicinski X-Patchwork-Id: 222787 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=-10.1 required=3.0 tests=DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT 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 EAFE6C10F25 for ; Tue, 10 Mar 2020 02:15:49 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id B49482146E for ; Tue, 10 Mar 2020 02:15:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1583806549; bh=yM975sCXfhKdsrwOu9EN7k4m+pjnXh80jfuWr3lwQ2A=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=OzEF2GLOuqzr20XHC4Kwz+VJyp3iwcj7w3RjSwRLQakdV8UoTTSLGl8vxpEdUCT4p eKVSA4YXUH7NvdjzjfFIFMdNSUMYnaCd1vHCc9s7WH8/IyHiGBdTgGJy8I1m+PwLCK s28HciI0KViwzFlgU8JeTk00EOCiNKj3L2iMxqkc= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726982AbgCJCPs (ORCPT ); Mon, 9 Mar 2020 22:15:48 -0400 Received: from mail.kernel.org ([198.145.29.99]:35696 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726766AbgCJCP0 (ORCPT ); Mon, 9 Mar 2020 22:15:26 -0400 Received: from kicinski-fedora-PC1C0HJN.thefacebook.com (unknown [163.114.132.128]) (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 A48F524671; Tue, 10 Mar 2020 02:15:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1583806525; bh=yM975sCXfhKdsrwOu9EN7k4m+pjnXh80jfuWr3lwQ2A=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=KmaHVq86KnkNET+lKOiKvwlW3fXagd7gTo9Mbkq/r6yzFep7zs5Tr6bzK4iwawqdX c0eFgVLGbiiiXn7hdJT9J4Ywk0uhl3AJqDDt1ghKOFNyT2ES1mRGP3ZvNu1GXqv7sN VSqfim/QauKbzN5XWYRk/cmSazGz/eml09JAX5iA= From: Jakub Kicinski To: davem@davemloft.net Cc: netdev@vger.kernel.org, akiyano@amazon.com, netanel@amazon.com, gtzalik@amazon.com, irusskikh@marvell.com, f.fainelli@gmail.com, bcm-kernel-feedback-list@broadcom.com, rmody@marvell.com, GR-Linux-NIC-Dev@marvell.com, aelior@marvell.com, skalluru@marvell.com, GR-everest-linux-l2@marvell.com, opendmb@gmail.com, siva.kallam@broadcom.com, prashant@broadcom.com, mchan@broadcom.com, dchickles@marvell.com, sburla@marvell.com, fmanlunas@marvell.com, tariqt@mellanox.com, vishal@chelsio.com, leedom@chelsio.com, ulli.kroll@googlemail.com, linus.walleij@linaro.org, Jakub Kicinski Subject: [PATCH net-next 08/15] net: bna: reject unsupported coalescing params Date: Mon, 9 Mar 2020 19:15:05 -0700 Message-Id: <20200310021512.1861626-9-kuba@kernel.org> X-Mailer: git-send-email 2.24.1 In-Reply-To: <20200310021512.1861626-1-kuba@kernel.org> References: <20200310021512.1861626-1-kuba@kernel.org> MIME-Version: 1.0 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Set ethtool_ops->supported_coalesce_params to let the core reject unsupported coalescing parameters. This driver did not previously reject unsupported parameters. Signed-off-by: Jakub Kicinski --- drivers/net/ethernet/brocade/bna/bnad_ethtool.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/net/ethernet/brocade/bna/bnad_ethtool.c b/drivers/net/ethernet/brocade/bna/bnad_ethtool.c index 505e9c6d74a6..588c4804d10a 100644 --- a/drivers/net/ethernet/brocade/bna/bnad_ethtool.c +++ b/drivers/net/ethernet/brocade/bna/bnad_ethtool.c @@ -1115,6 +1115,9 @@ bnad_flash_device(struct net_device *netdev, struct ethtool_flash *eflash) } static const struct ethtool_ops bnad_ethtool_ops = { + .supported_coalesce_params = ETHTOOL_COALESCE_USECS | + ETHTOOL_COALESCE_TX_MAX_FRAMES | + ETHTOOL_COALESCE_USE_ADAPTIVE_RX, .get_drvinfo = bnad_get_drvinfo, .get_wol = bnad_get_wol, .get_link = ethtool_op_get_link,