View | Details | Raw Unified | Return to ticket 341 | Differences between
and this patch

Collapse All | Expand All

(-)a/src/plugins/acct_gather_energy/ipmi/acct_gather_energy_ipmi.c (-2 / +8 lines)
Lines 724-737 static int _get_joules_task(uint16_t delta) Link Here
724
		if (slurm_ipmi_conf.adjustment)
724
		if (slurm_ipmi_conf.adjustment)
725
			local_energy->base_consumed_energy +=
725
			local_energy->base_consumed_energy +=
726
				_get_additional_consumption(
726
				_get_additional_consumption(
727
					now, time_call,
727
					local_energy->poll_time, now,
728
					local_energy->current_watts,
728
					local_energy->current_watts,
729
					local_energy->current_watts);
729
					local_energy->current_watts);
730
	} else {
730
	} else {
731
		/* This is just for the step, so take all the pervious
731
		/* This is just for the step, so take all the pervious
732
		   consumption out of the mix.
732
		   consumption out of the mix.
733
		*/
733
		*/
734
		start_current_energy = local_energy->consumed_energy;
734
		if (slurm_ipmi_conf.adjustment)
735
			local_energy->previous_consumed_energy +=
736
				_get_additional_consumption(
737
					local_energy->poll_time, now,
738
					local_energy->current_watts,
739
					local_energy->current_watts);
740
		start_current_energy = local_energy->previous_consumed_energy;
735
		local_energy->base_consumed_energy = 0;
741
		local_energy->base_consumed_energy = 0;
736
		first = false;
742
		first = false;
737
	}
743
	}

Return to ticket 341