Lines Matching refs:ipmipowercap

230 		IPMI_POWER_CAP *ipmipowercap);
3558 ipmi_get_power_cap(struct ipmi_intf * intf, IPMI_POWER_CAP * ipmipowercap) in ipmi_get_power_cap() argument
3563 sizeof(*ipmipowercap), ipmipowercap); in ipmi_get_power_cap()
3581 rdata = (void*)ipmipowercap; in ipmi_get_power_cap()
3588 ipmipowercap->PowerCap = BSWAP_16(ipmipowercap->PowerCap); in ipmi_get_power_cap()
3589 ipmipowercap->MaximumPowerConsmp = BSWAP_16(ipmipowercap->MaximumPowerConsmp); in ipmi_get_power_cap()
3590 ipmipowercap->MinimumPowerConsmp = BSWAP_16(ipmipowercap->MinimumPowerConsmp); in ipmi_get_power_cap()
3591 ipmipowercap->totalnumpowersupp = BSWAP_16(ipmipowercap->totalnumpowersupp); in ipmi_get_power_cap()
3592 ipmipowercap->AvailablePower = BSWAP_16(ipmipowercap->AvailablePower); in ipmi_get_power_cap()
3593 ipmipowercap->SystemThrottling = BSWAP_16(ipmipowercap->SystemThrottling); in ipmi_get_power_cap()
3594 ipmipowercap->Resv = BSWAP_16(ipmipowercap->Resv); in ipmi_get_power_cap()
3612 IPMI_POWER_CAP ipmipowercap; in ipmi_print_power_cap() local
3613 memset(&ipmipowercap, 0, sizeof(ipmipowercap)); in ipmi_print_power_cap()
3614 rc = ipmi_get_power_cap(intf, &ipmipowercap); in ipmi_print_power_cap()
3617 tempbtuphrconv = watt_to_btuphr_conversion(ipmipowercap.MaximumPowerConsmp); in ipmi_print_power_cap()
3619 tempbtuphrconv = watt_to_btuphr_conversion(ipmipowercap.MinimumPowerConsmp); in ipmi_print_power_cap()
3621 tempbtuphrconv = watt_to_btuphr_conversion(ipmipowercap.PowerCap); in ipmi_print_power_cap()
3624 printf("Maximum power: %d Watt\n", ipmipowercap.MaximumPowerConsmp); in ipmi_print_power_cap()
3625 printf("Minimum power: %d Watt\n", ipmipowercap.MinimumPowerConsmp); in ipmi_print_power_cap()
3626 printf("Power cap : %d Watt\n", ipmipowercap.PowerCap); in ipmi_print_power_cap()
3650 IPMI_POWER_CAP ipmipowercap; in ipmi_set_power_cap() local
3663 sizeof(ipmipowercap), &ipmipowercap); in ipmi_set_power_cap()
3681 rdata = (void *)&ipmipowercap; in ipmi_set_power_cap()
3688 ipmipowercap.PowerCap = BSWAP_16(ipmipowercap.PowerCap); in ipmi_set_power_cap()
3689 ipmipowercap.MaximumPowerConsmp = BSWAP_16(ipmipowercap.MaximumPowerConsmp); in ipmi_set_power_cap()
3690 ipmipowercap.MinimumPowerConsmp = BSWAP_16(ipmipowercap.MinimumPowerConsmp); in ipmi_set_power_cap()
3691 ipmipowercap.AvailablePower = BSWAP_16(ipmipowercap.AvailablePower); in ipmi_set_power_cap()
3692 ipmipowercap.totalnumpowersupp = BSWAP_16(ipmipowercap.totalnumpowersupp); in ipmi_set_power_cap()
3700 data[4] = ((ipmipowercap.MaximumPowerConsmp & 0xFF)); in ipmi_set_power_cap()
3701 data[5] = ((ipmipowercap.MaximumPowerConsmp & 0xFF00) >> 8); in ipmi_set_power_cap()
3702 data[6] = ((ipmipowercap.MinimumPowerConsmp & 0xFF)); in ipmi_set_power_cap()
3703 data[7] = ((ipmipowercap.MinimumPowerConsmp & 0xFF00) >> 8); in ipmi_set_power_cap()
3704 data[8] = (ipmipowercap.totalnumpowersupp); in ipmi_set_power_cap()
3705 data[9] = ((ipmipowercap.AvailablePower & 0xFF)); in ipmi_set_power_cap()
3706 data[10] = ((ipmipowercap.AvailablePower & 0xFF00) >> 8); in ipmi_set_power_cap()
3707 data[11] = (ipmipowercap.SystemThrottling); in ipmi_set_power_cap()
3718 val = ((val*(ipmipowercap.MaximumPowerConsmp in ipmi_set_power_cap()
3719 - ipmipowercap.MinimumPowerConsmp)) / 100) in ipmi_set_power_cap()
3720 + ipmipowercap.MinimumPowerConsmp; in ipmi_set_power_cap()
3726 if (((val < ipmipowercap.MinimumPowerConsmp) in ipmi_set_power_cap()
3727 || (val > ipmipowercap.MaximumPowerConsmp)) && (unit == watt)) { in ipmi_set_power_cap()
3730 ipmipowercap.MinimumPowerConsmp, ipmipowercap.MaximumPowerConsmp); in ipmi_set_power_cap()
3732 } else if (((val < ipmipowercap.MinimumPowerConsmp) in ipmi_set_power_cap()
3733 || (val > ipmipowercap.MaximumPowerConsmp)) && (unit == btuphr)) { in ipmi_set_power_cap()
3734 minpowerbtuphr = watt_to_btuphr_conversion(ipmipowercap.MinimumPowerConsmp); in ipmi_set_power_cap()
3735 maxpowerbtuphr = watt_to_btuphr_conversion(ipmipowercap.MaximumPowerConsmp); in ipmi_set_power_cap()
3736 maxpowerbtuphr1 = watt_to_btuphr_conversion(ipmipowercap.MaximumPowerConsmp); in ipmi_set_power_cap()