From 11974ace2d8681ae3efe027b4020869ccee48878 Mon Sep 17 00:00:00 2001 From: Christian Gromm Date: Thu, 28 May 2020 14:41:43 +0200 Subject: [PATCH] staging: most: usb: init return value in default path of switch/case expression This patch avoids returning an uninitialized value in the default path of the switch expression. Signed-off-by: Christian Gromm Reported-by: Dan Carpenter Link: https://lore.kernel.org/r/1590669703-20004-1-git-send-email-christian.gromm@microchip.com Signed-off-by: Greg Kroah-Hartman --- drivers/staging/most/usb/usb.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/staging/most/usb/usb.c b/drivers/staging/most/usb/usb.c index df5876c..2640c5b 100644 --- a/drivers/staging/most/usb/usb.c +++ b/drivers/staging/most/usb/usb.c @@ -215,6 +215,7 @@ static unsigned int get_stream_frame_size(struct device *dev, break; default: dev_warn(dev, "Query frame size of non-streaming channel\n"); + frame_size = 0; break; } return frame_size; -- 2.7.4