Page MenuHomeFreeBSD

D36215.diff
No OneTemporary

D36215.diff

diff --git a/usr.sbin/bhyve/pci_nvme.c b/usr.sbin/bhyve/pci_nvme.c
--- a/usr.sbin/bhyve/pci_nvme.c
+++ b/usr.sbin/bhyve/pci_nvme.c
@@ -1550,7 +1550,7 @@
dest = vm_map_gpa(sc->nsc_pi->pi_vmctx, command->prp1,
sizeof(uint32_t) * 1024);
/* All unused entries shall be zero */
- bzero(dest, sizeof(uint32_t) * 1024);
+ memset(dest, 0, sizeof(uint32_t) * 1024);
((uint32_t *)dest)[0] = 1;
break;
case 0x03: /* list of NSID structures in CDW1.NSID, 4096 bytes */
@@ -1562,12 +1562,12 @@
dest = vm_map_gpa(sc->nsc_pi->pi_vmctx, command->prp1,
sizeof(uint32_t) * 1024);
/* All bytes after the descriptor shall be zero */
- bzero(dest, sizeof(uint32_t) * 1024);
+ memset(dest, 0, sizeof(uint32_t) * 1024);
/* Return NIDT=1 (i.e. EUI64) descriptor */
((uint8_t *)dest)[0] = 1;
((uint8_t *)dest)[1] = sizeof(uint64_t);
- bcopy(sc->nsdata.eui64, ((uint8_t *)dest) + 4, sizeof(uint64_t));
+ memcpy(((uint8_t *)dest) + 4, sc->nsdata.eui64, sizeof(uint64_t));
break;
case 0x13:
/*

File Metadata

Mime Type
text/plain
Expires
Thu, Mar 6, 11:54 PM (15 h, 37 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
17021814
Default Alt Text
D36215.diff (1 KB)

Event Timeline