public inbox for llvm@lists.linux.dev
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Joel Fernandes <joelagnelf@nvidia.com>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev
Subject: [jfern:sched/scx-dlserver-boost 16/16] kernel/sched/deadline.c:1765:5: warning: no previous prototype for function 'dl_server_remove_params'
Date: Fri, 28 Mar 2025 14:15:28 +0800	[thread overview]
Message-ID: <202503281421.a2nhfsTA-lkp@intel.com> (raw)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/jfern/linux.git sched/scx-dlserver-boost
head:   153b74fef19625181700e52ed4017330372a961e
commit: 153b74fef19625181700e52ed4017330372a961e [16/16] Add a function to remove the dl_server's bw reservation
config: riscv-randconfig-002-20250328 (https://download.01.org/0day-ci/archive/20250328/202503281421.a2nhfsTA-lkp@intel.com/config)
compiler: clang version 21.0.0git (https://github.com/llvm/llvm-project c2692afc0a92cd5da140dfcdfff7818a5b8ce997)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250328/202503281421.a2nhfsTA-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202503281421.a2nhfsTA-lkp@intel.com/

All warnings (new ones prefixed by >>):

   In file included from kernel/sched/build_policy.c:60:
>> kernel/sched/deadline.c:1765:5: warning: no previous prototype for function 'dl_server_remove_params' [-Wmissing-prototypes]
    1765 | int dl_server_remove_params(struct sched_dl_entity *dl_se)
         |     ^
   kernel/sched/deadline.c:1765:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
    1765 | int dl_server_remove_params(struct sched_dl_entity *dl_se)
         | ^
         | static 
   1 warning generated.


vim +/dl_server_remove_params +1765 kernel/sched/deadline.c

  1755	
  1756	/**
  1757	 * dl_server_remove_params - Remove bandwidth reservation for a DL server
  1758	 * @dl_se: The DL server entity to remove bandwidth for
  1759	 *
  1760	 * This function removes the bandwidth reservation for a DL server entity,
  1761	 * cleaning up all bandwidth accounting and server state.
  1762	 *
  1763	 * Returns: 0 on success, negative error code on failure
  1764	 */
> 1765	int dl_server_remove_params(struct sched_dl_entity *dl_se)
  1766	{
  1767	    struct rq *rq = dl_se->rq;
  1768	    int cpu = cpu_of(rq);
  1769	    struct dl_bw *dl_b;
  1770	    int cpus;
  1771	
  1772	    if (!dl_se->dl_runtime)
  1773	        return 0;  /* Already disabled */
  1774	
  1775	    /*
  1776		 * First dequeue if still queued. It should not be queued since
  1777		 * we call this only after the last dl_server_stop().
  1778		 */
  1779	    if (WARN_ON_ONCE(on_dl_rq(dl_se)))
  1780	        dequeue_dl_entity(dl_se, DEQUEUE_SLEEP);
  1781	
  1782	    /* Cancel any pending timers */
  1783	    hrtimer_try_to_cancel(&dl_se->dl_timer);
  1784	    hrtimer_try_to_cancel(&dl_se->inactive_timer);
  1785	
  1786	    
  1787		/* Remove bandwidth from both runqueue and root domain accounting */
  1788	    dl_b = dl_bw_of(cpu);
  1789	    guard(raw_spinlock)(&dl_b->lock);
  1790	    cpus = dl_bw_cpus(cpu);
  1791	
  1792	    sub_rq_bw(dl_se, &rq->dl);
  1793	    __dl_sub(dl_b, dl_se->dl_bw, cpus);
  1794	
  1795	    /*
  1796	     * If server was active and consuming bandwidth, remove it from
  1797	     * running bandwidth accounting. This should not happen because
  1798	     * we call this only after the last dl_server_stop().
  1799	     */
  1800	    if (WARN_ON_ONCE(!dl_se->dl_non_contending))
  1801	        sub_running_bw(dl_se, &rq->dl);
  1802	
  1803	    /*
  1804		 * Clear all server parameters. This will also clear ->dl_server so
  1805		 * the next dl_server_apply_params() will reconfigure the server.
  1806		 */
  1807	    __dl_clear_params(dl_se);
  1808	
  1809	    return 0;
  1810	}
  1811	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

                 reply	other threads:[~2025-03-28  6:15 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202503281421.a2nhfsTA-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=joelagnelf@nvidia.com \
    --cc=llvm@lists.linux.dev \
    --cc=oe-kbuild-all@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox