mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-02 16:46:41 +07:00
usb: gadget: Remove dead branch code
'num' is a u8 variable, it never greater than 255, So the if branch is dead code and can be removed. Signed-off-by: YueHaibing <yuehaibing@huawei.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
This commit is contained in:
parent
f17b5f06cb
commit
d7c3eeffbc
@ -1570,10 +1570,6 @@ uvcg_uncompressed_##cname##_store(struct config_item *item, \
|
||||
if (ret) \
|
||||
goto end; \
|
||||
\
|
||||
if (num > 255) { \
|
||||
ret = -EINVAL; \
|
||||
goto end; \
|
||||
} \
|
||||
u->desc.aname = num; \
|
||||
ret = len; \
|
||||
end: \
|
||||
@ -1767,10 +1763,6 @@ uvcg_mjpeg_##cname##_store(struct config_item *item, \
|
||||
if (ret) \
|
||||
goto end; \
|
||||
\
|
||||
if (num > 255) { \
|
||||
ret = -EINVAL; \
|
||||
goto end; \
|
||||
} \
|
||||
u->desc.aname = num; \
|
||||
ret = len; \
|
||||
end: \
|
||||
|
Loading…
Reference in New Issue
Block a user