0001
0002
0003
0004
0005
0006
0007
0008
0009
0010 #ifndef AMD_SFH_HID_DESCRIPTOR_H
0011 #define AMD_SFH_HID_DESCRIPTOR_H
0012
0013 enum desc_type {
0014
0015 descr_size = 1,
0016 input_size,
0017 feature_size,
0018 };
0019
0020 struct common_feature_property {
0021
0022 u8 report_id;
0023 u8 connection_type;
0024 u8 report_state;
0025 u8 power_state;
0026 u8 sensor_state;
0027 u32 report_interval;
0028 } __packed;
0029
0030 struct common_input_property {
0031
0032 u8 report_id;
0033 u8 sensor_state;
0034 u8 event_type;
0035 } __packed;
0036
0037 struct accel3_feature_report {
0038 struct common_feature_property common_property;
0039
0040 u16 accel_change_sesnitivity;
0041 s16 accel_sensitivity_max;
0042 s16 accel_sensitivity_min;
0043 } __packed;
0044
0045 struct accel3_input_report {
0046 struct common_input_property common_property;
0047
0048 int in_accel_x_value;
0049 int in_accel_y_value;
0050 int in_accel_z_value;
0051
0052 u8 in_accel_shake_detection;
0053 } __packed;
0054
0055 struct gyro_feature_report {
0056 struct common_feature_property common_property;
0057
0058 u16 gyro_change_sesnitivity;
0059 s16 gyro_sensitivity_max;
0060 s16 gyro_sensitivity_min;
0061 } __packed;
0062
0063 struct gyro_input_report {
0064 struct common_input_property common_property;
0065
0066 int in_angel_x_value;
0067 int in_angel_y_value;
0068 int in_angel_z_value;
0069 } __packed;
0070
0071 struct magno_feature_report {
0072 struct common_feature_property common_property;
0073
0074 u16 magno_headingchange_sensitivity;
0075 s16 heading_min;
0076 s16 heading_max;
0077 u16 flux_change_sensitivity;
0078 s16 flux_min;
0079 s16 flux_max;
0080 } __packed;
0081
0082 struct magno_input_report {
0083 struct common_input_property common_property;
0084 int in_magno_x;
0085 int in_magno_y;
0086 int in_magno_z;
0087 int in_magno_accuracy;
0088 } __packed;
0089
0090 struct als_feature_report {
0091 struct common_feature_property common_property;
0092
0093 u16 als_change_sesnitivity;
0094 s16 als_sensitivity_max;
0095 s16 als_sensitivity_min;
0096 } __packed;
0097
0098 struct als_input_report {
0099 struct common_input_property common_property;
0100
0101 int illuminance_value;
0102 } __packed;
0103
0104 struct hpd_feature_report {
0105 struct common_feature_property common_property;
0106 } __packed;
0107
0108 struct hpd_input_report {
0109 struct common_input_property common_property;
0110
0111 u8 human_presence;
0112 } __packed;
0113
0114 #endif