diff --git a/arch/arm64/src/imx9/Make.defs b/arch/arm64/src/imx9/Make.defs index e0f21cdc539fa..456fe4b89f19e 100644 --- a/arch/arm64/src/imx9/Make.defs +++ b/arch/arm64/src/imx9/Make.defs @@ -91,3 +91,8 @@ endif ifeq ($(CONFIG_IMX9_FLEXCAN), y) CHIP_CSRCS += imx9_flexcan.c endif + +ifneq ($(CONFI_IMX9_HAVE_ATF_FIRMWARE), y) + CHIP_CSRCS += imx9_reset.c +endif + diff --git a/arch/arm64/src/imx9/imx9_reset.c b/arch/arm64/src/imx9/imx9_reset.c new file mode 100644 index 0000000000000..48da1c06639be --- /dev/null +++ b/arch/arm64/src/imx9/imx9_reset.c @@ -0,0 +1,50 @@ +/**************************************************************************** + * arch/arm64/src/imx9/imx9_reset.c + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. The + * ASF licenses this file to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance with the + * License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT + * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the + * License for the specific language governing permissions and limitations + * under the License. + * + ****************************************************************************/ + +/**************************************************************************** + * Included Files + ****************************************************************************/ + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include "imx9_pmic.h" + +/**************************************************************************** + * Public Functions + ****************************************************************************/ + +void up_systemreset(void) +{ + imx9_pmic_reset(); + + /* Wait for the reset */ + + while (1); +} +