From 39f48fe49d40fad99c5c838862575ec8d7995ab7 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Thu, 18 Mar 2021 10:54:01 +0100 Subject: [PATCH] Revert "net: Introduce parse_protocol header_ops callback" This reverts commit 6eef125294f50a3bd68de12263073a1abba7ab70 which is commit e78b2915517e8fcadb1bc130ad6aeac7099e510c upstream. This breaks the ABI and is not needed in the android-4.19-stable branch as the issue it was added for is not relevant here. Bug: 161946584 Signed-off-by: Greg Kroah-Hartman Change-Id: I56c67b283aa119d80c5f013a274622e8c6bdf2a0 --- include/linux/netdevice.h | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index 72c2add39d54..ed8005903781 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h @@ -275,7 +275,6 @@ struct header_ops { const struct net_device *dev, const unsigned char *haddr); bool (*validate)(const char *ll_header, unsigned int len); - __be16 (*parse_protocol)(const struct sk_buff *skb); ANDROID_KABI_RESERVE(1); ANDROID_KABI_RESERVE(2); @@ -2948,15 +2947,6 @@ static inline int dev_parse_header(const struct sk_buff *skb, return dev->header_ops->parse(skb, haddr); } -static inline __be16 dev_parse_header_protocol(const struct sk_buff *skb) -{ - const struct net_device *dev = skb->dev; - - if (!dev->header_ops || !dev->header_ops->parse_protocol) - return 0; - return dev->header_ops->parse_protocol(skb); -} - /* ll_header must have at least hard_header_len allocated */ static inline bool dev_validate_header(const struct net_device *dev, char *ll_header, int len)