From: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
To: 吉藤英明 <hideaki.yoshifuji@miraclelinux.com>
Cc: Neil Horman <nhorman@tuxdriver.com>,
David Miller <davem@davemloft.net>,
lucien.xin@gmail.com, netdev@vger.kernel.org,
linux-sctp@vger.kernel.org, yoshfuji@linux-ipv6.org
Subject: Re: [PATCH net-next 3/5] sctp: add spp_ipv6_flowlabel and spp_dscp for sctp_paddrparams
Date: Mon, 25 Jun 2018 13:31:59 -0300 [thread overview]
Message-ID: <20180625163157.GA542@localhost.localdomain> (raw)
In-Reply-To: <CAPA1RqB48gBWKOQck6Ke5yH3cm1B5QtJKh1CL4SYfqes8Tc+Nw@mail.gmail.com>
Hi,
On Tue, Jun 26, 2018 at 01:12:00AM +0900, 吉藤英明 wrote:
> Hi,
>
> 2018-06-25 22:03 GMT+09:00 Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>:
> > On Mon, Jun 25, 2018 at 07:28:47AM -0400, Neil Horman wrote:
> >> On Mon, Jun 25, 2018 at 04:31:26PM +0900, David Miller wrote:
> >> > From: Xin Long <lucien.xin@gmail.com>
> >> > Date: Mon, 25 Jun 2018 10:14:35 +0800
> >> >
> >> > > struct sctp_paddrparams {
> >> > > @@ -773,6 +775,8 @@ struct sctp_paddrparams {
> >> > > __u32 spp_pathmtu;
> >> > > __u32 spp_sackdelay;
> >> > > __u32 spp_flags;
> >> > > + __u32 spp_ipv6_flowlabel;
> >> > > + __u8 spp_dscp;
> >> > > } __attribute__((packed, aligned(4)));
> >> >
> >> > I don't think you can change the size of this structure like this.
> >> >
> >> > This check in sctp_setsockopt_peer_addr_params():
> >> >
> >> > if (optlen != sizeof(struct sctp_paddrparams))
> >> > return -EINVAL;
> >> >
> >> > is going to trigger in old kernels when executing programs
> >> > built against the new struct definition.
> >
> > That will happen, yes, but do we really care about being future-proof
> > here? I mean: if we also update such check(s) to support dealing with
> > smaller-than-supported structs, newer kernels will be able to run
> > programs built against the old struct, and the new one; while building
> > using newer headers and running on older kernel may fool the
> > application in other ways too (like enabling support for something
> > that is available on newer kernel and that is not present in the older
> > one).
>
> We should not break existing apps.
> We still accept apps of pre-2.4 era without sin6_scope_id
> (e.g., net/ipv6/af_inet6.c:inet6_bind()).
Yes. That's what I tried to say. That is supporting an old app built
with old kernel headers and running on a newer kernel, and not the
other way around (an app built with fresh headers and running on an
old kernel).
>
> >
> >> >
> >> I think thats also the reason its a packed aligned attribute, it can't be
> >> changed, or older kernels won't be able to fill it out properly.
> >> Neil
> >
> > It's more for supporting running 32-bits apps on 64-bit kernels
> > (according to 20c9c825b12fc).
> >
> > Marcelo
next prev parent reply other threads:[~2018-06-25 16:32 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-06-25 2:14 [PATCH net-next 0/5] sctp: fully support for dscp and flowlabel per transport Xin Long
2018-06-25 2:14 ` [PATCH net-next 1/5] ipv4: add __ip_queue_xmit() that supports tos param Xin Long
2018-06-25 2:14 ` [PATCH net-next 2/5] sctp: add support for dscp and flowlabel per transport Xin Long
2018-06-25 2:14 ` [PATCH net-next 3/5] sctp: add spp_ipv6_flowlabel and spp_dscp for sctp_paddrparams Xin Long
2018-06-25 2:14 ` [PATCH net-next 4/5] sctp: add support for setting flowlabel when adding a transport Xin Long
2018-06-25 2:14 ` [PATCH net-next 5/5] sctp: check for ipv6_pinfo legal sndflow with flowlabel in sctp_v6_get_dst Xin Long
2018-06-25 7:31 ` [PATCH net-next 3/5] sctp: add spp_ipv6_flowlabel and spp_dscp for sctp_paddrparams David Miller
2018-06-25 11:28 ` Neil Horman
2018-06-25 13:03 ` Marcelo Ricardo Leitner
2018-06-25 16:12 ` 吉藤英明
2018-06-25 16:31 ` Marcelo Ricardo Leitner [this message]
2018-06-26 4:33 ` Xin Long
2018-06-26 12:02 ` 吉藤英明
2018-06-28 6:40 ` Xin Long
2018-06-30 8:15 ` 吉藤英明
2018-06-25 7:26 ` [PATCH net-next 1/5] ipv4: add __ip_queue_xmit() that supports tos param David Miller
2018-06-25 11:13 ` Neil Horman
2018-06-26 4:38 ` Xin Long
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=20180625163157.GA542@localhost.localdomain \
--to=marcelo.leitner@gmail.com \
--cc=davem@davemloft.net \
--cc=hideaki.yoshifuji@miraclelinux.com \
--cc=linux-sctp@vger.kernel.org \
--cc=lucien.xin@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=nhorman@tuxdriver.com \
--cc=yoshfuji@linux-ipv6.org \
/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 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 NNTP newsgroup(s).