Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

platform/surface: aggregator_tabletsw: Use target-ID enum instead of hard-coding values

Instead of hard-coding the target ID, use the respective enum
ssam_ssh_tid value.

Signed-off-by: Maximilian Luz <luzmaximilian@gmail.com>
Link: https://lore.kernel.org/r/20221202223327.690880-6-luzmaximilian@gmail.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>

authored by

Maximilian Luz and committed by
Hans de Goede
36f672a4 0a603d71

+3 -3
+3 -3
drivers/platform/surface/surface_aggregator_tabletsw.c
··· 247 247 248 248 SSAM_DEFINE_SYNC_REQUEST_R(__ssam_kip_get_cover_state, u8, { 249 249 .target_category = SSAM_SSH_TC_KIP, 250 - .target_id = 0x01, 250 + .target_id = SSAM_SSH_TID_SAM, 251 251 .command_id = 0x1d, 252 252 .instance_id = 0x00, 253 253 }); ··· 371 371 int status; 372 372 373 373 rqst.target_category = SSAM_SSH_TC_POS; 374 - rqst.target_id = 0x01; 374 + rqst.target_id = SSAM_SSH_TID_SAM; 375 375 rqst.command_id = 0x01; 376 376 rqst.instance_id = 0x00; 377 377 rqst.flags = SSAM_REQUEST_HAS_RESPONSE; ··· 430 430 431 431 SSAM_DEFINE_SYNC_REQUEST_WR(__ssam_pos_get_posture_for_source, __le32, __le32, { 432 432 .target_category = SSAM_SSH_TC_POS, 433 - .target_id = 0x01, 433 + .target_id = SSAM_SSH_TID_SAM, 434 434 .command_id = 0x02, 435 435 .instance_id = 0x00, 436 436 });