Re: [PATCH] net: ieee802154: adf7242: Fix erroneous RX enable

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello.

[Just back from a a few weeks leave and catching up]

On 25.06.2018 15:49, Alexandru Ardelean wrote:
> From: Michael Hennerich <michael.hennerich@xxxxxxxxxx>
> 
> Only enable RX mode if the netdev is opened.
> 
> Signed-off-by: Michael Hennerich <michael.hennerich@xxxxxxxxxx>
> Signed-off-by: Alexandru Ardelean <alexandru.ardelean@xxxxxxxxxx>
> ---
>  drivers/net/ieee802154/adf7242.c | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/net/ieee802154/adf7242.c b/drivers/net/ieee802154/adf7242.c
> index 3e85e9500233..0a240a3f7817 100644
> --- a/drivers/net/ieee802154/adf7242.c
> +++ b/drivers/net/ieee802154/adf7242.c
> @@ -739,7 +739,10 @@ static int adf7242_channel(struct ieee802154_hw *hw, u8 page, u8 channel)
>  	adf7242_write_reg(lp, REG_CH_FREQ1, freq >> 8);
>  	adf7242_write_reg(lp, REG_CH_FREQ2, freq >> 16);
>  
> -	return adf7242_cmd(lp, CMD_RC_RX);
> +	if (test_bit(FLAG_START, &lp->flags))
> +		return adf7242_cmd_rx(lp);
> +	else
> +		return adf7242_cmd(lp, CMD_RC_PHY_RDY);

What is the difference between the CMD_RC_PHY_RDY and the CMD_RC_RX
command here. From the commit log I would have expected the if check but
not a change in the issued command?

regards
Stefan Schmidt
--
To unsubscribe from this list: send the line "unsubscribe linux-wpan" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux