@@ -300,24 +300,28 @@ static void pcpu_start_fn(struct pcpu *pcpu, void (*func)(void *), void *data)
300300 pcpu_sigp_retry (pcpu , SIGP_RESTART , 0 );
301301}
302302
303+ typedef void (pcpu_delegate_fn )(void * );
304+
303305/*
304306 * Call function via PSW restart on pcpu and stop the current cpu.
305307 */
306- static void __pcpu_delegate (void ( * func )( void * ) , void * data )
308+ static void __pcpu_delegate (pcpu_delegate_fn * func , void * data )
307309{
308310 func (data ); /* should not return */
309311}
310312
311313static void __no_sanitize_address pcpu_delegate (struct pcpu * pcpu ,
312- void ( * func )( void * ) ,
314+ pcpu_delegate_fn * func ,
313315 void * data , unsigned long stack )
314316{
315317 struct lowcore * lc = lowcore_ptr [pcpu - pcpu_devices ];
316318 unsigned long source_cpu = stap ();
317319
318320 __load_psw_mask (PSW_KERNEL_BITS | PSW_MASK_DAT );
319- if (pcpu -> address == source_cpu )
320- CALL_ON_STACK (__pcpu_delegate , stack , 2 , func , data );
321+ if (pcpu -> address == source_cpu ) {
322+ call_on_stack (2 , stack , void , __pcpu_delegate ,
323+ pcpu_delegate_fn * , func , void * , data );
324+ }
321325 /* Stop target cpu (if func returns this stops the current cpu). */
322326 pcpu_sigp_retry (pcpu , SIGP_STOP , 0 );
323327 /* Restart func on the target cpu and stop the current cpu. */
0 commit comments