public inbox for passt-dev@passt.top
 help / color / mirror / code / Atom feed
From: David Gibson <david@gibson.dropbear.id.au>
To: Laurent Vivier <lvivier@redhat.com>
Cc: passt-dev@passt.top
Subject: Re: [PATCH 5/5] vhost-user: add vhost-user
Date: Mon, 15 Jul 2024 10:37:30 +1000	[thread overview]
Message-ID: <ZpRvSiTxJCQ794u3@zatzit> (raw)
In-Reply-To: <66f54470-cf49-4a31-bb98-fa7b684100b5@redhat.com>

[-- Attachment #1: Type: text/plain, Size: 1166 bytes --]

On Fri, Jul 12, 2024 at 04:49:07PM +0200, Laurent Vivier wrote:
> On 24/06/2024 07:05, David Gibson wrote:
> > On Fri, Jun 21, 2024 at 04:56:40PM +0200, Laurent Vivier wrote:
[snip]
> > > +/**
> > > + * struct tcp_payload_t - TCP header and data to send segments with payload
> > > + * @th:		TCP header
> > > + * @data:	TCP data
> > > + */
> > > +struct tcp_payload_t {
> > > +	struct tcphdr th;
> > > +	uint8_t data[IP_MAX_MTU - sizeof(struct tcphdr)];
> > > +};
> > 
> > This could be common with tcp_buf.c, couldn't it?
> 
> In fact, no: because we cannot have the ((aligned)) attribute as the address
> is provided by the guest.

Ah, right.  It still concerns me a bit, having two structures with the
same name in different parts of the code, when the difference between
them is so subtle.

Could we use a common struct for both "buf" and vu, and put the
alignment constraint on the actual array in the buf code, rather than
on the type?

-- 
David Gibson (he or they)	| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you, not the other way
				| around.
http://www.ozlabs.org/~dgibson

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

      reply	other threads:[~2024-07-15  0:43 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-21 14:56 [PATCH 0/5] Add vhost-user support to passt. (part 3) Laurent Vivier
2024-06-21 14:56 ` [PATCH 1/5] packet: replace struct desc by struct iovec Laurent Vivier
2024-06-24  2:48   ` David Gibson
2024-07-04 15:52     ` Laurent Vivier
2024-07-05  1:28       ` David Gibson
2024-06-21 14:56 ` [PATCH 2/5] vhost-user: introduce virtio API Laurent Vivier
2024-06-24  2:56   ` David Gibson
2024-07-05 15:06     ` Laurent Vivier
2024-07-05 23:53       ` David Gibson
2024-06-21 14:56 ` [PATCH 3/5] vhost-user: introduce vhost-user API Laurent Vivier
2024-06-24  3:02   ` David Gibson
2024-07-11 12:07     ` Laurent Vivier
2024-06-21 14:56 ` [PATCH 4/5] iov: add iov_count() Laurent Vivier
2024-06-24  3:03   ` David Gibson
2024-06-24  6:59     ` Laurent Vivier
2024-06-21 14:56 ` [PATCH 5/5] vhost-user: add vhost-user Laurent Vivier
2024-06-24  5:05   ` David Gibson
2024-07-12 14:49     ` Laurent Vivier
2024-07-15  0:37       ` David Gibson [this message]

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=ZpRvSiTxJCQ794u3@zatzit \
    --to=david@gibson.dropbear.id.au \
    --cc=lvivier@redhat.com \
    --cc=passt-dev@passt.top \
    /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.
Code repositories for project(s) associated with this public inbox

	https://passt.top/passt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for IMAP folder(s).