mfd: rtsx: Fix oops when rtsx_pci_sdmmc is not probed
If rtsx_pci_sdmmc is not probed, function pointer pcr->slots[].card_event will point to NULL, and thus rtsx_pci_card_detect will reference a NULL pointer. Check card_event pointer before referencing it can avoid kernel panic. Signed-off-by: NWei WANG <wei_wang@realsil.com.cn> Signed-off-by: NSamuel Ortiz <sameo@linux.intel.com>
Showing
想要评论请 注册 或 登录