Streams ioctl for _I_CMD within kernel causes EFAULT
If a kernel module issues a streams ioctl call for _I_CMD, then it will fail with EFAULT.
This is because
strioctl() wrongly attempts to use
copyin() on the data despite the presence of the
Example code (vp is a pointer to a TLI vnode).
strcmd_t strcmd; int32_t rval; strcmd.sc_cmd = TI_GETMYNAME; strcmd.sc_timeout = 1; strcmd.sc_len = STRCMDBUFSIZE; ASSERT0(VOP_IOCTL(vp, _I_CMD, (intptr_t)&strcmd, FKIOCTL, CRED(), &rval, NULL));