1/* 2 * Copyright (c) 2012 ARM Limited 3 * All rights reserved 4 * 5 * The license below extends only to copyright in the software and shall 6 * not be construed as granting a license to any other intellectual 7 * property including but not limited to intellectual property relating 8 * to a hardware implementation of the functionality of the software --- 258 unchanged lines hidden (view full) --- 267{ 268 AddrRangeList ranges; 269 AddrRangeList actualRanges = masterPort.getSlavePort().getAddrRanges(); 270 271 for (AddrRangeIter r = actualRanges.begin(); r != actualRanges.end(); ++r) { 272 AddrRange range = *r; 273 274 for (int j = 0; j < originalRanges.size(); ++j) { |
275 if (range.intersects(originalRanges[j])) |
276 fatal("Cannot remap range that intersects the original" 277 " ranges but are not a subset.\n"); |
278 if (range.isSubset(originalRanges[j])) { |
279 // range is a subset 280 Addr offset = range.start - originalRanges[j].start; 281 range.start -= offset; 282 range.end -= offset; 283 } 284 ranges.push_back(range); 285 } 286 } 287 288 return ranges; 289} 290 291 |