Skip to content

Commit

Permalink
HiKey970: Enable LDO33 for PCI-E switch
Browse files Browse the repository at this point in the history
Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
  • Loading branch information
Mani-Sadhasivam committed Mar 19, 2019
1 parent 348ccb5 commit 32e59f8
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Platforms/Hisilicon/HiKey970/HiKey970Dxe/HiKey970Dxe.c
Expand Up @@ -387,6 +387,13 @@ RegulatorEenable (
DEBUG ((DEBUG_WARN, "Warning: Couldn't Set LDO28 ON (status: %r)\n", Status));
}

/* LDO33 enable */
RegVal = 0x01;
Status = mSpmiIo->Write(mSpmiIo, SPMI_SLAVEID_HI6421v600, PMIC_LDO33_ONOFF_ADDR, (UINT8*)&RegVal, 1);
if (EFI_ERROR (Status)) {
DEBUG ((DEBUG_WARN, "Warning: Couldn't Set LDO33 ON (status: %r)\n", Status));
}

return EFI_SUCCESS;
}
#endif
Expand Down
2 changes: 2 additions & 0 deletions Platforms/Hisilicon/HiKey970/Include/Kirin970.h
Expand Up @@ -63,7 +63,9 @@
#define PMIC_OSC32K_ONOFF_CTRL_EN_32K (1 << 1)

#define PMIC_LDO28_VSET_ADDR 0x069
#define PMIC_LDO33_VSET_ADDR 0x06D
#define PMIC_LDO28_ONOFF_ADDR 0x02E
#define PMIC_LDO33_ONOFF_ADDR 0x032

#define CRG_REG_BASE 0xFFF35000

Expand Down

0 comments on commit 32e59f8

Please sign in to comment.