From: Ben Pfaff <blp@nicira.com>
To: Thomas Graf <tgraf@redhat.com>
Cc: jesse@nicira.com, dev@openvswitch.org, fleitner@redhat.com,
netdev@vger.kernel.org
Subject: Re: [ovs-dev] [PATCH openvswitch] netlink: Implement & enable memory mapped netlink i/o
Date: Mon, 25 Nov 2013 15:02:53 -0800 [thread overview]
Message-ID: <20131125230253.GR1435@nicira.com> (raw)
In-Reply-To: <2336aeee25d64eab89302c28c33b7cb7d1a55560.1385057738.git.tgraf@redhat.com>
On Thu, Nov 21, 2013 at 07:16:54PM +0100, Thomas Graf wrote:
> Based on the initial patch by Cong Wang posted a couple of months
> ago.
>
> This is the user space counterpart needed for the kernel patch
> '[PATCH net-next 3/8] openvswitch: Enable memory mapped Netlink i/o'
>
> Allows the kernel to construct Netlink messages on memory mapped
> buffers and thus avoids copying. The functionality is enabled on
> sockets used for unicast traffic.
>
> Further optimizations are possible by avoiding the copy into the
> ofpbuf after reading.
>
> Cc: Cong Wang <xiyou.wangcong@gmail.com>
> Signed-off-by: Thomas Graf <tgraf@redhat.com>
Does this depend on other patches or some specific Linux kernel
headers? It doesn't build here on GCC (similar results with Clang):
../lib/netlink-socket.c: In function 'nl_sock_set_ring':
../lib/netlink-socket.c:101:12: error: variable 'req' has initializer but incomplete type
../lib/netlink-socket.c:102:9: error: unknown field 'nm_block_size' specified in initializer
../lib/netlink-socket.c:102:9: error: excess elements in struct initializer [-Werror]
../lib/netlink-socket.c:102:9: error: (near initialization for 'req') [-Werror]
../lib/netlink-socket.c:103:9: error: unknown field 'nm_block_nr' specified in initializer
../lib/netlink-socket.c:103:9: error: excess elements in struct initializer [-Werror]
../lib/netlink-socket.c:103:9: error: (near initialization for 'req') [-Werror]
../lib/netlink-socket.c:104:9: error: unknown field 'nm_frame_size' specified in initializer
../lib/netlink-socket.c:104:9: error: excess elements in struct initializer [-Werror]
../lib/netlink-socket.c:104:9: error: (near initialization for 'req') [-Werror]
../lib/netlink-socket.c:101:24: error: storage size of 'req' isn't known
../lib/netlink-socket.c:109:43: error: 'NETLINK_RX_RING' undeclared (first use in this function)
../lib/netlink-socket.c:109:43: note: each undeclared identifier is reported only once for each function it appears in
../lib/netlink-socket.c:110:46: error: 'NETLINK_TX_RING' undeclared (first use in this function)
../lib/netlink-socket.c:101:24: error: unused variable 'req' [-Werror=unused-variable]
../lib/netlink-socket.c: In function 'nl_sock_send_mmap':
../lib/netlink-socket.c:369:22: error: 'NL_MMAP_HDRLEN' undeclared (first use in this function)
../lib/netlink-socket.c:374:12: error: dereferencing pointer to incomplete type
../lib/netlink-socket.c:374:27: error: 'NL_MMAP_STATUS_UNUSED' undeclared (first use in this function)
../lib/netlink-socket.c:385:8: error: dereferencing pointer to incomplete type
../lib/netlink-socket.c:386:8: error: dereferencing pointer to incomplete type
../lib/netlink-socket.c:386:23: error: 'NL_MMAP_STATUS_VALID' undeclared (first use in this function)
../lib/netlink-socket.c: In function 'nl_sock_recv_mmap':
../lib/netlink-socket.c:514:16: error: dereferencing pointer to incomplete type
../lib/netlink-socket.c:515:10: error: 'NL_MMAP_STATUS_VALID' undeclared (first use in this function)
../lib/netlink-socket.c:516:16: error: dereferencing pointer to incomplete type
../lib/netlink-socket.c:518:16: error: dereferencing pointer to incomplete type
../lib/netlink-socket.c:518:30: error: 'NL_MMAP_STATUS_UNUSED' undeclared (first use in this function)
../lib/netlink-socket.c:523:40: error: 'NL_MMAP_HDRLEN' undeclared (first use in this function)
../lib/netlink-socket.c:523:59: error: dereferencing pointer to incomplete type
../lib/netlink-socket.c:527:10: error: 'NL_MMAP_STATUS_COPY' undeclared (first use in this function)
../lib/netlink-socket.c:535:10: error: 'NL_MMAP_STATUS_RESERVED' undeclared (first use in this function)
../lib/netlink-socket.c:546:8: error: dereferencing pointer to incomplete type
cc1: all warnings being treated as errors
next prev parent reply other threads:[~2013-11-25 23:03 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-21 18:16 [PATCH openvswitch] netlink: Implement & enable memory mapped netlink i/o Thomas Graf
2013-11-25 23:02 ` Ben Pfaff [this message]
[not found] ` <20131125230253.GR1435-l0M0P4e3n4LQT0dZR+AlfA@public.gmane.org>
2013-11-27 22:51 ` Thomas Graf
2013-11-28 19:24 ` [ovs-dev] " Ben Pfaff
[not found] ` <20131128192449.GA28279-l0M0P4e3n4LQT0dZR+AlfA@public.gmane.org>
2013-11-28 22:31 ` Thomas Graf
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20131125230253.GR1435@nicira.com \
--to=blp@nicira.com \
--cc=dev@openvswitch.org \
--cc=fleitner@redhat.com \
--cc=jesse@nicira.com \
--cc=netdev@vger.kernel.org \
--cc=tgraf@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.