Fix ATS usage to be compliant with DAPL ATS.
authorftillier <ftillier@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Mon, 11 Jul 2005 23:03:30 +0000 (23:03 +0000)
committerftillier <ftillier@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Mon, 11 Jul 2005 23:03:30 +0000 (23:03 +0000)
git-svn-id: svn://openib.tc.cornell.edu/gen1/trunk@35 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86

inc/iba/ib_al.h
ulp/ipoib/kernel/ipoib_driver.c

index 0aa34fb..69ae4a8 100644 (file)
@@ -96,14 +96,21 @@ typedef uint8_t             ib_shmid_t[64];
 * SEE ALSO\r
 *      ib_reg_shmid\r
 *********/\r
-/****\r
-*\r
-* ICS ATS definitions\r
+\r
+\r
+/****d* Access Layer/ATS\r
+* NAME\r
+*      DAPL Address Translation Service\r
 *\r
+* DESCRIPTION\r
+*      ATS service ID, service name, and IPv4 offset for DAPL-compliant\r
+*      ATS service records.\r
 */\r
-#define ATS_SERVICE_ID      CL_NTOH64( 0x1000066A00040000 )\r
-#define ATS_NAME            "Address Translation Service"\r
-#define ATS_IPV4_OFFSET     12\r
+#define ATS_SERVICE_ID         CL_NTOH64( 0x10000CE100415453 )\r
+#define ATS_NAME                       "DAPL Address Translation Service"\r
+#define ATS_IPV4_OFFSET                12\r
+/**********/\r
+\r
 \r
 /****s* Access Layer/ib_mad_element_t\r
 * NAME\r
index bedeaf8..5ad31b2 100644 (file)
@@ -2065,8 +2065,10 @@ ipoib_reg_addrs(
                if( p_addr_item->h_reg_svc )\r
                        continue;\r
 \r
-               ib_service.svc_rec.service_id = ATS_SERVICE_ID;\r
-               ib_service.svc_rec.service_id |= ((uint64_t)idx) << 56;\r
+               ib_service.svc_rec.service_id =\r
+                       ATS_SERVICE_ID & CL_HTON64(0xFFFFFFFFFFFFFF00);\r
+               /* ATS service IDs start at 0x10000CE100415453 */\r
+               ib_service.svc_rec.service_id |= ((uint64_t)(idx + 0x53)) << 56;\r
 \r
                cl_memcpy( &ib_service.svc_rec.service_data8[ATS_IPV4_OFFSET],\r
                        p_addr_item->address.as_bytes, IPV4_ADDR_SIZE );\r