All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ajit Khaparde <ajit.khaparde@broadcom.com>
To: dev@dpdk.org
Cc: thomas@monjalon.net,
	Kishore Padmanabha <kishore.padmanabha@broadcom.com>
Subject: [dpdk-dev] [PATCH] net/bnxt: fix build failure
Date: Thu,  8 Jul 2021 15:49:50 -0700	[thread overview]
Message-ID: <20210708224950.39452-1-ajit.khaparde@broadcom.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 1411 bytes --]

Fix build failures because of uninitialized variable usage.

Fixes: 05b405d58148 ("net/bnxt: add dpool allocator for EM allocation")

Signed-off-by: Kishore Padmanabha <kishore.padmanabha@broadcom.com>
Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
---
 drivers/net/bnxt/tf_core/dpool.c     | 1 +
 drivers/net/bnxt/tf_ulp/ulp_mapper.c | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/net/bnxt/tf_core/dpool.c b/drivers/net/bnxt/tf_core/dpool.c
index 0dae42b1bb..145efa486f 100644
--- a/drivers/net/bnxt/tf_core/dpool.c
+++ b/drivers/net/bnxt/tf_core/dpool.c
@@ -125,6 +125,7 @@ int dpool_defrag(struct dpool *dpool,
 		largest_free_size = 0;
 		largest_free_index = 0;
 		count = 0;
+		index = 0;
 
 		for (i = 0; i < dpool->size; i++) {
 			if (DP_IS_FREE(dpool->entry[i].flags)) {
diff --git a/drivers/net/bnxt/tf_ulp/ulp_mapper.c b/drivers/net/bnxt/tf_ulp/ulp_mapper.c
index acd9f996e8..871dbad0fe 100644
--- a/drivers/net/bnxt/tf_ulp/ulp_mapper.c
+++ b/drivers/net/bnxt/tf_ulp/ulp_mapper.c
@@ -2249,7 +2249,7 @@ ulp_mapper_index_tbl_process(struct bnxt_ulp_mapper_parms *parms,
 	struct tf_free_tbl_entry_parms free_parms = { 0 };
 	uint32_t tbl_scope_id;
 	struct tf *tfp;
-	struct bnxt_ulp_glb_resource_info glb_res;
+	struct bnxt_ulp_glb_resource_info glb_res = { 0 };
 	uint16_t bit_size;
 	bool alloc = false;
 	bool write = false;
-- 
2.21.1 (Apple Git-122.3)


             reply	other threads:[~2021-07-08 22:49 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-08 22:49 Ajit Khaparde [this message]
2021-07-09  8:48 ` [dpdk-dev] [PATCH] net/bnxt: fix build failure Thomas Monjalon
2021-07-09 14:41   ` Ajit Khaparde
2021-07-09 15:37     ` [dpdk-dev] [PATCH v2] " Ajit Khaparde
2021-07-09 18:38       ` Ajit Khaparde
2021-07-09 20:39         ` Thomas Monjalon
2021-07-09 15:02   ` [dpdk-dev] [PATCH] " Lance Richardson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210708224950.39452-1-ajit.khaparde@broadcom.com \
    --to=ajit.khaparde@broadcom.com \
    --cc=dev@dpdk.org \
    --cc=kishore.padmanabha@broadcom.com \
    --cc=thomas@monjalon.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.