Mike Christie wrote: > I was working on this patch. It seems to work for iser and cxgbi in the > normal case. iscsi_tcp is broken with it (there is debugging stuff in > iscsi_tcp.c so do not look at it for review purposes).
Thanks for doing that, I tested it with 2.6.37 -- works just fine, e.g with redirect the current portal shows me where this iser session landed, etc. > There is one problem with in the error path. If we are disconnecting the > interconnect (running ep_disconnect in iser's case), while the address > sysfs file is being read, the ep_disconnect function could free, and the > kernel could realloc to something else, the low level struct's memory > that the ib_conn is accessing at the same time and we could end up with > memory access issues. I was thinking we could just add a lock around the > ep_connect/ep_disconnect and iscsi_iser_conn_get_param code and add some > state bits and do something similar for other drivers. I noted that in the patch I posted earlier the session lock was taken when serving _CONN_PORT/ADDRESS get param, it was actually copy/pasted from the iscsi_tcp code... but I wasn't looking on if/how this protects against ep_disconnect destroying the underlying ib connection, etc. If we want to go simple, maybe we can use the approach of the (iser, cxgbi, etc) transport binding code to make a copy of the remote address in the form of the portal_port/address fields of struct iscsi_conn, e.g not remove these fields as done by your patch Or. -- You received this message because you are subscribed to the Google Groups "open-iscsi" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/open-iscsi?hl=en.
