Re: [ofa-general] [PATCH v3] iw_cxgb3: Support "iwarp-only" interfaces to avoid 4-tuple conflicts.

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Sean Hefty
Date: Thursday, September 27, 2007 - 11:38 am

> The sysadmin creates "for iwarp use only" alias interfaces of the form

I'm still not sure about this, but haven't come up with anything better 
myself.  And if there's a good chance of other rnic's needing the same 
support, I'd rather see the common code separated out, even if just 
encapsulated within this module for easy re-use.

As for the code, I have a couple of questions about whether deadlock and 
a race condition are possible, plus a few minor comments.


Should this return success/failure?


If insert_ifa() fails, what will iwch_listeners_add_addr() do?  (I'm not 
easily seeing the relationship between the address list and the listen 
list at this point.)


The behavior of the listen lists is similar to what's done in the 
rdma_cm: Wildcard listens are stored in a listen_any_list.  When new 
devices are added, associated listens are added to each device.  This is 
similar, except we're dealing with devices and addresses.  I'm wondering 
if we shouldn't mimic the same behavior and track listens in 
iwch_addrlist directly.  (I don't see anything wrong with this approach 
though.)

What happens if an address changes between iwarp only and non-iwarp?

How are listens on specific addresses handled from an rdma_cm level? 
Does the rdma_cm map the address to the device, call the iw_cm to 
listen, which in turn calls the device listen function?  The device then 
checks that the address has been marked as iwarp only?  (I'm being too 
lazy to trace this through the code, but if you don't know off the top 
of your head, I will do that.)


What thread is being blocked here, and what sets the event?


nit: in place of 'h' in several places, how about 'rnicp', which is also 
used?


Adding some white space would improve readability.


This ends up blocking while holding a mutex, which looks like deadlock 
potential.


Similar to above - blocking while holding a mutex.  There are a couple 
of other places where this also occurs.


Is there a race between listen_start() being called and inserting the ep 
into the list?  Could anything try to find the ep on the list after 
listen_start returns?


I didn't notice where this was used.


or this.

-
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [ofa-general] [PATCH v3] iw_cxgb3: Support "iwarp-only ..., Sean Hefty, (Thu Sep 27, 11:38 am)