diff options
Diffstat (limited to 'drivers/misc/mei/pci-me.c')
| -rw-r--r-- | drivers/misc/mei/pci-me.c | 23 | 
1 files changed, 13 insertions, 10 deletions
| diff --git a/drivers/misc/mei/pci-me.c b/drivers/misc/mei/pci-me.c index 4ff40d319676..78b3172c8e6e 100644 --- a/drivers/misc/mei/pci-me.c +++ b/drivers/misc/mei/pci-me.c @@ -93,6 +93,8 @@ static const struct pci_device_id mei_me_pci_tbl[] = {  	{MEI_PCI_DEVICE(MEI_DEV_ID_BXT_M, MEI_ME_PCH8_CFG)},  	{MEI_PCI_DEVICE(MEI_DEV_ID_APL_I, MEI_ME_PCH8_CFG)}, +	{MEI_PCI_DEVICE(MEI_DEV_ID_GLK, MEI_ME_PCH8_CFG)}, +  	{MEI_PCI_DEVICE(MEI_DEV_ID_KBP, MEI_ME_PCH8_CFG)},  	{MEI_PCI_DEVICE(MEI_DEV_ID_KBP_2, MEI_ME_PCH8_CFG)}, @@ -226,12 +228,15 @@ static int mei_me_probe(struct pci_dev *pdev, const struct pci_device_id *ent)  	pdev->dev_flags |= PCI_DEV_FLAGS_NEEDS_RESUME;  	/* -	* For not wake-able HW runtime pm framework -	* can't be used on pci device level. -	* Use domain runtime pm callbacks instead. -	*/ -	if (!pci_dev_run_wake(pdev)) -		mei_me_set_pm_domain(dev); +	 * ME maps runtime suspend/resume to D0i states, +	 * hence we need to go around native PCI runtime service which +	 * eventually brings the device into D3cold/hot state, +	 * but the mei device cannot wake up from D3 unlike from D0i3. +	 * To get around the PCI device native runtime pm, +	 * ME uses runtime pm domain handlers which take precedence +	 * over the driver's pm handlers. +	 */ +	mei_me_set_pm_domain(dev);  	if (mei_pg_is_enabled(dev))  		pm_runtime_put_noidle(&pdev->dev); @@ -271,8 +276,7 @@ static void mei_me_shutdown(struct pci_dev *pdev)  	dev_dbg(&pdev->dev, "shutdown\n");  	mei_stop(dev); -	if (!pci_dev_run_wake(pdev)) -		mei_me_unset_pm_domain(dev); +	mei_me_unset_pm_domain(dev);  	mei_disable_interrupts(dev);  	free_irq(pdev->irq, dev); @@ -300,8 +304,7 @@ static void mei_me_remove(struct pci_dev *pdev)  	dev_dbg(&pdev->dev, "stop\n");  	mei_stop(dev); -	if (!pci_dev_run_wake(pdev)) -		mei_me_unset_pm_domain(dev); +	mei_me_unset_pm_domain(dev);  	mei_disable_interrupts(dev); |