refuse to adhere to SMMU for BPMP-FW
This commit is contained in:
1 parent
19f040ece1
commit
fc10a53bda
2 files changed
+17
-9
No files matched your search
@@ -1,18 +1,21 @@
|
|||||||
|
903c903
|
||||||
|
< void EnableBpmpSmmu() {
|
||||||
|
---
|
||||||
|
> [[maybe_unused]] void EnableBpmpSmmu() {
|
||||||
|
1200c1200
|
||||||
|
< EnableBpmpSmmu();
|
||||||
|
---
|
||||||
|
> // EnableBpmpSmmu(); I REFUSE
|
||||||
1221c1221
|
1221c1221
|
||||||
< const auto target_fw = GetTargetFirmware();
|
< const auto target_fw = GetTargetFirmware();
|
||||||
---
|
---
|
||||||
> // const auto target_fw = GetTargetFirmware();
|
> // const auto target_fw = GetTargetFirmware();
|
||||||
1223,1226c1223,1226
|
1223,1233c1223,1234
|
||||||
< if (target_fw >= TargetFirmware_2_0_0) {
|
< if (target_fw >= TargetFirmware_2_0_0) {
|
||||||
< /* Set the PMC secure. */
|
< /* Set the PMC secure. */
|
||||||
< reg::ReadWrite(APB_MISC + APB_MISC_SECURE_REGS_APB_SLAVE_SECURITY_ENABLE_REG0_0, SLAVE_SECURITY_REG_BITS_ENUM(0, PMC, ENABLE));
|
< reg::ReadWrite(APB_MISC + APB_MISC_SECURE_REGS_APB_SLAVE_SECURITY_ENABLE_REG0_0, SLAVE_SECURITY_REG_BITS_ENUM(0, PMC, ENABLE));
|
||||||
< }
|
< }
|
||||||
---
|
<
|
||||||
> // if (target_fw >= TargetFirmware_2_0_0) {
|
|
||||||
> // /* Set the PMC secure. */ I REFUSE
|
|
||||||
> // reg::ReadWrite(APB_MISC + APB_MISC_SECURE_REGS_APB_SLAVE_SECURITY_ENABLE_REG0_0, SLAVE_SECURITY_REG_BITS_ENUM(0, PMC, ENABLE));
|
|
||||||
> // }
|
|
||||||
1228,1233c1228,1234
|
|
||||||
< if (target_fw >= TargetFirmware_4_0_0) {
|
< if (target_fw >= TargetFirmware_4_0_0) {
|
||||||
< /* Set the MC secure. */
|
< /* Set the MC secure. */
|
||||||
< reg::ReadWrite(APB_MISC + APB_MISC_SECURE_REGS_APB_SLAVE_SECURITY_ENABLE_REG1_0, SLAVE_SECURITY_REG_BITS_ENUM(1, MC0, ENABLE),
|
< reg::ReadWrite(APB_MISC + APB_MISC_SECURE_REGS_APB_SLAVE_SECURITY_ENABLE_REG1_0, SLAVE_SECURITY_REG_BITS_ENUM(1, MC0, ENABLE),
|
||||||
@@ -20,6 +23,11 @@
|
|||||||
< SLAVE_SECURITY_REG_BITS_ENUM(1, MCB, ENABLE));
|
< SLAVE_SECURITY_REG_BITS_ENUM(1, MCB, ENABLE));
|
||||||
< }
|
< }
|
||||||
---
|
---
|
||||||
|
> // if (target_fw >= TargetFirmware_2_0_0) {
|
||||||
|
> // /* Set the PMC secure. */ I REFUSE
|
||||||
|
> // reg::ReadWrite(APB_MISC + APB_MISC_SECURE_REGS_APB_SLAVE_SECURITY_ENABLE_REG0_0, SLAVE_SECURITY_REG_BITS_ENUM(0, PMC, ENABLE));
|
||||||
|
> // }
|
||||||
|
>
|
||||||
> // if (target_fw >= TargetFirmware_4_0_0) {
|
> // if (target_fw >= TargetFirmware_4_0_0) {
|
||||||
> // /* Set the MC secure. */ I REFUSE
|
> // /* Set the MC secure. */ I REFUSE
|
||||||
> // reg::ReadWrite(APB_MISC + APB_MISC_SECURE_REGS_APB_SLAVE_SECURITY_ENABLE_REG1_0, SLAVE_SECURITY_REG_BITS_ENUM(1, MC0, ENABLE),
|
> // reg::ReadWrite(APB_MISC + APB_MISC_SECURE_REGS_APB_SLAVE_SECURITY_ENABLE_REG1_0, SLAVE_SECURITY_REG_BITS_ENUM(1, MC0, ENABLE),
|
||||||
|
|||||||
@@ -900,7 +900,7 @@ namespace ams::secmon {
|
|||||||
reg::ReadWrite(PMC + APBDEV_PMC_SECURE_SCRATCH39, REG_BITS_VALUE(0, 27, WarmbootCarveoutConfig));
|
reg::ReadWrite(PMC + APBDEV_PMC_SECURE_SCRATCH39, REG_BITS_VALUE(0, 27, WarmbootCarveoutConfig));
|
||||||
}
|
}
|
||||||
|
|
||||||
void EnableBpmpSmmu() {
|
[[maybe_unused]] void EnableBpmpSmmu() {
|
||||||
/* Define the ASID contents. */
|
/* Define the ASID contents. */
|
||||||
constexpr int BpmpAsid = 1;
|
constexpr int BpmpAsid = 1;
|
||||||
constexpr uintptr_t BpmpAsidPde = MemoryRegionPhysicalDeviceSecurityEngine.GetAddress();
|
constexpr uintptr_t BpmpAsidPde = MemoryRegionPhysicalDeviceSecurityEngine.GetAddress();
|
||||||
@@ -1197,7 +1197,7 @@ namespace ams::secmon {
|
|||||||
reg::ReadWrite(SYSTEM + AHB_ARBITRATION_DISABLE, AHB_REG_BITS_ENUM(ARBITRATION_DISABLE_COP, DISABLE));
|
reg::ReadWrite(SYSTEM + AHB_ARBITRATION_DISABLE, AHB_REG_BITS_ENUM(ARBITRATION_DISABLE_COP, DISABLE));
|
||||||
|
|
||||||
/* Turn on the SMMU for the BPMP. */
|
/* Turn on the SMMU for the BPMP. */
|
||||||
EnableBpmpSmmu();
|
// EnableBpmpSmmu(); I REFUSE
|
||||||
|
|
||||||
/* Wait until the flow controller reports that the BPMP is halted. */
|
/* Wait until the flow controller reports that the BPMP is halted. */
|
||||||
while (!reg::HasValue(FLOW_CTLR + FLOW_CTLR_HALT_COP_EVENTS, FLOW_REG_BITS_ENUM(HALT_COP_EVENTS_MODE, FLOW_MODE_STOP))) {
|
while (!reg::HasValue(FLOW_CTLR + FLOW_CTLR_HALT_COP_EVENTS, FLOW_REG_BITS_ENUM(HALT_COP_EVENTS_MODE, FLOW_MODE_STOP))) {
|
||||||
|
|||||||
Reference in new issue
Block a user