public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Vlad Yasevich <vladislav.yasevich@hp.com>
To: Dave Johnson <djohnson+linux-kernel@sw.starentnetworks.com>
Cc: lksctp-developers@lists.sourceforge.net,
	linux-kernel@vger.kernel.org,
	Srinivas Akkipeddi <sakkiped@starentnetworks.com>
Subject: Re: [PATCH] SCTP: IPv4 mapped addr not returned in SCTPv6 accept()
Date: Thu, 26 Jul 2007 16:49:40 -0400	[thread overview]
Message-ID: <46A908E4.7080502@hp.com> (raw)
In-Reply-To: <18089.1986.267726.233112@zeus.sw.starentnetworks.com>

Dave Johnson wrote:
> Vlad Yasevich writes:
>> Ok.  First, this is a different bug, so I would prefer a separate patch.
>> Also, I see the problem and it's ugly, but this solution is not really correct,
>> both conceptually and code wise.
>>
>> Conceptually, the v4 code should never worry about V4-mapped addresses and shouldn't
>> muck with them.  They are IPv6 addresses and there should be a clean separation.
>>
>> Code wise, the code in the __sctp_connect() is terrible.
>>
>> Does the attached patch work for you in this case.
> 
> yes, with the v4mapped in ipv6.c and your patch, connect and accept
> both work with v4 mapped addresses.
> 
> Note instead of:
> 
>> +	af = sctp_get_af_specific(sa_addr->sa.sa_family);
>> +	af->to_sk_daddr(sa_addr, sk);
> 
> you should have:
> 
>> +	af = sctp_get_af_specific(sa_addr->sa_family);
>> +	af->to_sk_daddr((union sctp_addr *)sa_addr, sk);
> 
> 

Feel free to clean it up and submit both patches.

-vlad

  reply	other threads:[~2007-07-26 20:50 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-25 23:49 [PATCH] SCTP: IPv4 mapped addr not returned in SCTPv6 accept() Dave Johnson
2007-07-26 17:55 ` Vlad Yasevich
2007-07-26 19:00   ` Dave Johnson
2007-07-26 19:42     ` Vlad Yasevich
2007-07-26 20:44       ` Dave Johnson
2007-07-26 20:49         ` Vlad Yasevich [this message]
2007-07-31  0:23           ` David Miller
2007-07-31 13:53             ` Vlad Yasevich
2007-08-06 20:48               ` [PATCH] SCTP: fix IPv4 addr in SCTPv6 accept()/getpeername() Dave Johnson
2007-08-06 20:48       ` [PATCH] SCTP: IPv4 mapped addr not returned in SCTPv6 accept() Dave Johnson
2007-08-06 20:55         ` Vlad Yasevich

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=46A908E4.7080502@hp.com \
    --to=vladislav.yasevich@hp.com \
    --cc=djohnson+linux-kernel@sw.starentnetworks.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lksctp-developers@lists.sourceforge.net \
    --cc=sakkiped@starentnetworks.com \
    /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