All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stefan Schmidt <stefan@datenfreihafen.org>
To: Miquel Raynal <miquel.raynal@bootlin.com>,
	Alexander Aring <alex.aring@gmail.com>,
	linux-wpan@vger.kernel.org
Cc: "David S. Miller" <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>,
	netdev@vger.kernel.org, David Girault <david.girault@qorvo.com>,
	Romuald Despres <romuald.despres@qorvo.com>,
	Frederic Blain <frederic.blain@qorvo.com>,
	Nicolas Schodet <nico@ni.fr.eu.org>,
	Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Subject: Re: [wpan v3 1/6] net: ieee802154: hwsim: Ensure proper channel selection at probe time
Date: Tue, 25 Jan 2022 15:28:11 +0100	[thread overview]
Message-ID: <d3cab1bb-184d-73f9-7bd8-8eefc5e7e70c@datenfreihafen.org> (raw)
In-Reply-To: <20220125121426.848337-2-miquel.raynal@bootlin.com>


Hello.

On 25.01.22 13:14, Miquel Raynal wrote:
> Drivers are expected to set the PHY current_channel and current_page
> according to their default state. The hwsim driver is advertising being
> configured on channel 13 by default but that is not reflected in its own
> internal pib structure. In order to ensure that this driver consider the
> current channel as being 13 internally, we at least need to set the
> pib->channel field to 13.
> 
> Fixes: f25da51fdc38 ("ieee802154: hwsim: add replacement for fakelb")
> Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
> ---
>   drivers/net/ieee802154/mac802154_hwsim.c | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/net/ieee802154/mac802154_hwsim.c b/drivers/net/ieee802154/mac802154_hwsim.c
> index 8caa61ec718f..00ec188a3257 100644
> --- a/drivers/net/ieee802154/mac802154_hwsim.c
> +++ b/drivers/net/ieee802154/mac802154_hwsim.c
> @@ -786,6 +786,7 @@ static int hwsim_add_one(struct genl_info *info, struct device *dev,
>   		goto err_pib;
>   	}
>   
> +	pib->page = 13;

You want to set channel not page here.

>   	rcu_assign_pointer(phy->pib, pib);
>   	phy->idx = idx;
>   	INIT_LIST_HEAD(&phy->edges);
> 

regards
Stefan Schmidt

  reply	other threads:[~2022-01-25 14:35 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-25 12:14 [wpan v3 0/6] ieee802154: A bunch of fixes Miquel Raynal
2022-01-25 12:14 ` [wpan v3 1/6] net: ieee802154: hwsim: Ensure proper channel selection at probe time Miquel Raynal
2022-01-25 14:28   ` Stefan Schmidt [this message]
2022-01-25 16:48     ` Miquel Raynal
2022-01-26 13:38       ` Stefan Schmidt
2022-01-26 22:54         ` Alexander Aring
2022-01-27  7:33           ` Stefan Schmidt
2022-01-27  8:45             ` Miquel Raynal
2022-01-25 12:14 ` [wpan v3 2/6] net: ieee802154: mcr20a: Fix lifs/sifs periods Miquel Raynal
2022-01-25 12:14 ` [wpan v3 3/6] net: ieee802154: at86rf230: Stop leaking skb's Miquel Raynal
2022-01-25 12:14 ` [wpan v3 4/6] net: ieee802154: ca8210: " Miquel Raynal
2022-01-25 12:14 ` [wpan v3 5/6] net: ieee802154: Return meaningful error codes from the netlink helpers Miquel Raynal
2022-01-25 12:14 ` [wpan v3 6/6] MAINTAINERS: Remove Harry Morris bouncing address Miquel Raynal
2022-01-27  7:33 ` [wpan v3 0/6] ieee802154: A bunch of fixes Stefan Schmidt

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=d3cab1bb-184d-73f9-7bd8-8eefc5e7e70c@datenfreihafen.org \
    --to=stefan@datenfreihafen.org \
    --cc=alex.aring@gmail.com \
    --cc=davem@davemloft.net \
    --cc=david.girault@qorvo.com \
    --cc=frederic.blain@qorvo.com \
    --cc=kuba@kernel.org \
    --cc=linux-wpan@vger.kernel.org \
    --cc=miquel.raynal@bootlin.com \
    --cc=netdev@vger.kernel.org \
    --cc=nico@ni.fr.eu.org \
    --cc=romuald.despres@qorvo.com \
    --cc=thomas.petazzoni@bootlin.com \
    /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.