[openib-general] [PATCH] ib_addr: local/loopback address handling
Michael S. Tsirkin
mst at mellanox.co.il
Wed Mar 29 00:11:15 PST 2006
Quoting r. Sean Hefty <mshefty at ichips.intel.com>:
> Subject: Re: [openib-general] [PATCH] ib_addr: local/loopback address handling
>
> Michael S. Tsirkin wrote:
> >>I'm not as sure about this change; specifically the use of LOOPBACK().
> >>If the user specifies 127.0.0.1 for their source address, this will end
> >>up changing that address to whatever the destination address is. Is this
> >>really what we want?
> >
> >My testing shows that in sockets 127.0.0.1 is same as 0.
>
> Maybe I wasn't being clear. If the user tries to connect from 127.0.0.1 to
> 192.168.0.101, this patch will change their source address from 127.0.0.1
> to be 192.168.0.101. The current code leaves the source address as
> 127.0.0.1.
And then the connection will fail since 127.0.0.1 is not an IB device.
So why is this behaviour useful?
> What ib_addr is trying to allow is connecting to a remote IP address.
> If a source address is not specified, then one is assigned.
Right, so it has to have some routing logic. If this code is not in ib_addr then
the same logic will have to be placed in all ULPs. That's not too bad, but it
just seems a waste.
--
Michael S. Tsirkin
Staff Engineer, Mellanox Technologies
More information about the general
mailing list