1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-11-29 08:08:37 +00:00

procstat: Recognize HWCAP and HWCAP2 with auxv command

The two most recent additions to the elf auxiliary vector are
HWCAP and HWCAP2 which describe platform specific cpu capabilities.

Make procstat recognize these fields so that they aren't displayed
as UNKNOWN.

Reviewed by:	trociny, markj
Approved by:	markj (mentor)
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D20582
This commit is contained in:
Mitchell Horne 2019-06-11 00:59:46 +00:00
parent ffedb98b3e
commit 8a250c7568
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=348887

View File

@ -184,6 +184,18 @@ procstat_auxv(struct procstat *procstat, struct kinfo_proc *kipp)
xo_emit("{dw:/%s}{Lw:/%-16s/%s}{:AT_EHDRFLAGS/%#lx}\n",
prefix, "AT_EHDRFLAGS", (u_long)auxv[i].a_un.a_val);
break;
#endif
#ifdef AT_HWCAP
case AT_HWCAP:
xo_emit("{dw:/%s}{Lw:/%-16s/%s}{:AT_HWCAP/%#lx}\n",
prefix, "AT_HWCAP", (u_long)auxv[i].a_un.a_val);
break;
#endif
#ifdef AT_HWCAP2
case AT_HWCAP2:
xo_emit("{dw:/%s}{Lw:/%-16s/%s}{:AT_HWCAP2/%#lx}\n",
prefix, "AT_HWCAP2", (u_long)auxv[i].a_un.a_val);
break;
#endif
default:
xo_emit("{dw:/%s}{Lw:/%16ld/%ld}{:UNKNOWN/%#lx}\n",