From 76df998b4891260cb7074c472cfda4714bfe07b4 Mon Sep 17 00:00:00 2001 From: sephe Date: Fri, 24 Jun 2016 01:49:59 +0000 Subject: MFC 301017,301018,301019,301020,301021,301022,301106 301017 hyperv/vmbus: Indentation cleanup No functional changes. MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6602 301018 hyperv/vmbus: Move global vmbus id array to stack. MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6603 301019 hyperv/vmbus: Redefine SynIC message. - Avoid unnecessary indirection. - Avoid bit fields. - Use __packed. Reviewed by: Jun Su MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6636 301020 hyperv/vmbus: White space cleanup No functional changes MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6637 301021 hyperv: Move guid2str from vmbus file to hyperv file - Use uint8_t for GUID byte array. - Define GUID string length. - Break long lines. - Nuke unnecessary stack variable. MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6640 301022 hyperv/kvp: Use if_xname. MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6641 301106 hyperv/vmbus: Redefine event flags. - Nuke unnecessary union. - Avoid convoluted macro indirection. MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6671 --- sys/dev/hyperv/include/hyperv.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'sys/dev/hyperv/include/hyperv.h') diff --git a/sys/dev/hyperv/include/hyperv.h b/sys/dev/hyperv/include/hyperv.h index aeec8ec..44683d8 100644 --- a/sys/dev/hyperv/include/hyperv.h +++ b/sys/dev/hyperv/include/hyperv.h @@ -121,10 +121,12 @@ typedef uint8_t hv_bool_uint8_t; HV_ALIGN_DOWN(addr, PAGE_SIZE)) >> PAGE_SHIFT ) typedef struct hv_guid { - unsigned char data[16]; + uint8_t data[16]; } __packed hv_guid; -int snprintf_hv_guid(char *, size_t, const hv_guid *); +#define HYPERV_GUID_STRLEN 40 + +int hyperv_guid2str(const struct hv_guid *, char *, size_t); #define HV_NIC_GUID \ .data = {0x63, 0x51, 0x61, 0xF8, 0x3E, 0xDF, 0xc5, 0x46, \ -- cgit v1.1