All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alexander Aring <alex.aring@gmail.com>
To: Matteo Petracca <matteo.petracca@sssup.it>
Cc: linux-wpan@vger.kernel.org
Subject: Re: Ieee802154 socket problem with SIOCGIFADDR
Date: Tue, 12 May 2015 12:33:05 +0200	[thread overview]
Message-ID: <20150512103301.GD733@omega> (raw)
In-Reply-To: <5551CC74.60702@sssup.it>

On Tue, May 12, 2015 at 11:48:36AM +0200, Matteo Petracca wrote:
> You were right, I did not remove the Assertion.
> 
> Now the patch is all there and the modules are
> updated.
> 
> What happens now is a strange behaviour, booting
> the system I just turn on the wpan interface putting
> as panid 0xaaaa:
> 
> ifconfig wpan0 up
> 
> the device starts to read from the network, and this is
> what I have in output with dmesg is:
> 
> [  131.445285] ieee802154: bad frame received (type = 3)
> [  133.777933] ieee802154: bad frame received (type = 3)
> [  136.110635] ieee802154: bad frame received (type = 3)
> [  148.318471] ieee802154: bad frame received (type = 3)
> [  150.651288] ieee802154: bad frame received (type = 3)
> [  152.984910] ieee802154: bad frame received (type = 3)
> [  165.195277] ieee802154: bad frame received (type = 3)
> [  167.527936] ieee802154: bad frame received (type = 3)
> [  169.860422] ieee802154: bad frame received (type = 3)
> [  182.071635] ieee802154: bad frame received (type = 3)
> [  184.406857] ieee802154: bad frame received (type = 3)
> [  186.739487] ieee802154: bad frame received (type = 3)
> [  198.947054] ieee802154: bad frame received (type = 3)
> [  201.279710] ieee802154: bad frame received (type = 3)
> [  203.612262] ieee802154: bad frame received (type = 3)
> [  215.819843] ieee802154: bad frame received (type = 3)
> [  218.155852] ieee802154: bad frame received (type = 3)
> [  220.488465] ieee802154: bad frame received (type = 3)
> 
> Moreover SIOCGIFADDR still does not work.
> 

This is a behaviour because we have lack of support to parse mac_cmd
frames [0]. And I see now I already told you that! [1]

The current parsing mechanism is very dataframes specfic there is an 
draft for reworking this frame parsing style and do it like mac80211
(which have a lot of more frametypes than 802.15.4). See [2]:
"new frame parsing style in mac802154 and ieee802154 based on mac80211
frame parsing design. Draft is mac802154 rx and 6LoWPAN. Crypto need to
be done at first, otherwise I can’t test it."

Nevertheless it needs time to supporting it, you could simple add a case
that the frame is delivered to userspace, but then this frame could not
valid 802.15.4 frametype and you need to check that again in userspace.

I also noticed that the raw socket don't put the mac header into payload
(which should it do), see [3] (that's something which already told you).

and yes, the 802.15.4 sockets needs a complete rework/cleanup. This is
an opentask section at [4], we should orient us at bluetooth socket
code.

- Alex

[0] http://git.kernel.org/cgit/linux/kernel/git/bluetooth/bluetooth-next.git/tree/net/mac802154/rx.c#n104
[1] http://www.spinics.net/lists/linux-wpan/msg01623.html
[2] http://wpan.cakelab.org/
[3] http://www.spinics.net/lists/linux-wpan/msg01623.html
[4] http://wpan.cakelab.org/


      reply	other threads:[~2015-05-12 10:33 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-09 14:41 Ieee802154 socket problem with SIOCGIFADDR Matteo Petracca
2015-05-09 16:42 ` Alexander Aring
2015-05-11 16:43   ` Matteo Petracca
2015-05-11 16:51     ` Alexander Aring
2015-05-11 16:58       ` Matteo Petracca
2015-05-11 17:29         ` Alexander Aring
2015-05-11 17:37       ` Alexander Aring
2015-05-11 17:51     ` Alexander Aring
2015-05-12  8:32       ` Matteo Petracca
2015-05-12  8:39         ` Alexander Aring
2015-05-12  9:48           ` Matteo Petracca
2015-05-12 10:33             ` Alexander Aring [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150512103301.GD733@omega \
    --to=alex.aring@gmail.com \
    --cc=linux-wpan@vger.kernel.org \
    --cc=matteo.petracca@sssup.it \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.