New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
librbd: support eventfd for AIO completion notifications #5465
Conversation
51335be
to
a19a61e
Compare
67cd704
to
5415f2e
Compare
5415f2e
to
8c24267
Compare
8c24267
to
d2a97de
Compare
a23b84b
to
1912157
Compare
#define CEPH_COMMON_EVENT_TYPE_H | ||
|
||
#define EVENT_SOCKET_TYPE_NONE 0 | ||
#define EVENT_SOCKET_TYPE_PIPE 1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need librbd API exposed version of _PIPE and _EVENTFD. Since this file isn't part of the API, might as well move to an enum within event_socket.h?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What if user specify notify type? like rbd_set_image_notification
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's my concern -- this header file isn't part of the API so the end-user won't have access to it. My suggestion is to create librbd specific aliases for these values in librbd.h (similar to how librados aliases own flag constants within the API).
3d83a69
to
9c884da
Compare
9c884da
to
60c06d8
Compare
updated @dillaman |
@yuyuyu101 can you rebase and repush? |
EventSocket will wrap different user event notification method like linux eventfd, solaris port. Caller can user this to replace signal Signed-off-by: Haomai Wang <haomaiwang@gmail.com>
1ed1c60
to
6f81e9e
Compare
@dillaman done |
TP_FIELDS( | ||
ctf_integer_hex(void*, imagectx, imagectx) | ||
ctf_integer(int, numcomp, numcomp) | ||
ctf_integer(int, max, max) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Parameter max
doesn't exist
Signed-off-by: Haomai Wang <haomaiwang@gmail.com>
Signed-off-by: Haomai Wang <haomaiwang@gmail.com>
Signed-off-by: Haomai Wang <haomaiwang@gmail.com>
Signed-off-by: Haomai Wang <haomaiwang@gmail.com>
Signed-off-by: Haomai Wang <haomaiwang@gmail.com>
Signed-off-by: Haomai Wang <haomaiwang@gmail.com>
Signed-off-by: Haomai Wang <haomaiwang@gmail.com>
Signed-off-by: Haomai Wang <haomaiwang@gmail.com>
Signed-off-by: Haomai Wang <haomaiwang@gmail.com>
Signed-off-by: Haomai Wang <haomai@xsky.com>
Signed-off-by: Haomai Wang <haomai@xsky.com>
Signed-off-by: Haomai Wang <haomai@xsky.com>
Signed-off-by: Haomai Wang <haomai@xsky.com>
Since xlist clear method invoked below is enough to disassociate the xlist item from the xlist, so the remove_myself() call in the destructor is safe to invoke since it's already been removed from the list. Signed-off-by: Haomai Wang <haomai@xsky.com>
Signed-off-by: Haomai Wang <haomai@xsky.com>
Signed-off-by: Haomai Wang <haomai@xsky.com>
Signed-off-by: Haomai Wang <haomai@xsky.com>
6f81e9e
to
c57ceff
Compare
librbd: support eventfd for AIO completion notifications Reviewed-by: Jason Dillaman <dillaman@redhat.com>
thanks |
Currently librbd support aio_read/write with specified
callback(AioCompletion). It would be nice for simple caller logic, but
it also has some problems:
littleweight" job, especially when "callback" need to update some status with lock hold