kern: replace several EBADF with EINVAL
EBADF semantic is that the passed fd is invalid, not that it is of wrong
type. Using EBADF in these places in kern_event.c and sys_procdesc.c
give bad examples to copy from.
Note that places in kern_event.c that checks KQ_CLOSING and return EBADF
are kept, since KQ_CLOSING is the transient state before the fd is
finally closed and become eligible for EBADF.
Reviewed by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D52410