All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Krzysztof Kozlowski <krzk@kernel.org>
Cc: oe-kbuild-all@lists.linux.dev, Lee Jones <lee@kernel.org>,
	Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Subject: [lee-mfd:for-mfd-next 23/25] drivers/mfd/ezx-pcap.c:412:25: error: assignment to 'struct workqueue_struct *' from 'int' makes pointer from integer without a cast
Date: Wed, 25 Mar 2026 10:37:04 +0800	[thread overview]
Message-ID: <202603251022.UUrCADAc-lkp@intel.com> (raw)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.git for-mfd-next
head:   a526075f56fb8f2fd96f791654ff1557e6680bde
commit: 356ee03f6ae7d04f90d8e2104660193c4f3a071c [23/25] mfd: ezx-pcap: Avoid rescheduling after destroying workqueue
config: x86_64-randconfig-161-20260325 (https://download.01.org/0day-ci/archive/20260325/202603251022.UUrCADAc-lkp@intel.com/config)
compiler: gcc-14 (Debian 14.2.0-19) 14.2.0
smatch: v0.5.0-9004-gb810ac53
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260325/202603251022.UUrCADAc-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/202603251022.UUrCADAc-lkp@intel.com/

All errors (new ones prefixed by >>):

   drivers/mfd/ezx-pcap.c: In function 'ezx_pcap_probe':
   drivers/mfd/ezx-pcap.c:412:27: error: implicit declaration of function 'devm_alloc_ordered_workqueue'; did you mean 'alloc_ordered_workqueue'? [-Wimplicit-function-declaration]
     412 |         pcap->workqueue = devm_alloc_ordered_workqueue(&spi->dev, "pcapd", 0);
         |                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
         |                           alloc_ordered_workqueue
>> drivers/mfd/ezx-pcap.c:412:25: error: assignment to 'struct workqueue_struct *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
     412 |         pcap->workqueue = devm_alloc_ordered_workqueue(&spi->dev, "pcapd", 0);
         |                         ^


vim +412 drivers/mfd/ezx-pcap.c

   379	
   380	static int ezx_pcap_probe(struct spi_device *spi)
   381	{
   382		struct pcap_platform_data *pdata = dev_get_platdata(&spi->dev);
   383		struct pcap_chip *pcap;
   384		int i, adc_irq;
   385		int ret;
   386	
   387		/* platform data is required */
   388		if (!pdata)
   389			return -ENODEV;
   390	
   391		pcap = devm_kzalloc(&spi->dev, sizeof(*pcap), GFP_KERNEL);
   392		if (!pcap)
   393			return -ENOMEM;
   394	
   395		spin_lock_init(&pcap->io_lock);
   396		spin_lock_init(&pcap->adc_lock);
   397		INIT_WORK(&pcap->isr_work, pcap_isr_work);
   398		INIT_WORK(&pcap->msr_work, pcap_msr_work);
   399		spi_set_drvdata(spi, pcap);
   400	
   401		/* setup spi */
   402		spi->bits_per_word = 32;
   403		spi->mode = SPI_MODE_0 | (pdata->config & PCAP_CS_AH ? SPI_CS_HIGH : 0);
   404		ret = spi_setup(spi);
   405		if (ret)
   406			return ret;
   407	
   408		pcap->spi = spi;
   409	
   410		/* setup irq */
   411		pcap->irq_base = pdata->irq_base;
 > 412		pcap->workqueue = devm_alloc_ordered_workqueue(&spi->dev, "pcapd", 0);
   413		if (!pcap->workqueue)
   414			return -ENOMEM;
   415	
   416		/* redirect interrupts to AP, except adcdone2 */
   417		if (!(pdata->config & PCAP_SECOND_PORT))
   418			ezx_pcap_write(pcap, PCAP_REG_INT_SEL,
   419						(1 << PCAP_IRQ_ADCDONE2));
   420	
   421		/* setup irq chip */
   422		for (i = pcap->irq_base; i < (pcap->irq_base + PCAP_NIRQS); i++) {
   423			irq_set_chip_and_handler(i, &pcap_irq_chip, handle_simple_irq);
   424			irq_set_chip_data(i, pcap);
   425			irq_clear_status_flags(i, IRQ_NOREQUEST | IRQ_NOPROBE);
   426		}
   427	
   428		/* mask/ack all PCAP interrupts */
   429		ezx_pcap_write(pcap, PCAP_REG_MSR, PCAP_MASK_ALL_INTERRUPT);
   430		ezx_pcap_write(pcap, PCAP_REG_ISR, PCAP_CLEAR_INTERRUPT_REGISTER);
   431		pcap->msr = PCAP_MASK_ALL_INTERRUPT;
   432	
   433		irq_set_irq_type(spi->irq, IRQ_TYPE_EDGE_RISING);
   434		irq_set_chained_handler_and_data(spi->irq, pcap_irq_handler, pcap);
   435		irq_set_irq_wake(spi->irq, 1);
   436	
   437		/* ADC */
   438		adc_irq = pcap_to_irq(pcap, (pdata->config & PCAP_SECOND_PORT) ?
   439						PCAP_IRQ_ADCDONE2 : PCAP_IRQ_ADCDONE);
   440	
   441		ret = devm_request_irq(&spi->dev, adc_irq, pcap_adc_irq, 0, "ADC",
   442					pcap);
   443		if (ret)
   444			goto free_irqchip;
   445	
   446		/* setup subdevs */
   447		for (i = 0; i < pdata->num_subdevs; i++) {
   448			ret = pcap_add_subdev(pcap, &pdata->subdevs[i]);
   449			if (ret)
   450				goto remove_subdevs;
   451		}
   452	
   453		/* board specific quirks */
   454		if (pdata->init)
   455			pdata->init(pcap);
   456	
   457		return 0;
   458	
   459	remove_subdevs:
   460		device_for_each_child(&spi->dev, NULL, pcap_remove_subdev);
   461	free_irqchip:
   462		for (i = pcap->irq_base; i < (pcap->irq_base + PCAP_NIRQS); i++)
   463			irq_set_chip_and_handler(i, NULL, NULL);
   464	
   465		return ret;
   466	}
   467	

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

             reply	other threads:[~2026-03-25  2:37 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-25  2:37 kernel test robot [this message]
2026-03-25  7:20 ` [lee-mfd:for-mfd-next 23/25] drivers/mfd/ezx-pcap.c:412:25: error: assignment to 'struct workqueue_struct *' from 'int' makes pointer from integer without a cast Krzysztof Kozlowski
2026-03-25 13:01   ` Lee Jones

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=202603251022.UUrCADAc-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=krzk@kernel.org \
    --cc=lee@kernel.org \
    --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.