blob: 3446c5b772e5974325efc3200e87c98f47960d78 [file] [log] [blame]
Greg Kroah-Hartmanb2441312017-11-01 15:07:57 +01001/* SPDX-License-Identifier: GPL-2.0 */
Stefan Richter28646822010-07-27 10:26:33 +02002#ifndef __nosy_user_h
3#define __nosy_user_h
4
Stefan Richterb5e47722010-07-27 10:28:30 +02005#include <linux/ioctl.h>
6#include <linux/types.h>
Stefan Richter28646822010-07-27 10:26:33 +02007
8#define NOSY_IOC_GET_STATS _IOR('&', 0, struct nosy_stats)
9#define NOSY_IOC_START _IO('&', 1)
10#define NOSY_IOC_STOP _IO('&', 2)
11#define NOSY_IOC_FILTER _IOW('&', 2, __u32)
12
13struct nosy_stats {
Stefan Richterb5e47722010-07-27 10:28:30 +020014 __u32 total_packet_count;
15 __u32 lost_packet_count;
Stefan Richter28646822010-07-27 10:26:33 +020016};
17
Stefan Richterb5e47722010-07-27 10:28:30 +020018/*
Stefan Richter28646822010-07-27 10:26:33 +020019 * Format of packets returned from the kernel driver:
20 *
Stefan Richterfd8c8d42010-07-22 11:56:38 +020021 * quadlet with timestamp (microseconds, CPU endian)
22 * quadlet-padded packet data... (little endian)
23 * quadlet with ack (little endian)
Stefan Richter28646822010-07-27 10:26:33 +020024 */
25
26#endif /* __nosy_user_h */