Re: [PATCH] emulator: Swap max and min interval

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

 



Hi Arek,

On Wed, Aug 12, 2015, Arkadiusz Lichwa wrote:
> Fixes btdev controller bits when assigning actual parameters,
> max and min interval, in LE Meta event for LE Connection Update to be sent 
> to host.
> ---
>  emulator/btdev.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/emulator/btdev.c b/emulator/btdev.c
> index cd211ef..57e51a0 100644
> --- a/emulator/btdev.c
> +++ b/emulator/btdev.c
> @@ -3322,8 +3322,8 @@ static void default_cmd_completion(struct btdev *btdev, uint16_t opcode,
>  			return;
>  		lecu = data;
>  		le_conn_update(btdev, le16_to_cpu(lecu->handle),
> -				le16_to_cpu(lecu->min_interval),
>  				le16_to_cpu(lecu->max_interval),
> +				le16_to_cpu(lecu->min_interval),
>  				le16_to_cpu(lecu->latency),
>  				le16_to_cpu(lecu->supv_timeout),
>  				le16_to_cpu(lecu->min_length),

Good catch, but I think it makes more sense to keep the order as min,
max since that's how it is in HCI as well. Since this is such a trivial
thing I went ahead and fixed is myself (i.e. swapped the order in the
function instead of the caller).

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



[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux