FW: wrapper device driver

riya khanna riyakhanna1983 at gmail.com
Mon Feb 2 17:46:24 EST 2015


The goal is to provide multiple instances of a real device, where each
instance could be assigned to a container. This is to enable support
for device multiplexing in user space.

I did look at CUSE. However,  I realized that not all the device
driver's all all operations to be forwarded to CUSE proxy daemon -
some device drivers do bookkeeping based on process PID, so CUSE proxy
daemon cannot operate on behalf of processes. Performance is another
reason.

So would it be acceptable to modify CUSE kernel driver to
filp_open(real_device_node), and use corresponding
real_filp->f_op->operation() for the file_operations that cannot be
forwarded to or are unimplemented by userspace CUSE proxy. Target/real
device file operations would act as fallback operations for
unimplemented operations.

On Mon, Feb 2, 2015 at 4:17 PM, Greg KH <greg at kroah.com> wrote:
> On Mon, Feb 02, 2015 at 04:05:35PM -0600, riya khanna wrote:
>> I guess a userspace library approach won't be transparent to the applications.
>
> Look at cuse, I think it provides what you are wanting to do here.
>
> But as you really didn't say what your goals are, it's hard to
> determine.
>
> good luck,
>
> greg k-h



More information about the Kernelnewbies mailing list