All of lore.kernel.org
 help / color / mirror / Atom feed
* [zen:5.14/prjc 93/221] kernel/sched/alt_core.c:5867:5: warning: no previous prototype for 'sched_cpu_wait_empty'
@ 2021-09-27 18:31 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-09-27 18:31 UTC (permalink / raw)
  To: kbuild-all

[-- Attachment #1: Type: text/plain, Size: 11499 bytes --]

tree:   https://github.com/zen-kernel/zen-kernel 5.14/prjc
head:   a74cb46b3e41b71e5eb452467ef2000188afe8d7
commit: 0ffe7639e645a6c63351dadeaaf22fef46cbbb40 [93/221] sched/alt: Sync up missing new interfaces.
config: parisc-randconfig-r013-20210927 (attached as .config)
compiler: hppa-linux-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://github.com/zen-kernel/zen-kernel/commit/0ffe7639e645a6c63351dadeaaf22fef46cbbb40
        git remote add zen https://github.com/zen-kernel/zen-kernel
        git fetch --no-tags zen 5.14/prjc
        git checkout 0ffe7639e645a6c63351dadeaaf22fef46cbbb40
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross ARCH=parisc 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All warnings (new ones prefixed by >>):

    3090 |         psi_task_tick(rq);
         |         ^~~~~~~~~~~~~
         |         psi_task_switch
   kernel/sched/alt_core.c: In function '__schedule':
   kernel/sched/alt_core.c:3726:28: error: 'struct task_struct' has no member named 'state'; did you mean '__state'?
    3726 |         prev_state = prev->state;
         |                            ^~~~~
         |                            __state
   kernel/sched/alt_core.c:3727:59: error: 'struct task_struct' has no member named 'state'; did you mean '__state'?
    3727 |         if (!preempt && prev_state && prev_state == prev->state) {
         |                                                           ^~~~~
         |                                                           __state
   kernel/sched/alt_core.c:3729:31: error: 'struct task_struct' has no member named 'state'; did you mean '__state'?
    3729 |                         prev->state = TASK_RUNNING;
         |                               ^~~~~
         |                               __state
   kernel/sched/alt_core.c: In function 'sched_submit_work':
   kernel/sched/alt_core.c:3828:19: error: 'struct task_struct' has no member named 'state'; did you mean '__state'?
    3828 |         if (!tsk->state)
         |                   ^~~~~
         |                   __state
   In file included from arch/parisc/include/asm/bug.h:93,
                    from include/linux/bug.h:5,
                    from include/linux/thread_info.h:13,
                    from include/asm-generic/current.h:5,
                    from ./arch/parisc/include/generated/asm/current.h:1,
                    from include/linux/sched.h:12,
                    from include/linux/kthread.h:6,
                    from include/trace/events/sched.h:8,
                    from kernel/sched/alt_core.c:15:
   kernel/sched/alt_core.c: In function 'schedule_idle':
   kernel/sched/alt_core.c:3903:31: error: 'struct task_struct' has no member named 'state'; did you mean '__state'?
    3903 |         WARN_ON_ONCE(current->state);
         |                               ^~~~~
   include/asm-generic/bug.h:104:32: note: in definition of macro 'WARN_ON_ONCE'
     104 |         int __ret_warn_on = !!(condition);                      \
         |                                ^~~~~~~~~
   kernel/sched/alt_core.c: In function '__sched_setscheduler':
   kernel/sched/alt_core.c:4425:46: error: 'MAX_USER_RT_PRIO' undeclared (first use in this function); did you mean 'MAX_RT_PRIO'?
    4425 |             (p->mm && attr->sched_priority > MAX_USER_RT_PRIO - 1) ||
         |                                              ^~~~~~~~~~~~~~~~
         |                                              MAX_RT_PRIO
   kernel/sched/alt_core.c:4425:46: note: each undeclared identifier is reported only once for each function it appears in
   kernel/sched/alt_core.c: At top level:
   kernel/sched/alt_core.c:5183:13: error: redefinition of '_cond_resched'
    5183 | int __sched _cond_resched(void)
         |             ^~~~~~~~~~~~~
   In file included from include/linux/kthread.h:6,
                    from include/trace/events/sched.h:8,
                    from kernel/sched/alt_core.c:15:
   include/linux/sched.h:1957:19: note: previous definition of '_cond_resched' with type 'int(void)'
    1957 | static inline int _cond_resched(void)
         |                   ^~~~~~~~~~~~~
   kernel/sched/alt_core.c: In function '__do_sys_sched_get_priority_max':
   kernel/sched/alt_core.c:5336:23: error: 'MAX_USER_RT_PRIO' undeclared (first use in this function); did you mean 'MAX_RT_PRIO'?
    5336 |                 ret = MAX_USER_RT_PRIO-1;
         |                       ^~~~~~~~~~~~~~~~
         |                       MAX_RT_PRIO
   kernel/sched/alt_core.c: In function 'sched_show_task':
   kernel/sched/alt_core.c:5446:16: error: 'struct task_struct' has no member named 'state'; did you mean '__state'?
    5446 |         if (p->state == TASK_RUNNING)
         |                ^~~~~
         |                __state
   kernel/sched/alt_core.c: In function 'state_filter_match':
   kernel/sched/alt_core.c:5475:18: error: 'struct task_struct' has no member named 'state'; did you mean '__state'?
    5475 |         if (!(p->state & state_filter))
         |                  ^~~~~
         |                  __state
   kernel/sched/alt_core.c:5482:56: error: 'struct task_struct' has no member named 'state'; did you mean '__state'?
    5482 |         if (state_filter == TASK_UNINTERRUPTIBLE && p->state == TASK_IDLE)
         |                                                        ^~~~~
         |                                                        __state
   kernel/sched/alt_core.c: At top level:
   kernel/sched/alt_core.c:5489:6: error: conflicting types for 'show_state_filter'; have 'void(long unsigned int)'
    5489 | void show_state_filter(unsigned long state_filter)
         |      ^~~~~~~~~~~~~~~~~
   In file included from kernel/sched/alt_sched.h:9,
                    from kernel/sched/sched.h:6,
                    from kernel/sched/alt_core.c:18:
   include/linux/sched/debug.h:17:13: note: previous declaration of 'show_state_filter' with type 'void(unsigned int)'
      17 | extern void show_state_filter(unsigned int state_filter);
         |             ^~~~~~~~~~~~~~~~~
   kernel/sched/alt_core.c: In function 'init_idle':
   kernel/sched/alt_core.c:5548:15: error: 'struct task_struct' has no member named 'state'; did you mean '__state'?
    5548 |         idle->state = TASK_RUNNING;
         |               ^~~~~
         |               __state
   kernel/sched/alt_core.c: At top level:
   kernel/sched/alt_core.c:5622:6: warning: no previous prototype for 'idle_task_exit' [-Wmissing-prototypes]
    5622 | void idle_task_exit(void)
         |      ^~~~~~~~~~~~~~
   kernel/sched/alt_core.c:5771:5: warning: no previous prototype for 'sched_cpu_activate' [-Wmissing-prototypes]
    5771 | int sched_cpu_activate(unsigned int cpu)
         |     ^~~~~~~~~~~~~~~~~~
   kernel/sched/alt_core.c:5804:5: warning: no previous prototype for 'sched_cpu_deactivate' [-Wmissing-prototypes]
    5804 | int sched_cpu_deactivate(unsigned int cpu)
         |     ^~~~~~~~~~~~~~~~~~~~
   kernel/sched/alt_core.c:5847:5: warning: no previous prototype for 'sched_cpu_starting' [-Wmissing-prototypes]
    5847 | int sched_cpu_starting(unsigned int cpu)
         |     ^~~~~~~~~~~~~~~~~~
>> kernel/sched/alt_core.c:5867:5: warning: no previous prototype for 'sched_cpu_wait_empty' [-Wmissing-prototypes]
    5867 | int sched_cpu_wait_empty(unsigned int cpu)
         |     ^~~~~~~~~~~~~~~~~~~~
   kernel/sched/alt_core.c:5872:5: warning: no previous prototype for 'sched_cpu_dying' [-Wmissing-prototypes]
    5872 | int sched_cpu_dying(unsigned int cpu)
         |     ^~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors


vim +/sched_cpu_wait_empty +5867 kernel/sched/alt_core.c

  5770	
> 5771	int sched_cpu_activate(unsigned int cpu)
  5772	{
  5773		struct rq *rq = cpu_rq(cpu);
  5774		unsigned long flags;
  5775	
  5776	#ifdef CONFIG_SCHED_SMT
  5777		/*
  5778		 * When going up, increment the number of cores with SMT present.
  5779		 */
  5780		if (cpumask_weight(cpu_smt_mask(cpu)) == 2)
  5781			static_branch_inc_cpuslocked(&sched_smt_present);
  5782	#endif
  5783		set_cpu_active(cpu, true);
  5784	
  5785		if (sched_smp_initialized)
  5786			cpuset_cpu_active();
  5787	
  5788		/*
  5789		 * Put the rq online, if not already. This happens:
  5790		 *
  5791		 * 1) In the early boot process, because we build the real domains
  5792		 *    after all cpus have been brought up.
  5793		 *
  5794		 * 2) At runtime, if cpuset_cpu_active() fails to rebuild the
  5795		 *    domains.
  5796		 */
  5797		raw_spin_lock_irqsave(&rq->lock, flags);
  5798		set_rq_online(rq);
  5799		raw_spin_unlock_irqrestore(&rq->lock, flags);
  5800	
  5801		return 0;
  5802	}
  5803	
  5804	int sched_cpu_deactivate(unsigned int cpu)
  5805	{
  5806		int ret;
  5807	
  5808		set_cpu_active(cpu, false);
  5809		/*
  5810		 * We've cleared cpu_active_mask, wait for all preempt-disabled and RCU
  5811		 * users of this state to go away such that all new such users will
  5812		 * observe it.
  5813		 *
  5814		 * Do sync before park smpboot threads to take care the rcu boost case.
  5815		 */
  5816		synchronize_rcu();
  5817	
  5818	#ifdef CONFIG_SCHED_SMT
  5819		/*
  5820		 * When going down, decrement the number of cores with SMT present.
  5821		 */
  5822		if (cpumask_weight(cpu_smt_mask(cpu)) == 2) {
  5823			static_branch_dec_cpuslocked(&sched_smt_present);
  5824			if (!static_branch_likely(&sched_smt_present))
  5825				cpumask_clear(&sched_sg_idle_mask);
  5826		}
  5827	#endif
  5828	
  5829		if (!sched_smp_initialized)
  5830			return 0;
  5831	
  5832		ret = cpuset_cpu_inactive(cpu);
  5833		if (ret) {
  5834			set_cpu_active(cpu, true);
  5835			return ret;
  5836		}
  5837		return 0;
  5838	}
  5839	
  5840	static void sched_rq_cpu_starting(unsigned int cpu)
  5841	{
  5842		struct rq *rq = cpu_rq(cpu);
  5843	
  5844		rq->calc_load_update = calc_load_update;
  5845	}
  5846	
  5847	int sched_cpu_starting(unsigned int cpu)
  5848	{
  5849		sched_rq_cpu_starting(cpu);
  5850		sched_tick_start(cpu);
  5851		return 0;
  5852	}
  5853	
  5854	#ifdef CONFIG_HOTPLUG_CPU
  5855	
  5856	/*
  5857	 * Invoked immediately before the stopper thread is invoked to bring the
  5858	 * CPU down completely. At this point all per CPU kthreads except the
  5859	 * hotplug thread (current) and the stopper thread (inactive) have been
  5860	 * either parked or have been unbound from the outgoing CPU. Ensure that
  5861	 * any of those which might be on the way out are gone.
  5862	 *
  5863	 * If after this point a bound task is being woken on this CPU then the
  5864	 * responsible hotplug callback has failed to do it's job.
  5865	 * sched_cpu_dying() will catch it with the appropriate fireworks.
  5866	 */
> 5867	int sched_cpu_wait_empty(unsigned int cpu)
  5868	{
  5869		return 0;
  5870	}
  5871	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 36951 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-09-27 18:31 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-27 18:31 [zen:5.14/prjc 93/221] kernel/sched/alt_core.c:5867:5: warning: no previous prototype for 'sched_cpu_wait_empty' kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.