Merge "diag: Fix issues with peripheral buffering control packets"
This commit is contained in:
commit
6ea21b3adb
|
@ -1150,9 +1150,12 @@ int diag_send_buffering_tx_mode_pkt(uint8_t peripheral,
|
|||
int err = 0;
|
||||
struct diag_ctrl_peripheral_tx_mode ctrl_pkt;
|
||||
|
||||
if (!peripheral || !params)
|
||||
if (!params)
|
||||
return -EIO;
|
||||
|
||||
if (peripheral >= NUM_PERIPHERALS)
|
||||
return -EINVAL;
|
||||
|
||||
if (!driver->feature[peripheral].peripheral_buffering) {
|
||||
pr_debug("diag: In %s, peripheral %d doesn't support buffering\n",
|
||||
__func__, peripheral);
|
||||
|
@ -1202,7 +1205,7 @@ int diag_send_buffering_wm_values(uint8_t peripheral,
|
|||
return -EIO;
|
||||
|
||||
if (peripheral >= NUM_PERIPHERALS)
|
||||
return -EIO;
|
||||
return -EINVAL;
|
||||
|
||||
if (!driver->feature[peripheral].peripheral_buffering) {
|
||||
pr_debug("diag: In %s, peripheral %d doesn't support buffering\n",
|
||||
|
|
Loading…
Reference in New Issue