[PATCH] usb: host: remove unnecessary condition check

2018-11-02 Thread Chengguang Xu
dma_pool_destroy() can handle NULL pointer correctly, so there is no need to check NULL pointer before calling dma_pool_destroy(). Signed-off-by: Chengguang Xu --- drivers/usb/host/ohci-mem.c | 12 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/drivers/usb/host/ohci

[PATCH] usb: cast sizeof() to int when comparing with error code

2018-06-25 Thread Chengguang Xu
Negative error code will be larger than sizeof(). Signed-off-by: Chengguang Xu --- drivers/usb/serial/ir-usb.c | 2 +- drivers/usb/serial/quatech2.c | 2 +- drivers/usb/serial/ssu100.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/usb/serial/ir-usb.c b