commit 1004f70507ce29372e7ba03f67b241f3442b64ed
parent 91ddb9d7b78de139f5d62f8ae2298b2e42550114
Author: Broadcom SDK Release <sdk.releases@broadcom.com>
Date: Tue, 29 Sep 2020 23:44:02 -0700
SDK-213274: Added support for field actions bcmFieldActionHashSelect0 and
bcm...
Devices: 56870_A0,56870_B0,56873_A0
Module: field
Symptom:
TD3X devices has no support for field actions bcmFieldActionHashSelect0
and bcmFieldActionHashSelect1, causing asserts.
Added support for field actions bcmFieldActionHashSelect0 and
bcmFieldActionHashSelect1 for TD3X devices.
Diffstat:
3 files changed, 11 insertions(+), 11 deletions(-)
diff --git a/sdk-6.5.16/src/bcm/esw/field_common.c b/sdk-6.5.16/src/bcm/esw/field_common.c
@@ -13819,8 +13819,8 @@ _field_action_hw_resources_free(int unit, _field_entry_t *f_ent,
case bcmFieldActionHashSelect1:
/* Applicable to stage lookup on TRIDENT2 device only. */
if ((0 == (SOC_IS_TRIDENT2X(unit) || SOC_IS_TITAN2PLUS(unit)
- || SOC_IS_TOMAHAWKX(unit))) ||
- (_BCM_FIELD_STAGE_LOOKUP != f_ent->group->stage_id)) {
+ || soc_feature(unit, soc_feature_field_multi_pipe_support)))
+ || (_BCM_FIELD_STAGE_LOOKUP != f_ent->group->stage_id)) {
break;
}
mem = ((fa->action == bcmFieldActionHashSelect0)?
@@ -27916,7 +27916,7 @@ _field_resources_free(int unit, _field_entry_t *f_ent, uint32 flags)
#if defined(BCM_TRIDENT2_SUPPORT)
if ((SOC_IS_TRIDENT2X(unit) || SOC_IS_TITAN2PLUS(unit) ||
- SOC_IS_TOMAHAWKX(unit))) {
+ soc_feature(unit, soc_feature_field_multi_pipe_support))) {
rv = _bcm_field_td2_hash_select_profile_hw_free(unit, f_ent, flags);
BCM_IF_ERROR_RETURN(rv);
}
@@ -28130,7 +28130,7 @@ _field_hw_resources_alloc(int unit, _field_entry_t *f_ent)
#if defined(BCM_TRIDENT2_SUPPORT)
/* Allocate hash select profiles. */
if ((SOC_IS_TRIDENT2X(unit) || SOC_IS_TITAN2PLUS(unit) ||
- SOC_IS_TOMAHAWKX(unit))) {
+ soc_feature(unit, soc_feature_field_multi_pipe_support))) {
rv = _bcm_field_td2_hash_select_profile_hw_alloc(unit, f_ent);
if (BCM_FAILURE(rv)) {
_field_mtp_hw_free(unit, f_ent, _FP_ACTION_HW_FREE);
@@ -28159,7 +28159,7 @@ _field_hw_resources_alloc(int unit, _field_entry_t *f_ent)
_field_redirect_profile_hw_free(unit, f_ent, _FP_ACTION_HW_FREE);
#if defined(BCM_TRIDENT2_SUPPORT)
if ((SOC_IS_TRIDENT2X(unit) || SOC_IS_TITAN2PLUS(unit) ||
- SOC_IS_TOMAHAWKX(unit))) {
+ soc_feature(unit, soc_feature_field_multi_pipe_support))) {
_bcm_field_td2_hash_select_profile_hw_free(unit,
f_ent,
_FP_ACTION_HW_FREE);
@@ -28227,7 +28227,7 @@ _field_hw_resources_alloc(int unit, _field_entry_t *f_ent)
}
#if defined(BCM_TRIDENT2_SUPPORT)
if ((SOC_IS_TRIDENT2X(unit) || SOC_IS_TITAN2PLUS(unit) ||
- SOC_IS_TOMAHAWKX(unit))) {
+ soc_feature(unit, soc_feature_field_multi_pipe_support))) {
_bcm_field_td2_hash_select_profile_hw_free(unit,
f_ent,
_FP_ACTION_HW_FREE);
diff --git a/sdk-6.5.16/src/bcm/esw/trident2/field.c b/sdk-6.5.16/src/bcm/esw/trident2/field.c
@@ -8307,7 +8307,7 @@ _bcm_field_td2_hash_select_profile_hw_free(int unit,
/* Applicable to stage lookup on TRIDENT2 devices. */
if ((0 == (SOC_IS_TRIDENT2X(unit) || SOC_IS_TITAN2PLUS(unit)||
- SOC_IS_TOMAHAWKX(unit) )) ||
+ soc_feature(unit, soc_feature_field_multi_pipe_support))) ||
(_BCM_FIELD_STAGE_LOOKUP != f_ent->group->stage_id)) {
return (BCM_E_NONE);
}
@@ -8370,7 +8370,7 @@ _bcm_field_td2_hash_select_profile_hw_alloc (int unit, _field_entry_t *f_ent)
/* Applicable to stage lookup on TRIDENT2 devices only. */
if ((0 == (SOC_IS_TRIDENT2X(unit) || SOC_IS_TITAN2PLUS(unit) ||
- SOC_IS_TOMAHAWKX(unit))) ||
+ soc_feature(unit, soc_feature_field_multi_pipe_support))) ||
(_BCM_FIELD_STAGE_LOOKUP != f_ent->group->stage_id)) {
return (BCM_E_NONE);
}
diff --git a/sdk-6.5.16/src/bcm/esw/trx/field.c b/sdk-6.5.16/src/bcm/esw/trx/field.c
@@ -21265,7 +21265,7 @@ _field_tr2_actions_recover(int unit,
SOC_PBMP_CLEAR(pbmp);
#if defined(BCM_TRIDENT2_SUPPORT)
if ((SOC_IS_TRIDENT2X(unit) || SOC_IS_TITAN2PLUS(unit) ||
- SOC_IS_TOMAHAWKX(unit) )) {
+ soc_feature(unit, soc_feature_field_multi_pipe_support) )) {
hash_select_entry_ptr[0] = (uint32 *)hash_select_entry_arr;
hash_select_entry_ptr[1] = hash_select_entry_ptr[0] +
soc_mem_entry_words(unit,
@@ -26282,7 +26282,7 @@ _field_tr2_actions_recover(int unit,
case HASH_FIELD_BITMAP_PTR_Af:
if ((SOC_IS_TRIDENT2X(unit) ||
SOC_IS_TITAN2PLUS(unit) ||
- SOC_IS_TOMAHAWKX(unit) )) {
+ soc_feature(unit, soc_feature_field_multi_pipe_support) )) {
hw_index = PolicyGet(unit, policy_mem, policy_entry,
HASH_FIELD_BITMAP_PTR_Af);
action = bcmFieldActionHashSelect0;
@@ -26303,7 +26303,7 @@ _field_tr2_actions_recover(int unit,
case HASH_FIELD_BITMAP_PTR_Bf:
if ((SOC_IS_TRIDENT2X(unit) ||
SOC_IS_TITAN2PLUS(unit) ||
- SOC_IS_TOMAHAWKX(unit) )) {
+ soc_feature(unit, soc_feature_field_multi_pipe_support) )) {
hw_index = PolicyGet(unit, policy_mem, policy_entry,
HASH_FIELD_BITMAP_PTR_Bf);
action = bcmFieldActionHashSelect1;