Created attachment 256 [details] real cpu frequency instead of weighted frequency
I haven't looked much at this, but is this really what you want? Is current_weighted_freq even used in the structure if this is applied?
The current_weighted_freq variable remains in use, but only in the jobacct_gather_cgroup.c module. In fact, the logic in jobacct_gather_cgroup.c closely resembles that of jobacct_gather_linux.c (without this patch). So perhaps both files should be changed. I'm going to copy Martin on this bug to see if he cares to comment.
I'm not sure why Yiannis suggested this change. I'll ask him about it. He's on vacation until August 19, so I probably won't get a reply before then. I agree that jobacct_gather_linux.c and jobacct_gather_cgroup.c should probably work the same way.
Yiannis, Could you comment on this?
Created attachment 758 [details] same patch, but for v14.11 This is teh same logic as in Yiannis' patch, but updated for verion 14.11 (or 14.03).
In reviewing this code, it appears the original logic is probably doing what we want. If you care to explain why this should change and re-open the ticket that's fine, but for now I am closing this.