fastboot: getvar: Add "is-userspace" variable
PATCH v2 1/1 fastboot: getvar: Add "is-userspace" variable
As per documentation [1], Android-Q requires for bootloader to provide "is-userspace" variable. "no" value should be always returned. This patch implements this fastboot variable.
---
Changes in v2:
- use the fixed link for tag instead of floating one for master branch
- add "getvar:" in the commit title to be more specific
drivers/fastboot/fb_getvar.c | 9 +++++++++ 1 file changed, 9 insertions(+)
drivers/fastboot/fb_getvar.c +9 -0
@@ -28,6 +28,7 @@ static void getvar_partition_type(char *part_name, char *response);#if CONFIG_IS_ENABLED (FASTBOOT_FLASH )static void getvar_partition_size (char *part_name,char *response);#endif +static void getvar_is_userspace (char *var_parameter,char *response); static const struct { const char *variable;
@@ -78,6 +79,9 @@ static const struct { .variable = "partition-size", .dispatch = getvar_partition_size#endif + }, { + .variable = "is-userspace", + .dispatch = getvar_is_userspace } };
@@ -243,6 +247,11 @@ static void getvar_partition_size(char *part_name, char *response) }#endif +static void getvar_is_userspace (char *var_parameter,char *response) +{ +fastboot_okay ("no" , response); +} +/** * fastboot_getvar() - Writes variable indicated by cmd_parameter to response. *
Signature · 1 line
2.20.1
PATCH v2 1/1 fastboot: getvar: Add "is-userspace" variable
Quoted 5 lines · Sam Protsenko
As per documentation [1], Android-Q requires for bootloader to provide "is-userspace" variable. "no" value should be always returned. This patch implements this fastboot variable.
FWIW, s/master/android-q-preview-4/ in the original link would have worked as well.
Quoted 6 lines
Signed-off-by Sam Protsenko <[email protected]>---
Changes in v2:
- use the fixed link for tag instead of floating one for master branch
- add "getvar:" in the commit title to be more specific
Thanks!
Signature · 2 lines
Best Regards, Eugeniu.