All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Jon Hunter <jonathanh@nvidia.com>
Cc: oe-kbuild-all@lists.linux.dev
Subject: [jonhunter:tegra/next-fixes 11/11] kernel/irq/manage.c:850:33: error: implicit declaration of function 'irq_get_desc_buslock'
Date: Sat, 10 May 2025 19:11:29 +0800	[thread overview]
Message-ID: <202505101946.DNxhuust-lkp@intel.com> (raw)

tree:   https://github.com/jonhunter/linux tegra/next-fixes
head:   b6ba16943c776b1cd2b3559317337eb24b70f742
commit: b6ba16943c776b1cd2b3559317337eb24b70f742 [11/11] Revert "genirq/manage: Rework irq_set_irq_wake()"
config: i386-buildonly-randconfig-002-20250510 (https://download.01.org/0day-ci/archive/20250510/202505101946.DNxhuust-lkp@intel.com/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250510/202505101946.DNxhuust-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/202505101946.DNxhuust-lkp@intel.com/

All errors (new ones prefixed by >>):

   kernel/irq/manage.c: In function 'irq_set_irq_wake':
>> kernel/irq/manage.c:850:33: error: implicit declaration of function 'irq_get_desc_buslock' [-Werror=implicit-function-declaration]
     850 |         struct irq_desc *desc = irq_get_desc_buslock(irq, &flags, IRQ_GET_DESC_CHECK_GLOBAL);
         |                                 ^~~~~~~~~~~~~~~~~~~~
   kernel/irq/manage.c:850:33: warning: initialization of 'struct irq_desc *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
>> kernel/irq/manage.c:886:9: error: implicit declaration of function 'irq_put_desc_busunlock' [-Werror=implicit-function-declaration]
     886 |         irq_put_desc_busunlock(desc, flags);
         |         ^~~~~~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors


vim +/irq_get_desc_buslock +850 kernel/irq/manage.c

   828	
   829	/**
   830	 * irq_set_irq_wake - control irq power management wakeup
   831	 * @irq:	interrupt to control
   832	 * @on:	enable/disable power management wakeup
   833	 *
   834	 * Enable/disable power management wakeup mode, which is disabled by
   835	 * default.  Enables and disables must match, just as they match for
   836	 * non-wakeup mode support.
   837	 *
   838	 * Wakeup mode lets this IRQ wake the system from sleep states like
   839	 * "suspend to RAM".
   840	 *
   841	 * Note: irq enable/disable state is completely orthogonal to the
   842	 * enable/disable state of irq wake. An irq can be disabled with
   843	 * disable_irq() and still wake the system as long as the irq has wake
   844	 * enabled. If this does not hold, then the underlying irq chip and the
   845	 * related driver need to be investigated.
   846	 */
   847	int irq_set_irq_wake(unsigned int irq, unsigned int on)
   848	{
   849		unsigned long flags;
 > 850		struct irq_desc *desc = irq_get_desc_buslock(irq, &flags, IRQ_GET_DESC_CHECK_GLOBAL);
   851		int ret = 0;
   852	
   853		if (!desc)
   854			return -EINVAL;
   855	
   856		/* Don't use NMIs as wake up interrupts please */
   857		if (irq_is_nmi(desc)) {
   858			ret = -EINVAL;
   859			goto out_unlock;
   860		}
   861	
   862		/* wakeup-capable irqs can be shared between drivers that
   863		 * don't need to have the same sleep mode behaviors.
   864		 */
   865		if (on) {
   866			if (desc->wake_depth++ == 0) {
   867				ret = set_irq_wake_real(irq, on);
   868				if (ret)
   869					desc->wake_depth = 0;
   870				else
   871					irqd_set(&desc->irq_data, IRQD_WAKEUP_STATE);
   872			}
   873		} else {
   874			if (desc->wake_depth == 0) {
   875				WARN(1, "Unbalanced IRQ %d wake disable\n", irq);
   876			} else if (--desc->wake_depth == 0) {
   877				ret = set_irq_wake_real(irq, on);
   878				if (ret)
   879					desc->wake_depth = 1;
   880				else
   881					irqd_clear(&desc->irq_data, IRQD_WAKEUP_STATE);
   882			}
   883		}
   884	
   885	out_unlock:
 > 886		irq_put_desc_busunlock(desc, flags);
   887		return ret;
   888	}
   889	EXPORT_SYMBOL(irq_set_irq_wake);
   890	

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

                 reply	other threads:[~2025-05-10 11:12 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=202505101946.DNxhuust-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=jonathanh@nvidia.com \
    --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 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.