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

platform/x86: x86-android-tablets: Stop using EPROBE_DEFER

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>

authored by

Hans de Goede and committed by
Ilpo Järvinen
01fd7cf3 83fdf93f

+8 -4
+4 -2
drivers/platform/x86/x86-android-tablets/core.c
··· 276 276 struct pci_dev *pdev; 277 277 278 278 pdev = pci_get_domain_bus_and_slot(0, 0, info->ctrl.pci.devfn); 279 - if (!pdev) 280 - return ERR_PTR(-EPROBE_DEFER); 279 + if (!pdev) { 280 + pr_err("error could not get PCI serdev at devfn 0x%02x\n", info->ctrl.pci.devfn); 281 + return ERR_PTR(-ENODEV); 282 + } 281 283 282 284 /* This puts our reference on pdev and returns a ref on the ctrl */ 283 285 return get_serdev_controller_from_parent(&pdev->dev, 0, info->ctrl_devname);
+4 -2
drivers/platform/x86/x86-android-tablets/other.c
··· 711 711 712 712 /* Reprobe the SDIO controller to enumerate the now enabled Wifi module */ 713 713 pdev = pci_get_domain_bus_and_slot(0, 0, PCI_DEVFN(0x11, 0)); 714 - if (!pdev) 715 - return -EPROBE_DEFER; 714 + if (!pdev) { 715 + pr_warn("Could not get PCI SDIO at devfn 0x%02x\n", PCI_DEVFN(0x11, 0)); 716 + return 0; 717 + } 716 718 717 719 ret = device_reprobe(&pdev->dev); 718 720 if (ret)