voltage_domain.hh (10249:6bbb7ae309ac) | voltage_domain.hh (10395:77b9f96786c1) |
---|---|
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 --- 46 unchanged lines hidden (view full) --- 55 */ 56class VoltageDomain : public SimObject 57{ 58 public: 59 60 typedef VoltageDomainParams Params; 61 VoltageDomain(const Params *p); 62 | 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 --- 46 unchanged lines hidden (view full) --- 55 */ 56class VoltageDomain : public SimObject 57{ 58 public: 59 60 typedef VoltageDomainParams Params; 61 VoltageDomain(const Params *p); 62 |
63 typedef SrcClockDomain::PerfLevel PerfLevel; 64 |
|
63 /** 64 * Get the current voltage. 65 * 66 * @return Voltage of the domain 67 */ 68 double voltage() const { return voltageOpPoints[_perfLevel]; } 69 | 65 /** 66 * Get the current voltage. 67 * 68 * @return Voltage of the domain 69 */ 70 double voltage() const { return voltageOpPoints[_perfLevel]; } 71 |
72 /** 73 * Get the voltage at specified performance level. 74 * 75 * @param perf_level Performance level for which the voltage is requested 76 * @return Voltage of the domain at specified performance level 77 */ 78 double voltage(PerfLevel perf_level) const 79 { 80 return voltageOpPoints[perf_level]; 81 } 82 |
|
70 uint32_t numVoltages() const { return (uint32_t)voltageOpPoints.size(); } 71 | 83 uint32_t numVoltages() const { return (uint32_t)voltageOpPoints.size(); } 84 |
72 typedef SrcClockDomain::PerfLevel PerfLevel; 73 | |
74 /** 75 * Set the voltage point of the domain. 76 * @param Voltage value to be set 77 */ 78 void perfLevel(PerfLevel perf_level); 79 80 /** 81 * Get the voltage point of the domain. --- 62 unchanged lines hidden --- | 85 /** 86 * Set the voltage point of the domain. 87 * @param Voltage value to be set 88 */ 89 void perfLevel(PerfLevel perf_level); 90 91 /** 92 * Get the voltage point of the domain. --- 62 unchanged lines hidden --- |