Skip to content
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

Enable vhosts hotplugs. #537

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

outscale-fne
Copy link
Contributor

@outscale-fne outscale-fne commented Aug 6, 2020

The idea is to make QEMU act as a server and PACKETGRAPH as a client so they can handle both hotplugs.
This is using the virtio vhost protocol.

tests/vhost/test-vhost.c Outdated Show resolved Hide resolved
src/utils/qemu.c Show resolved Hide resolved
src/utils/qemu.h Show resolved Hide resolved
src/vhost.c Outdated Show resolved Hide resolved
src/vhost.c Show resolved Hide resolved
src/vhost.c Show resolved Hide resolved
src/vhost.c Outdated Show resolved Hide resolved
src/vhost.c Outdated Show resolved Hide resolved
tests/integration/tests.c Outdated Show resolved Hide resolved
tests/vhost/test-vhost.c Outdated Show resolved Hide resolved
@outscale-fne
Copy link
Contributor Author

@outscale-mgo your review has been checked and changes have been applied :)

@outscale-fne outscale-fne force-pushed the fne-vhosts branch 3 times, most recently from e62d406 to fce41b9 Compare November 2, 2020 16:32
src/utils/qemu.c Outdated Show resolved Hide resolved
src/vhost.c Show resolved Hide resolved
src/vhost.c Outdated Show resolved Hide resolved
src/vhost.c Outdated Show resolved Hide resolved
src/vhost.c Show resolved Hide resolved
@@ -278,7 +293,9 @@ static void vhost_create_socket(struct pg_vhost_state *state, uint64_t flags,
int ret;

path = g_strdup_printf("%s/qemu-%s", sockets_path, state->brick.name);
g_remove(path);
/* If the socket is CLIENT do NOT destroy the socket. */
if ((flags & 1) == 0)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Must set parenthesis @outscale-toa : Else I get this:

src/vhost.c: In function ‘vhost_create_socket’:
src/vhost.c:297:12: error: suggest parentheses around comparison in operand of ‘&’ [-Werror=parentheses]
  if (flags & 1 == 0)
            ^
src/vhost.c: At top level:
cc1: error: unrecognized command line option ‘-Wno-address-of-packed-member’ [-Werror]
cc1: error: unrecognized command line option ‘-Wno-unknown-warning-option’ [-Werror]
cc1: error: unrecognized command line option ‘-Wno-implicite-fallthrough’ [-Werror]
cc1: all warnings being treated as errors
Makefile:93: recipe for target 'src/vhost-dev.o' failed
make: *** [src/vhost-dev.o] Error 1

@outscale-fne outscale-fne force-pushed the fne-vhosts branch 2 times, most recently from c047916 to f0ff06d Compare November 12, 2020 13:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants