Skip to content

Commit dc6280f

Browse files
committed
[CLI] Fix spacing within the Power Monitor print
1 parent 622c285 commit dc6280f

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

aarch64/corefreq-cli.c

+4-4
Original file line numberDiff line numberDiff line change
@@ -4733,8 +4733,8 @@ void Power(unsigned int iter)
47334733
idx += ldx;
47344734

47354735
for (pw = PWR_DOMAIN(PKG); pw < PWR_DOMAIN(PLATFORM); pw++) {
4736-
rdx = sprintf(&out[idx], "%.*s" "%6.2f%6.2f%6.2f",
4737-
pw == PWR_DOMAIN(PKG) ? 1 : 2, hSpace,
4736+
rdx = sprintf(&out[idx], "%.*s" "%6.2f %5.1f %6.2f",
4737+
pw == PWR_DOMAIN(PKG) ? 0 : 1, hSpace,
47384738
RO(Shm)->Proc.State.Energy[pw].Limit[SENSOR_LOWEST],
47394739
RO(Shm)->Proc.State.Energy[pw].Current,
47404740
RO(Shm)->Proc.State.Energy[pw].Limit[SENSOR_HIGHEST]);
@@ -4746,8 +4746,8 @@ void Power(unsigned int iter)
47464746
idx += 10;
47474747

47484748
for (pw = PWR_DOMAIN(PKG); pw < PWR_DOMAIN(PLATFORM); pw++) {
4749-
rdx = sprintf(&out[idx], "%.*s" "%6.2f%6.2f%6.2f",
4750-
pw == PWR_DOMAIN(PKG) ? 1 : 2, hSpace,
4749+
rdx = sprintf(&out[idx], "%.*s" "%6.2f %5.1f %6.2f",
4750+
pw == PWR_DOMAIN(PKG) ? 0 : 1, hSpace,
47514751
RO(Shm)->Proc.State.Power[pw].Limit[SENSOR_LOWEST],
47524752
RO(Shm)->Proc.State.Power[pw].Current,
47534753
RO(Shm)->Proc.State.Power[pw].Limit[SENSOR_HIGHEST]);

x86_64/corefreq-cli.c

+4-4
Original file line numberDiff line numberDiff line change
@@ -6981,8 +6981,8 @@ void Power(unsigned int iter)
69816981
idx += ldx;
69826982

69836983
for (pw = PWR_DOMAIN(PKG); pw < PWR_DOMAIN(PLATFORM); pw++) {
6984-
rdx = sprintf(&out[idx], "%.*s" "%6.2f%6.2f%6.2f",
6985-
pw == PWR_DOMAIN(PKG) ? 1 : 2, hSpace,
6984+
rdx = sprintf(&out[idx], "%.*s" "%6.2f %5.1f %6.2f",
6985+
pw == PWR_DOMAIN(PKG) ? 0 : 1, hSpace,
69866986
RO(Shm)->Proc.State.Energy[pw].Limit[SENSOR_LOWEST],
69876987
RO(Shm)->Proc.State.Energy[pw].Current,
69886988
RO(Shm)->Proc.State.Energy[pw].Limit[SENSOR_HIGHEST]);
@@ -6994,8 +6994,8 @@ void Power(unsigned int iter)
69946994
idx += 10;
69956995

69966996
for (pw = PWR_DOMAIN(PKG); pw < PWR_DOMAIN(PLATFORM); pw++) {
6997-
rdx = sprintf(&out[idx], "%.*s" "%6.2f%6.2f%6.2f",
6998-
pw == PWR_DOMAIN(PKG) ? 1 : 2, hSpace,
6997+
rdx = sprintf(&out[idx], "%.*s" "%6.2f %5.1f %6.2f",
6998+
pw == PWR_DOMAIN(PKG) ? 0 : 1, hSpace,
69996999
RO(Shm)->Proc.State.Power[pw].Limit[SENSOR_LOWEST],
70007000
RO(Shm)->Proc.State.Power[pw].Current,
70017001
RO(Shm)->Proc.State.Power[pw].Limit[SENSOR_HIGHEST]);

0 commit comments

Comments
 (0)