Re: [PATCH wpan-next v3 11/11] ieee802154: Give the user the association list

2023-09-18 Thread kernel test robot
Hi Miquel, kernel test robot noticed the following build errors: [auto build test ERROR on net-next/main] [also build test ERROR on net/main linus/master v6.6-rc2 next-20230918] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use

Re: [PATCH wpan-next v2 02/11] ieee802154: Internal PAN management

2023-09-18 Thread Alexander Aring
Hi, On Mon, Sep 18, 2023 at 10:15 AM Miquel Raynal wrote: > > Hi Alexander, > > > > > > > > +// SPDX-License-Identifier: GPL-2.0 > > > > > > +/* > > > > > > + * IEEE 802.15.4 PAN management > > > > > > + * > > > > > > + * Copyright (C) 2021 Qorvo US, Inc > > > > > > + * Authors: > > > > > > + *

[PATCH wpan-next v3 09/11] mac802154: Follow the number of associated devices

2023-09-18 Thread Miquel Raynal
Track the count of associated devices. Limit the number of associations using the value provided by the user if any. If we reach the maximum number of associations, we tell the device we are at capacity. If the user do not want to accept any more associations, it may specify the value 0 to the maxi

Re: [PATCH wpan-next v2 11/11] ieee802154: Give the user the association list

2023-09-18 Thread Stefan Schmidt
Hello Miquel. On 18.09.23 09:08, Miquel Raynal wrote: Hi Stefan, ste...@datenfreihafen.org wrote on Sat, 16 Sep 2023 17:36:41 +0200: Hello Miquel. On 01.09.23 19:05, Miquel Raynal wrote: Upon request, we must be able to provide to the user the list of associations currently in place. Let's

Re: [PATCH wpan-next v2 02/11] ieee802154: Internal PAN management

2023-09-18 Thread Miquel Raynal
Hi Alexander, > > > > > +// SPDX-License-Identifier: GPL-2.0 > > > > > +/* > > > > > + * IEEE 802.15.4 PAN management > > > > > + * > > > > > + * Copyright (C) 2021 Qorvo US, Inc > > > > > + * Authors: > > > > > + * - David Girault > > > > > + * - Miquel Raynal > > > > > + */ > > > > > + >

[PATCH wpan-next v3 06/11] mac802154: Handle disassociations

2023-09-18 Thread Miquel Raynal
Devices may decide to disassociate from their coordinator for different reasons (device turning off, coordinator signal strength too low, etc), the MAC layer just has to send a disassociation notification. If the ack of the disassociation notification is not received, the device may consider itsel

[PATCH wpan-next v3 07/11] mac802154: Handle association requests from peers

2023-09-18 Thread Miquel Raynal
Coordinators may have to handle association requests from peers which want to join the PAN. The logic involves: - Acknowledging the request (done by hardware) - If requested, a random short address that is free on this PAN should be chosen for the device. - Sending an association response with th

[PATCH wpan-next v3 02/11] ieee802154: Internal PAN management

2023-09-18 Thread Miquel Raynal
Introduce structures to describe peer devices in a PAN as well as a few related helpers. We basically care about: - Our unique parent after associating with a coordinator. - Peer devices, children, which successfully associated with us. Signed-off-by: Miquel Raynal --- include/net/cfg802154.h |

[PATCH wpan-next v3 08/11] ieee802154: Add support for limiting the number of associated devices

2023-09-18 Thread Miquel Raynal
Coordinators may refuse associations. We need a user input for that. Let's add a new netlink command which can provide a maximum number of devices we accept to associate with as a first step. Later, we could also forward the request to userspace and check whether the association should be accepted

[PATCH wpan-next v3 01/11] ieee802154: Let PAN IDs be reset

2023-09-18 Thread Miquel Raynal
Soon association and disassociation will be implemented, which will require to be able to either change the PAN ID from 0x to a real value when association succeeded, or to reset the PAN ID to 0x upon disassociation. Let's allow to do that manually for now. Signed-off-by: Miquel Raynal --

[PATCH wpan-next v3 00/11] ieee802154: Associations between devices

2023-09-18 Thread Miquel Raynal
Hello, [I know we are in the middle of the merge window, I don't think it matters on the wpan side, so as the wpan subsystem did not evolve much since the previous merge window I figured I would not delay the sending of this series given the fact that I should have send it at the beginning of the

[PATCH wpan-next v3 03/11] ieee802154: Add support for user association requests

2023-09-18 Thread Miquel Raynal
Users may decide to associate with a peer, which becomes our parent coordinator. Let's add the necessary netlink support for this. Signed-off-by: Miquel Raynal --- include/net/cfg802154.h | 4 +++ include/net/ieee802154_netdev.h | 38 + include/net/nl802154.h

[PATCH wpan-next v3 11/11] ieee802154: Give the user the association list

2023-09-18 Thread Miquel Raynal
Upon request, we must be able to provide to the user the list of associations currently in place. Let's add a new netlink command and attribute for this purpose. Signed-off-by: Miquel Raynal --- include/net/nl802154.h| 18 ++- net/ieee802154/nl802154.c | 101

[PATCH wpan-next v3 05/11] ieee802154: Add support for user disassociation requests

2023-09-18 Thread Miquel Raynal
A device may decide at some point to disassociate from a PAN, let's introduce a netlink command for this purpose. Signed-off-by: Miquel Raynal --- include/net/cfg802154.h | 3 +++ include/net/ieee802154_netdev.h | 11 + include/net/nl802154.h | 1 + net/ieee802154/nl80

[PATCH wpan-next v3 10/11] mac802154: Handle disassociation notifications from peers

2023-09-18 Thread Miquel Raynal
Peers may decided to disassociate from us, their coordinator, in this case they will send a disassociation notification which we must acknowledge. If we don't, the peer device considers itself disassociated anyway. We also need to drop the reference to this child from our internal structures. Sign

[PATCH wpan-next v3 04/11] mac802154: Handle associating

2023-09-18 Thread Miquel Raynal
Joining a PAN officially goes by associating with a coordinator. This coordinator may have been discovered thanks to the beacons it sent in the past. Add support to the MAC layer for these associations, which require: - Sending an association request - Receiving an association response The associa

Re: [PATCH wpan-next v3 00/11] ieee802154: Associations between devices

2023-09-18 Thread Miquel Raynal
miquel.ray...@bootlin.com wrote on Mon, 18 Sep 2023 17:07:58 +0200: > Hello, > > [I know we are in the middle of the merge window, I don't think it > matters on the wpan side, so as the wpan subsystem did not evolve > much since the previous merge window I figured I would not delay the > sendin

Re: [PATCH wpan-next v2 02/11] ieee802154: Internal PAN management

2023-09-18 Thread Alexander Aring
Hi, On Mon, Sep 18, 2023 at 5:01 AM Miquel Raynal wrote: > > Hello, > > aahri...@redhat.com wrote on Sun, 17 Sep 2023 07:50:55 -0400: > > > Hi, > > > > On Sat, Sep 16, 2023 at 11:39 AM Stefan Schmidt > > wrote: > > > > > > Hello Miquel. > > > > > > On 01.09.23 19:04, Miquel Raynal wrote: > > > >

Re: [PATCH wpan-next v2 02/11] ieee802154: Internal PAN management

2023-09-18 Thread Miquel Raynal
Hello, aahri...@redhat.com wrote on Sun, 17 Sep 2023 07:50:55 -0400: > Hi, > > On Sat, Sep 16, 2023 at 11:39 AM Stefan Schmidt > wrote: > > > > Hello Miquel. > > > > On 01.09.23 19:04, Miquel Raynal wrote: > > > Introduce structures to describe peer devices in a PAN as well as a few > > > rel

Re: [PATCH wpan-next v2 07/11] mac802154: Handle association requests from peers

2023-09-18 Thread Miquel Raynal
Hi Stefan, > > +static int > > +mac802154_send_association_resp_locked(struct ieee802154_sub_if_data > > *sdata, > > + struct ieee802154_pan_device *target, > > + struct ieee802154_assoc_resp_pl > > *assoc_resp_pl) > > +{ > > +

Re: [PATCH wpan-next v2 11/11] ieee802154: Give the user the association list

2023-09-18 Thread Miquel Raynal
Hi Stefan, ste...@datenfreihafen.org wrote on Sat, 16 Sep 2023 17:36:41 +0200: > Hello Miquel. > > On 01.09.23 19:05, Miquel Raynal wrote: > > Upon request, we must be able to provide to the user the list of > > associations currently in place. Let's add a new netlink command and > > attribute f