Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

rtc: v3020: remove redundant initialization of variable retval

The variable retval is being initialized with a value that is never read,
it is being updated later on. The assignment is redundant and can be
removed.

Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Link: https://lore.kernel.org/r/20210609120050.185746-1-colin.king@canonical.com

authored by

Colin Ian King and committed by
Alexandre Belloni
fc3c3352 950ac33d

+1 -1
+1 -1
drivers/rtc/rtc-v3020.c
··· 282 282 { 283 283 struct v3020_platform_data *pdata = dev_get_platdata(&pdev->dev); 284 284 struct v3020 *chip; 285 - int retval = -EBUSY; 285 + int retval; 286 286 int i; 287 287 288 288 chip = devm_kzalloc(&pdev->dev, sizeof(*chip), GFP_KERNEL);