/* Issue favored core read command */
value = cmd << MSR_OC_MAILBOX_CMD_OFFSET; /* Set the busy bit to indicate OS is trying to issue command */
value |= BIT_ULL(MSR_OC_MAILBOX_BUSY_BIT);
ret = wrmsrq_safe(MSR_OC_MAILBOX, value); if (ret) {
pr_debug("cpu %d OC mailbox write failed\n", cpu); return ret;
}
for (i = 0; i < OC_MAILBOX_RETRY_COUNT; ++i) {
ret = rdmsrq_safe(MSR_OC_MAILBOX, &value); if (ret) {
pr_debug("cpu %d OC mailbox read failed\n", cpu); break;
}
if (value & BIT_ULL(MSR_OC_MAILBOX_BUSY_BIT)) {
pr_debug("cpu %d OC mailbox still processing\n", cpu);
ret = -EBUSY; continue;
}
if ((value >> MSR_OC_MAILBOX_RSP_OFFSET) & 0xff) {
pr_debug("cpu %d OC mailbox cmd failed\n", cpu);
ret = -ENXIO; break;
}
ret = value & 0xff;
pr_debug("cpu %d max_ratio %d\n", cpu, ret); break;
}
priority = get_oc_core_priority(cpu); if (priority < 0) return0;
sched_set_itmt_core_prio(priority, cpu);
/* Enable ITMT feature when a core with different priority is found */ if (max_highest_perf <= min_highest_perf) { if (priority > max_highest_perf)
max_highest_perf = priority;
if (priority < min_highest_perf)
min_highest_perf = priority;
if (max_highest_perf > min_highest_perf)
schedule_work(&sched_itmt_work);
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.