linux/include/uapi/linux/net_tstamp.h

/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
/*
 * Userspace API for hardware time stamping of network packets
 *
 * Copyright (C) 2008,2009 Intel Corporation
 * Author: Patrick Ohly <[email protected]>
 *
 */

#ifndef _NET_TIMESTAMPING_H
#define _NET_TIMESTAMPING_H

#include <linux/types.h>
#include <linux/socket.h>   /* for SO_TIMESTAMPING */

/* SO_TIMESTAMPING flags */
enum {};

/*
 * SO_TIMESTAMPING flags are either for recording a packet timestamp or for
 * reporting the timestamp to user space.
 * Recording flags can be set both via socket options and control messages.
 */
#define SOF_TIMESTAMPING_TX_RECORD_MASK

/**
 * struct so_timestamping - SO_TIMESTAMPING parameter
 *
 * @flags:	SO_TIMESTAMPING flags
 * @bind_phc:	Index of PTP virtual clock bound to sock. This is available
 *		if flag SOF_TIMESTAMPING_BIND_PHC is set.
 */
struct so_timestamping {};

/**
 * struct hwtstamp_config - %SIOCGHWTSTAMP and %SIOCSHWTSTAMP parameter
 *
 * @flags:	one of HWTSTAMP_FLAG_*
 * @tx_type:	one of HWTSTAMP_TX_*
 * @rx_filter:	one of HWTSTAMP_FILTER_*
 *
 * %SIOCGHWTSTAMP and %SIOCSHWTSTAMP expect a &struct ifreq with a
 * ifr_data pointer to this structure.  For %SIOCSHWTSTAMP, if the
 * driver or hardware does not support the requested @rx_filter value,
 * the driver may use a more general filter mode.  In this case
 * @rx_filter will indicate the actual mode on return.
 */
struct hwtstamp_config {};

/* possible values for hwtstamp_config->flags */
enum hwtstamp_flags {};

/* possible values for hwtstamp_config->tx_type */
enum hwtstamp_tx_types {};

/* possible values for hwtstamp_config->rx_filter */
enum hwtstamp_rx_filters {};

/* SCM_TIMESTAMPING_PKTINFO control message */
struct scm_ts_pktinfo {};

/*
 * SO_TXTIME gets a struct sock_txtime with flags being an integer bit
 * field comprised of these values.
 */
enum txtime_flags {};

struct sock_txtime {};

#endif /* _NET_TIMESTAMPING_H */