git: ec5c52b7a313 - stable/13 - nvmecontrol wdc: Remove unused but set variable.
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 11 Nov 2022 18:36:50 UTC
The branch stable/13 has been updated by jhb:
URL: https://cgit.FreeBSD.org/src/commit/?id=ec5c52b7a313f9890405de9b2f5179691d60ee80
commit ec5c52b7a313f9890405de9b2f5179691d60ee80
Author: John Baldwin <jhb@FreeBSD.org>
AuthorDate: 2022-10-03 23:10:42 +0000
Commit: John Baldwin <jhb@FreeBSD.org>
CommitDate: 2022-11-11 18:18:53 +0000
nvmecontrol wdc: Remove unused but set variable.
Reviewed by: imp
Differential Revision: https://reviews.freebsd.org/D36812
(cherry picked from commit d81082a7ad25f26309a1466b9ad565f507bed275)
---
sbin/nvmecontrol/modules/wdc/wdc.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/sbin/nvmecontrol/modules/wdc/wdc.c b/sbin/nvmecontrol/modules/wdc/wdc.c
index 050458a8812f..a60f72942186 100644
--- a/sbin/nvmecontrol/modules/wdc/wdc.c
+++ b/sbin/nvmecontrol/modules/wdc/wdc.c
@@ -783,7 +783,6 @@ static void
print_hgst_info_log(const struct nvme_controller_data *cdata __unused, void *buf, uint32_t size __unused)
{
uint8_t *walker, *end, *subpage;
- int pages;
uint16_t len;
uint8_t subtype, res;
@@ -791,8 +790,7 @@ print_hgst_info_log(const struct nvme_controller_data *cdata __unused, void *buf
printf("===================\n");
walker = buf;
- pages = *walker++;
- walker++;
+ walker += 2; /* Page count */
len = le16dec(walker);
walker += 2;
end = walker + len; /* Length is exclusive of this header */