[openib-general] Re: [PATCH] Opensm - asserts before OSM_LOG_ENTER - cont.
Hal Rosenstock
halr at voltaire.com
Thu Feb 9 07:22:37 PST 2006
Hi Yael,
On Mon, 2006-02-06 at 03:41, Yael Kalka wrote:
> Hi Hal,
>
> The Patch Michael Tsirkin suggested for fixing the OSM_LOG_ENTER
> problem works fine both for windows and for linux.
> Here is the patch for this, instead of the previous one I sent.
Thanks. Applied.
-- Hal
> Thanks,
> Yael
>
> Signed-off-by: Yael Kalka <yael at mellanox.co.il>
>
> Index: include/opensm/osm_log.h
> ===================================================================
> --- include/opensm/osm_log.h (revision 5307)
> +++ include/opensm/osm_log.h (working copy)
> @@ -71,17 +71,15 @@ BEGIN_C_DECLS
> #define LOG_ENTRY_SIZE_MAX 4096
> #define BUF_SIZE LOG_ENTRY_SIZE_MAX
>
> -#define OSM_LOG_DEFINE_FUNC( NAME ) \
> - static const char osm_log_func_name[] = #NAME
> +#define __func__ __FUNCTION__
>
> #define OSM_LOG_ENTER( OSM_LOG_PTR, NAME ) \
> - OSM_LOG_DEFINE_FUNC( NAME ); \
> osm_log( OSM_LOG_PTR, OSM_LOG_FUNCS, \
> - "%s: [\n", osm_log_func_name );
> + "%s: [\n", __func__ );
>
> #define OSM_LOG_EXIT( OSM_LOG_PTR ) \
> osm_log( OSM_LOG_PTR, OSM_LOG_FUNCS, \
> - "%s: ]\n", osm_log_func_name );
> + "%s: ]\n", __func__ );
>
> /****h* OpenSM/Log
> * NAME
>
More information about the general
mailing list