[POWERPC] Fix bugs in the hypervisor call stats code
There were a few issues with the HCALL_STATS code: - PURR cpu feature checks were backwards - We iterated one entry off the end of the hcall_stats array - Remove dead update_hcall_stats() function prototype I noticed one thing while debugging, and that is we call H_ENTER (to set up the MMU hashtable in early init) before we have done the cpu fixups. This means we will execute the PURR SPR reads even on a CPU that isnt capable of it. I wonder if we can move the CPU feature fixups earlier. Signed-off-by: Anton Blanchard <anton@samba.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
This commit is contained in:
committed by
Paul Mackerras
parent
ab87e8dc88
commit
dc40127ca5
@@ -252,8 +252,6 @@ struct hcall_stats {
|
||||
unsigned long tb_total; /* total wall time (mftb) of calls. */
|
||||
unsigned long purr_total; /* total cpu time (PURR) of calls. */
|
||||
};
|
||||
void update_hcall_stats(unsigned long opcode, unsigned long tb_delta,
|
||||
unsigned long purr_delta);
|
||||
#define HCALL_STAT_ARRAY_SIZE ((MAX_HCALL_OPCODE >> 2) + 1)
|
||||
|
||||
#endif /* __ASSEMBLY__ */
|
||||
|
||||
Reference in New Issue
Block a user