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

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

?? ixosaliomem.c

?? u-boot1.3.0的原碼,從配了網絡驅動和FLASH的驅動,并該用ESC竟如
?? C
字號:
/** * @file IxOsalIoMem.c  * * @brief OS-independent IO/Mem implementation  *  *  * @par * IXP400 SW Release version 2.0 *  * -- Copyright Notice -- *  * @par * Copyright 2001-2005, Intel Corporation. * All rights reserved. *  * @par * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright *    notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright *    notice, this list of conditions and the following disclaimer in the *    documentation and/or other materials provided with the distribution. * 3. Neither the name of the Intel Corporation nor the names of its contributors *    may be used to endorse or promote products derived from this software *    without specific prior written permission. *  * @par * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS ``AS IS'' * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED.  IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. *  * @par * -- End of Copyright Notice -- *//* Access to the global mem map is only allowed in this file */#define IxOsalIoMem_C#include "IxOsal.h"#define SEARCH_PHYSICAL_ADDRESS (1)#define SEARCH_VIRTUAL_ADDRESS  (2)/* * Searches for map using one of the following criteria: *  * - enough room to include a zone starting with the physical "requestedAddress" of size "size" (for mapping) * - includes the virtual "requestedAddress" in its virtual address space (already mapped, for unmapping) * - correct coherency * * Returns a pointer to the map or NULL if a suitable map is not found. */PRIVATE IxOsalMemoryMap *ixOsalMemMapFind (UINT32 requestedAddress,    UINT32 size, UINT32 searchCriteria, UINT32 requestedEndianType){    UINT32 mapIndex;    UINT32 numMapElements =        sizeof (ixOsalGlobalMemoryMap) / sizeof (IxOsalMemoryMap);    for (mapIndex = 0; mapIndex < numMapElements; mapIndex++)    {        IxOsalMemoryMap *map = &ixOsalGlobalMemoryMap[mapIndex];        if (searchCriteria == SEARCH_PHYSICAL_ADDRESS            && requestedAddress >= map->physicalAddress            && (requestedAddress + size) <= (map->physicalAddress + map->size)            && (map->mapEndianType & requestedEndianType) != 0)        {            return map;        }        else if (searchCriteria == SEARCH_VIRTUAL_ADDRESS            && requestedAddress >= map->virtualAddress            && requestedAddress <= (map->virtualAddress + map->size)            && (map->mapEndianType & requestedEndianType) != 0)        {            return map;        }        else if (searchCriteria == SEARCH_PHYSICAL_ADDRESS)        {            ixOsalLog (IX_OSAL_LOG_LVL_DEBUG3,                IX_OSAL_LOG_DEV_STDOUT,                "Osal: Checking [phys addr 0x%x:size 0x%x:endianType %d]\n",                map->physicalAddress, map->size, map->mapEndianType, 0, 0, 0);        }    }    /*     * not found      */    return NULL;}/* * This function maps an I/O mapped physical memory zone of the given size * into a virtual memory zone accessible by the caller and returns a cookie -  * the start address of the virtual memory zone.  * IX_OSAL_MMAP_PHYS_TO_VIRT should NOT therefore be used on the returned  * virtual address. * The memory zone is to be unmapped using ixOsalMemUnmap once the caller has * finished using this zone (e.g. on driver unload) using the cookie as  * parameter. * The IX_OSAL_READ/WRITE_LONG/SHORT macros should be used to read and write  * the mapped memory, adding the necessary offsets to the address cookie. * * Note: this function is not to be used directly. Use IX_OSAL_MEM_MAP  * instead. */PUBLIC void *ixOsalIoMemMap (UINT32 requestedAddress,    UINT32 size, IxOsalMapEndianessType requestedEndianType){    IxOsalMemoryMap *map;    ixOsalLog (IX_OSAL_LOG_LVL_DEBUG3,        IX_OSAL_LOG_DEV_STDOUT,        "OSAL: Mapping [addr 0x%x:size 0x%x:endianType %d]\n",        requestedAddress, size, requestedEndianType, 0, 0, 0);    if (requestedEndianType == IX_OSAL_LE)    {        ixOsalLog (IX_OSAL_LOG_LVL_ERROR,            IX_OSAL_LOG_DEV_STDOUT,            "ixOsalIoMemMap: Please specify component coherency mode to use MEM functions \n",            0, 0, 0, 0, 0, 0);        return (NULL);    }    map = ixOsalMemMapFind (requestedAddress,        size, SEARCH_PHYSICAL_ADDRESS, requestedEndianType);    if (map != NULL)    {        UINT32 offset = requestedAddress - map->physicalAddress;        ixOsalLog (IX_OSAL_LOG_LVL_DEBUG3,            IX_OSAL_LOG_DEV_STDOUT, "OSAL: Found map [", 0, 0, 0, 0, 0, 0);        ixOsalLog (IX_OSAL_LOG_LVL_DEBUG3,            IX_OSAL_LOG_DEV_STDOUT, map->name, 0, 0, 0, 0, 0, 0);        ixOsalLog (IX_OSAL_LOG_LVL_DEBUG3,            IX_OSAL_LOG_DEV_STDOUT,            ":addr 0x%x: virt 0x%x:size 0x%x:ref %d:endianType %d]\n",            map->physicalAddress, map->virtualAddress,            map->size, map->refCount, map->mapEndianType, 0);        if (map->type == IX_OSAL_DYNAMIC_MAP && map->virtualAddress == 0)        {            if (map->mapFunction != NULL)            {                map->mapFunction (map);                if (map->virtualAddress == 0)                {                    /*                     * failed                      */                    ixOsalLog (IX_OSAL_LOG_LVL_FATAL,                        IX_OSAL_LOG_DEV_STDERR,                        "OSAL: Remap failed - [addr 0x%x:size 0x%x:endianType %d]\n",                        requestedAddress, size, requestedEndianType, 0, 0, 0);                    return NULL;                }            }            else            {                /*                 * error, no map function for a dynamic map                  */                ixOsalLog (IX_OSAL_LOG_LVL_FATAL,                    IX_OSAL_LOG_DEV_STDERR,                    "OSAL: No map function for a dynamic map - "                    "[addr 0x%x:size 0x%x:endianType %d]\n",                    requestedAddress, size, requestedEndianType, 0, 0, 0);                return NULL;            }        }        /*         * increment reference count          */        map->refCount++;        return (void *) (map->virtualAddress + offset);    }    /*     * requested address is not described in the global memory map      */    ixOsalLog (IX_OSAL_LOG_LVL_FATAL,        IX_OSAL_LOG_DEV_STDERR,        "OSAL: No mapping found - [addr 0x%x:size 0x%x:endianType %d]\n",        requestedAddress, size, requestedEndianType, 0, 0, 0);    return NULL;}/* * This function unmaps a previously mapped I/O memory zone using * the cookie obtained in the mapping operation. The memory zone in question * becomes unavailable to the caller once unmapped and the cookie should be * discarded. * * This function cannot fail if the given parameter is correct and does not * return a value. * * Note: this function is not to be used directly. Use IX_OSAL_MEM_UNMAP * instead. */PUBLIC voidixOsalIoMemUnmap (UINT32 requestedAddress, UINT32 endianType){    IxOsalMemoryMap *map;    if (endianType == IX_OSAL_LE)    {        ixOsalLog (IX_OSAL_LOG_LVL_ERROR,            IX_OSAL_LOG_DEV_STDOUT,            "ixOsalIoMemUnmap: Please specify component coherency mode to use MEM functions \n",            0, 0, 0, 0, 0, 0);        return;    }    if (requestedAddress == 0)    {        /*         * invalid virtual address          */        return;    }    map =        ixOsalMemMapFind (requestedAddress, 0, SEARCH_VIRTUAL_ADDRESS,        endianType);    if (map != NULL)    {        if (map->refCount > 0)        {            /*             * decrement reference count              */            map->refCount--;            if (map->refCount == 0)            {                /*                 * no longer used, deallocate                  */                if (map->type == IX_OSAL_DYNAMIC_MAP                    && map->unmapFunction != NULL)                {                    map->unmapFunction (map);                }            }        }    }    else    {        ixOsalLog (IX_OSAL_LOG_LVL_WARNING,            IX_OSAL_LOG_DEV_STDERR,            "OSAL: ixOsServMemUnmap didn't find the requested map "            "[virt addr 0x%x: endianType %d], ignoring call\n",            requestedAddress, endianType, 0, 0, 0, 0);    }}/*  * This function Converts a virtual address into a physical  * address, including the dynamically mapped memory. *  * Parameters	virtAddr - virtual address to convert * Return value: corresponding physical address, or NULL  *               if there is no physical address addressable  *               by the given virtual address * OS: 	VxWorks, Linux, WinCE, QNX, eCos * Reentrant: Yes * IRQ safe: Yes */PUBLIC UINT32ixOsalIoMemVirtToPhys (UINT32 virtualAddress, UINT32 requestedCoherency){    IxOsalMemoryMap *map =        ixOsalMemMapFind (virtualAddress, 0, SEARCH_VIRTUAL_ADDRESS,        requestedCoherency);    if (map != NULL)    {        return map->physicalAddress + virtualAddress - map->virtualAddress;    }    else    {        return (UINT32) IX_OSAL_MMU_VIRT_TO_PHYS (virtualAddress);    }}/*  * This function Converts a virtual address into a physical  * address, including the dynamically mapped memory. *  * Parameters	virtAddr - virtual address to convert * Return value: corresponding physical address, or NULL  *               if there is no physical address addressable  *               by the given virtual address * OS: 	VxWorks, Linux, WinCE, QNX, eCos * Reentrant: Yes * IRQ safe: Yes */PUBLIC UINT32ixOsalIoMemPhysToVirt (UINT32 physicalAddress, UINT32 requestedCoherency){    IxOsalMemoryMap *map =        ixOsalMemMapFind (physicalAddress, 0, SEARCH_PHYSICAL_ADDRESS,        requestedCoherency);    if (map != NULL)    {        return map->virtualAddress + physicalAddress - map->physicalAddress;    }    else    {        return (UINT32) IX_OSAL_MMU_PHYS_TO_VIRT (physicalAddress);    }}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
免费观看在线综合色| 美女在线观看视频一区二区| 欧美午夜免费电影| 午夜欧美2019年伦理| 国产日韩影视精品| 在线观看国产精品网站| 国产一区二区三区蝌蚪| 一区二区三区四区亚洲| 欧美一区二区黄| 99久久99久久精品免费观看| 日本欧美在线观看| 亚洲柠檬福利资源导航| 日韩欧美一级片| 91美女视频网站| 久久精品国产一区二区| 一区二区三区四区在线播放| 久久久久久夜精品精品免费| 欧美色倩网站大全免费| 丁香网亚洲国际| 丝袜亚洲精品中文字幕一区| 7777精品伊人久久久大香线蕉超级流畅| 国产 日韩 欧美大片| 爽好多水快深点欧美视频| 国产网红主播福利一区二区| 在线观看免费视频综合| youjizz久久| 久久www免费人成看片高清| 一区二区三区国产精品| 久久久九九九九| 日韩免费视频一区二区| 欧美影院午夜播放| 成人高清免费观看| 韩日欧美一区二区三区| 石原莉奈在线亚洲二区| 亚洲欧美激情在线| 久久久精品国产免大香伊| 777a∨成人精品桃花网| 色激情天天射综合网| 成人av中文字幕| 国内一区二区视频| 午夜av电影一区| 一区二区三区美女| 亚洲人成网站色在线观看| 欧美激情一区二区三区全黄| 欧美成人欧美edvon| 欧美日韩一卡二卡| 色婷婷久久久久swag精品| jizz一区二区| 成人黄色网址在线观看| 国产suv精品一区二区6| 国产一区欧美一区| 免费成人你懂的| 日韩电影一区二区三区| 日韩主播视频在线| 日韩va欧美va亚洲va久久| 亚洲高清视频在线| 亚洲自拍偷拍麻豆| 亚洲国产精品自拍| 亚洲二区在线视频| 午夜影院久久久| 亚洲第四色夜色| 日韩不卡一二三区| 久久精品99国产精品日本| 久久se这里有精品| 久久99久久精品| 国产在线视频一区二区三区| 久久激情五月激情| 国产在线视频精品一区| 成人免费视频播放| 99久久久精品| 欧美亚洲综合久久| 在线免费精品视频| 在线视频欧美精品| 欧美日韩一区二区三区免费看| 91小视频在线观看| 欧洲一区在线电影| 成人免费av网站| 一本色道久久综合精品竹菊| 成人国产精品视频| 欧美日韩午夜影院| 日韩精品一区二| 日韩女优毛片在线| 亚洲国产成人私人影院tom| 亚洲图片你懂的| 亚洲成人7777| 国产一区二区福利视频| 99久久国产综合精品色伊| 欧美日韩一级视频| 久久久久久一二三区| 日韩理论片在线| 免费在线成人网| 成人禁用看黄a在线| 欧美日韩在线综合| 久久久一区二区三区| 中文字幕日韩av资源站| 午夜精品在线视频一区| 久久er精品视频| 99久久99久久综合| 日韩精品专区在线影院观看| 国产精品―色哟哟| 午夜久久久久久久久久一区二区| 国产乱子轮精品视频| 91网页版在线| 精品国产乱码久久久久久影片| 中文字幕不卡一区| 午夜一区二区三区视频| 国产成人日日夜夜| 欧美日韩一区二区在线视频| 精品91自产拍在线观看一区| 亚洲美女区一区| 美女一区二区三区在线观看| 99久久免费精品| 精品国产乱码久久久久久浪潮| 亚洲欧美日韩综合aⅴ视频| 九一九一国产精品| 欧美性色aⅴ视频一区日韩精品| 久久久久九九视频| 日韩av二区在线播放| 成人午夜视频网站| 欧美图区在线视频| 国产精品午夜春色av| 免费在线欧美视频| 欧美日韩综合在线免费观看| 国产精品理伦片| 国产一区二区不卡在线| 777色狠狠一区二区三区| 亚洲日本在线视频观看| 国产激情视频一区二区在线观看 | 欧美亚一区二区| 久久久久九九视频| 日韩电影网1区2区| 欧美视频在线一区| 亚洲欧美经典视频| 成人中文字幕合集| 久久女同性恋中文字幕| 日韩av不卡在线观看| 欧美性生活久久| 亚洲精品日产精品乱码不卡| 成人高清视频在线| 国产午夜精品福利| 精品一区二区在线观看| 欧美一区二区三区四区高清 | 日韩亚洲欧美成人一区| 亚洲成人资源网| 欧美影院一区二区三区| 亚洲精品一二三四区| 91在线无精精品入口| 久久蜜桃香蕉精品一区二区三区| 亚洲综合无码一区二区| 91女神在线视频| 亚洲欧美偷拍三级| 色94色欧美sute亚洲线路二 | 亚洲成在线观看| 欧美三级日韩在线| 亚洲一区二区三区三| 91成人免费电影| 国产精品国产三级国产aⅴ入口| 成人小视频免费在线观看| 中文无字幕一区二区三区| 成人午夜激情视频| 亚洲国产高清不卡| 成人黄色小视频在线观看| 亚洲三级电影全部在线观看高清| 91首页免费视频| 一区二区高清免费观看影视大全| 在线观看欧美日本| 亚洲成人免费电影| 91精品国产91热久久久做人人| 日韩电影免费一区| 欧美一二三在线| 国产精品自在欧美一区| 国产精品久久毛片av大全日韩| 91麻豆.com| 视频在线观看一区| 91精品视频网| 国产成都精品91一区二区三| 亚洲视频一二三| 欧美日韩国产天堂| 奇米888四色在线精品| 欧美日韩精品三区| 激情综合网最新| 国产精品国产三级国产| 欧美视频一区二区三区| 麻豆freexxxx性91精品| 日本一区二区免费在线 | 成人激情免费网站| 亚洲综合在线电影| 欧美不卡一区二区三区四区| 国产精品99久久久久久久女警| 日韩理论片一区二区| 精品视频资源站| 韩国理伦片一区二区三区在线播放| 国产精品无码永久免费888| 欧洲精品视频在线观看| 日本一区中文字幕| 欧美视频一区在线| 国模一区二区三区白浆| 亚洲免费在线观看| 日韩欧美电影一二三| 99久久精品一区|