Release 4.11 net/802/p8023.c
/*
* NET3: 802.3 data link hooks used for IPX 802.3
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version
* 2 of the License, or (at your option) any later version.
*
* 802.3 isn't really a protocol data link layer. Some old IPX stuff
* uses it however. Note that there is only one 802.3 protocol layer
* in the system. We don't currently support different protocols
* running raw 802.3 on different devices. Thankfully nobody else
* has done anything like the old IPX.
*/
#include <linux/in.h>
#include <linux/mm.h>
#include <linux/module.h>
#include <linux/netdevice.h>
#include <linux/skbuff.h>
#include <linux/slab.h>
#include <net/datalink.h>
#include <net/p8022.h>
/*
* Place an 802.3 header on a packet. The driver will do the mac
* addresses, we just need to give it the buffer length.
*/
static int p8023_request(struct datalink_proto *dl,
struct sk_buff *skb, unsigned char *dest_node)
{
struct net_device *dev = skb->dev;
dev_hard_header(skb, dev, ETH_P_802_3, dest_node, NULL, skb->len);
return dev_queue_xmit(skb);
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Linus Torvalds (pre-git) | 44 | 83.02% | 3 | 60.00% |
Arnaldo Carvalho de Melo | 8 | 15.09% | 1 | 20.00% |
Stephen Hemminger | 1 | 1.89% | 1 | 20.00% |
Total | 53 | 100.00% | 5 | 100.00% |
/*
* Create an 802.3 client. Note there can be only one 802.3 client
*/
struct datalink_proto *make_8023_client(void)
{
struct datalink_proto *proto = kmalloc(sizeof(*proto), GFP_ATOMIC);
if (proto) {
proto->header_length = 0;
proto->request = p8023_request;
}
return proto;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Linus Torvalds (pre-git) | 42 | 91.30% | 2 | 50.00% |
Arnaldo Carvalho de Melo | 4 | 8.70% | 2 | 50.00% |
Total | 46 | 100.00% | 4 | 100.00% |
/*
* Destroy the 802.3 client.
*/
void destroy_8023_client(struct datalink_proto *dl)
{
kfree(dl);
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Linus Torvalds (pre-git) | 15 | 100.00% | 2 | 100.00% |
Total | 15 | 100.00% | 2 | 100.00% |
EXPORT_SYMBOL(destroy_8023_client);
EXPORT_SYMBOL(make_8023_client);
MODULE_LICENSE("GPL");
Overall Contributors
Person | Tokens | Prop | Commits | CommitProp |
Linus Torvalds (pre-git) | 115 | 73.25% | 7 | 53.85% |
Arnaldo Carvalho de Melo | 33 | 21.02% | 3 | 23.08% |
Dave Jones | 5 | 3.18% | 1 | 7.69% |
Tejun Heo | 3 | 1.91% | 1 | 7.69% |
Stephen Hemminger | 1 | 0.64% | 1 | 7.69% |
Total | 157 | 100.00% | 13 | 100.00% |
Information contained on this website is for historical information purposes only and does not indicate or represent copyright ownership.