MFC r267986:
Remove odd practice of inverting error codes.

-EPERM is equal to ERESTART, returning which from ioctl() handler causes
infinite syscall restart.
MFC r268419:
Fix use-after-free on XPT_RESET_BUS.

That command is not queued, so does not use later status update.
MFC r267877:
Lock devstat updates in block backend to make it usable.  Polish lock names.