At 07/01/2011 04:54 AM, Eric Blake Write:
On 06/29/2011 06:13 PM, Wen Congyang wrote:
>> This sounds highly related to Matthias' issue:
>>
https://www.redhat.com/archives/libvir-list/2011-June/msg01484.html
Matthias was using 1.3...
>>
>> What version of systemtap headers and gcc are you using, that produce
>> this error?
>
> I use RHEL6RC, and the version of systemtap headers and gcc are:
>
> # rpm -qa 'systemtap*'
> systemtap-sdt-devel-1.2-9.el6.x86_64
but you are using 1.2. The older we go, the worse the systemtap headers
were, apparently. Unfortunately, I don't currently have a machine with
headers that old to debug it myself.
>>> }
>>> PROBE(CLIENT_AUTH_ALLOW, "fd=%d, auth=%d, username=%s",
>>> - virNetServerClientGetFD(client), REMOTE_AUTH_POLKIT, ident);
>>> + virNetServerClientGetFD(client), REMOTE_AUTH_POLKIT, (char
*)ident);
>>
>> If a cast really helps matters, I'd almost rather hide it within the
>> #define PROBE() than make callers have to worry about it, but I'm
>> reluctant to add a cast without knowing exactly why you are hitting
>> compilation failure.
What does STAP_PROBE3 look like in your /usr/include/sys/sdt.h?
#if ! defined EXPERIMENTAL_KPROBE_SDT
....
#define STAP_PROBE3_(probe,label,parm1,parm2,parm3) \
do STAP_SEMAPHORE(probe) { \
STAP_SDT_VOLATILE __typeof__((parm1)) arg1 = parm1; \
STAP_SDT_VOLATILE __typeof__((parm2)) arg2 = parm2; \
STAP_SDT_VOLATILE __typeof__((parm3)) arg3 = parm3; \
STAP_UNINLINE; \
STAP_PROBE_DATA(probe,STAP_UPROBE_GUARD,2f); \
__asm__ volatile ("2:\n" \
STAP_NOP "/* %0 %1 %2 */" :: "g"(arg1), "g"(arg2),
"g"(arg3)); \
} while (0)
....
#else /* ! defined EXPERIMENTAL_KPROBE_SDT */
...
#define STAP_PROBE3_(probe,label,parm1,parm2,parm3) \
do STAP_SEMAPHORE(probe) { \
__extension__ struct {size_t arg1 __attribute__((aligned(8))); \
size_t arg2 __attribute__((aligned(8))); \
size_t arg3 __attribute__((aligned(8)));} \
stap_probe3_args = {(size_t)parm1, (size_t)parm2, (size_t)parm3}; \
STAP_PROBE_DATA(probe,STAP_GUARD,3); \
syscall (STAP_SYSCALL, #probe, STAP_GUARD, &stap_probe3_args); \
} while (0)
...
#endif
...
#define STAP_PROBE3(provider,probe,parm1,parm2,parm3) \
STAP_PROBE3_(probe,STAP_LABEL(STAP_LABEL_PREFIX(probe),STAP_COUNTER),(parm1),(parm2),(parm3))