]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
platform/x86: x86-android-tablets: Stop using EPROBE_DEFER
authorHans de Goede <hansg@kernel.org>
Sat, 20 Sep 2025 20:07:13 +0000 (22:07 +0200)
committerIlpo Järvinen <ilpo.jarvinen@linux.intel.com>
Fri, 26 Sep 2025 11:26:43 +0000 (14:26 +0300)
Since the x86-android-tablets code uses platform_create_bundle() it cannot
use EPROBE_DEFER and the driver-core will translate EPROBE_DEFER to ENXIO.

Stop using EPROBE_DEFER instead log an error and return ENODEV, or for
non-fatal cases log a warning and return 0.

Reviewed-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Reviewed-by: Andy Shevchenko <andy@kernel.org>
Signed-off-by: Hans de Goede <hansg@kernel.org>
Link: https://patch.msgid.link/20250920200713.20193-21-hansg@kernel.org
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
drivers/platform/x86/x86-android-tablets/core.c
drivers/platform/x86/x86-android-tablets/other.c

index a8e9fa97b676b1e2f8c842a394da257c642649cb..6588fae303562b7dc9a1a8d281b167e44f0d3e84 100644 (file)
@@ -276,8 +276,10 @@ get_serdev_controller_by_pci_parent(const struct x86_serdev_info *info)
        struct pci_dev *pdev;
 
        pdev = pci_get_domain_bus_and_slot(0, 0, info->ctrl.pci.devfn);
-       if (!pdev)
-               return ERR_PTR(-EPROBE_DEFER);
+       if (!pdev) {
+               pr_err("error could not get PCI serdev at devfn 0x%02x\n", info->ctrl.pci.devfn);
+               return ERR_PTR(-ENODEV);
+       }
 
        /* This puts our reference on pdev and returns a ref on the ctrl */
        return get_serdev_controller_from_parent(&pdev->dev, 0, info->ctrl_devname);
index ea7a01d7ccb460eb91b923e99c86492432eeea8d..7532af2d72d1d9de807a1f371425249ac5ff86da 100644 (file)
@@ -711,8 +711,10 @@ static int __init vexia_edu_atla10_9v_init(struct device *dev)
 
        /* Reprobe the SDIO controller to enumerate the now enabled Wifi module */
        pdev = pci_get_domain_bus_and_slot(0, 0, PCI_DEVFN(0x11, 0));
-       if (!pdev)
-               return -EPROBE_DEFER;
+       if (!pdev) {
+               pr_warn("Could not get PCI SDIO at devfn 0x%02x\n", PCI_DEVFN(0x11, 0));
+               return 0;
+       }
 
        ret = device_reprobe(&pdev->dev);
        if (ret)