[PATCH v7 2/5] riscv_cbqri: resctrl: Add cache allocation via capacity block mask

Luck, Tony tony.luck at intel.com
Tue Oct 13 08:55:57 PDT 2026


> > 3) What should happen to the legacy /sys/fs/resctrl/info/L2/cbm_mask?
> > Just hide it? I also considered renaming the resource to "L2A" to
> > avoid surprising legacy code.
> The current direction is to have these top level files continue to return
> the properties of the default/legacy control while in "legacy" control mode.
> When user space switches the control mode then these files return empty.
>
> This is what is implemented in RFC v2 so you should be able to see it in action.
>
> It was noted as one of RFC v2's opens:
>       - When switching control mode to native the top level control info files
>         stop returning information. This could be considered "work as intended"?
>
> An example of this behavior in action as applied to "min_bandwidth" can be seen
> on slide 4 of
> https://lpc.events/event/20/contributions/2368/attachments/2066/4625/resctrl_2026_combined.pdf
>
> Hiding the files could also be an option. I have not heard strong opinions on how this
> should be handled after the above mentions of current direction.

My PoC hasn't implemented anything for the control_mode file so I get this:

$ cat L2/control_mode
[legacy] native
$ sudo sh -c "echo native > L2/control_mode"
sh: 1: echo: echo: I/O error
$ cat last_cmd_status
Changing control mode not supported for this resource.

But it isn't clear to me what legacy vs. native should mean for asymmetric L2.

Potentially: Legacy mode: L2 is disabled to avoid confusion with different bitmasks per domain?

-Tony


More information about the linux-riscv mailing list