[openib-general] [PATCH} OpenSM vendor layer: Use MAX macro in umad_receiver
Hal Rosenstock
halr at voltaire.com
Mon Aug 29 08:08:02 PDT 2005
OpenSM vendor layer: Use MAX macro in umad_receiver rather than open
coding it. Pointed out by Grant Grundler <iod00d at hp.com>
Signed-off-by: Hal Rosenstock <halr at voltaire.com>
Index: osm_vendor_ibumad.c
===================================================================
--- osm_vendor_ibumad.c (revision 3200)
+++ osm_vendor_ibumad.c (working copy)
@@ -271,8 +271,7 @@ umad_receiver(void *p_ptr)
if (!(madw_p = osm_mad_pool_get(p_bind->p_mad_pool,
(osm_bind_handle_t)p_bind,
- length > MAD_BLOCK_SIZE ?
- length : MAD_BLOCK_SIZE,
+ MAX(length, MAD_BLOCK_SIZE),
&osm_addr))) {
osm_log( p_vend->p_log, OSM_LOG_ERROR, "umad_receiver: "
"request for a new madw failed -- dropping packet\n" );
More information about the general
mailing list