• Arnd Bergmann's avatar
    thermal: qcom: tsens-8916: mark PM functions __maybe_unused · 5b97469a
    Arnd Bergmann authored
    The newly added tsens-8916 driver produces warnings when CONFIG_PM
    is disabled:
    
    drivers/thermal/qcom/tsens.c:53:12: error: 'tsens_resume' defined but not used [-Werror=unused-function]
     static int tsens_resume(struct device *dev)
                ^~~~~~~~~~~~
    drivers/thermal/qcom/tsens.c:43:12: error: 'tsens_suspend' defined but not used [-Werror=unused-function]
     static int tsens_suspend(struct device *dev)
                ^~~~~~~~~~~~~
    
    This marks both functions __maybe_unused to let the compiler
    know that they might be used in other configurations, without
    adding ugly #ifdef logic.
    Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
    Reviewed-by: default avatarRajendra Nayak <rnayak@codeaurora.org>
    Signed-off-by: default avatarZhang Rui <rui.zhang@intel.com>
    5b97469a
tsens.c 4.42 KB