fiq.c

来自「S3C24A0的完整BSP包,对开发此芯片的开发者很有用.」· C语言 代码 · 共 43 行

C
43
字号
//
// Copyright (c) Microsoft Corporation.  All rights reserved.
//
//
// Use of this source code is subject to the terms of the Microsoft end-user
// license agreement (EULA) under which you licensed this SOFTWARE PRODUCT.
// If you did not accept the terms of the EULA, you are not authorized to use
// this source code. For a copy of the EULA, please see the LICENSE.RTF on your
// install media.
//
//------------------------------------------------------------------------------
//
//  File: fiq.c
//
//  This file implement fast interrupt handler for S3C3210X SoC. It is
//  implemented in separate file to allow replacement in platform.
//
#include <windows.h>
#include <ceddk.h>
#include <nkintr.h>
#include <oal.h>
#include <s3c24A0.h>

extern void OEMEmergencyPowerOff();
//------------------------------------------------------------------------------
//
//  Function:  OEMInterruptHandlerFIQ
//
void OEMInterruptHandlerFIQ()
{
	// This FIQ interrupt is from BAT_FLT.	
	volatile S3C24A0_IOPORT_REG	*s24A0IOP = (S3C24A0_IOPORT_REG*)OALPAtoVA(S3C24A0_BASE_REG_PA_IOPORT, FALSE);
	volatile S3C24A0_INTR_REG	*s24A0INT = (S3C24A0_INTR_REG*)OALPAtoVA(S3C24A0_BASE_REG_PA_INTR, FALSE);
	
	s24A0IOP->GPDAT &= ~(0xa << 4);   /* LED Off */
//	OEMEmergencyPowerOff();
	RETAILMSG(1, (TEXT(">>> OEMInterruptHandlerFIQ \r\n")));
	while(1);
}

//------------------------------------------------------------------------------

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?