Message ID | 20161013153105.2517-12-piotr.luc@intel.com (mailing list archive) |
---|---|
State | Not Applicable, archived |
Headers | show |
Piotr, Thanks for sending the patch, I've made this change to my turbostat branch for 4.10. I did not apply your patch directly because for some reason it didn't appear in patchwork for linux-pm, only for lkml, which I do not review. Also, your patch depended on your style update patch to use the model # macros. Unfortunately what you did not know was that I'd already applied a slightly different style update patch. (and it was my fault that I did not push it upstream before my summer sabbatical, sorry) In general, though, a good strategy when mixing style and functionality patches is to do the functionality first. The reason is both that style patches tend to conflict more, and you don't want them to hold up the functionality. Also, if your functionality patch does not depend on style, it is easier to backport to distros who avoid style updates. Fortunately, this one was trivial. thanks, Len Brown, Intel Open Source Technology Center -- To unsubscribe from this list: send the line "unsubscribe linux-pm" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Thu, 2016-12-01 at 01:47 -0500, Len Brown wrote: > Piotr, > Thanks for sending the patch, I've made this change to my turbostat > branch for 4.10. > > I did not apply your patch directly because for some reason it didn't > appear in patchwork for linux-pm, > only for lkml, which I do not review. The missing from linux-pm was my mistake due to lack of experience and perspicacity; I did not add the linux-pm list to cc because I could not find an entry for turbostat on MAINTAINERS file. Probably, it is mentioned implicitly but I did not come across it. > > Also, your patch depended on your style update patch to use the model > # macros. > Unfortunately what you did not know was that I'd already applied a > slightly different style update patch. > (and it was my fault that I did not push it upstream before my summer > sabbatical, sorry) NP, this was an easy change made automatically by my script. > > In general, though, a good strategy when mixing style and > functionality patches > is to do the functionality first. The reason is both that style > patches tend to conflict more, > and you don't want them to hold up the functionality. > Also, if your functionality patch does not depend on style, > it is easier to backport to distros who avoid style updates. Thanks for the tip. However, in this case, I got comments to use the macros instead raw numbers in my patch and remove unnecessary comments. It caused that the style patch came first. Thanks Piotr
diff --git a/tools/power/x86/turbostat/turbostat.c b/tools/power/x86/turbostat/turbostat.c index 09a542cc..5773509 100644 --- a/tools/power/x86/turbostat/turbostat.c +++ b/tools/power/x86/turbostat/turbostat.c @@ -2213,6 +2213,7 @@ int probe_nhm_msrs(unsigned int family, unsigned int model) pkg_cstate_limits = amt_pkg_cstate_limits; break; case INTEL_FAM6_XEON_PHI_KNL: /* PHI */ + case INTEL_FAM6_XEON_PHI_KNM: /* PHI */ pkg_cstate_limits = phi_pkg_cstate_limits; break; case INTEL_FAM6_ATOM_GOLDMONT: /* BXT */ @@ -2238,6 +2239,7 @@ int has_nhm_turbo_ratio_limit(unsigned int family, unsigned int model) case INTEL_FAM6_NEHALEM_EX: /* Nehalem-EX Xeon - Beckton */ case INTEL_FAM6_WESTMERE_EX: /* Westmere-EX Xeon - Eagleton */ case INTEL_FAM6_XEON_PHI_KNL: /* PHI - Knights Landing (different MSR definition) */ + case INTEL_FAM6_XEON_PHI_KNM: /* PHI - Knights Mill (similar to KNL) */ return 0; default: return 1; @@ -2285,6 +2287,7 @@ int has_knl_turbo_ratio_limit(unsigned int family, unsigned int model) switch (model) { case INTEL_FAM6_XEON_PHI_KNL: /* Knights Landing */ + case INTEL_FAM6_XEON_PHI_KNM: /* Knights Mill */ return 1; default: return 0; @@ -2315,6 +2318,7 @@ int has_config_tdp(unsigned int family, unsigned int model) case INTEL_FAM6_SKYLAKE_X: /* SKX */ case INTEL_FAM6_XEON_PHI_KNL: /* Knights Landing */ + case INTEL_FAM6_XEON_PHI_KNM: /* Knights Mill */ return 1; default: return 0; @@ -2616,6 +2620,7 @@ rapl_dram_energy_units_probe(int model, double rapl_energy_units) case INTEL_FAM6_BROADWELL_X: /* BDX */ case INTEL_FAM6_BROADWELL_XEON_D: /* BDX-DE */ case INTEL_FAM6_XEON_PHI_KNL: /* KNL */ + case INTEL_FAM6_XEON_PHI_KNM: /* KNM */ return (rapl_dram_energy_units = 15.3 / 1000000); default: return (rapl_energy_units); @@ -2664,6 +2669,7 @@ void rapl_probe(unsigned int family, unsigned int model) case INTEL_FAM6_BROADWELL_XEON_D: /* BDX-DE */ case INTEL_FAM6_SKYLAKE_X: /* SKX */ case INTEL_FAM6_XEON_PHI_KNL: /* KNL */ + case INTEL_FAM6_XEON_PHI_KNM: /* KNM */ do_rapl = RAPL_PKG | RAPL_DRAM | RAPL_DRAM_POWER_INFO | RAPL_DRAM_PERF_STATUS | RAPL_PKG_PERF_STATUS | RAPL_PKG_POWER_INFO; break; case INTEL_FAM6_SANDYBRIDGE_X: @@ -3024,6 +3030,7 @@ int is_knl(unsigned int family, unsigned int model) return 0; switch (model) { case INTEL_FAM6_XEON_PHI_KNL: /* KNL */ + case INTEL_FAM6_XEON_PHI_KNM: /* KNM */ return 1; } return 0;