Add support for A-only 2SI

This commit is contained in:
topjohnwu
2019-09-22 05:15:31 -04:00
parent 0e5a113a0c
commit ee0cef06a6
3 changed files with 29 additions and 8 deletions

View File

@ -97,21 +97,32 @@ public:
}
};
/* *******************
* Logical Partitions
* *******************/
/* *************
* 2 Stage Init
* *************/
class FirstStageInit : public BaseInit {
class ABFirstStageInit : public BaseInit {
protected:
void prepare();
public:
FirstStageInit(char *argv[], cmdline *cmd) : BaseInit(argv, cmd) {};
ABFirstStageInit(char *argv[], cmdline *cmd) : BaseInit(argv, cmd) {};
void start() override {
prepare();
exec_init("/system/bin/init");
}
};
class AFirstStageInit : public BaseInit {
protected:
void prepare();
public:
AFirstStageInit(char *argv[], cmdline *cmd) : BaseInit(argv, cmd) {};
void start() override {
prepare();
exec_init();
}
};
class SecondStageInit : public SARCommon {
protected:
void early_mount() override;
@ -121,7 +132,7 @@ public:
};
/* ***********
* Normal SAR
* Legacy SAR
* ***********/
class SARInit : public SARCommon {