I booted from a USB floppy drive into DOS and the laptop keyboard functions perfectly in DOS!
I suspect you are right that it is a hardware fault.
Does not compute!
Others with this problem have found the underlying cause to be anything from bad battery to failing hard disk to BIOS settings to registry errors.
Here's one fix that might be worth investigating:
Code 10 Device manager/ Keyboard not working, mouse not working /ps2
SD