>>>>> Hi, >>>>> >>>>> I work on a driver (drivers/net/ethernet/mellanox/mlxsw) that is made up >>>>> of three modules: mlxsw_pci, mlxsw_core and a third module that is >>>>> loaded by mlxsw_core according to the probed PCI device ID via >>>>> request_module(). However, this function fails with rawhide kernels >>>>> during boot. >>>>> >>>>> While debugging this, I found out that if I build the kernel myself with >>>>> the exact same config, but set CONFIG_MODULE_SIG=n, then everything is >>>>> fine. In addition, when modprobing mlxsw_pci myself all the modules are >>>>> successfully loaded. >>>>> >>>>> Any ideas how this can be solved? Did anyone else bump into this >>>>> problem? >>>>> >>>>> Thanks. >>>>> >>>> >>>>Can you share kernel logs showing the error? >>> >>>The only error in the log is the one from the driver: >>> >>>mlxsw_pci 0000:03:00.0: cannot register bus device >>>mlxsw_pci: probe of 0000:03:00.0 failed with error -22 >> >> Laura, note that this is because module mlxsw_spectrum failed to load in >> this function: >> >> static struct mlxsw_driver *mlxsw_core_driver_get(const char *kind) >> { >> struct mlxsw_driver *mlxsw_driver; >> >> spin_lock(&mlxsw_core_driver_list_lock); >> mlxsw_driver = __driver_find(kind); >> if (!mlxsw_driver) { >> spin_unlock(&mlxsw_core_driver_list_lock); >> request_module(MLXSW_MODULE_ALIAS_PREFIX "%s", kind); >> spin_lock(&mlxsw_core_driver_list_lock); >> mlxsw_driver = __driver_find(kind); >> } >> if (mlxsw_driver) { >> if (!try_module_get(mlxsw_driver->owner)) >> mlxsw_driver = NULL; >> } >> >> spin_unlock(&mlxsw_core_driver_list_lock); >> return mlxsw_driver; >> } >> >> Here, "request_module" won't load the mlxsw_spectrum module. But this issue >> happens only during the boot time. >> >> If you try to "modprobe mlxsw_pci" by hand later on, all works fine. > > Is mlxsw_pci actually in the initramfs, and is it signed in it? I was about to ask the same. for the generic initrd dracut matches modules against a particular setup call/funciton [1] for a class of devices to work out what to pull in and often these sort of modules don't match as the sub modules. I have a similar issue with the dw_mmc-* where the core dw_mmc.ko gets pulled in but not the HW specific variants. I'm not worked out a good clean way to deal with that in dracut as yet. Peter [1] storage uses these 'ahci_platform_get_resources|ata_scsi_ioctl|scsi_add_host|blk_cleanup_queue|register_mtd_blktrans|scsi_esp_register|register_virtio_device|usb_stor_disconnect|mmc_add_host|sdhci_add_host|scsi_add_host_with_dma' _______________________________________________ kernel mailing list kernel@xxxxxxxxxxxxxxxxxxxxxxx https://lists.fedoraproject.org/admin/lists/kernel@xxxxxxxxxxxxxxxxxxxxxxx