From: Yumei Huang <yuhuang@redhat.com>
To: Volker Diels-Grabsch <v@njh.eu>
Cc: passt-dev@passt.top, sbrivio@redhat.com, dgibson@redhat.com,
boleyn.su@gmail.com, david@gibson.dropbear.id.au,
jmaloy@redhat.com
Subject: Re: [PATCH v2] tcp: Store the owner connections for flags frames
Date: Thu, 11 Sep 2025 09:10:49 +0800 [thread overview]
Message-ID: <CANsz47mLk-PTrbCRYmvz4ELsoSRWCEKQoYOnymxUTSYt_RnDjg@mail.gmail.com> (raw)
In-Reply-To: <aMFXzY5rWd7NEVI9@6153f789-1cf1-4ca3-8cea-6fa7ae195a8b.njh.eu>
On Wed, Sep 10, 2025 at 6:50 PM Volker Diels-Grabsch <v@njh.eu> wrote:
>
> Dear Yumei,
>
> Thanks a lot for providing a proper fix for that issue. Just a minor
> nitpick from my side:
>
> Yumei Huang wrote:
> > @@ -209,13 +209,14 @@ int tcp_buf_send_flag(const struct ctx *c, struct tcp_tap_conn *conn, int flags)
> > if (ret <= 0)
> > return ret;
> >
> > - tcp_payload_used++;
> > + tcp_frame_conns[tcp_payload_used++] = conn;
> > l4len = optlen + sizeof(struct tcphdr);
> > iov[TCP_IOV_PAYLOAD].iov_len = l4len;
> > tcp_l2_buf_fill_headers(conn, iov, NULL, seq, false);
> >
> > if (flags & DUP_ACK) {
> > struct iovec *dup_iov = tcp_l2_iov[tcp_payload_used++];
> > + tcp_frame_conns[tcp_payload_used - 1] = conn;
>
> I find it a bit strange to read that way, incrementing tcp_payload_used
> just to subtract one from it in the next step. I, personally, would
> find it easier to read and to understand that way around:
>
> struct iovec *dup_iov = tcp_l2_iov[tcp_payload_used];
> tcp_frame_conns[tcp_payload_used++] = conn;
Good point. Sent v3. Thanks!
>
> But maybe it's just me.
>
>
> Best regards,
> Volker
>
> --
> .---<<<((()))>>>---.
> | [[||]] |
> '---<<<((()))>>>---'
>
--
Thanks,
Yumei Huang
prev parent reply other threads:[~2025-09-11 1:11 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-10 9:56 [PATCH v2] tcp: Store the owner connections for flags frames Yumei Huang
2025-09-10 10:49 ` Volker Diels-Grabsch
2025-09-11 1:10 ` Yumei Huang [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=CANsz47mLk-PTrbCRYmvz4ELsoSRWCEKQoYOnymxUTSYt_RnDjg@mail.gmail.com \
--to=yuhuang@redhat.com \
--cc=boleyn.su@gmail.com \
--cc=david@gibson.dropbear.id.au \
--cc=dgibson@redhat.com \
--cc=jmaloy@redhat.com \
--cc=passt-dev@passt.top \
--cc=sbrivio@redhat.com \
--cc=v@njh.eu \
/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).