Squashed backup commit (no shallow-clone history issues) of xiaomi-mt6833-dev/kernel_xiaomi_mt6833 (lineage-23.2 branch, upstream commit 9eece662e) plus all fixes applied to get everpal_defconfig building clean against a modern (GCC 15.2.0) toolchain -- see the previous commit message on the lineage-23.2 branch (also in this repo history is not available here since this is a squashed snapshot; full incremental history lives in the local DL380 checkout and the upstream GitHub remote). Upstream: https://github.com/xiaomi-mt6833-dev/kernel_xiaomi_mt6833 (lineage-23.2)
29 lines
535 B
C
29 lines
535 B
C
/* SPDX-License-Identifier: GPL-2.0-only */
|
|
/*
|
|
* Copyright (c) 2014 Nicira, Inc.
|
|
*/
|
|
|
|
#ifndef _NET_MPLS_H
|
|
#define _NET_MPLS_H 1
|
|
|
|
#include <linux/if_ether.h>
|
|
#include <linux/netdevice.h>
|
|
|
|
#define MPLS_HLEN 4
|
|
|
|
struct mpls_shim_hdr {
|
|
__be32 label_stack_entry;
|
|
};
|
|
|
|
static inline bool eth_p_mpls(__be16 eth_type)
|
|
{
|
|
return eth_type == htons(ETH_P_MPLS_UC) ||
|
|
eth_type == htons(ETH_P_MPLS_MC);
|
|
}
|
|
|
|
static inline struct mpls_shim_hdr *mpls_hdr(const struct sk_buff *skb)
|
|
{
|
|
return (struct mpls_shim_hdr *)skb_network_header(skb);
|
|
}
|
|
#endif
|