netdigger
netdigger

Reputation: 3789

Kernel User I/O application development

I've read up on the following links about User I/O: http://www.hep.by/gnu/kernel/uio-howto/

and followed http://nairobi-embedded.org/uio_example.html.

I'm using the ivshmem device to map memory from the host to the guest (in QEmu). The client driver that I'm using is kernel_module/uio/uio_ivshmem.c from https://www.gitorious.org/nahanni/guest-code.

I've had success sharing the memory between several guests, and I can also issue interrupts from the host to the guest, using the ivshmem-server from the git repository above.

But I cant figure out how I can "interrupt" from the guest to notice that writing to the memory is completed. I.e. signal to the other guest that it should read what the first guest has written.

What am I doing wrong? Is there any way to send interrupts using UIO or can I only receive? How else am I supposed to notice that I'm done writing/reading?

Upvotes: 6

Views: 485

Answers (1)

netdigger
netdigger

Reputation: 3789

Ok, I've now figured out why I cant send interrupts.

I did try using the test applications, but, as you can read in this (http://lists.gnu.org/archive/html/qemu-devel/2014-08/msg05388.html) post, a patch in the kernel broke uio_ivshmem.c.

This patch made ivshmem unable to map BAR0, which is used to send interrupts. BAR2 is still fine and can be used to share data, though interrupts wont work.

Upvotes: 2

Related Questions