[PATCHv2} opensm/osm_torus.c: Fix crash in torus_update_osm_vlarb
---
Change since v1:
Fixed NULL pointer check on sw->port[port_num]
Pointed out by: Jim Schutt <[email protected]>
opensm/osm_torus.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
opensm/osm_torus.c +1 -1
@@ -8089,7 +8089,7 @@ void torus_update_osm_vlarb(void *context, osm_physp_t *osm_phys_port,* So, leave VL 0 alone, remap VL 4 to VL 1, zero out the rest, * and compress out the zero entries to the end. */ -if (!sw || !port_num || +if (!sw || !port_num || !sw->port[port_num] || sw->port[port_num]->pgrp->port_grp !=2 *TORUS_MAX_DIM )return ;
Signature · 6 lines
1.7.8.2 -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 50BD18CA.8040409-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org
Jim Schutt
Acked-byQuoted 3 lines · Hal Rosenstock
Acked-by Jim Schutt <[email protected]>
Quoted 13 lines
---
Change since v1:
Fixed NULL pointer check on sw->port[port_num]
Pointed out by: Jim Schutt<[email protected]>opensm/osm_torus.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)opensm/osm_torus.c +0
-0
opensm/osm_torus.c void torus_update_osm_vlarb(void *context, osm_physp_t *osm_phys_port, · line 8095
Quoted 8 lines
opensm/osm_torus.c +1
-1@@ -8089,7 +8089,7 @@ void torus_update_osm_vlarb(void *context, osm_physp_t *osm_phys_port,* So, leave VL 0 alone, remap VL 4 to VL 1, zero out the rest, * and compress out the zero entries to the end. */ -if (!sw || !port_num || +if (!sw || !port_num || !sw->port[port_num] || sw->port[port_num]->pgrp->port_grp !=2 *TORUS_MAX_DIM )return ;
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html