git: 44b4f0370fe9 - main - bnxt: Remove dead write to cp_ring_id

From: Warner Losh <imp_at_FreeBSD.org>
Date: Mon, 28 Feb 2022 17:50:38 UTC
The branch main has been updated by imp:

URL: https://cgit.FreeBSD.org/src/commit/?id=44b4f0370fe90d11306e9d3fdcacdc5b4ccc946e

commit 44b4f0370fe90d11306e9d3fdcacdc5b4ccc946e
Author:     Warner Losh <imp@FreeBSD.org>
AuthorDate: 2022-02-28 17:13:27 +0000
Commit:     Warner Losh <imp@FreeBSD.org>
CommitDate: 2022-02-28 17:14:34 +0000

    bnxt: Remove dead write to cp_ring_id
    
    Since this is read from memory, reading it and then ignoring it is dead
    code...
    
    Sponsored by:           Netflix
---
 sys/dev/bnxt/bnxt_hwrm.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/sys/dev/bnxt/bnxt_hwrm.c b/sys/dev/bnxt/bnxt_hwrm.c
index 60485cd06799..0009ffa25053 100644
--- a/sys/dev/bnxt/bnxt_hwrm.c
+++ b/sys/dev/bnxt/bnxt_hwrm.c
@@ -119,7 +119,6 @@ _hwrm_send_message(struct bnxt_softc *softc, void *msg, uint32_t msg_len)
 	struct hwrm_err_output *resp = (void *)softc->hwrm_cmd_resp.idi_vaddr;
 	uint32_t *data = msg;
 	int i;
-	uint16_t cp_ring_id;
 	uint8_t *valid;
 	uint16_t err;
 	uint16_t max_req_len = HWRM_MAX_REQ_LEN;
@@ -128,7 +127,6 @@ _hwrm_send_message(struct bnxt_softc *softc, void *msg, uint32_t msg_len)
 	/* TODO: DMASYNC in here. */
 	req->seq_id = htole16(softc->hwrm_cmd_seq++);
 	memset(resp, 0, PAGE_SIZE);
-	cp_ring_id = le16toh(req->cmpl_ring);
 
 	if (softc->flags & BNXT_FLAG_SHORT_CMD) {
 		void *short_cmd_req = softc->hwrm_short_cmd_req_addr.idi_vaddr;