linux/include/net/flow.h

/* SPDX-License-Identifier: GPL-2.0 */
/*
 *
 *	Generic internet FLOW.
 *
 */

#ifndef _NET_FLOW_H
#define _NET_FLOW_H

#include <linux/in6.h>
#include <linux/atomic.h>
#include <linux/container_of.h>
#include <linux/uidgid.h>

struct flow_keys;

/*
 * ifindex generation is per-net namespace, and loopback is
 * always the 1st device in ns (see net_dev_init), thus any
 * loopback device should get ifindex 1
 */

#define LOOPBACK_IFINDEX

struct flowi_tunnel {};

struct flowi_common {};

flowi_uli;

struct flowi4 {} __attribute__((__aligned__));

static inline void flowi4_init_output(struct flowi4 *fl4, int oif,
				      __u32 mark, __u8 tos, __u8 scope,
				      __u8 proto, __u8 flags,
				      __be32 daddr, __be32 saddr,
				      __be16 dport, __be16 sport,
				      kuid_t uid)
{}

/* Reset some input parameters after previous lookup */
static inline void flowi4_update_output(struct flowi4 *fl4, int oif,
					__be32 daddr, __be32 saddr)
{}


struct flowi6 {} __attribute__((__aligned__));

struct flowi {} __attribute__((__aligned__));

static inline struct flowi *flowi4_to_flowi(struct flowi4 *fl4)
{}

static inline struct flowi_common *flowi4_to_flowi_common(struct flowi4 *fl4)
{}

static inline struct flowi *flowi6_to_flowi(struct flowi6 *fl6)
{}

static inline struct flowi_common *flowi6_to_flowi_common(struct flowi6 *fl6)
{}

__u32 __get_hash_from_flowi6(const struct flowi6 *fl6, struct flow_keys *keys);

#endif