crypto: qat - expose pm_idle_enabled through sysfs
authorLucas Segarra Fernandez <lucas.segarra.fernandez@intel.com>
Fri, 9 Jun 2023 17:06:14 +0000 (19:06 +0200)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 16 Jun 2023 12:30:57 +0000 (20:30 +0800)
commit2382b5ae80467cb61339db130a07e5075ebb270d
treefae8972f333c6f8667ca65c5a48f56f146884c07
parent5005327514064840c6713b793cd80c5b98afba3d
crypto: qat - expose pm_idle_enabled through sysfs

Expose 'pm_idle_enabled' sysfs attribute. This attribute controls how
idle conditions are handled. If it is set to 1 (idle support enabled)
when the device detects an idle condition, the driver will transition
the device to the 'MIN' power configuration.

In order to set the value of this attribute for a device, the device
must be in the 'down' state.

This only applies to qat_4xxx generation.

Signed-off-by: Lucas Segarra Fernandez <lucas.segarra.fernandez@intel.com>
Reviewed-by: Giovanni Cabiddu <giovanni.cabiddu@intel.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Documentation/ABI/testing/sysfs-driver-qat
drivers/crypto/intel/qat/qat_common/adf_cfg_strings.h
drivers/crypto/intel/qat/qat_common/adf_gen4_pm.c
drivers/crypto/intel/qat/qat_common/adf_gen4_pm.h
drivers/crypto/intel/qat/qat_common/adf_sysfs.c