Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6d5b9314 authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "fastbootd: Add is-userspace variable."

parents 770395de d9ba061e
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -57,3 +57,4 @@
#define FB_VAR_SLOT_SUCCESSFUL "slot-successful"
#define FB_VAR_SLOT_UNBOOTABLE "slot-unbootable"
#define FB_VAR_IS_LOGICAL "is-logical"
#define FB_VAR_IS_USERSPACE "is-userspace"
+2 −1
Original line number Diff line number Diff line
@@ -59,7 +59,8 @@ bool GetVarHandler(FastbootDevice* device, const std::vector<std::string>& args)
            {FB_VAR_SLOT_SUCCESSFUL, GetSlotSuccessful},
            {FB_VAR_SLOT_UNBOOTABLE, GetSlotUnbootable},
            {FB_VAR_PARTITION_SIZE, GetPartitionSize},
            {FB_VAR_IS_LOGICAL, GetPartitionIsLogical}};
            {FB_VAR_IS_LOGICAL, GetPartitionIsLogical},
            {FB_VAR_IS_USERSPACE, GetIsUserspace}};

    // args[0] is command name, args[1] is variable.
    auto found_variable = kVariableMap.find(args[1]);
+4 −0
Original line number Diff line number Diff line
@@ -165,3 +165,7 @@ bool GetPartitionIsLogical(FastbootDevice* device, const std::vector<std::string
    }
    return device->WriteFail("Partition not found");
}

bool GetIsUserspace(FastbootDevice* device, const std::vector<std::string>& /* args */) {
    return device->WriteOkay("yes");
}
+1 −0
Original line number Diff line number Diff line
@@ -36,3 +36,4 @@ bool GetUnlocked(FastbootDevice* device, const std::vector<std::string>& args);
bool GetHasSlot(FastbootDevice* device, const std::vector<std::string>& args);
bool GetPartitionSize(FastbootDevice* device, const std::vector<std::string>& args);
bool GetPartitionIsLogical(FastbootDevice* device, const std::vector<std::string>& args);
bool GetIsUserspace(FastbootDevice* device, const std::vector<std::string>& args);