These should be installed already, both are dependencies of x11/xorg and x11/xorg-minimal. So I suspect you never actually installed x11/xorg.I installed x11-drivers/xf86-input-keyboard and x11-drivers/xf86-input-mouse ports and that did the trick.