Skip to content

wpan-tools: new netlink interfaces calls

Alexander Aring linux-wpan 2 versions In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest6 patches 1 replyIn review
  2. v16 patches 2 repliesSuperseded

changes since v2 from the cover letter

- remove stolen LGPL code and reimplement a own header for unsupported netlink attributes of the netlink library. Maybe somebody should add it to netlink...

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/6nl_extras: initial commit for extra nl bindingssrc/nl_extras.h+36 -01 reply
2/6phy: add support for tx power pib attributesrc/nl802154.h src/phy.c+32 -00 replies
3/6phy: add support for setting cca_modesrc/nl802154.h src/phy.c+30 -00 replies
4/6mac: add support for setting max_frame_retriessrc/mac.c src/nl802154.h+33 -00 replies
5/6mac: initial support for setting csma paramssrc/mac.c src/nl802154.h+92 -00 replies
6/6phy: add support for cca mode 3 and/or handlingsrc/nl802154.h src/phy.c+15 -20 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCHv2 wpan-tools 0/6] wpan-tools: new netlink interfaces calls

Hi all,

this patch series adds support for new netlink interfaces. For all new users on this mailinglist. This is the new userspace tool for the wpan rework [0] branch.

I removed the mib lock in the rework. Now you can only set the pan_id or short address (don't implement the setting of short address now) when the netdevice is _down_.

Then we don't need the the mib lock anymore. It's protected by RTNL if netdevice is down. When it's up it's a read only variable and we can use the variable in hot path like tx/rx without locking. (This is like setting and use of dev_addr of an netdev device).

I disabled the af802154 and security layer for now, but I will add this later at the end of the rework.

I also detected that our cca_mode handling is a driver specific netlink call. This is... not good. :-) And this is the current mainline behaviour...

In the rework I added enums for the 802.15.4 CCA_MODE numbers and now the at86rf231 makes a mapping from 802.15.4 specifc CCA_MODE to driver cca_mode( which is the register value).

I need to begin to write more text about the new behaviour, is there anybody outside who already test something?

We don't have the multiple phy layer, I dropped them. This was needed for the channel hoping. We need some new idea to provide a channel hoping logic, or simple but the logic for this in userspace. (You can change the channel while netdev is up).

There are several other netlink interfaces (setting short_address,setting energy detection value of phy)

The energy detection level is not part of the 802.15.4 pib, so this will be a direct call to the driver (not saving any value of this in the pib).

- Alex

[0] https://github.com/linux-wpan/linux-wpan-next/tree/wpan_rework_rfc

changes since v2:
- remove stolen LGPL code and reimplement a own header for unsupported netlink attributes of the netlink library. Maybe somebody should add it to netlink...

Alexander Aring (6):
nl_extras: initial commit for extra nl bindings
phy: add support for tx power pib attribute
phy: add support for setting cca_mode
mac: add support for setting max_frame_retries
mac: initial support for setting csma params
phy: add support for cca mode 3 and/or handling

 src/mac.c       | 113 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 src/nl802154.h  |  20 ++++++++++
 src/nl_extras.h |  36 ++++++++++++++++++
 src/phy.c       |  67 +++++++++++++++++++++++++++++++++
 4 files changed, 236 insertions(+)
 create mode 100644 src/nl_extras.h
Signature · 1 line
2.1.0