亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? sngks32cintrctl.c

?? Vxworks_Bsp_S344b0x Source
?? C
字號:
/* sngks32cIntrCtl.c - Samsung KS32C interrupt controller driver *//* Copyright 1984-2001 Wind River Systems, Inc. */#include "copyright_wrs.h"/*modification history--------------------01c,02oct01,m_h  race condition01b,26apr01,m_h  convert tabs to spaces for readability01a,12apr01,m_h  created from snds100 template.*//*DESCRIPTIONThis module implements interrupt controller driver for Samsung's KS32C50100microprocessor which is an ARM based processor with several integrated peripherals.  It has an interrupt controller, two 32-bit timers, one Ethernet controller, two HDLC controllers, one IIC controller, general purpose I/O ports, and a 2-channel DMA controller.The KS32C interrupt controller is a simple, generic interrupt controllerthat manages 21 levels of interrupts from various sources internal to themicroprocessor and external to it.  For external interrupts are supported.The interrupt controller has control and pending status registers, maskregister and supports level-sensitive interrupts.  This library providesthe routines to manage interrupts multiplexed by the KS32C interrupt controller.The KS32C interrupt controller registers used by this driver are describedbelow under the symbolic names used herein.SNGKS32C_INTENB (write): this is the mask register described in theKS32C50100 Users' Manual.  When this register is written, each data bit that is clear (0) causes the corresponding interrupt to be enabled.Each bit that is set (1) causes the corresponding interrupt to be disabled.SNGKS32C_INTPEND (read): this is the interrupt pending register.When this register is read, each data bit that is set (1) indicates thatan interrupt is pending from the corresponding source. Level 20 is thehighest priority and level 0 is the lowest.SNGKS32C_INTMODE (write): this register is used to configure the interruptsin FIQ or IRQ mode.  Each bit set in this register configures the correspondinginterrupt as FIQ.  Otherwise the interrupt is treated as IRQ.  VxWorksdoes not support the high priority FIQ mode of interrupts.  Hence all theinterrupts have to be configured in IRQ mode.The interrupt priority registers can be used to change the prioritiesof the interrupts from the default settings.  This feature is notsupported in this driver.  All the interrupts are set with the defaultpriority ordering.The number of interrupts supported by the device i.e. the number ofvalid bits in the SNGKS32C_INTPEND register (21), is specified bySNGKS32C_INTNUMLEVELS.sngks32carm7.h has defined the addresses of the controller chips registers:SNGKS32C_INTENB, SNGKS32C_INTDIS and SNGKS32C_INTPEND and also the driver constants SNGKS32C_INTMASK_VAL, SNGKS32C_INTNUMLEVELS.The chip registers are memory-mapped at specified addresses internal tothe processor.  32-bit accesses can be made to these register locations.The macros SNGKS32C_INT_REG_READ and SNGKS32C_INT_REG_WRITE are used toaccess these registers.The BSP will initialize this driver in sysHwInit2(), after initializingthe main interrupt library, usually intLibInit().  The initializationroutine, sngks32cIntDevInit() will setup the interrupt controller device,it will mask off all individual interrupt sources and then set theinterrupt level to enable all interrupts.  See sngks32cIntDevInit for moreinformation.All of the functions in this library are global.  This allows them tobe used by the BSP if it is necessary to create wrapper routines or toincorporate several drivers together as one.SEE ALSO<Samsung KS32C50100 User's Manual>*/#include "vxWorks.h"#include "config.h"#include "intLib.h"#include "s3c44b0x.h"#if !defined (S3C44B0X_INTPND) || !defined (S3C44B0X_INTENB) || \    !defined (S3C44B0X_INTMASK_VAL) || !defined (S3C44B0X_INTNUMLEVELS) || \    !defined (S3C44B0X_INTDIS)#   error missing S3C44B0X interrupt definitions#endif#define SNGKS32C_INT_VEC_BASE    (0x0)/* hardware access methods */#ifndef SNGKS32C_INT_REG_READ#   define SNGKS32C_INT_REG_READ(x,result) \        ((result) = *(volatile UINT32 *)(x))#endif    /*SNGKS32C_INT_REG_READ*/#ifndef SNGKS32C_INT_REG_WRITE#   define SNGKS32C_INT_REG_WRITE(x,data) \        (*((volatile UINT32 *)(x)) = (data))#endif /*SNGKS32C_INT_REG_WRITE*//* Convert level number to vector number */#ifndef SNGKS32C_INT_LVL_VEC_MAP#   define SNGKS32C_INT_LVL_VEC_MAP(level, vector) \        ((vector) = ((level) + SNGKS32C_INT_VEC_BASE))#endif/* Convert pending register value, to a level number */#ifndef SNGKS32C_INT_PEND_LVL_MAP#   define SNGKS32C_INT_PEND_LVL_MAP(pendReg, level) \        ((level) = (pendReg))#endif/* driver constants */#define SNGKS32C_INT_ALL_ENABLED     (S3C44B0X_INTNUMLEVELS)#define SNGKS32C_INT_ALL_DISABLED    (S3C44B0X_INTNUMLEVELS-1)/* Local data *//* * A mask word.  Bits are set in this word when a specific level * is enabled. It is used to mask off individual levels that have * not been explicitly enabled. */LOCAL UINT32 sngks32cIntLvlEnabled;/* forward declarations */STATUS    sngks32cIntLvlVecChk  (int*, int*);STATUS    sngks32cIntLvlEnable  (int);STATUS    sngks32cIntLvlDisable (int);/*added by amine*/STATUS s3c44BIntLvlAck (int level, int vector){	SNGKS32C_INT_REG_WRITE(S3C44B0X_I_ISPC,(1 << vector));	return OK;}/********************************************************************************* sngks32cIntDevInit - initialize the interrupt controller** This routine will initialize the interrupt controller device, disabling all* interrupt sources.  It will also connect the device driver specific routines* into the architecture level hooks.  If the BSP needs to create a wrapper* routine around any of the arhitecture level routines, it should install the* pointer to the wrapper routine after calling this routine.** RETURNS: N/A*/void sngks32cIntDevInit (void)    {    SNGKS32C_INT_REG_WRITE (S3C44B0X_INTCON, 5);    /* install the driver routines in the architecture hooks */    sysIntLvlVecChkRtn     = sngks32cIntLvlVecChk;    sysIntLvlEnableRtn     = sngks32cIntLvlEnable;    sysIntLvlDisableRtn    = sngks32cIntLvlDisable;		/*added by amine*/	sysIntLvlVecAckRtn     = s3c44BIntLvlAck;  	    sngks32cIntLvlEnabled  = 0x0;     /* all sources disabled */    SNGKS32C_INT_REG_WRITE (S3C44B0X_INTENB, ((~sngks32cIntLvlEnabled) & S3C44B0X_INTMASK_VAL));    /*SNGKS32C_INT_REG_WRITE (S3C44B0X_INTPND, S3C44B0X_INTMASK_VAL);*/    SNGKS32C_INT_REG_WRITE (S3C44B0X_I_ISPC, S3C44B0X_INTMASK_VAL);    SNGKS32C_INT_REG_WRITE (S3C44B0X_INTMOD,SNGKS32C_INTMODEIRQ);    }/********************************************************************************* sngks32cIntLvlVecChk - check for and return any pending interrupts** This routine interrogates the hardware to determine the highest priority* interrupt pending.  It returns the vector associated with that interrupt, and* also the interrupt priority level prior to the interrupt (not the* level of the interrupt).  The current interrupt priority level is then* raised to the level of the current interrupt so that only higher priority* interrupts will be accepted until this interrupt is finished.** The return value ERROR indicates that no pending interrupt was found and* that the level and vector values were not returned.** RETURNS: OK or ERROR if no interrupt is pending.*/STATUS  sngks32cIntLvlVecChk    (    int* pLevel,  /* ptr to receive old interrupt level */    int* pVector  /* ptr to receive current interrupt vector */    )    {    int newLevel;    int intPendMask = 0x2000000;    int count;    UINT32 isr;	int intMask;	    /* Read pending interrupt register and mask undefined bits */    SNGKS32C_INT_REG_READ (S3C44B0X_INTPND, newLevel);    if ((newLevel & S3C44B0X_INTMASK_VAL) == 0)        return ERROR;		SNGKS32C_INT_REG_READ (S3C44B0X_INTENB, intMask);	newLevel = newLevel&(~intMask);	if (newLevel == 0)        return ERROR;    /*     * Step through the bits looking for a 1. This *will* terminate.     * We could use ffsLsb() for this if we don't mind the function call     * overhead     */    for (count = 0, isr = 25; count < S3C44B0X_INTNUMLEVELS; count++)        {        if (intPendMask & newLevel)            break;        isr--;        intPendMask >>= 1;        }    *pVector = isr;    /* Acknowledge the interrupt as given in SNGKS32C ARM7 sample code */    /*SNGKS32C_INT_REG_WRITE(S3C44B0X_INTPND,(1 << isr));*/	/*SNGKS32C_INT_REG_WRITE(S3C44B0X_I_ISPC,(1 << isr));*/    return OK;    }/********************************************************************************* sngks32cIntLvlEnable - enable a single interrupt level** Enable a specific interrupt level.  The enabled level will be allowed to* generate an interrupt, when the overall interrupt level is set below the* specified level.  Without being enabled, the interrupt is blocked regardless* of the overall interrupt level setting.** RETURNS: OK or ERROR if the specified level cannot be enabled.*/STATUS  sngks32cIntLvlEnable    (    int level  /* level to be enabled */    )    {    int key;    if (level < 0 ||        level >= S3C44B0X_INTNUMLEVELS)        return ERROR;    /* clear bit in mask register */    key = intLock ();    sngks32cIntLvlEnabled |= ((1 << level));    SNGKS32C_INT_REG_WRITE (S3C44B0X_INTENB, ((~sngks32cIntLvlEnabled) & S3C44B0X_INTMASK_VAL));    intUnlock (key);    return OK;    }/********************************************************************************* sngks32cIntLvlDisable - disable a single interrupt level** Disable a specific interrupt level.  The disabled level is prevented* from generating an interrupt even if the overall interrupt level is set* below the specified level.** RETURNS: OK or ERROR, if the specified interrupt level cannot be disabled.*/STATUS  sngks32cIntLvlDisable    (    int level  /* level to be disabled */    )    {    int key;    if (level < 0 ||        level >= S3C44B0X_INTNUMLEVELS)        return ERROR;    /* set bit in mask register */    key = intLock ();    sngks32cIntLvlEnabled &= ~(1 << level);    SNGKS32C_INT_REG_WRITE (S3C44B0X_INTENB, ((~sngks32cIntLvlEnabled) & S3C44B0X_INTMASK_VAL));    intUnlock (key);    return OK;    }

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美国产97人人爽人人喊| 成人免费观看av| 在线亚洲人成电影网站色www| 91精品啪在线观看国产60岁| 精品乱码亚洲一区二区不卡| 日本美女一区二区三区视频| 欧美日韩国产片| 一区二区三区鲁丝不卡| 色美美综合视频| 亚洲码国产岛国毛片在线| 91丨porny丨蝌蚪视频| 中文字幕一区二区日韩精品绯色| 成人精品一区二区三区四区| 久久亚洲精华国产精华液| 国产一区二区在线观看视频| 欧美精品一区二区精品网| 国产一区二区毛片| 国产三级三级三级精品8ⅰ区| 99国产精品99久久久久久| 亚洲美女免费在线| 欧美日韩精品综合在线| 国产麻豆一精品一av一免费 | 亚洲欧美中日韩| 欧洲人成人精品| 午夜精品影院在线观看| 色先锋久久av资源部| 蜜桃免费网站一区二区三区| 亚洲精品在线观| 色婷婷综合久久久久中文一区二区 | 韩国毛片一区二区三区| ww亚洲ww在线观看国产| 国产91丝袜在线观看| 亚洲欧美一区二区三区孕妇| 欧美日韩一区二区三区不卡 | 中文字幕一区二区三区乱码在线| 成人app下载| 国产精品丝袜91| 在线观看国产一区二区| 日韩一区精品视频| 欧美国产日本韩| 欧美中文字幕一区二区三区| 蜜桃在线一区二区三区| 国产精品久久久久毛片软件| 欧美在线视频全部完| 精品一区二区三区av| 亚洲视频小说图片| 制服丝袜一区二区三区| 蜜臀va亚洲va欧美va天堂| 亚洲精品一区二区三区四区高清 | 美女视频黄久久| 中文字幕一区二区三区色视频| 欧美日韩久久久一区| 国产91精品露脸国语对白| 首页亚洲欧美制服丝腿| 国产日韩欧美高清| 亚洲欧美视频在线观看视频| 91老司机福利 在线| 日韩中文字幕av电影| 欧美videos大乳护士334| 91在线观看地址| 狠狠色丁香久久婷婷综合_中| 一区二区三区影院| 国产亚洲欧美在线| 欧美一区二区三区视频在线 | 麻豆精品视频在线观看免费| 国产精品久久久久久久久免费桃花 | 亚洲电影欧美电影有声小说| 欧美精品一区二区三区在线| 97国产一区二区| 国产精品一区一区三区| 亚洲成av人片一区二区三区| 国产精品久久国产精麻豆99网站| 欧美一区三区四区| 欧美这里有精品| 97精品视频在线观看自产线路二| 国产精品一区二区91| 日韩av午夜在线观看| 一区二区三区在线视频免费观看| 日韩视频免费观看高清完整版| 日本乱人伦aⅴ精品| 成人福利视频网站| 精品一区二区综合| 午夜精品影院在线观看| 亚洲免费电影在线| 中文字幕人成不卡一区| 亚洲精品在线电影| 日韩视频一区二区三区| 777午夜精品视频在线播放| 欧美视频日韩视频| 精品视频1区2区| 欧美视频精品在线观看| 欧美在线播放高清精品| 日本久久一区二区| 欧美怡红院视频| 精品视频1区2区3区| 欧美日韩午夜在线| 欧美亚一区二区| 91啪九色porn原创视频在线观看| www.激情成人| 色狠狠色狠狠综合| 欧美色图一区二区三区| 欧美日韩精品三区| 欧美成人精品3d动漫h| 欧美唯美清纯偷拍| 欧美性色综合网| 欧美中文字幕一二三区视频| 欧美日韩免费一区二区三区视频| 欧美伊人精品成人久久综合97| 色狠狠av一区二区三区| 欧美日韩电影一区| 日韩一区二区三区观看| 久久影院视频免费| 国产精品污网站| 亚洲精品国产高清久久伦理二区| 日本一区二区在线不卡| 国产欧美日韩在线| 136国产福利精品导航| 亚洲五码中文字幕| 免费观看日韩电影| 国产成人av影院| 国产一区二区三区av电影| 成人一区二区三区中文字幕| 在线观看一区日韩| 欧美一三区三区四区免费在线看 | 56国语精品自产拍在线观看| 日韩午夜av一区| 国产精品―色哟哟| 国产精品无码永久免费888| 国产精品久线在线观看| 亚洲国产精品久久久男人的天堂 | wwwwww.欧美系列| 国产精品久久毛片av大全日韩| 一区二区三区在线免费播放| 日本网站在线观看一区二区三区| 国产一区二区三区| 一本大道av一区二区在线播放| 欧美日韩国产bt| 日韩一区二区高清| 亚洲国产岛国毛片在线| 国产精品嫩草久久久久| 偷拍日韩校园综合在线| 成人久久久精品乱码一区二区三区| 欧美综合亚洲图片综合区| 精品国产网站在线观看| 亚洲免费观看视频| 国产伦精品一区二区三区免费| 国产精品77777| 欧美最猛性xxxxx直播| 2022国产精品视频| 亚洲最新在线观看| 成人午夜视频福利| 欧美大白屁股肥臀xxxxxx| 亚洲bdsm女犯bdsm网站| 91官网在线免费观看| 亚洲黄色小视频| 在线看国产一区二区| 亚洲欧美视频在线观看视频| 99精品一区二区| 亚洲欧美日韩电影| 色综合天天综合色综合av| 中文字幕电影一区| 国产精品538一区二区在线| 精品国产污污免费网站入口| 蜜臀av性久久久久蜜臀aⅴ流畅| 欧美日韩国产色站一区二区三区| 亚洲图片一区二区| 精品视频123区在线观看| 夜夜嗨av一区二区三区| 欧美亚洲国产bt| 亚洲国产精品欧美一二99| 欧美色网一区二区| 三级影片在线观看欧美日韩一区二区| 色婷婷综合久久久| 一个色综合网站| 欧美男生操女生| 免费看精品久久片| 久久久久久久久免费| 丰满放荡岳乱妇91ww| 亚洲人成伊人成综合网小说| 在线观看亚洲精品视频| 五月激情丁香一区二区三区| 正在播放亚洲一区| 久久国产精品无码网站| 精品国产乱码久久久久久牛牛 | www..com久久爱| 亚洲欧美激情小说另类| 欧美日韩一区在线| 久久机这里只有精品| 久久精品免费在线观看| 成人毛片视频在线观看| 亚洲精品视频观看| 91精选在线观看| 久草这里只有精品视频| 中文字幕成人av| 欧美性色欧美a在线播放| 麻豆精品视频在线观看视频| 国产精品天天摸av网| 欧美三级视频在线播放| 日韩激情一二三区| 久久久亚洲精品石原莉奈|