From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 5288AA04AE; Tue, 5 May 2020 06:03:49 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id C9FCC1D513; Tue, 5 May 2020 06:03:48 +0200 (CEST) Received: from rnd-relay.smtp.broadcom.com (rnd-relay.smtp.broadcom.com [192.19.229.170]) by dpdk.org (Postfix) with ESMTP id D6C0B1D182 for ; Tue, 5 May 2020 06:03:46 +0200 (CEST) Received: from mail-irv-17.broadcom.com (mail-irv-17.lvn.broadcom.net [10.75.242.48]) by rnd-relay.smtp.broadcom.com (Postfix) with ESMTP id 9F04030C00F; Mon, 4 May 2020 21:03:19 -0700 (PDT) DKIM-Filter: OpenDKIM Filter v2.10.3 rnd-relay.smtp.broadcom.com 9F04030C00F DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=broadcom.com; s=dkimrelay; t=1588651399; bh=uGrPTMxAToiB8o0b+P7MSHxVHOGXSpJHyG6v6Li5cwo=; h=From:To:Cc:Subject:Date:From; b=OW38HtD7/29up6bdxBeSsosAOG0MAaCeHcpUqR3zuGgFDJktMWRCB1+n+NM0gzliO /U1X9C0FQYcjjLvgRJuHQsCNfdGuSDqgThe/b3C2WxgkKQXhbWdckZwEBhlDwDlWza yUE4BUSB8PEe20WBEeTYmSCMkqFE7ipOChe2bntw= Received: from localhost.localdomain (unknown [10.230.26.175]) by mail-irv-17.broadcom.com (Postfix) with ESMTP id 48E4E140069; Mon, 4 May 2020 21:03:44 -0700 (PDT) From: Ajit Khaparde To: dev@dpdk.org Cc: Randy Schacher , Peter Spreadborough Date: Mon, 4 May 2020 21:03:37 -0700 Message-Id: <20200505040337.34463-1-ajit.khaparde@broadcom.com> X-Mailer: git-send-email 2.21.1 (Apple Git-122.3) MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH] net/bnxt: fix build with gcc10 default fno-common X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" From: Randy Schacher Remove the defensive compile-time checker macro. Bugzilla ID: 468 Fixes: 8430a8b841c8 ("net/bnxt: add initial TruFlow core session open") Signed-off-by: Randy Schacher Reviewed-by: Peter Spreadborough Reviewed-by: Ajit Khaparde --- drivers/net/bnxt/tf_core/hwrm_tf.h | 24 ------------------------ 1 file changed, 24 deletions(-) diff --git a/drivers/net/bnxt/tf_core/hwrm_tf.h b/drivers/net/bnxt/tf_core/hwrm_tf.h index 6299d588a..341909573 100644 --- a/drivers/net/bnxt/tf_core/hwrm_tf.h +++ b/drivers/net/bnxt/tf_core/hwrm_tf.h @@ -38,11 +38,6 @@ typedef enum tf_subtype { /* u32_t tlv_resp_value[170]; */ #define TF_MAX_RESP_SIZE 680 -#define __BUILD_BUG_ON(condition, line) \ - char p##line[(condition) ? 1 : -1] -#define _BUILD_BUG_ON(condition, line) __BUILD_BUG_ON(condition, line) -#define BUILD_BUG_ON(condition) _BUILD_BUG_ON(condition, __LINE__) - /* Use this to allocate/free any kind of * indexes over HWRM and fill the parms pointer */ @@ -98,7 +93,6 @@ typedef struct tf_session_attach_input { /* Session Name */ char session_name[TF_SESSION_NAME_MAX]; } tf_session_attach_input_t, *ptf_session_attach_input_t; -BUILD_BUG_ON(sizeof(tf_session_attach_input_t) <= TF_MAX_REQ_SIZE); /* Input params for session resource HW qcaps */ typedef struct tf_session_hw_resc_qcaps_input { @@ -111,7 +105,6 @@ typedef struct tf_session_hw_resc_qcaps_input { /* When set to 1, indicates the query apply to TX */ #define TF_SESSION_HW_RESC_QCAPS_INPUT_FLAGS_DIR_TX (0x1) } tf_session_hw_resc_qcaps_input_t, *ptf_session_hw_resc_qcaps_input_t; -BUILD_BUG_ON(sizeof(tf_session_hw_resc_qcaps_input_t) <= TF_MAX_REQ_SIZE); /* Output params for session resource HW qcaps */ typedef struct tf_session_hw_resc_qcaps_output { @@ -216,7 +209,6 @@ typedef struct tf_session_hw_resc_qcaps_output { /* Maximum non-guaranteed number of LAG table entries */ uint16_t lag_tbl_entries_max; } tf_session_hw_resc_qcaps_output_t, *ptf_session_hw_resc_qcaps_output_t; -BUILD_BUG_ON(sizeof(tf_session_hw_resc_qcaps_output_t) <= TF_MAX_RESP_SIZE); /* Input params for session resource HW alloc */ typedef struct tf_session_hw_resc_alloc_input { @@ -275,7 +267,6 @@ typedef struct tf_session_hw_resc_alloc_input { /* Number of LAG table entries to be allocated */ uint16_t num_lag_tbl_entries; } tf_session_hw_resc_alloc_input_t, *ptf_session_hw_resc_alloc_input_t; -BUILD_BUG_ON(sizeof(tf_session_hw_resc_alloc_input_t) <= TF_MAX_REQ_SIZE); /* Output params for session resource HW alloc */ typedef struct tf_session_hw_resc_alloc_output { @@ -368,7 +359,6 @@ typedef struct tf_session_hw_resc_alloc_output { /* Number of LAG table entries allocated */ uint16_t lag_tbl_entries_stride; } tf_session_hw_resc_alloc_output_t, *ptf_session_hw_resc_alloc_output_t; -BUILD_BUG_ON(sizeof(tf_session_hw_resc_alloc_output_t) <= TF_MAX_RESP_SIZE); /* Input params for session resource HW free */ typedef struct tf_session_hw_resc_free_input { @@ -471,7 +461,6 @@ typedef struct tf_session_hw_resc_free_input { /* Number of LAG table entries allocated */ uint16_t lag_tbl_entries_stride; } tf_session_hw_resc_free_input_t, *ptf_session_hw_resc_free_input_t; -BUILD_BUG_ON(sizeof(tf_session_hw_resc_free_input_t) <= TF_MAX_REQ_SIZE); /* Input params for session resource HW flush */ typedef struct tf_session_hw_resc_flush_input { @@ -574,7 +563,6 @@ typedef struct tf_session_hw_resc_flush_input { /* Number of LAG table entries allocated */ uint16_t lag_tbl_entries_stride; } tf_session_hw_resc_flush_input_t, *ptf_session_hw_resc_flush_input_t; -BUILD_BUG_ON(sizeof(tf_session_hw_resc_flush_input_t) <= TF_MAX_REQ_SIZE); /* Input params for session resource SRAM qcaps */ typedef struct tf_session_sram_resc_qcaps_input { @@ -587,7 +575,6 @@ typedef struct tf_session_sram_resc_qcaps_input { /* When set to 1, indicates the query apply to TX */ #define TF_SESSION_SRAM_RESC_QCAPS_INPUT_FLAGS_DIR_TX (0x1) } tf_session_sram_resc_qcaps_input_t, *ptf_session_sram_resc_qcaps_input_t; -BUILD_BUG_ON(sizeof(tf_session_sram_resc_qcaps_input_t) <= TF_MAX_REQ_SIZE); /* Output params for session resource SRAM qcaps */ typedef struct tf_session_sram_resc_qcaps_output { @@ -654,7 +641,6 @@ typedef struct tf_session_sram_resc_qcaps_output { /* Maximum non-guaranteed number of NAT D_IPV4 */ uint16_t nat_d_ipv4_max; } tf_session_sram_resc_qcaps_output_t, *ptf_session_sram_resc_qcaps_output_t; -BUILD_BUG_ON(sizeof(tf_session_sram_resc_qcaps_output_t) <= TF_MAX_RESP_SIZE); /* Input params for session resource SRAM alloc */ typedef struct tf_session_sram_resc_alloc_input { @@ -695,7 +681,6 @@ typedef struct tf_session_sram_resc_alloc_input { /* Number of NAT destination IPV4 addresses to be allocated */ uint16_t num_nat_d_ipv4; } tf_session_sram_resc_alloc_input_t, *ptf_session_sram_resc_alloc_input_t; -BUILD_BUG_ON(sizeof(tf_session_sram_resc_alloc_input_t) <= TF_MAX_REQ_SIZE); /* Output params for session resource SRAM alloc */ typedef struct tf_session_sram_resc_alloc_output { @@ -757,7 +742,6 @@ typedef struct tf_session_sram_resc_alloc_output { /* Number of NAT destination IPV4 addresses allocated */ uint16_t nat_d_ipv4_stride; } tf_session_sram_resc_alloc_output_t, *ptf_session_sram_resc_alloc_output_t; -BUILD_BUG_ON(sizeof(tf_session_sram_resc_alloc_output_t) <= TF_MAX_RESP_SIZE); /* Input params for session resource SRAM free */ typedef struct tf_session_sram_resc_free_input { @@ -825,7 +809,6 @@ typedef struct tf_session_sram_resc_free_input { /* Number of NAT destination IPV4 addresses allocated */ uint16_t nat_d_ipv4_stride; } tf_session_sram_resc_free_input_t, *ptf_session_sram_resc_free_input_t; -BUILD_BUG_ON(sizeof(tf_session_sram_resc_free_input_t) <= TF_MAX_REQ_SIZE); /* Input params for session resource SRAM flush */ typedef struct tf_session_sram_resc_flush_input { @@ -893,7 +876,6 @@ typedef struct tf_session_sram_resc_flush_input { /* Number of NAT destination IPV4 addresses allocated */ uint16_t nat_d_ipv4_stride; } tf_session_sram_resc_flush_input_t, *ptf_session_sram_resc_flush_input_t; -BUILD_BUG_ON(sizeof(tf_session_sram_resc_flush_input_t) <= TF_MAX_REQ_SIZE); /* Input params for table type set */ typedef struct tf_tbl_type_set_input { @@ -914,7 +896,6 @@ typedef struct tf_tbl_type_set_input { /* Index to set */ uint32_t index; } tf_tbl_type_set_input_t, *ptf_tbl_type_set_input_t; -BUILD_BUG_ON(sizeof(tf_tbl_type_set_input_t) <= TF_MAX_REQ_SIZE); /* Input params for table type get */ typedef struct tf_tbl_type_get_input { @@ -931,7 +912,6 @@ typedef struct tf_tbl_type_get_input { /* Index to get */ uint32_t index; } tf_tbl_type_get_input_t, *ptf_tbl_type_get_input_t; -BUILD_BUG_ON(sizeof(tf_tbl_type_get_input_t) <= TF_MAX_REQ_SIZE); /* Output params for table type get */ typedef struct tf_tbl_type_get_output { @@ -940,7 +920,6 @@ typedef struct tf_tbl_type_get_output { /* Data read */ uint8_t data[TF_BULK_RECV]; } tf_tbl_type_get_output_t, *ptf_tbl_type_get_output_t; -BUILD_BUG_ON(sizeof(tf_tbl_type_get_output_t) <= TF_MAX_RESP_SIZE); /* Input params for EM internal rule insert */ typedef struct tf_em_internal_insert_input { @@ -963,7 +942,6 @@ typedef struct tf_em_internal_insert_input { /* number of bits in em_key */ uint16_t em_key_bitlen; } tf_em_internal_insert_input_t, *ptf_em_internal_insert_input_t; -BUILD_BUG_ON(sizeof(tf_em_internal_insert_input_t) <= TF_MAX_REQ_SIZE); /* Output params for EM internal rule insert */ typedef struct tf_em_internal_insert_output { @@ -972,7 +950,6 @@ typedef struct tf_em_internal_insert_output { /* EM record offset 0~3 */ uint8_t rptr_entry; } tf_em_internal_insert_output_t, *ptf_em_internal_insert_output_t; -BUILD_BUG_ON(sizeof(tf_em_internal_insert_output_t) <= TF_MAX_RESP_SIZE); /* Input params for EM INTERNAL rule delete */ typedef struct tf_em_internal_delete_input { @@ -991,6 +968,5 @@ typedef struct tf_em_internal_delete_input { /* number of bits in em_key */ uint16_t em_key_bitlen; } tf_em_internal_delete_input_t, *ptf_em_internal_delete_input_t; -BUILD_BUG_ON(sizeof(tf_em_internal_delete_input_t) <= TF_MAX_REQ_SIZE); #endif /* _HWRM_TF_H_ */ -- 2.21.1 (Apple Git-122.3)