mfd: rave-sp: Add legacy EEPROM access command translation
authorAndrey Smirnov <andrew.smirnov@gmail.com>
Sat, 7 Jul 2018 02:41:06 +0000 (19:41 -0700)
committerLee Jones <lee.jones@linaro.org>
Fri, 27 Jul 2018 07:13:25 +0000 (08:13 +0100)
This is needed to make rave-sp-eeprom driver work on "legacy"
firmware.

Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
drivers/mfd/rave-sp.c
include/linux/mfd/rave-sp.h

index aa75d5841ca0286906687c8a16d9932653819b4c..a999fa721b039d4c8ca9306e692a918489952847 100644 (file)
@@ -635,6 +635,8 @@ static int rave_sp_default_cmd_translate(enum rave_sp_command command)
                return 0x1E;
        case RAVE_SP_CMD_RESET_REASON:
                return 0x1F;
+       case RAVE_SP_CMD_RMB_EEPROM:
+               return 0x20;
        default:
                return -EINVAL;
        }
index fe0ce7bc59cfa2948ed9ad15d0f7700af8f93d3a..11eef77ef976d28922a82d5534a06673af9216b0 100644 (file)
@@ -21,6 +21,7 @@ enum rave_sp_command {
        RAVE_SP_CMD_STATUS                      = 0xA0,
        RAVE_SP_CMD_SW_WDT                      = 0xA1,
        RAVE_SP_CMD_PET_WDT                     = 0xA2,
+       RAVE_SP_CMD_RMB_EEPROM                  = 0xA4,
        RAVE_SP_CMD_SET_BACKLIGHT               = 0xA6,
        RAVE_SP_CMD_RESET                       = 0xA7,
        RAVE_SP_CMD_RESET_REASON                = 0xA8,