firmware: arm_scpi: improve handling of protocol and firmware version subfields
authorHeiner Kallweit <hkallweit1@gmail.com>
Tue, 5 Dec 2017 22:16:55 +0000 (23:16 +0100)
committerSudeep Holla <sudeep.holla@arm.com>
Fri, 23 Feb 2018 15:12:41 +0000 (15:12 +0000)
commit7cd49a264594251d87e504fe07dcb1fe2c99bbef
treee29359b9f8d005aaf57a3e9b6260e617fea8f085
parenta963d7c5264eaa544837ac8182a9eea55007a669
firmware: arm_scpi: improve handling of protocol and firmware version subfields

By using FIELD_GET and proper masks we can avoid quite some shifting
and masking macro magic and make the code better readable.

Tested-by: Kevin Hilman <khilman@baylibre.com>
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: Sudeep Holla <sudeep.holla@arm.com>
drivers/firmware/arm_scpi.c