Hi Aring, > On Mon, Jul 13, 2015 at 01:50:33PM +0200, Lukasz Duda wrote: > > Allocating context table for stateful compression when interface is > > set up. Removing context table when interface is being unregistered. > > > > Signed-off-by: Lukasz Duda <lukasz.duda@xxxxxxxxxxxxx> > > Signed-off-by: Glenn Ruben Bakke <glenn.ruben.bakke@xxxxxxxxxxxxx> > > --- > > net/bluetooth/6lowpan.c | 4 ++++ > > 1 file changed, 4 insertions(+) > > > > diff --git a/net/bluetooth/6lowpan.c b/net/bluetooth/6lowpan.c index > > 2fb7b30..60c7e80 100644 > > --- a/net/bluetooth/6lowpan.c > > +++ b/net/bluetooth/6lowpan.c > > @@ -871,6 +871,9 @@ static int setup_netdev(struct l2cap_chan *chan, > struct lowpan_dev **dev) > > &chan->src, chan->src_type); > > set_bit(__LINK_STATE_PRESENT, &netdev->state); > > > > + /* Allocate context table for stateful compression. */ > > + lowpan_context_table_alloc(netdev); > > + > > *dev = netdev_priv(netdev); > > (*dev)->netdev = netdev; > > (*dev)->hdev = chan->conn->hcon->hdev; @@ -1415,6 +1418,7 @@ > static > > int device_event(struct notifier_block *unused, > > if (entry->netdev == netdev) { > > BT_DBG("Unregistered netdev %s %p", > > netdev->name, netdev); > > + lowpan_context_table_free(netdev); > > list_del(&entry->list); > > break; > > } > > Don't we need similar allocation in net/ieee802154/6lowpan/core.c ? > > - Alex Yes we need the same for IEEE802.15.4. Since I can test stateful compression feature only with BT-LE right now, I decided to not touch this part. However this is an obvious goal to create generic stateful compression for all set of 6LoWPAN protocols. Regards, Łukasz ��.n��������+%������w��{.n�����{����^n�r������&��z�ޗ�zf���h���~����������_��+v���)ߣ�