History log of /linux-master/drivers/net/ethernet/chelsio/cxgb4/cxgb4_dcb.c
Revision Date Author Comments
# 36884330 30-Jun-2022 Li kunyu <kunyu@nfschina.com>

cxgb4: Fix typo in string

Remove the repeated ',' from string

Signed-off-by: Li kunyu <kunyu@nfschina.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# 4fa9c49f 29-May-2019 Thomas Gleixner <tglx@linutronix.de>

treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 291

Based on 2 normalized pattern(s):

this program is free software you can redistribute it and or modify
it under the terms and conditions of the gnu general public license
version 2 as published by the free software foundation this program
is distributed in the hope it will be useful but without any
warranty without even the implied warranty of merchantability or
fitness for a particular purpose see the gnu general public license
for more details the full gnu general public license is included in
this distribution in the file called copying

this program is free software you can redistribute it and or modify
it under the terms and conditions of the gnu general public license
version 2 as published by the free software foundation this program
is distributed in the hope [that] it will be useful but without any
warranty without even the implied warranty of merchantability or
fitness for a particular purpose see the gnu general public license
for more details the full gnu general public license is included in
this distribution in the file called copying

extracted by the scancode license scanner the SPDX license identifier

GPL-2.0-only

has been chosen to replace the boilerplate/reference in 57 file(s).

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Alexios Zavras <alexios.zavras@intel.com>
Reviewed-by: Allison Randal <allison@lohutok.net>
Cc: linux-spdx@vger.kernel.org
Link: https://lkml.kernel.org/r/20190529141901.515993066@linutronix.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# 3b0b8f0d 30-Sep-2018 Nathan Chancellor <nathan@kernel.org>

cxgb4: Use proper enum in cxgb4_dcb_handle_fw_update

Clang warns when one enumerated type is implicitly converted to another.

drivers/net/ethernet/chelsio/cxgb4/cxgb4_dcb.c:303:7: warning: implicit
conversion from enumeration type 'enum cxgb4_dcb_state' to different
enumeration type 'enum cxgb4_dcb_state_input' [-Wenum-conversion]
? CXGB4_DCB_STATE_FW_ALLSYNCED
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/chelsio/cxgb4/cxgb4_dcb.c:304:7: warning: implicit
conversion from enumeration type 'enum cxgb4_dcb_state' to different
enumeration type 'enum cxgb4_dcb_state_input' [-Wenum-conversion]
: CXGB4_DCB_STATE_FW_INCOMPLETE);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2 warnings generated.

Use the equivalent value of the expected type to silence Clang while
resulting in no functional change.

CXGB4_DCB_STATE_FW_INCOMPLETE = CXGB4_DCB_INPUT_FW_INCOMPLETE = 2
CXGB4_DCB_STATE_FW_ALLSYNCED = CXGB4_DCB_INPUT_FW_ALLSYNCED = 3

Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
Reviewed-by: Nick Desaulniers <ndesaulniers@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# c3ec8bcc 14-Sep-2018 Ganesh Goudar <ganeshgr@chelsio.com>

cxgb4: update supported DCB version

- In CXGB4_DCB_STATE_FW_INCOMPLETE state check if the dcb
version is changed and update the dcb supported version.

- Also, fill the priority code point value for priority
based flow control.

Signed-off-by: Ganesh Goudar <ganeshgr@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# ebddd97a 10-Aug-2018 Ganesh Goudar <ganeshgr@chelsio.com>

cxgb4: add support to display DCB info

display Data Center bridging information in debug
fs.

Signed-off-by: Casey Leedom <leedom@chelsio.com>
Signed-off-by: Ganesh Goudar <ganeshgr@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# ba581f77 23-Sep-2017 Ganesh Goudar <ganeshgr@chelsio.com>

cxgb4: do DCB state reset in couple of places

reset the driver's DCB state in couple of places
where it was missing.

Signed-off-by: Casey Leedom <leedom@chelsio.com>
Signed-off-by: Ganesh Goudar <ganeshgr@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# 134491fd 26-Apr-2016 Hariprasad Shenai <hariprasad@chelsio.com>

cxgb4: DCB message handler needs to use correct portid to netdev mapping

Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# 8d6541b7 17-Jul-2015 Anish Bhatt <anish@chelsio.com>

cxgb4 : Fill in number of DCB traffic classes supported

Signed-off-by: Anish Bhatt <anish@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# a85c2eb3 17-Jul-2015 Anish Bhatt <anish@chelsio.com>

cxgb4 : Allow firmware DCB info to be queried in host state

Since finally DCB traffic management is still handled by firmware,
allow firmware to be fully programmed and queried even in host
managed state for the cases where this was previously rejected.

Signed-off-by: Anish Bhatt <anish@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# a44e7b73 17-Jul-2015 Anish Bhatt <anish@chelsio.com>

cxgb4 : Only pass app selector of 0 or 3 to firmware

This keeps app format passed to firmware the same irrespective
of DCBx version in use.

Signed-off-by: Anish Bhatt <anish@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# 4a95b6d0 05-Feb-2015 Lad, Prabhakar <prabhakar.csengg@gmail.com>

chelsio: cxgb4: fix sparse warning

this patch fixes following sparse warning:

cxgb4_dcb.c:25:6: warning: symbol 'dcb_ver_array' was not declared. Should it be static?

Alongside making it const.

Signed-off-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# ba0c39cb 30-Jan-2015 Anish Bhatt <anish@chelsio.com>

cxgb4 : Improve IEEE DCBx support, other minor open-lldp fixes

* Add support for IEEE ets & pfc api.
* Fix bug that resulted in incorrect bandwidth percentage being returned for
CEE peers
* Convert pfc enabled info from firmware format to what dcbnl expects before
returning

Signed-off-by: Anish Bhatt <anish@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# 2b5fb1f2 20-Nov-2014 Hariprasad Shenai <hariprasad@chelsio.com>

cxgb4/cxgb4vf/csiostor: Cleanup macros/register defines related to port and VI

This patch cleanups all port and VI related macros/register defines that are
defined in t4fw_api.h and the affected files.

Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# 17544e2a 20-Nov-2014 Anish Bhatt <anish@chelsio.com>

cxgb4 : Fix DCB priority groups being returned in wrong order

Peer priority groups were being reversed, but this was missed in the previous
fix sent out for this issue.

v2 : Previous patch was doing extra unnecessary work, result is the same.
Please ignore previous patch

Fixes : ee7bc3cdc270 ('cxgb4 : dcb open-lldp interop fixes')

Signed-off-by: Anish Bhatt <anish@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# ee7bc3cd 12-Nov-2014 Anish Bhatt <anish@chelsio.com>

cxgb4 : dcb open-lldp interop fixes

* In LLD_MANAGED mode, traffic classes were being returned in reverse order to
lldp agent.
* Priotype of strict is no longer the default returned.
* Change behaviour of getdcbx() based on discussions on lldp-devel

These were missed as there was no working fetch interface for open-lldp when
running in LLD_MANAGED mode till now.

Fixes: 76bcb31efc06 ("cxgb4 : Add DCBx support codebase and dcbnl_ops")

Signed-off-by: Anish Bhatt <anish@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# a815286b 07-Nov-2014 Anish Bhatt <anish@chelsio.com>

cxgb4 : Fix bug in DCB app deletion

Unlike CEE, IEEE has a bespoke app delete call and does not rely on priority
for app deletion

Fixes : 2376c879b80c ('cxgb4 : Improve handling of DCB negotiation or loss
thereof')

Signed-off-by: Anish Bhatt <anish@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# 3bb06261 23-Oct-2014 Anish Bhatt <anish@chelsio.com>

cxgb4 : Handle dcb enable correctly

Disabling DCBx in firmware automatically enables DCBx for control via host
lldp agents. Wait for an explicit setstate call from an lldp agents to enable
DCBx instead.

Fixes: 76bcb31efc06 ("cxgb4 : Add DCBx support codebase and dcbnl_ops")

Signed-off-by: Anish Bhatt <anish@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# 2376c879 23-Oct-2014 Anish Bhatt <anish@chelsio.com>

cxgb4 : Improve handling of DCB negotiation or loss thereof

Clear out any DCB apps we might have added to kernel table when we lose DCB
sync (or IEEE equivalent event). These were previously left behind and not
cleaned up correctly. IEEE allows individual components to work independently,
so improve check for IEEE completion by specifying individual components.

Fixes: 10b0046685ab ("cxgb4: IEEE fixes for DCBx state machine")

Signed-off-by: Anish Bhatt <anish@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# 10b00466 07-Aug-2014 Anish Bhatt <anish@chelsio.com>

cxgb4: IEEE fixes for DCBx state machine

* Changes required due to 16eecd9be4b05 ("dcbnl : Fix misleading
dcb_app->priority explanation")
* Driver was previously not aware of what DCBx version was negotiated by
firmware, this could lead to DCB app table in kernel or in firmware being
populated wrong since IEEE/CEE used different formats made clear by above
mentioned commit
* Driver was missing a couple of state transitions that could be caused
by other drivers that use chelsio hardware, resulting in incorrect behaviour
(the change that addresses this also flips the state machine to switch on
state instead of transition, hope this is okay in current window)
* Prio queue info & tsa is no longer thrown away

v2: Print DCBx state transition messages only when debug is enabled

Signed-off-by: Anish Bhatt <anish@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# c2659479 16-Jul-2014 Anish Bhatt <anish@chelsio.com>

Update setapp/getapp prototypes in dcbnl_rtnl_ops to return int instead of u8

v2: fixed issue with checking return of dcbnl_rtnl_ops->getapp()

Signed-off-by: Anish Bhatt <anish@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# 5433ba36 24-Jun-2014 Anish Bhatt <anish@chelsio.com>

cxgb4: Fix endian bug introduced in cxgb4 dcb patchset

Hi,
This patch fixes warnings generated by sparse as pointed out by kbuild test
robot, please apply to net-next. Applies on top of
commit 79631c89ed70643fd0579a65834b227795b251ee ("trivial: net/irda/irlmp.c:
Fix closing brace followed by if")
-Anish

v2: cleanup submission as per davem's feedback

Fixes: 76bcb31efc06 ("cxgb4 : Add DCBx support codebase and dcbnl_ops")
Signed-off-by: Anish Bhatt <anish@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>


# 76bcb31e 19-Jun-2014 Anish Bhatt <anish@chelsio.com>

cxgb4 : Add DCBx support codebase and dcbnl_ops

Signed-off-by: Anish Bhatt <anish@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>