]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
eeprom: idt_89hpesx: Restore printing the unsupported fwnode name
authorAndy Shevchenko <andy.shevchenko@gmail.com>
Mon, 7 Jun 2021 22:17:56 +0000 (01:17 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 20 Jul 2021 14:15:56 +0000 (16:15 +0200)
[ Upstream commit e0db3deea73ba418bf5dc21f5a4e32ca87d16dde ]

When iterating over child firmware nodes restore printing the name of ones
that are not supported.

While at it, refactor loop body to clearly show that we stop at the first match.

Fixes: db15d73e5f0e ("eeprom: idt_89hpesx: Support both ACPI and OF probing")
Cc: Huy Duong <qhuyduong@hotmail.com>
Signed-off-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Link: https://lore.kernel.org/r/20210607221757.81465-2-andy.shevchenko@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/misc/eeprom/idt_89hpesx.c

index b93b83fc3e3ead46de2b471fdcb54f7919d59252..5879ba82c7186a5f0ab0d8f6990a3d6a3e1d4d03 100644 (file)
@@ -1128,11 +1128,10 @@ static void idt_get_fw_data(struct idt_89hpesx_dev *pdev)
 
        device_for_each_child_node(dev, fwnode) {
                ee_id = idt_ee_match_id(fwnode);
-               if (!ee_id) {
-                       dev_warn(dev, "Skip unsupported EEPROM device");
-                       continue;
-               } else
+               if (ee_id)
                        break;
+
+               dev_warn(dev, "Skip unsupported EEPROM device %pfw\n", fwnode);
        }
 
        /* If there is no fwnode EEPROM device, then set zero size */