bluetooth: 6lowpan: use lowpan dispatch helpers
authorAlexander Aring <alex.aring@gmail.com>
Tue, 13 Oct 2015 11:42:55 +0000 (13:42 +0200)
committerMarcel Holtmann <marcel@holtmann.org>
Tue, 20 Oct 2015 22:49:24 +0000 (00:49 +0200)
commitcefdb801c80736017b5a0d97a4a9f816d5a98fc4
treeb24038cd412000fafe0e31dcb01a0166572c641f
parent71cd2aa53dbf9eb8cb954fc9e65de8dab774b7f6
bluetooth: 6lowpan: use lowpan dispatch helpers

This patch adds a check if the dataroom of skb contains a dispatch value
by checking if skb->len != 0. This patch also change the dispatch
evaluation by the recently introduced helpers for checking the common
6LoWPAN dispatch values for IPv6 and IPHC header.

There was also a forgotten else branch which should drop the packet if
no matching dispatch is available.

Signed-off-by: Alexander Aring <alex.aring@gmail.com>
Acked-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
net/bluetooth/6lowpan.c