From 21d22bf74eef4e5c16ce4cf865c606dc9bbf2939 Mon Sep 17 00:00:00 2001 From: Benjamin Tissoires Date: Tue, 20 Oct 2015 17:32:56 -0400 Subject: [PATCH] hidpp20: change hidpp20_onboard_profiles_read_memory API It looks like we can not use a section > 0xff and that the first parameter corresponds to the type of the available memory (rom or flash). Signed-off-by: Benjamin Tissoires --- src/hidpp20.c | 2 +- src/hidpp20.h | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/hidpp20.c b/src/hidpp20.c index 86d67f15..1aecd0e2 100644 --- a/src/hidpp20.c +++ b/src/hidpp20.c @@ -933,7 +933,7 @@ int hidpp20_adjustable_dpi_set_sensor_dpi(struct hidpp20_device *device, #define HIDPP20_PROFILE_SIZE (15*16) #define HIDPP20_BUTTON_HID 0x80 -static int +int hidpp20_onboard_profiles_read_memory(struct hidpp20_device *device, uint8_t read_rom, uint8_t page, diff --git a/src/hidpp20.h b/src/hidpp20.h index 0e6eaa9e..5f1d83ca 100644 --- a/src/hidpp20.h +++ b/src/hidpp20.h @@ -322,6 +322,13 @@ int hidpp20_onboard_profiles_read(struct hidpp20_device *device, enum ratbag_button_action_special hidpp20_onboard_profiles_get_special(uint8_t code); +int +hidpp20_onboard_profiles_read_memory(struct hidpp20_device *device, + uint8_t read_rom, + uint8_t page, + uint8_t section, + uint8_t result[16]); + /* -------------------------------------------------------------------------- */ /* 0x8110 - Mouse Button Spy */ /* -------------------------------------------------------------------------- */