Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 30 Mar 2015 09:49:56 -0400
From:      Juan Mojica <jmojica@gmail.com>
To:        FreeBSD Net <freebsd-net@freebsd.org>
Subject:   Programmatically Creating VLAN in the Kernel
Message-ID:  <CAPKuH-zfRDxQ1U1kFdFr9PM76OD-AmxVpQ9-ya7t3fd2KQF=xw@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
I'm trying to programmatically create a VLAN in the kernel via ifioctl, but
I'm hitting a "copyin" in the ioctl path, and since the address I'm passing
in is a kernel address and not a user space address, the copyin is failing.

Calling the ioctl from user space is a non-starter at this point, and I
believe there will be other ioctls that will have to be called from the
kernel which will hit the same issue.

Any suggestions?

So far I've thought about marking the ifreq flags to indicate the request
came from the kernel and essentially bypass the copyin.  Another option
would be to make the create functions globally available, but this would
violate the modularity of the VLAN module.

Thanks in advance,
-- 
Juan Mojica
Email: jmojica@gmail.com



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAPKuH-zfRDxQ1U1kFdFr9PM76OD-AmxVpQ9-ya7t3fd2KQF=xw>