[PATCH v1 2/2] platform/x86: serial-multi-instantiate: Remove duplicate check

Andy Shevchenko
2025-11-25T09:42:55Z

Since i2c_acpi_client_count() stopped returning 0 and instead
uses -ENOENT, remove the duplicated check in smi_i2c_probe().

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
drivers/platform/x86/serial-multi-instantiate.c | 3 ---
1 file changed, 3 deletions(-)

diff --git a/drivers/platform/x86/serial-multi-instantiate.c b/drivers/platform/x86/serial-multi-instantiate.c
index db030b0f176a..3f6f5d51442c 100644
--- a/drivers/platform/x86/serial-multi-instantiate.c
+++ b/drivers/platform/x86/serial-multi-instantiate.c
@@ -198,9 +198,6 @@ static int smi_i2c_probe(struct platform_device *pdev, struct smi *smi,
ret = i2c_acpi_client_count(adev);
if (ret < 0)
return ret;
- if (!ret)
- return -ENOENT;
-
count = ret;

smi->i2c_devs = devm_kcalloc(dev, count, sizeof(*smi->i2c_devs), GFP_KERNEL);
--
2.50.1