From: Yuyang Du <yuyang.du@intel.com>
To: dirk.brandewie@gmail.com
Cc: linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org,
rjw@rjwysocki.net, Dirk Brandewie <dirk.j.brandewie@intel.com>
Subject: Re: [PATCH 4/5] intel_pstate: Remove C0 tracking
Date: Fri, 9 May 2014 09:44:23 +0800 [thread overview]
Message-ID: <20140509014422.GA9855@intel.com> (raw)
In-Reply-To: <1399579047-5792-5-git-send-email-dirk.j.brandewie@intel.com>
Hi Dirk,
I don't get why you remove the c0 tracking. This is my understanding wrong.
Suppose it is removed, then the objective of the PID control is:
delta(aperf) / delta(mperf) * max_pstate / current_pstate
But delta(aperf) / delta(mperf) * max_pstate is the average frequency of the last
time frame, and current_pstate is the last requested frequency, then the
objective is:
last_freq_average / last_requested_freq ==> setpoint
What does it mean, SW satisfaction of freq request? Why control that?
Thanks
Yuyang
> @@ -561,46 +559,37 @@ static inline void intel_pstate_calc_busy(struct cpudata *cpu,
> struct sample *sample)
> {
> int32_t core_pct;
> - int32_t c0_pct;
>
> core_pct = div_fp(int_tofp((sample->aperf)),
> int_tofp((sample->mperf)));
> core_pct = mul_fp(core_pct, int_tofp(100));
> FP_ROUNDUP(core_pct);
>
> - c0_pct = div_fp(int_tofp(sample->mperf), int_tofp(sample->tsc));
> -
> sample->freq = fp_toint(
> mul_fp(int_tofp(cpu->pstate.max_pstate * 1000), core_pct));
>
> - sample->core_pct_busy = mul_fp(core_pct, c0_pct);
> + sample->core_pct_busy = core_pct;
> }
next prev parent reply other threads:[~2014-05-09 9:49 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-08 19:57 [PATCH 0/5] updates for intel_pstate dirk.brandewie
2014-05-08 19:57 ` [PATCH 2/5] intel_pstate: remove setting P state to MAX on init dirk.brandewie
2014-05-08 19:57 ` [PATCH 3/5] intel_pstate: Fix fixed point rounding macro dirk.brandewie
2014-05-12 12:17 ` Rafael J. Wysocki
2014-05-08 19:57 ` [PATCH 4/5] intel_pstate: Remove C0 tracking dirk.brandewie
2014-05-09 1:44 ` Yuyang Du [this message]
2014-05-12 0:26 ` Rafael J. Wysocki
[not found] ` <CADmjqpOnzRrB8gJsmHWG=4bvhERLovnKyP0Pcki_uVJ3qpfD0g@mail.gmail.com>
2014-05-12 2:27 ` Stratos Karafotis
2014-05-12 12:16 ` Rafael J. Wysocki
2014-05-12 14:39 ` Dirk Brandewie
2014-05-12 23:45 ` Rafael J. Wysocki
2014-05-08 19:57 ` [PATCH 5/5] intel_pstate: Add CPU IDs for Broadwell processors dirk.brandewie
2014-05-08 20:30 ` [PATCH 0/5] updates for intel_pstate Rafael J. Wysocki
2014-05-08 21:08 ` Dirk Brandewie
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20140509014422.GA9855@intel.com \
--to=yuyang.du@intel.com \
--cc=dirk.brandewie@gmail.com \
--cc=dirk.j.brandewie@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=rjw@rjwysocki.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).