Lines Matching refs:ldev
61 static int lowpan_dev_init(struct net_device *ldev) in lowpan_dev_init() argument
63 netdev_lockdep_set_classes(ldev); in lowpan_dev_init()
107 static void lowpan_setup(struct net_device *ldev) in lowpan_setup() argument
109 memset(ldev->broadcast, 0xff, IEEE802154_ADDR_LEN); in lowpan_setup()
111 ldev->hard_header_len = sizeof(struct ipv6hdr); in lowpan_setup()
112 ldev->flags = IFF_BROADCAST | IFF_MULTICAST; in lowpan_setup()
113 ldev->priv_flags |= IFF_NO_QUEUE; in lowpan_setup()
115 ldev->netdev_ops = &lowpan_netdev_ops; in lowpan_setup()
116 ldev->header_ops = &lowpan_header_ops; in lowpan_setup()
117 ldev->needs_free_netdev = true; in lowpan_setup()
118 ldev->features |= NETIF_F_NETNS_LOCAL; in lowpan_setup()
131 static int lowpan_newlink(struct net *src_net, struct net_device *ldev, in lowpan_newlink() argument
145 wdev = dev_get_by_index(dev_net(ldev), nla_get_u32(tb[IFLA_LINK])); in lowpan_newlink()
158 lowpan_802154_dev(ldev)->wdev = wdev; in lowpan_newlink()
160 memcpy(ldev->dev_addr, wdev->dev_addr, IEEE802154_ADDR_LEN); in lowpan_newlink()
167 ldev->needed_headroom = LOWPAN_IPHC_MAX_HEADER_LEN + in lowpan_newlink()
169 ldev->needed_tailroom = wdev->needed_tailroom; in lowpan_newlink()
171 ldev->neigh_priv_len = sizeof(struct lowpan_802154_neigh); in lowpan_newlink()
173 ret = lowpan_register_netdevice(ldev, LOWPAN_LLTYPE_IEEE802154); in lowpan_newlink()
179 wdev->ieee802154_ptr->lowpan_dev = ldev; in lowpan_newlink()
183 static void lowpan_dellink(struct net_device *ldev, struct list_head *head) in lowpan_dellink() argument
185 struct net_device *wdev = lowpan_802154_dev(ldev)->wdev; in lowpan_dellink()
190 lowpan_unregister_netdevice(ldev); in lowpan_dellink()