[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <a08e9235-7452-417c-a308-b062c4ce510d@redhat.com>
Date: Mon, 27 Jan 2025 10:05:54 +0100
From: Paolo Abeni <pabeni@...hat.com>
To: John Ousterhout <ouster@...stanford.edu>
Cc: netdev@...r.kernel.org, edumazet@...gle.com, horms@...nel.org,
kuba@...nel.org
Subject: Re: [PATCH net-next v6 03/12] net: homa: create shared Homa header
files
On 1/24/25 10:21 PM, John Ousterhout wrote:
> On Thu, Jan 23, 2025 at 3:01 AM Paolo Abeni <pabeni@...hat.com> wrote:
>>
>> On 1/15/25 7:59 PM, John Ousterhout wrote:
>> [...]
>>> +/**
>>> + * union sockaddr_in_union - Holds either an IPv4 or IPv6 address (smaller
>>> + * and easier to use than sockaddr_storage).
>>> + */
>>> +union sockaddr_in_union {
>>> + /** @sa: Used to access as a generic sockaddr. */
>>> + struct sockaddr sa;
>>> +
>>> + /** @in4: Used to access as IPv4 socket. */
>>> + struct sockaddr_in in4;
>>> +
>>> + /** @in6: Used to access as IPv6 socket. */
>>> + struct sockaddr_in6 in6;
>>> +};
>>
>> There are other protocol using the same struct with a different name
>> (sctp) or a very similar struct (mptcp). It would be nice to move this
>> in a shared header and allow re-use.
>
> I would be happy to do this, but I suspect it should be done
> separately from this patch series. It's not obvious to me where such a
> definition should go; can you suggest an appropriate place for it?
Probably a new header file under include/net/. My choice for files name
are usually not quite good, but I would go for 'sockaddr_generic.h' or
'sockaddr_common.h'
/P
Powered by blists - more mailing lists