Mike Christie wrote:
> ccing Or.
>
> Or, I am ccing you because some time ago Erez was working on support for
> older RHEL and SLES kernels for OFED. It looks like the patch below
> would not be useful to you because iser is supported in those kernels,
> but did you guys all need RHEL 4 and maybe SLES 9 support too?
>
>
>
> On 08/31/2009 08:15 AM, Rakesh Ranjan wrote:
>> Hi Mike,
>>
>> Attached is patch for libiscsi/libiscsi_tcp to support cxgb3i on
>> RHEL-5.{,0,1,3} and SLES 10 and it applied on top of
>> 2.6.14-23_compat.patch. Its based on your work for RHEL-5.4. I have run
>> the regression test on mentioned platform and it worked without any
>> problem. If you find it okay, then I will send the final patch with
>> little bit more cleanup and needed Makefile changes.
>>
>> Regards
>> Rakesh Ranjan
>
>
> I think you reverted some fixes/changes from upstream. For example the
> code below is a change I did upstream, but it did not make it into RHEL
> 5.4. You also reverted Erez's debugging stuff from upstream. You can
> check kernel.git/git to see the commits that have been done upstream
> then check if the are not present in RHEL 5.4 (I think the code in
> open-iscsi.org/kernel should be in sync with what I just send to James
> for scsi-misc/2.6.32).
Okay I will re spin the patch against scsi-misc/2.6.32.
> How do you plan on distributing the patch? Are you doing to intergate it
> into the 2.6.14-23_compat.patch patch with maybe some ifdef RHEL/SLESs,
> or are you going to add a new patch for RHEL/SLES then in the Makefile
> figure out if we are using a RHEL/SLES kernel, or are you just going to
> carry it yourself?
>
Right now in my local tree I am using it as separate patch with Makefile
changes to pick it up depending upon platform used. Unless you have some
other plans, I think this approach would be good for upstream inclusion.
Regards
Rakesh Ranjan
>
>
> diff -Nuarp a/iscsi_tcp.c b/iscsi_tcp.c
> --- a/iscsi_tcp.c 2009-08-31 18:32:05.000000000 +0530
> +++ b/iscsi_tcp.c 2009-08-31 18:33:16.000000000 +0530
> @@ -254,6 +254,8 @@ static int iscsi_sw_tcp_xmit_segment(str
>
> if (r < 0) {
> iscsi_tcp_segment_unmap(segment);
> + if (copied || r == -EAGAIN)
> + break;
> return r;
> }
> copied += r;
> @@ -274,17 +276,11 @@ static int iscsi_sw_tcp_xmit(struct iscs
>
> while (1) {
> rc = iscsi_sw_tcp_xmit_segment(tcp_conn, segment);
> - /*
> - * We may not have been able to send data because the conn
> - * is getting stopped. libiscsi will know so propogate err
> - * for it to do the right thing.
> - */
> - if (rc == -EAGAIN)
> - return rc;
> - else if (rc < 0) {
> + if (rc < 0) {
> rc = ISCSI_ERR_XMIT_FAILED;
> goto error;
> - } else if (rc == 0)
> + }
> + if (rc == 0)
> break;
>
> consumed += rc;
> @@ -465,10 +461,9 @@ static int iscsi_sw_tcp_pdu_init(struct
> offset, count);
> }
>
> - if (err) {
> + if (err)
> /* got invalid offset/len */
> - return -EIO;
> - }
> + return -EINVAL;
> return 0;
> }
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---