Date: Sun, 29 Nov 2015 16:04:59 GMT From: def@FreeBSD.org To: svn-soc-all@FreeBSD.org Subject: socsvn commit: r294537 - soc2013/def/crashdump-head/sys/kern Message-ID: <201511291604.tATG4xhN048890@socsvn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: def Date: Sun Nov 29 16:04:58 2015 New Revision: 294537 URL: http://svnweb.FreeBSD.org/socsvn/?view=rev&rev=294537 Log: Add ifdefs in order to compile kernel without EKCD. Modified: soc2013/def/crashdump-head/sys/kern/kern_shutdown.c Modified: soc2013/def/crashdump-head/sys/kern/kern_shutdown.c ============================================================================== --- soc2013/def/crashdump-head/sys/kern/kern_shutdown.c Sun Nov 29 14:44:40 2015 (r294536) +++ soc2013/def/crashdump-head/sys/kern/kern_shutdown.c Sun Nov 29 16:04:58 2015 (r294537) @@ -157,7 +157,7 @@ uint32_t kdc_encryptedkeysize; uint8_t kdc_encryptedkey[]; }; -#endif /* EKCD */ +#endif /* * Variable panicstr contains argument to first call to panic; used as flag @@ -897,9 +897,13 @@ kerneldumpcrypto_dumpkeysize(const struct kerneldumpcrypto *kdc) { +#ifdef EKCD if (kdc == NULL) return (0); return (kdc->kdc_dumpkeysize); +#else + return (0); +#endif } /* Registration of dumpers */ @@ -916,7 +920,9 @@ return (error); if (di == NULL) { +#ifdef EKCD free(dumper.kdc, M_EKCD); +#endif bzero(&dumper, sizeof dumper); dumpdevname[0] = '\0'; return (0); @@ -1026,7 +1032,7 @@ return (0); } -#endif +#endif /* EKCD */ /* Call dumper with bounds checking. */ static int @@ -1065,6 +1071,7 @@ return (dump_raw_write(di, kdh, physical, offset, sizeof(*kdh))); } +#ifdef EKCD int dump_write_key(struct dumperinfo *di, vm_offset_t physical, off_t offset) { @@ -1092,6 +1099,15 @@ free(buf, M_EKCD); return (ret); } +#else /* !EKCD */ +int +dump_write_key(struct dumperinfo *di __unused, vm_offset_t physical __unused, + off_t offset __unused) +{ + + return (0); +} +#endif /* EKCD */ void mkdumpheader(struct kerneldumpheader *kdh, char *magic, uint32_t archver,
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201511291604.tATG4xhN048890>