[openib-general] [Bug 327] New: want to set the scsi target id during srp login

bugzilla-daemon at lists.openfabrics.org bugzilla-daemon at lists.openfabrics.org
Fri Jan 26 13:14:52 PST 2007


https://bugs.openfabrics.org/show_bug.cgi?id=327

           Summary: want to set the scsi target id during srp login
           Product: OpenFabrics Linux
           Version: 1.1
          Platform: All
        OS/Version: Other
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: SRP
        AssignedTo: bugzilla at openib.org
        ReportedBy: chas at cmf.nrl.navy.mil


we have a need to set the scsi id for each login (in order to track it later).

diff -u drivers/infiniband/ulp/srp/ib_srp.c.orig
drivers/infiniband/ulp/srp/ib_srp.c
--- drivers/infiniband/ulp/srp/ib_srp.c.orig    2006-12-21 14:15:33.728164124
-0500
+++ drivers/infiniband/ulp/srp/ib_srp.c 2007-01-26 16:11:10.130470635 -0500
@@ -1544,6 +1544,7 @@
        SRP_OPT_MAX_SECT        = 1 << 5,
        SRP_OPT_MAX_CMD_PER_LUN = 1 << 6,
        SRP_OPT_IO_CLASS        = 1 << 7,
+       SRP_OPT_TARGET_ID       = 1 << 8,
        SRP_OPT_ALL             = (SRP_OPT_ID_EXT       |
                                   SRP_OPT_IOC_GUID     |
                                   SRP_OPT_DGID         |
@@ -1560,6 +1561,7 @@
        { SRP_OPT_MAX_SECT,             "max_sect=%d"           },
        { SRP_OPT_MAX_CMD_PER_LUN,      "max_cmd_per_lun=%d"    },
        { SRP_OPT_IO_CLASS,             "io_class=%x"           },
+       { SRP_OPT_TARGET_ID,            "target_id=%d"          },
        { SRP_OPT_ERR,                  NULL                    }
 };

@@ -1659,6 +1661,14 @@
                        target->io_class = token;
                        break;

+               case SRP_OPT_TARGET_ID:
+                       if (match_int(args, &token)) {
+                               printk(KERN_WARNING PFX "bad target_id
parameter '%s'\n", p);
+                               goto out;
+                       }
+                       target->scsi_id = token;
+                       break;
+
                default:
                        printk(KERN_WARNING PFX "unknown parameter or missing
value "
                               "'%s' in target creation request\n", p);


-- 
Configure bugmail: https://bugs.openfabrics.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.




More information about the general mailing list