}
static int
-netdev_pltap_rx_recv(struct netdev_rx *rx_, void *buffer, size_t size)
+netdev_pltap_rx_recv(struct netdev_rx *rx_, struct ofpbuf *buffer)
{
+ size_t size = ofpbuf_tailroom(buffer);
struct netdev_rx_pltap *rx = netdev_rx_pltap_cast(rx_);
struct tun_pi pi;
struct iovec iov[2] = {
{ .iov_base = &pi, .iov_len = sizeof(pi) },
- { .iov_base = buffer, .iov_len = size }
+ { .iov_base = buffer->data, .iov_len = size }
};
for (;;) {
ssize_t retval;
retval = writev(dev->fd, iov, 2);
if (retval >= 0) {
if (retval != size + 4) {
- VLOG_WARN_RL(&rl, "sent partial Ethernet packet (%zd bytes of %zu) on %s",
+ VLOG_WARN_RL(&rl, "sent partial Ethernet packet (%"PRIdSIZE" bytes of %"PRIuSIZE") on %s",
retval, size + 4, netdev_get_name(netdev_));
}
return 0;
NULL, /* set_queue */
NULL, /* delete_queue */
NULL, /* get_queue_stats */
- NULL, /* dump_queues */
+ NULL, /* queue_dump_start */
+ NULL, /* queue_dump_next */
+ NULL, /* queue_dump_done */
NULL, /* dump_queue_stats */
NULL, /* get_in4 */
netdev_pltap_update_flags,
- netdev_pltap_change_seq,
-
netdev_pltap_rx_alloc,
netdev_pltap_rx_construct,
netdev_pltap_rx_destruct,