difficult problem with function declaration

Hello,
I have a problem with the declaration of a function.
This is how I declare the function :

c:63: void foo(threadpool tp,void (*func)(void), (void*)arg);

Inside main, I call it like this:

      main\(\)\{
              ..........
       threadpool y;

c:104: foo(y,foo2,(void*)x);

}

and here is the foo2,and foo:
c:109:void foo(threadpool tp,void (*func)(void), (void*)arg){.........}
c:110: void * foo2(void *arg) {......}

gcc gives me those things:

c:63: error: expected declaration specifiers or �...� before �(� token
c:104: warning: passing argument 2 of �foo� from incompatible pointer type
c:63: note: expected �void (*)(void )� but argument is of type �void * ()(void *)�
c:104: error: too many arguments to function �foo�
c:110: error: expected declaration specifiers or �...� before �(� token
c:110: error: expected identifier or �(� before �{� token

I dont know what the problem is,even if I tried a lot of things.Please help!
thanks in advance

What is the declaration and/or definition of foo2?

I declare foo2 before main as this: void * foo2(void *arg);
foo2 is a function which a thread from thread pool will execute.
I correct some things and the new errors are:

c:63: error: expected declaration specifiers or �...' before �(' token
c:104: warning: passing argument 2 of �foo' from incompatible pointer type
c:63: note: expected �void (*)(void )' but argument is of type �void * ()(void *)'
c:104: error: too many arguments to function �foo'
c: At top level:
c:110: error: expected declaration specifiers or �...' before �(' token

what is threadpool here? A struct?
function foo is expecting an address as it's 1st argument.
but in line 104, you are passing a value.

yes, threadpool is a struct.Ok this is right,the first value should be an adress,so I changed it.But this is not the problem I have.
Now, try to declare a function prototype:
typedef void (*TypeOfFunc)(void *);
and to use this prototype when it is to declare a function like this.
But still,the problems remain..:frowning: