Re: [PATCH 1/2] tools/mgmt-tester: Add RPA Add Device test case

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

 



Hi Jakub,

On Mon, Jul 13, 2015, Jakub Pawlowski wrote:
> +static const uint8_t add_device_nval_4[] = {
> +					0x12, 0x34, 0x56, 0x78, 0x9a, 0xbc,
> +					0x02,
> +					0x02,
> +};
> +static const uint8_t add_device_rsp_4[] =  {
> +					0x12, 0x34, 0x56, 0x78, 0x9a, 0xbc,
> +					0x02,
> +};
> +static const struct generic_data add_device_fail_4 = {
> +	.send_opcode = MGMT_OP_ADD_DEVICE,
> +	.send_param = add_device_nval_4,
> +	.send_len = sizeof(add_device_nval_4),
> +	.expect_param = add_device_rsp_4,
> +	.expect_len = sizeof(add_device_rsp_4),
> +	.expect_status = MGMT_STATUS_FAILED,

Why is the kernel returning FAILED here? Wouldn't INVALID_PARAMS be a
more accurate error (since you're passing invalid parameters to the mgmt
command).

If I got this right it's the hci_conn_params_set() call that's failing
and mapping to FAILED? You might want to update that function to use
a ERR_PTR() return and then look at the returned value to decide what
mgmt error to send.

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