• Kenji Kaneshige's avatar
    PCI ASPM: cleanup clkpm checks · 430842e2
    Kenji Kaneshige authored
    In the current ASPM implementation, callers of pcie_set_clock_pm() check
    Clock PM capability of the link or current Clock PM state of the link.
    This check should be done in pcie_set_clock_pm() itself.
    
    This patch moves those checks into pcie_set_clock_pm(). It also
    introduces pcie_set_clkpm_nocheck() that is equivalent to old
    pcie_set_clock_pm(), for the caller who wants to change Clocl PM state
    regardless of the Clock PM capability or current Clock PM state. In
    addition, this patch changes the function name from
    pcie_set_clock_pm() to pcie_set_clkpm() for consistency.
    Acked-by: default avatarShaohua Li <shaohua.li@intel.com>
    Signed-off-by: default avatarKenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
    Signed-off-by: default avatarJesse Barnes <jbarnes@virtuousgeek.org>
    430842e2
aspm.c 25.5 KB