Lines Matching refs:kdh

1486 dump_write_headers(struct dumperinfo *di, struct kerneldumpheader *kdh)
1497 hdrsz = sizeof(*kdh);
1515 return (di->dumper_hdr(di, kdh, key, keysize));
1518 buf = kdh;
1522 memcpy(buf, kdh, hdrsz);
1525 extent = dtoh64(kdh->dumpextent);
1572 dump_start(struct dumperinfo *di, struct kerneldumpheader *kdh)
1591 dumpextent = dtoh64(kdh->dumpextent);
1607 kdh->dumpextent = htod64(dumpextent);
1682 dump_finish(struct dumperinfo *di, struct kerneldumpheader *kdh)
1703 kdh->dumplength = htod64(di->dumpoff - di->origdumpoff);
1704 kdh->parity = 0;
1705 kdh->parity = kerneldump_parity(kdh);
1710 error = dump_write_headers(di, kdh);
1719 dump_init_header(const struct dumperinfo *di, struct kerneldumpheader *kdh,
1724 bzero(kdh, sizeof(*kdh));
1725 strlcpy(kdh->magic, magic, sizeof(kdh->magic));
1726 strlcpy(kdh->architecture, MACHINE_ARCH, sizeof(kdh->architecture));
1727 kdh->version = htod32(KERNELDUMPVERSION);
1728 kdh->architectureversion = htod32(archver);
1729 kdh->dumplength = htod64(dumplen);
1730 kdh->dumpextent = kdh->dumplength;
1731 kdh->dumptime = htod64(time_second);
1733 kdh->dumpkeysize = htod32(kerneldumpcrypto_dumpkeysize(di->kdcrypto));
1735 kdh->dumpkeysize = 0;
1737 kdh->blocksize = htod32(di->blocksize);
1738 strlcpy(kdh->hostname, prison0.pr_hostname, sizeof(kdh->hostname));
1739 dstsize = sizeof(kdh->versionstring);
1740 if (strlcpy(kdh->versionstring, version, dstsize) >= dstsize)
1741 kdh->versionstring[dstsize - 2] = '\n';
1743 strlcpy(kdh->panicstring, panicstr, sizeof(kdh->panicstring));
1745 kdh->compression = di->kdcomp->kdc_format;
1746 kdh->parity = kerneldump_parity(kdh);