[lkml]   [2002]   [Sep]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: __func__ in 2.5.33?
Rasmus Andersen wrote:
> Hi,
> I trying to compile the SX driver for the 2.5.33 kernel, I got a
> lot of warnings looking like (this is from a test program, not
> the driver itself)
> test.c: In function `main':
> test.c:6: called object is not a function
> test.c:6: parse error before string constant
> This seems to stem from the recent __FUNCTION__ vs. __func__
> change in kernel.h and the SX driver's use of __FUNCTION__ in the
> following construct
> #define func_enter() sx_dprintk (SX_DEBUG_FLOW, "sx: enter " __FUNCTION__ "\n")

The parenthesised (__func__) is there to force you to not try to
perform this string pasting. Support for __FUNCTION__ pasting is
being phased out of gcc.

You need:

#define func_enter() sx_dprintk (SX_DEBUG_FLOW, "sx: enter %s\n", __FUNCTION__)
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:28    [W:0.074 / U:1.144 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site