Hi,
The first and only rule of "PS/2 emulation for USB devices" is that it's dodgy and no modern OS should ever use it.
What I mean is that an OS should do PCI enumeration, find all USB controllers and disable "PS/2 emulation" in all USB controllers; and should not touch anything to do with PS/2 until after "PS/2 emulation" is disabled.
Note: If convenient; disabling "PS/2 emulation" in USB controllers can be done early during boot using special purpose code, before the OS starts a real USB controller driver, and even if proper USB controller drivers don't exist. For me specifically, I'm planning to do this very early during boot (before boot code tries to establish a "dynamic root of trust" via. AMD's SKINIT instruction or similar, before kernel is started) to reduce security risks.If your code works properly on computers with actual PS/2 (that aren't using "PS/2 emulation"), then I'd assume your code is fine.
Cheers,
Brendan