From: Andy Shevchenko Date: Sat, 9 Jul 2022 21:16:52 +0000 (+0300) Subject: platform/x86: serial-multi-instantiate: Get rid of redundant 'else' X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=f3e13bbc6f5a84f9c15883a97649023522eec481;p=linux.git platform/x86: serial-multi-instantiate: Get rid of redundant 'else' In the snippets like the following if (...) return / goto / break / continue ...; else ... the 'else' is redundant. Get rid of it. Signed-off-by: Andy Shevchenko Reviewed-by: Hans de Goede Link: https://lore.kernel.org/r/20220709211653.18938-5-andriy.shevchenko@linux.intel.com Signed-off-by: Hans de Goede --- diff --git a/drivers/platform/x86/serial-multi-instantiate.c b/drivers/platform/x86/serial-multi-instantiate.c index 0a2335693f4fd..24f915bbdec14 100644 --- a/drivers/platform/x86/serial-multi-instantiate.c +++ b/drivers/platform/x86/serial-multi-instantiate.c @@ -98,7 +98,7 @@ static int smi_spi_probe(struct platform_device *pdev, struct smi *smi, ret = acpi_spi_count_resources(adev); if (ret < 0) return ret; - else if (!ret) + if (!ret) return -ENOENT; count = ret; @@ -180,7 +180,7 @@ static int smi_i2c_probe(struct platform_device *pdev, struct smi *smi, ret = i2c_acpi_client_count(adev); if (ret < 0) return ret; - else if (!ret) + if (!ret) return -ENOENT; count = ret;