Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F107084501
D44121.id135102.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D44121.id135102.diff
View Options
diff --git a/sbin/nvmecontrol/logpage.c b/sbin/nvmecontrol/logpage.c
--- a/sbin/nvmecontrol/logpage.c
+++ b/sbin/nvmecontrol/logpage.c
@@ -425,15 +425,10 @@
else
status = "Inactive";
- if (fw->revision[i] == 0LLU)
+ if (fw->revision[i][0] == '\0')
printf("Empty\n");
else
- if (isprint(*(char *)&fw->revision[i]))
- printf("[%s] %.8s\n", status,
- (char *)&fw->revision[i]);
- else
- printf("[%s] %016jx\n", status,
- fw->revision[i]);
+ printf("[%s] %.8s\n", status, fw->revision[i]);
}
}
diff --git a/sys/dev/nvme/nvme.h b/sys/dev/nvme/nvme.h
--- a/sys/dev/nvme/nvme.h
+++ b/sys/dev/nvme/nvme.h
@@ -1563,7 +1563,8 @@
struct nvme_firmware_page {
uint8_t afi;
uint8_t reserved[7];
- uint64_t revision[7]; /* revisions for 7 slots */
+ /* revisions for 7 slots */
+ uint8_t revision[7][NVME_FIRMWARE_REVISION_LENGTH];
uint8_t reserved2[448];
} __packed __aligned(4);
@@ -2153,12 +2154,6 @@
static inline
void nvme_firmware_page_swapbytes(struct nvme_firmware_page *s __unused)
{
-#if _BYTE_ORDER != _LITTLE_ENDIAN
- int i;
-
- for (i = 0; i < 7; i++)
- s->revision[i] = le64toh(s->revision[i]);
-#endif
}
static inline
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Jan 10, 9:05 PM (15 h, 26 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
15746623
Default Alt Text
D44121.id135102.diff (1 KB)
Attached To
Mode
D44121: nvme: Firmware revisions in the firmware slot information log are ASCII strings
Attached
Detach File
Event Timeline
Log In to Comment