Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 12 Nov 2021 13:56:35 +0000
From:      tech-lists <tech-lists@zyxst.net>
To:        freebsd-hackers@freebsd.org
Subject:   why does clocked speed show up on arm64 but not on amd64?
Message-ID:  <YY5yk5REOTeF46vx@ceres.zyxst.net>

next in thread | raw e-mail | index | archive | help

--QJmlYWQanP4FlhYA
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Hi,

WHy does the clocked speed *not* show up on intel hardware in sysctl
dev.cpu ? It shows up in arm64 (ARM Cortex-A72)

intel:

% dmesg | grep 42
FreeBSD clang version 12.0.1 (git@github.com:llvm/llvm-project.git
llvmorg-12.0.1-0-gfed41342a82f)
CPU: Intel(R) Core(TM) i7-4770K CPU @ 3.50GHz (4251.32-MHz K8-class CPU)
                                                ^^^^^^^^^^^
shows in dmesg as above, but not in the dev.cpu sysctl

% sysctl dev.cpu.0 | less
dev.cpu.0.cx_method: C1/hlt
dev.cpu.0.cx_usage_counters: 1096037
dev.cpu.0.cx_usage: 100.00% last 4436us
dev.cpu.0.cx_lowest: C1
dev.cpu.0.cx_supported: C1/1/0
dev.cpu.0.freq_levels: 3400/84000 3200/77169 3100/73848 2900/67388
2700/61182 2500/55201 2400/52298 2200/46677 2000/41272 1800/36091
1700/34277 1500/29407 1300/24752 1100/20312 1000/18167 800/14031
dev.cpu.0.freq: 3400
dev.cpu.0.temperature: 43.0C
dev.cpu.0.coretemp.throttle_log: 0
dev.cpu.0.coretemp.tjmax: 100.0C
dev.cpu.0.coretemp.resolution: 1
dev.cpu.0.coretemp.delta: 57
dev.cpu.0.%parent: acpi0
dev.cpu.0.%pnpinfo: _HID=3Dnone _UID=3D0 _CID=3Dnone
dev.cpu.0.%location: handle=3D\_PR_.CPU0
dev.cpu.0.%driver: cpu
dev.cpu.0.%desc: ACPI CPU

But on the raspberry pi 4, the overclock shows in the sysctl *only*

% sysctl dev.cpu.0
dev.cpu.0.temperature: 49.1C
dev.cpu.0.freq_levels: 2100/-1 600/-1
dev.cpu.0.freq: 2100
dev.cpu.0.%parent: cpulist0
dev.cpu.0.%pnpinfo: name=3Dcpu@0 compat=3Darm,cortex-a72
dev.cpu.0.%location:=20
dev.cpu.0.%driver: cpu
dev.cpu.0.%desc: Open Firmware CPU

why the difference? The only place I'm expecting the overclock to not be
present would be on the rpi4, in its dmesg because u-boot hands off to
the OS, and maybe the cpu speed is missed in the handover.

However, I *am* able to see it here, on intel:

hw.clockrate: 4251
machdep.tsc_freq: 4251320612

but i'm puzzled why on intel it's not in dev.cpu.0.freq

The rpi4 doesn't have these two oids

thanks,
--=20
J.

--QJmlYWQanP4FlhYA
Content-Type: application/pgp-signature; name="signature.asc"

-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEE8n3tWhxW11Ccvv9/s8o7QhFzNAUFAmGOcooACgkQs8o7QhFz
NAUt5g/7BnOmebnEcar41HzpZ/cDAFDPpyS9ui5yqZ64Muxt9kOQXCCifzirVzEM
+d63GEtWzUktTGgMGxC3zLUx+9DJRZlIH0+9wH1NO7KxdmgO98Sm8aqMQ6IJojAj
iPWgUS/HqtGmHvQ73mHf3d1B7fC/1+jp7F9kGMvmOLXqBC83t5v4VS/qW6iHTNDn
htuamDSscU6zZ5TzRK7VdEf7VxuKg3XNaTLM5m7fgFQf63VKefBttTpr0HqnS7Yo
thAkPpr9GL6lCqnbqy6CKuAPyXSBxAveZx+1LTQeKOnJg9O8RUCzr8bOsekPm+B6
+cf5gCjBqxNDne3Z+DyhrUtUyUF1OcGQI/4GPlkHK9/ajIe4UTsTC0sGl8orQWnB
1pPkBYrU6vPa1isb8LcR3Qu+FpXv4A+nZmYKl72qz4+BRb7b+kzqcUepRfWVE8JX
t+r2UlL0ZayZX0Opsky3BOZe8QnY4MvZccl32AbyzrhOFFaAQ2uY2IACXCWvZh0v
q6aRkZHUhPR/HpdjLzWWCk6dylR4HW/szEJJcqv5srPXE1kFQWpYZK6zeypIAZpM
a5hAPrsDVeUCQ8lzaiueSDcp93EowpTiQ8RlhfIpnaTo1Q8LW8NsnP5vZs+bY3no
U7ClhRtyy+NEbbckoFRcMCmhCkRRlP9gYxONq8Kg84ZIJnaEl6g=
=tBOr
-----END PGP SIGNATURE-----

--QJmlYWQanP4FlhYA--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?YY5yk5REOTeF46vx>