Changeset 6816 in vbox
- Timestamp:
- Feb 5, 2008 9:50:07 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/MMHyper.cpp
r6529 r6816 745 745 { 746 746 AssertMsg(cb >= 8, ("Hey! Do you really mean to allocate less than 8 bytes?! cb=%d\n", cb)); 747 AssertMsg(cb <= _4M, ("Allocating more than 4MB!? (cb=%#x) HMA limit might need adjusting if you allocate more.\n", cb));748 747 749 748 /* … … 759 758 || cb <= 8*_1K) 760 759 { 761 Log2(("MMR3HyperAllocOnceNoRel: cb=%# x uAlignment=%#x returns %Rrc and *ppv=%p\n",760 Log2(("MMR3HyperAllocOnceNoRel: cb=%#zx uAlignment=%#x returns %Rrc and *ppv=%p\n", 762 761 cb, uAlignment, rc, *ppv)); 763 762 return rc; … … 798 797 return rc; 799 798 } 799 AssertMsgFailed(("Failed to allocate %zd bytes! %Rrc\n", cb, rc)); 800 800 SUPPageFree(pvPages, cb >> PAGE_SHIFT); 801 } 801 802 /* 803 * HACK ALERT! Try allocate it off the heap so that we don't freak 804 * out during vga/vmmdev mmio2 allocation with certain ram sizes. 805 */ 806 /** @todo make a proper fix for this so we will never end up in this kind of situation! */ 807 Log(("MMR3HyperAllocOnceNoRel: MMR3HyperMapHCRam failed with rc=%Rrc, try MMHyperAlloc(,%#d,,) instead\n", rc, cb)); 808 int rc2 = MMHyperAlloc(pVM, cb, uAlignment, enmTag, ppv); 809 if (RT_SUCCESS(rc2)) 810 { 811 Log2(("MMR3HyperAllocOnceNoRel: cb=%#x uAlignment=%#x returns %Rrc and *ppv=%p\n", 812 cb, uAlignment, rc, *ppv)); 813 return rc; 814 } 815 } 816 else 817 AssertMsgFailed(("Failed to allocate %zd bytes! %Rrc\n", cb, rc)); 818 802 819 if (rc == VERR_NO_MEMORY) 803 820 rc = VERR_MM_HYPER_NO_MEMORY; 804 Log2(("MMR3HyperAllocOnceNoRel: cb=%#x uAlignment=%#x returns %Rrc\n", cb, uAlignment, rc)); 805 AssertMsgFailed(("Failed to allocate %d bytes!\n", cb)); 821 LogRel(("MMR3HyperAllocOnceNoRel: cb=%#zx uAlignment=%#x returns %Rrc\n", cb, uAlignment, rc)); 806 822 return rc; 807 823 }
Note:
See TracChangeset
for help on using the changeset viewer.