NVPM ERROR using nvpmodel even with sudo

I’m not able to change the clock configuration using nvpmodel

$ sudo nvpmodel -m 2
NVPM ERROR: Error opening /sys/kernel/nvpmodel_emc_cap/nafll_cvnas: 2
NVPM ERROR: failed to write PARAM CVNAS: ARG MAX_FREQ: PATH: /sys/kernel/nvpmodel_emc_cap/nafll_cvnas VAL: 716800000
NVPM ERROR: failed to set power mode!
NVPM ERROR: Failed to exec option requests!

When I go to /sys/kernel/nvpmodel_emc_cap/ I can’t find nafll_cvnas, so it seems like the error makes sense, cause it is not available at all.

Where is the missing file?

I haven’t checked that particular nvpmodel for function, but all of the files in “/sys” are pseudo files and not real files. Each of those are actually a “fake” file in ram created by a kernel driver. Lack of that file implies lack of that driver or lack of a kernel feature. Have you modified the kernel or kernel config?

Yeah, you are right. Some time ago I was testing some kernel features for preempt-rt kernel and it seems I forgot to undo something. After updating the kernel with the standard Image coming with Linux_for_Tegra, nvpmodel is working again as expected.