Phil, Using the PFM_PLM* is just a matter of interpretation for your platform.
For what I can see from your proposal you have not changed anything to the existing code. You just changed the comments (interpretation). The good thing about using a numbering scheme as opposed to explicit names (e.g, KERNEL, INTR, USR, ...) is that it is up to each platform to map this to their actual priv levels. On Fri, Jul 21, 2006 at 01:21:08PM +0200, Philip Mucci wrote: > Hi folks, > > Would people care to standardize the definitions of PFM_PLM? > > Currently they are different for different architectures. This isn't so > much of an issue on x86, but on PPC64, MIPS and others that have > hypervisor modes, it seems like we should go from this: > > libpfm-3.x/include/perfmon/pfmlib.h:#define PFM_PLM0 > 0x1 /* kernel level (most privileged) */ > libpfm-3.x/include/perfmon/pfmlib.h:#define PFM_PLM1 > 0x2 /* priv level 1 */ > libpfm-3.x/include/perfmon/pfmlib.h:#define PFM_PLM2 > 0x4 /* priv level 2 */ > libpfm-3.x/include/perfmon/pfmlib.h:#define PFM_PLM3 > 0x8 /* user level (least privileged) */ > > > To this: > > libpfm-3.x/include/perfmon/pfmlib.h:#define PFM_PLM0 > 0x1 /* supervisor level (most privileged) */ > libpfm-3.x/include/perfmon/pfmlib.h:#define PFM_PLM1 > 0x2 /* interrupt level */ > libpfm-3.x/include/perfmon/pfmlib.h:#define PFM_PLM2 > 0x4 /* kernel level */ > libpfm-3.x/include/perfmon/pfmlib.h:#define PFM_PLM3 > 0x8 /* user level (least privileged) */ > > To change this in the current base would simply mean altering some low > level code in PFM. MIPS is currently the latter since it supports all > modes. > > Comments? > > Phil > > > _______________________________________________ > perfmon mailing list > [email protected] > http://www.hpl.hp.com/hosted/linux/mail-archives/perfmon/ -- -Stephane _______________________________________________ perfmon mailing list [email protected] http://www.hpl.hp.com/hosted/linux/mail-archives/perfmon/
