From: Sudeep Holla Date: Fri, 18 Aug 2017 14:39:28 +0000 (+0100) Subject: firmware: arm_scpi: fix endianness of dev_id in struct dev_pstate_set X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=0d30176819c8738b012ec623c7b3db19df818e70;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git firmware: arm_scpi: fix endianness of dev_id in struct dev_pstate_set scpi_device_{g,s}et_power_state correctly handles the conversion of endianness for dev_id using cpu_to_le16. However dev_id is declared as u16 in struct dev_pstate_set which is incorrect. This patch fixes the endianness of dev_id in dev_pstate_set structure. Fixes: 37a441dcd5f4 ("firmware: arm_scpi: add support for device power state management") Signed-off-by: Sudeep Holla --- diff --git a/drivers/firmware/arm_scpi.c b/drivers/firmware/arm_scpi.c index 8043e51de897..ab52f1bcd277 100644 --- a/drivers/firmware/arm_scpi.c +++ b/drivers/firmware/arm_scpi.c @@ -357,7 +357,7 @@ struct sensor_value { } __packed; struct dev_pstate_set { - u16 dev_id; + __le16 dev_id; u8 pstate; } __packed;