Age | Commit message (Collapse) | Author | Files | Lines |
|
This adds a simple .travis.yml file for integration with Travis CI. It
tries to build muser.git on a Ubuntu Bionic environment using the Linux
kernel 5.2.21.
Signed-off-by: Felipe Franciosi <felipe@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Fix the return values type
|
|
fix compilations problems for kernel 4.19.67 plus clean up
|
|
muser_cmd.mmap.response is unsigned and should not be used to return
errors, instead use muser_cmd.err
Also fixed the code path to use valid errno values.
Signed-off-by: Swapnil Ingle <swapnil.ingle@nutanix.com>
|
|
1> Use errno for the failures
2> Use signed types for the returned variables
Signed-off-by: Swapnil Ingle <swapnil.ingle@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
page_has_type() seems to be an internal function and
it's not critically usefull anyway
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
general fixes and cleanup
|
|
Signed-off-by: Swapnil Ingle <swapnil.ingle@nutanix.com>
|
|
Signed-off-by: Swapnil Ingle <swapnil.ingle@nutanix.com>
|
|
_IOW means userland is writing and kernel is reading
_IOR means userland is reading and kernel is writing
MUSER_DEV_CMD_WAIT should be _IOR as userland waits to read
cmd from kernel.
Signed-off-by: Swapnil Ingle <swapnil.ingle@nutanix.com>
|
|
Cleanup
|
|
Users of libmuser do not need to know about ERR/REQ IRQs. We can later
plumb the correct support to fire REQ IRQs (for graceful removal of
devices) via a dedicated method (if ever needed). Similarly we should
offer a method to raise an ERR IRQ accordingly.
Signed-off-by: Felipe Franciosi <felipe@nutanix.com>
|
|
The dump_buffer() method has internal guards, causing the function to be
optimised out (within a compilation unit) if DEBUG is not set. The
guards around the function export are not needed.
Signed-off-by: Felipe Franciosi <felipe@nutanix.com>
|
|
This makes all function signatures consistent, using a line break after
the return type. It also review the usage of const across the project
and fixes some other minor alignment issues.
Signed-off-by: Felipe Franciosi <felipe@nutanix.com>
|
|
Trivial spelling and grammar fixes
|
|
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
|
|
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
|
|
Signed-off-by: Felipe Franciosi <felipe@nutanix.com>
|
|
It wasn't on the right place...
Signed-off-by: Felipe Franciosi <felipe@nutanix.com>
|
|
Some guards were missing, others were misaligned.
Signed-off-by: Felipe Franciosi <felipe@nutanix.com>
|
|
Several files were missing license headers.
Signed-off-by: Felipe Franciosi <felipe@nutanix.com>
|
|
Remove various spurious whitespaces and empty lines. Some other
alignment issues, too.
Signed-off-by: Felipe Franciosi <felipe@nutanix.com>
|
|
Coding style says pointers should be explicitly checked.
|
|
This helped in debugging the recent config breakage.
|
|
|
|
This got broken at some point and we missed it. If a device doesn't add
capabilities then reading from the config region returns short and fails.
Signed-off-by: Felipe Franciosi <felipe@nutanix.com>
|
|
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Need to explain why.
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
total number of bytes read
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Previously we failed reads for capabilities that do not exist, that is any
read in region 0x40 and 0x100. It is s perfectly legitimate to read that part of
the PCI config space even if there's nothing there, we just return zeros.
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
All other prints for offset use hex, so let's make it consistent.
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|
|
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
|