From e7990b08820162090a90488ca79bc069cfe21487 Mon Sep 17 00:00:00 2001 From: Yaroslav Kolomiiets Date: Tue, 22 Oct 2024 02:17:07 +0100 Subject: [PATCH] unix: add PTP_PF_* constants on Linux These represent valid values for PtpPinDesc.Func. They are defined as enum, thus mkerrors.sh doesn't emit these. --- unix/linux/types.go | 7 +++++++ unix/ztypes_linux.go | 7 +++++++ 2 files changed, 14 insertions(+) diff --git a/unix/linux/types.go b/unix/linux/types.go index 928ad353..12937c9b 100644 --- a/unix/linux/types.go +++ b/unix/linux/types.go @@ -4148,6 +4148,13 @@ type ( PtpSysOffsetPrecise C.struct_ptp_sys_offset_precise ) +const ( + PTP_PF_NONE = C.PTP_PF_NONE + PTP_PF_EXTTS = C.PTP_PF_EXTTS + PTP_PF_PEROUT = C.PTP_PF_PEROUT + PTP_PF_PHYSYNC = C.PTP_PF_PHYSYNC +) + type ( HIDRawReportDescriptor C.struct_hidraw_report_descriptor HIDRawDevInfo C.struct_hidraw_devinfo diff --git a/unix/ztypes_linux.go b/unix/ztypes_linux.go index 9daae9c0..384850ed 100644 --- a/unix/ztypes_linux.go +++ b/unix/ztypes_linux.go @@ -4203,6 +4203,13 @@ type ( } ) +const ( + PTP_PF_NONE = 0x0 + PTP_PF_EXTTS = 0x1 + PTP_PF_PEROUT = 0x2 + PTP_PF_PHYSYNC = 0x3 +) + type ( HIDRawReportDescriptor struct { Size uint32