News for hackers. Stuff that matters.
Re:Google developing own CPUs for Chromebook laptops by frabert on Saturday October 02, 2021 @04:01PM (#28731571)
A kernel doesn't need to use all the instructions a CPU offers -- only the ones it needs.
Re:Google developing own CPUs for Chromebook laptops by ithkuil on Saturday October 02, 2021 @04:43PM (#28731910)
If the extra instructions also operate in extra state (e.g. extra registers) a kernel needs to know about their existence so it can correctly save and restore state on context switches
Re:Google developing own CPUs for Chromebook laptops by my123 on Saturday October 02, 2021 @04:56PM (#28732004)
Not necessarily/really, the custom extensions still need to be enabled by the kernel before they can be used.

As such, it isn’t actually an issue.

Re:Google developing own CPUs for Chromebook laptops by ndesaulniers on Saturday October 02, 2021 @09:18PM (#28733713)
You're confusing MSRs (which don't have to be saved/restored on context switch) with GPRs (which do).
Re:Google developing own CPUs for Chromebook laptops by ithkuil on Sunday October 03, 2021 @08:16AM (#28736584)
Well if there is a truly undocumented extension, how do I know it doesn't come with it's own registers (e.g. like a floating point unit does)
Re:Google developing own CPUs for Chromebook laptops by saagarjha on Saturday October 02, 2021 @09:58PM (#28733900)
Apple reserves certain MSRs that apply on a per-process basis, and thus must be applied on context switch.
Re:Google developing own CPUs for Chromebook laptops by Someone on Saturday October 02, 2021 @06:13PM (#28732585)
It doesn’t need to use them, but it must be aware of them, insofar as they may introduce security problems.

As an example, if the kernel doesn’t know of DMA channels, and it requires setup code to prevent user-level code from using them to copy across process boundaries, the kernel will run fine, but have glaring security problems.

Re:Google developing own CPUs for Chromebook laptops by surajrmal on Saturday October 02, 2021 @06:53PM (#28732832)
What dma channels doesn't require mapping registers into the user space process to work? There aren't usually magic instructions you have to opt into disabling as far as I know.
Re:Google developing own CPUs for Chromebook laptops by im3w1l on Saturday October 02, 2021 @07:01PM (#28732896)
Those are not security problems, they are insecurity features readjusts tinfoil.