Re: [RFC PATCH 03/13] user space API for time stamping of incoming and outgoing packets

David Miller
2008-11-12T10:02:48Z

From: Patrick Ohly <patrick.ohly@intel.com>
Date: Wed, 22 Oct 2008 17:01:05 +0200

> diff --git a/include/net/timestamping.h b/include/net/timestamping.h
> new file mode 100644
> index 0000000..53cb603
> --- /dev/null
> +++ b/include/net/timestamping.h
> @@ -0,0 +1,92 @@
> +#ifndef _NET_TIMESTAMPING_H
> +#define _NET_TIMESTAMPING_H
> +
> +#include <linux/socket.h> /* for SO_TIMESTAMPING */
> +
> +/**
> + * user space linux/socket.h might not have these defines yet:
> + * provide fallback
> + */
> +#if !defined(__kernel__) && !defined(SO_TIMESTAMPING)

It's __KERNEL__ not __kernel__, and user visible interfaces
should not be added to <net/foo.h> files.

Rather, they should be put into <linux/foo.h> files.

Since "timestamping.h" is too generic a name, use something
like <linux/net_tstamp.h>