Git Product home page Git Product logo

p2pmem-pci's People

Contributors

lsgunth avatar sbates130272 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

p2pmem-pci's Issues

Calling open() to /dev/p2pmemX fails, returning EINVAL

OS: Ubuntu 18.04.4 LTS
Kernel: 4.20.0

I am currently testing a custom device driver with p2pmem-pci userspace driver. My goal is to write a data to device's MMIO register through p2pmem-pci device.

#define _GNU_SOURCE 1
...
int fd = open("/dev/p2pmem0", O_WRONLY | O_DIRECT);

The open() returns -EINVAL due to O_DIRECT flag. If I remove O_DIRECT, open() succeeds but write operations do not work as intended (no MMIO write).
Manual of open() says the filesystem should not have journaling, which requires write buffer, so I also run the program in the journal-disabled ext4 fs, but have no lock.

Could you please let me know what should I do to make O_DIRECT works?

In p2pmem-test, pread() stuck

Hi,

I have two NVMe device with CMB.
When I want to use pread() form /dev/nvme0n1 to /dev/p2pmem0, it will stuck.
I trace the code and found it is fail in kernel function pci_p2pdma_map_sg_attrs().
It always report p2pdma map type unknown (PCI_P2PDMA_MAP_UNKNOWN).
Could you help me or give me some comment to fix this issue ?

Thank,
Joshua Lin

OS: Ubuntu 18.04.4 LTS
Kernel: 5.14.10
(re-build kernel and enable CONFIG_PCI_P2PDMA)

make module a late_initcall()

When we install p2pmem-pci.ko into a kernel there is a chance it will load before the device driver(s) for the PCIe devices that are publishing p2pdma memory (nvme for example). Therefore we want this module to load as late as possible via a late_initcall().

Do we still support EP with BAR exposed to user space as bounce buffer?

Hi,
I have no NVMe with CMB, but I have an FPGA that can be configured with a BAR mapped to its internal LPDDR. I tried this repo and exposed the BAR to user space as /dev/p2pmem0. But when I ran the p2pmem-test application, like "./p2pmem-test /dev/nvme0n1 /dev/nvme1n1 /dev/p2pmem0 -c 1 -s 4k --check" .
It ends up with a pwrite I/O error.
From the dmesg I can see the "blk_update_request: I/O error, dev nvme0n1, sector 0 op 0x1:(WRITE) flags 0x8800 phys_seg 1 prio class 0" error message.
So I am curious if we still have the bounce buffer support in p2pmem. Thanks in advance!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.