boot: refactor to use sts::boot namespace
This commit is contained in:
1 parent
4fbae9e5a4
commit
06416aeded
91 files changed
+3661
-3151
No files matched your search
@@ -14,14 +14,25 @@
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include "boot_functions.hpp"
|
||||
#include "boot_fan_enable.hpp"
|
||||
#include "boot_gpio_utils.hpp"
|
||||
#include "boot_spl_utils.hpp"
|
||||
|
||||
static constexpr u32 GpioPadName_FanEnable = 0x4B;
|
||||
namespace sts::boot {
|
||||
|
||||
namespace {
|
||||
|
||||
/* Convenience definitions. */
|
||||
constexpr u32 GpioPadName_FanEnable = 0x4B;
|
||||
|
||||
void Boot::SetFanEnabled() {
|
||||
if (Boot::GetHardwareType() == HardwareType_Copper) {
|
||||
Boot::GpioConfigure(GpioPadName_FanEnable);
|
||||
Boot::GpioSetDirection(GpioPadName_FanEnable, GpioDirection_Output);
|
||||
Boot::GpioSetValue(GpioPadName_FanEnable, GpioValue_High);
|
||||
}
|
||||
|
||||
void SetFanEnabled() {
|
||||
if (GetHardwareType() == spl::HardwareType::Copper) {
|
||||
gpio::Configure(GpioPadName_FanEnable);
|
||||
gpio::SetDirection(GpioPadName_FanEnable, GpioDirection_Output);
|
||||
gpio::SetValue(GpioPadName_FanEnable, GpioValue_High);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user