return TRUE;\r
}\r
\r
-/**\r
- Unlink the memory block from the pool's list.\r
-\r
- @param Head The block list head of the memory's pool.\r
- @param BlockToUnlink The memory block to unlink.\r
\r
-**/\r
-VOID\r
-EmmcPeimUnlinkMemBlock (\r
- IN EMMC_PEIM_MEM_BLOCK *Head,\r
- IN EMMC_PEIM_MEM_BLOCK *BlockToUnlink\r
- )\r
-{\r
- EMMC_PEIM_MEM_BLOCK *Block;\r
-\r
- ASSERT ((Head != NULL) && (BlockToUnlink != NULL));\r
-\r
- for (Block = Head; Block != NULL; Block = Block->Next) {\r
- if (Block->Next == BlockToUnlink) {\r
- Block->Next = BlockToUnlink->Next;\r
- BlockToUnlink->Next = NULL;\r
- break;\r
- }\r
- }\r
-}\r
\r
/**\r
Initialize the memory management pool for the host controller.\r
\r
//\r
// Unlink all the memory blocks from the pool, then free them.\r
- // EmmcPeimUnlinkMemBlock can't be used to unlink and free the\r
- // first block.\r
//\r
for (Block = Pool->Head->Next; Block != NULL; Block = Pool->Head->Next) {\r
EmmcPeimFreeMemBlock (Pool, Block);\r