/* Create an empty route table. This includes its internal route cache. */
IP6_ROUTE_TABLE* Ip6CreateRouteTable(VOID)
/* Create an empty route table. This includes its internal route cache. */
IP6_ROUTE_TABLE* Ip6CreateRouteTable(VOID)
{
  IP6_ROUTE_TABLE  *RtTable;
  UINT32           Index;
  RtTable = AllocatePool (sizeof (IP6_ROUTE_TABLE));
  if (RtTable == NULL) {
    return NULL;
  }
  RtTable->RefCnt   = 1;
  RtTable->TotalNum = 0;
  for (Index = 0; Index <= IP6_PREFIX_MAX; Index++) {
    InitializeListHead (&RtTable->RouteArea[Index]);
  }
  for (Index = 0; Index < IP6_ROUTE_CACHE_HASH_SIZE; Index++) {
    InitializeListHead (&RtTable->Cache.CacheBucket[Index]);
    RtTable->Cache.CacheNum[Index] = 0;
  }
  return RtTable;
}