Three functions use the same method to check incoming parameters. The
'len' parameter can be equal to 0 in case of a 'set' operation.
Currently these functions return an error code under that condition,
which is incorrect. The problem was introduced in recent patches in
which asserts were removed from the fullmac.
Despite this being a bug, my regression testing has not shown any problems.
Reported-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Roland Vossen <rvossen@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
bool bool_val;
u32 actionid;
- if (name == NULL || len <= 0)
+ if (name == NULL || len < 0)
return -EINVAL;
/* Set does not take qualifiers */
BRCMF_TRACE(("%s: Enter\n", __func__));
- if (name == NULL || len <= 0)
+ if (name == NULL || len < 0)
return -EINVAL;
/* Set does not take qualifiers */
BRCMF_TRACE(("%s: Enter\n", __func__));
- if (name == NULL || len <= 0)
+ if (name == NULL || len < 0)
return -EINVAL;
/* Set does not take qualifiers */