From patchwork Thu Jul 7 13:55:41 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shmulik Ravid X-Patchwork-Id: 103645 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 CCD03B6F18 for ; Thu, 7 Jul 2011 22:07:24 +1000 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755981Ab1GGMHU (ORCPT ); Thu, 7 Jul 2011 08:07:20 -0400 Received: from mms2.broadcom.com ([216.31.210.18]:2576 "EHLO mms2.broadcom.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755675Ab1GGMHT (ORCPT ); Thu, 7 Jul 2011 08:07:19 -0400 Received: from [10.9.200.133] by mms2.broadcom.com with ESMTP (Broadcom SMTP Relay (Email Firewall v6.3.2)); Thu, 07 Jul 2011 05:11:50 -0700 X-Server-Uuid: D3C04415-6FA8-4F2C-93C1-920E106A2031 Received: from mail-irva-13.broadcom.com (10.11.16.103) by IRVEXCHHUB02.corp.ad.broadcom.com (10.9.200.133) with Microsoft SMTP Server id 8.2.247.2; Thu, 7 Jul 2011 05:06:53 -0700 Received: from [10.185.7.69] (lb-tlvb-shmulik.il.broadcom.com [10.185.7.69]) by mail-irva-13.broadcom.com (Postfix) with ESMTP id E342874D0F; Thu, 7 Jul 2011 05:06:59 -0700 (PDT) Subject: [PATCH net next] bnx2x: Add dcbnl notification From: "Shmulik Ravid" To: davem@davemloft.net cc: "Eilon Greenstein" , netdev@vger.kernel.org Organization: Broadcom Date: Thu, 7 Jul 2011 16:55:41 +0300 Message-ID: <1310046941.22577.20.camel@lb-tlvb-shmulik.il.broadcom.com> MIME-Version: 1.0 X-Mailer: Evolution 2.12.3 (2.12.3-8.el5_2.3) X-WSS-ID: 620B7D0C62O20718102-01-01 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org This patch adds a dcbnl notification to the bnx2x. The notification is sent to user mode clients following a change in the dcb negotiated parameters as resolved by the embedded DCBX stack. Signed-off-by: Shmulik Ravid Signed-off-by: Eilon Greenstein --- drivers/net/bnx2x/bnx2x_dcb.c | 12 +++++++++--- 1 files changed, 9 insertions(+), 3 deletions(-) diff --git a/drivers/net/bnx2x/bnx2x_dcb.c b/drivers/net/bnx2x/bnx2x_dcb.c index b51a759..45cf3ce 100644 --- a/drivers/net/bnx2x/bnx2x_dcb.c +++ b/drivers/net/bnx2x/bnx2x_dcb.c @@ -19,14 +19,14 @@ #include #include #include -#ifdef BCM_DCBNL -#include -#endif #include "bnx2x.h" #include "bnx2x_cmn.h" #include "bnx2x_dcb.h" +#ifdef BCM_DCBNL +#include +#endif /* forward declarations of dcbx related functions */ static void bnx2x_dcbx_stop_hw_tx(struct bnx2x *bp); @@ -702,6 +702,12 @@ void bnx2x_dcbx_set_params(struct bnx2x *bp, u32 state) case BNX2X_DCBX_STATE_TX_RELEASED: DP(NETIF_MSG_LINK, "BNX2X_DCBX_STATE_TX_RELEASED\n"); bnx2x_fw_command(bp, DRV_MSG_CODE_DCBX_PMF_DRV_OK, 0); +#ifdef BCM_DCBNL + /** + * Send a notification for the new negotiated parameters + */ + dcbnl_cee_notify(bp->dev, RTM_GETDCB, DCB_CMD_CEE_GET, 0, 0); +#endif return; default: BNX2X_ERR("Unknown DCBX_STATE\n");