Changeset 18263 in vbox for trunk/src/VBox
- Timestamp:
- Mar 25, 2009 4:26:37 PM (16 years ago)
- Location:
- trunk/src/VBox/Main
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/ApplianceImpl.cpp
r18248 r18263 21 21 */ 22 22 23 #include <VBox/param.h> 23 24 #include <iprt/stream.h> 24 25 #include <iprt/path.h> … … 1298 1299 /* Check for the constrains */ 1299 1300 if (ullMemSizeVBox != 0 && 1300 (ullMemSizeVBox < static_cast<uint64_t>(SchemaDefs::MinGuestRAM)||1301 ullMemSizeVBox > static_cast<uint64_t>(SchemaDefs::MaxGuestRAM)))1301 (ullMemSizeVBox < MM_RAM_MIN_IN_MB || 1302 ullMemSizeVBox > MM_RAM_MAX_IN_MB)) 1302 1303 { 1303 1304 addWarning(tr("The virtual system \"%s\" claims support for %llu MB RAM size, but VirtualBox has support for min %u & max %u MB RAM size only."), 1304 vsysThis.strName.c_str(), ullMemSizeVBox, SchemaDefs::MinGuestRAM, SchemaDefs::MaxGuestRAM);1305 ullMemSizeVBox = RT_MIN(RT_MAX(ullMemSizeVBox, static_cast<uint64_t>(SchemaDefs::MinGuestRAM)), static_cast<uint64_t>(SchemaDefs::MaxGuestRAM));1305 vsysThis.strName.c_str(), ullMemSizeVBox, MM_RAM_MIN_IN_MB, MM_RAM_MAX_IN_MB); 1306 ullMemSizeVBox = RT_MIN(RT_MAX(ullMemSizeVBox, MM_RAM_MIN_IN_MB), MM_RAM_MAX_IN_MB); 1306 1307 } 1307 1308 if (vsysThis.ullMemorySize == 0) -
trunk/src/VBox/Main/MachineImpl.cpp
r18252 r18263 983 983 { 984 984 /* check RAM limits */ 985 if (memorySize < SchemaDefs::MinGuestRAM||986 memorySize > SchemaDefs::MaxGuestRAM)985 if (memorySize < MM_RAM_MIN_IN_MB || 986 memorySize > MM_RAM_MAX_IN_MB) 987 987 return setError (E_INVALIDARG, 988 988 tr ("Invalid RAM size: %lu MB (must be in range [%lu, %lu] MB)"), 989 memorySize, SchemaDefs::MinGuestRAM, SchemaDefs::MaxGuestRAM);989 memorySize, MM_RAM_MIN_IN_MB, MM_RAM_MAX_IN_MB); 990 990 991 991 AutoCaller autoCaller (this); -
trunk/src/VBox/Main/SystemPropertiesImpl.cpp
r16569 r18263 149 149 150 150 /* no need to lock, this is const */ 151 *minRAM = SchemaDefs::MinGuestRAM; 151 AssertCompile(MM_RAM_MIN_IN_MB >= SchemaDefs::MinGuestRAM); 152 *minRAM = MM_RAM_MIN_IN_MB; 152 153 153 154 return S_OK; … … 163 164 164 165 /* no need to lock, this is const */ 165 *maxRAM = SchemaDefs::MaxGuestRAM; 166 AssertCompile(MM_RAM_MAX_IN_MB <= SchemaDefs::MaxGuestRAM); 167 *maxRAM = MM_RAM_MAX_IN_MB; 166 168 167 169 return S_OK; -
trunk/src/VBox/Main/xml/VirtualBox-settings-common.xsd
r18023 r18263 777 777 </xsd:complexType> 778 778 779 <xsd:complexType name="TMemory"> 780 <xsd:attribute name="RAMSize" use="required"> 781 <xsd:simpleType> 782 <xsd:restriction base="xsd:unsignedInt"> 783 <xsd:minInclusive value="4"/> 784 <xsd:maxInclusive value="16384"/> 785 </xsd:restriction> 786 </xsd:simpleType> 787 </xsd:attribute> 788 </xsd:complexType> 789 779 790 <xsd:complexType name="THardware"> 780 791 <xsd:all> -
trunk/src/VBox/Main/xml/VirtualBox-settings-freebsd.xsd
r15708 r18263 55 55 --> 56 56 57 <xsd:complexType name="TMemory">58 <xsd:attribute name="RAMSize" use="required">59 <xsd:simpleType>60 <xsd:restriction base="xsd:unsignedInt">61 <xsd:minInclusive value="4"/>62 <xsd:maxInclusive value="3584"/>63 </xsd:restriction>64 </xsd:simpleType>65 </xsd:attribute>66 </xsd:complexType>67 68 57 <xsd:complexType name="TAudioAdapter"> 69 58 <xsd:complexContent> -
trunk/src/VBox/Main/xml/VirtualBox-settings-linux.xsd
r15708 r18263 55 55 --> 56 56 57 <xsd:complexType name="TMemory">58 <xsd:attribute name="RAMSize" use="required">59 <xsd:simpleType>60 <xsd:restriction base="xsd:unsignedInt">61 <xsd:minInclusive value="4"/>62 <xsd:maxInclusive value="3584"/>63 </xsd:restriction>64 </xsd:simpleType>65 </xsd:attribute>66 </xsd:complexType>67 68 57 <xsd:complexType name="TAudioAdapter"> 69 58 <xsd:complexContent> -
trunk/src/VBox/Main/xml/VirtualBox-settings-macosx.xsd
r15708 r18263 55 55 --> 56 56 57 <xsd:complexType name="TMemory">58 <xsd:attribute name="RAMSize" use="required">59 <xsd:simpleType>60 <xsd:restriction base="xsd:unsignedInt">61 <xsd:minInclusive value="4"/>62 <xsd:maxInclusive value="3584"/>63 </xsd:restriction>64 </xsd:simpleType>65 </xsd:attribute>66 </xsd:complexType>67 68 57 <xsd:complexType name="TAudioAdapter"> 69 58 <xsd:complexContent> -
trunk/src/VBox/Main/xml/VirtualBox-settings-os2.xsd
r15708 r18263 56 56 --> 57 57 58 <xsd:complexType name="TMemory">59 <xsd:attribute name="RAMSize" use="required">60 <xsd:simpleType>61 <xsd:restriction base="xsd:unsignedInt">62 <xsd:minInclusive value="4"/>63 <xsd:maxInclusive value="3584"/>64 </xsd:restriction>65 </xsd:simpleType>66 </xsd:attribute>67 </xsd:complexType>68 69 58 <xsd:complexType name="TAudioAdapter"> 70 59 <xsd:complexContent> -
trunk/src/VBox/Main/xml/VirtualBox-settings-solaris.xsd
r15708 r18263 55 55 --> 56 56 57 <xsd:complexType name="TMemory">58 <xsd:attribute name="RAMSize" use="required">59 <xsd:simpleType>60 <xsd:restriction base="xsd:unsignedInt">61 <xsd:minInclusive value="4"/>62 <xsd:maxInclusive value="3584"/>63 </xsd:restriction>64 </xsd:simpleType>65 </xsd:attribute>66 </xsd:complexType>67 68 57 <xsd:complexType name="TAudioAdapter"> 69 58 <xsd:complexContent> -
trunk/src/VBox/Main/xml/VirtualBox-settings-windows.xsd
r15708 r18263 55 55 --> 56 56 57 <xsd:complexType name="TMemory">58 <xsd:attribute name="RAMSize" use="required">59 <xsd:simpleType>60 <xsd:restriction base="xsd:unsignedInt">61 <xsd:minInclusive value="4"/>62 <xsd:maxInclusive value="3584"/>63 </xsd:restriction>64 </xsd:simpleType>65 </xsd:attribute>66 </xsd:complexType>67 68 57 <xsd:complexType name="TAudioAdapter"> 69 58 <xsd:complexContent>
Note:
See TracChangeset
for help on using the changeset viewer.