summaryrefslogtreecommitdiff
path: root/patches
diff options
context:
space:
mode:
authorAceLan Kao <acelan.kao@canonical.com>2017-08-08 21:14:51 +0800
committerJohannes Berg <johannes.berg@intel.com>2017-09-06 16:53:12 +0200
commit450ac626337307a5870000e9751a3ad3da2fd813 (patch)
tree1af808ad4315da04f40794682f17883320d2480f /patches
parente2b55245cfcb9a54fa7de357309a65205615f7d3 (diff)
backports: remove 802.15.4 entirely
802.15.4 has been removed by this commit, 15a3df8 backports: remove 802.15.4 entirely but there are some files left behind. Remove them all. Signed-off-by: AceLan Kao <acelan.kao@canonical.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'patches')
-rw-r--r--patches/0006-ieee802154-6lowpan-namespace.patch63
-rw-r--r--patches/0007-lowpan-inet_frag_lru_move.patch59
-rw-r--r--patches/0008-net-user-ns.patch17
-rw-r--r--patches/0013-fix-makefile-includes/6lowpan.patch10
-rw-r--r--patches/0013-fix-makefile-includes/cfg802154.patch10
-rw-r--r--patches/0030-qdisc_tx_busylock/ieee802154.patch22
-rw-r--r--patches/0044-no_user_ns_in_net/ieee802154.patch30
-rw-r--r--patches/0066-remove-netdev_ieee802154_ptr/cfg802154.patch18
-rw-r--r--patches/0068-proto-hash/ieee802154.patch62
9 files changed, 0 insertions, 291 deletions
diff --git a/patches/0006-ieee802154-6lowpan-namespace.patch b/patches/0006-ieee802154-6lowpan-namespace.patch
deleted file mode 100644
index 2412a450..00000000
--- a/patches/0006-ieee802154-6lowpan-namespace.patch
+++ /dev/null
@@ -1,63 +0,0 @@
-This is required unless we add some macro wrappers for this
-type of static work upstream but not sure if that is a good
-idea yet.
-
---- a/net/ieee802154/reassembly.c
-+++ b/net/ieee802154/reassembly.c
-@@ -97,7 +97,11 @@ static void lowpan_frag_expire(unsigned
- struct net *net;
-
- fq = container_of((struct inet_frag_queue *)data, struct frag_queue, q);
-+#if LINUX_VERSION_IS_GEQ(3,15,0)
- net = container_of(fq->q.net, struct net, ieee802154_lowpan.frags);
-+#else
-+ net = &init_net;
-+#endif
-
- spin_lock(&fq->q.lock);
-
-@@ -395,24 +399,44 @@ static int zero;
- static struct ctl_table lowpan_frags_ns_ctl_table[] = {
- {
- .procname = "6lowpanfrag_high_thresh",
-+#if LINUX_VERSION_IS_GEQ(3,15,0)
- .data = &init_net.ieee802154_lowpan.frags.high_thresh,
-+#else
-+ .data = &ieee802154_lowpan.frags.high_thresh,
-+#endif
- .maxlen = sizeof(int),
- .mode = 0644,
- .proc_handler = proc_dointvec_minmax,
-+#if LINUX_VERSION_IS_GEQ(3,15,0)
- .extra1 = &init_net.ieee802154_lowpan.frags.low_thresh
-+#else
-+ .extra1 = &ieee802154_lowpan.frags.low_thresh
-+#endif
- },
- {
- .procname = "6lowpanfrag_low_thresh",
-+#if LINUX_VERSION_IS_GEQ(3,15,0)
- .data = &init_net.ieee802154_lowpan.frags.low_thresh,
-+#else
-+ .data = &ieee802154_lowpan.frags.low_thresh,
-+#endif
- .maxlen = sizeof(int),
- .mode = 0644,
- .proc_handler = proc_dointvec_minmax,
- .extra1 = &zero,
-+#if LINUX_VERSION_IS_GEQ(3,15,0)
- .extra2 = &init_net.ieee802154_lowpan.frags.high_thresh
-+#else
-+ .extra2 = &ieee802154_lowpan.frags.high_thresh
-+#endif
- },
- {
- .procname = "6lowpanfrag_time",
-+#if LINUX_VERSION_IS_GEQ(3,15,0)
- .data = &init_net.ieee802154_lowpan.frags.timeout,
-+#else
-+ .data = &ieee802154_lowpan.frags.timeout,
-+#endif
- .maxlen = sizeof(int),
- .mode = 0644,
- .proc_handler = proc_dointvec_jiffies,
diff --git a/patches/0007-lowpan-inet_frag_lru_move.patch b/patches/0007-lowpan-inet_frag_lru_move.patch
deleted file mode 100644
index ef524148..00000000
--- a/patches/0007-lowpan-inet_frag_lru_move.patch
+++ /dev/null
@@ -1,59 +0,0 @@
-Domain specific backport for inet_frag_lru_move()
-This requires two parts, the data structure changes
-and then domain specific inet_frag_lru_move() define.
-
---- a/net/ieee802154/reassembly.c
-+++ b/net/ieee802154/reassembly.c
-@@ -89,6 +89,9 @@ static void lowpan_frag_init(struct inet
- fq->d_size = arg->d_size;
- fq->saddr = *arg->src;
- fq->daddr = *arg->dst;
-+#if LINUX_VERSION_IS_LESS(3,9,0)
-+ spin_lock_init(&fq->lru_lock);
-+#endif
- }
-
- static void lowpan_frag_expire(unsigned long data)
---- a/net/ieee802154/reassembly.h
-+++ b/net/ieee802154/reassembly.h
-@@ -2,6 +2,7 @@
- #define __IEEE802154_6LOWPAN_REASSEMBLY_H__
-
- #include <net/inet_frag.h>
-+#include <linux/spinlock.h>
-
- struct lowpan_create_arg {
- u16 tag;
-@@ -19,8 +20,32 @@ struct lowpan_frag_queue {
- u16 d_size;
- struct ieee802154_addr saddr;
- struct ieee802154_addr daddr;
-+#if LINUX_VERSION_IS_LESS(3,9,0)
-+ spinlock_t lru_lock;
-+#endif
- };
-
-+#if LINUX_VERSION_IS_LESS(3,9,0)
-+/*
-+ * XXX: this is a *domain* specific inet_frag_lru_move backport,
-+ * note the added lowpan_ prefix, this requires a respective patch
-+ * which extends struct lowpan_frag_queue with an lru_lock and
-+ * initializes it. We add this helper here to reduce the backport.
-+ * There is no way to generalize the other changes in the patch.
-+ */
-+#define inet_frag_lru_move LINUX_BACKPORT(lowpan_inet_frag_lru_move)
-+static inline void inet_frag_lru_move(struct inet_frag_queue *q)
-+{
-+ struct lowpan_frag_queue *fq;
-+
-+ fq = container_of(q, struct lowpan_frag_queue, q);
-+
-+ spin_lock(&fq->lru_lock);
-+ list_move_tail(&q->lru_list, &q->net->lru_list);
-+ spin_unlock(&fq->lru_lock);
-+}
-+#endif /* LINUX_VERSION_IS_LESS(3,9,0) */
-+
- static inline u32 ieee802154_addr_hash(const struct ieee802154_addr *a)
- {
- switch (a->mode) {
diff --git a/patches/0008-net-user-ns.patch b/patches/0008-net-user-ns.patch
deleted file mode 100644
index 79605c05..00000000
--- a/patches/0008-net-user-ns.patch
+++ /dev/null
@@ -1,17 +0,0 @@
-network namespaces didn't get usernamespaces pegged until 3.8
-via commit 038e7332b8.
-
---- a/net/ieee802154/reassembly.c
-+++ b/net/ieee802154/reassembly.c
-@@ -481,9 +481,11 @@ static int __net_init lowpan_frags_ns_sy
- table[1].extra2 = &ieee802154_lowpan->frags.high_thresh;
- table[2].data = &ieee802154_lowpan->frags.timeout;
-
-+#if LINUX_VERSION_IS_GEQ(3,8,0)
- /* Don't export sysctls to unprivileged users */
- if (net->user_ns != &init_user_ns)
- table[0].procname = NULL;
-+#endif /* LINUX_VERSION_IS_GEQ(3,8,0) */
- }
-
- hdr = register_net_sysctl(net, "net/ieee802154/6lowpan", table);
diff --git a/patches/0013-fix-makefile-includes/6lowpan.patch b/patches/0013-fix-makefile-includes/6lowpan.patch
deleted file mode 100644
index 70d0dd5a..00000000
--- a/patches/0013-fix-makefile-includes/6lowpan.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/net/6lowpan/core.c
-+++ b/net/6lowpan/core.c
-@@ -14,6 +14,7 @@
- #include <linux/module.h>
-
- #include <net/6lowpan.h>
-+#include <linux/if_arp.h>
-
- #include "6lowpan_i.h"
-
diff --git a/patches/0013-fix-makefile-includes/cfg802154.patch b/patches/0013-fix-makefile-includes/cfg802154.patch
deleted file mode 100644
index 93caa14a..00000000
--- a/patches/0013-fix-makefile-includes/cfg802154.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/include/net/cfg802154.h
-+++ b/include/net/cfg802154.h
-@@ -26,6 +26,7 @@
-
- struct wpan_phy;
- struct wpan_phy_cca;
-+struct wpan_dev;
-
- #ifdef CONFIG_IEEE802154_NL802154_EXPERIMENTAL
- struct ieee802154_llsec_device_key;
diff --git a/patches/0030-qdisc_tx_busylock/ieee802154.patch b/patches/0030-qdisc_tx_busylock/ieee802154.patch
deleted file mode 100644
index 3794a025..00000000
--- a/patches/0030-qdisc_tx_busylock/ieee802154.patch
+++ /dev/null
@@ -1,22 +0,0 @@
---- a/net/ieee802154/6lowpan_rtnl.c
-+++ b/net/ieee802154/6lowpan_rtnl.c
-@@ -428,7 +428,9 @@ static struct header_ops lowpan_header_o
- .create = lowpan_header_create,
- };
-
-+#if LINUX_VERSION_IS_GEQ(3,7,0)
- static struct lock_class_key lowpan_tx_busylock;
-+#endif
- static struct lock_class_key lowpan_netdev_xmit_lock_key;
-
- static void lowpan_set_lockdep_class_one(struct net_device *dev,
-@@ -442,7 +444,9 @@ static void lowpan_set_lockdep_class_one
- static int lowpan_dev_init(struct net_device *dev)
- {
- netdev_for_each_tx_queue(dev, lowpan_set_lockdep_class_one, NULL);
-+#if LINUX_VERSION_IS_GEQ(3,7,0)
- dev->qdisc_tx_busylock = &lowpan_tx_busylock;
-+#endif
- return 0;
- }
-
diff --git a/patches/0044-no_user_ns_in_net/ieee802154.patch b/patches/0044-no_user_ns_in_net/ieee802154.patch
deleted file mode 100644
index 6c3cd210..00000000
--- a/patches/0044-no_user_ns_in_net/ieee802154.patch
+++ /dev/null
@@ -1,30 +0,0 @@
---- a/net/ieee802154/dgram.c
-+++ b/net/ieee802154/dgram.c
-@@ -480,8 +480,13 @@ static int dgram_setsockopt(struct sock
- ro->want_ack = !!val;
- break;
- case WPAN_SECURITY:
-+#if LINUX_VERSION_IS_GEQ(3,8,0)
- if (!ns_capable(net->user_ns, CAP_NET_ADMIN) &&
- !ns_capable(net->user_ns, CAP_NET_RAW)) {
-+#else
-+ if (!capable(CAP_NET_ADMIN) &&
-+ !capable(CAP_NET_RAW)) {
-+#endif
- err = -EPERM;
- break;
- }
-@@ -504,8 +509,13 @@ static int dgram_setsockopt(struct sock
- }
- break;
- case WPAN_SECURITY_LEVEL:
-+#if LINUX_VERSION_IS_GEQ(3,8,0)
- if (!ns_capable(net->user_ns, CAP_NET_ADMIN) &&
- !ns_capable(net->user_ns, CAP_NET_RAW)) {
-+#else
-+ if (!capable(CAP_NET_ADMIN) &&
-+ !capable(CAP_NET_RAW)) {
-+#endif
- err = -EPERM;
- break;
- }
diff --git a/patches/0066-remove-netdev_ieee802154_ptr/cfg802154.patch b/patches/0066-remove-netdev_ieee802154_ptr/cfg802154.patch
deleted file mode 100644
index 04fd2394..00000000
--- a/patches/0066-remove-netdev_ieee802154_ptr/cfg802154.patch
+++ /dev/null
@@ -1,18 +0,0 @@
---- a/include/net/cfg802154.h
-+++ b/include/net/cfg802154.h
-@@ -359,6 +359,7 @@ struct wpan_dev {
-
- #define to_phy(_dev) container_of(_dev, struct wpan_phy, dev)
-
-+#if LINUX_VERSION_IS_GEQ(3,19,0)
- static inline int
- wpan_dev_hard_header(struct sk_buff *skb, struct net_device *dev,
- const struct ieee802154_addr *daddr,
-@@ -369,6 +370,7 @@ wpan_dev_hard_header(struct sk_buff *skb
-
- return wpan_dev->header_ops->create(skb, dev, daddr, saddr, len);
- }
-+#endif /* >= 3.19 */
-
- struct wpan_phy *
- wpan_phy_new(const struct cfg802154_ops *ops, size_t priv_size);
diff --git a/patches/0068-proto-hash/ieee802154.patch b/patches/0068-proto-hash/ieee802154.patch
deleted file mode 100644
index 9b5a9712..00000000
--- a/patches/0068-proto-hash/ieee802154.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-diff --git a/net/ieee802154/socket.c b/net/ieee802154/socket.c
-index e0bd013..9e78921 100644
---- a/net/ieee802154/socket.c
-+++ b/net/ieee802154/socket.c
-@@ -182,14 +182,20 @@ static int ieee802154_sock_ioctl(struct
- static HLIST_HEAD(raw_head);
- static DEFINE_RWLOCK(raw_lock);
-
-+#if LINUX_VERSION_IS_GEQ(4,6,0)
- static int raw_hash(struct sock *sk)
-+#else
-+static void raw_hash(struct sock *sk)
-+#endif
- {
- write_lock_bh(&raw_lock);
- sk_add_node(sk, &raw_head);
- sock_prot_inuse_add(sock_net(sk), sk->sk_prot, 1);
- write_unlock_bh(&raw_lock);
-
-+#if LINUX_VERSION_IS_GEQ(4,6,0)
- return 0;
-+#endif
- }
-
- static void raw_unhash(struct sock *sk)
-@@ -464,14 +470,20 @@ static inline struct dgram_sock *dgram_s
- return container_of(sk, struct dgram_sock, sk);
- }
-
-+#if LINUX_VERSION_IS_GEQ(4,6,0)
- static int dgram_hash(struct sock *sk)
-+#else
-+static void dgram_hash(struct sock *sk)
-+#endif
- {
- write_lock_bh(&dgram_lock);
- sk_add_node(sk, &dgram_head);
- sock_prot_inuse_add(sock_net(sk), sk->sk_prot, 1);
- write_unlock_bh(&dgram_lock);
-
-+#if LINUX_VERSION_IS_GEQ(4,6,0)
- return 0;
-+#endif
- }
-
- static void dgram_unhash(struct sock *sk)
-@@ -1031,11 +1043,15 @@ static int ieee802154_create(struct net
- sock_set_flag(sk, SOCK_ZAPPED);
-
- if (sk->sk_prot->hash) {
-+#if LINUX_VERSION_IS_GEQ(4,6,0)
- rc = sk->sk_prot->hash(sk);
- if (rc) {
- sk_common_release(sk);
- goto out;
- }
-+#else
-+ sk->sk_prot->hash(sk);
-+#endif
- }
-
- if (sk->sk_prot->init) {