From: Dan Carpenter <dan.carpenter@linaro.org>
To: oe-kbuild@lists.linux.dev,
AngeloGioacchino Del Regno
<angelogioacchino.delregno@collabora.com>,
linux-mediatek@lists.infradead.org
Cc: lkp@intel.com, oe-kbuild-all@lists.linux.dev, lee@kernel.org,
robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org,
matthias.bgg@gmail.com, angelogioacchino.delregno@collabora.com,
lgirdwood@gmail.com, broonie@kernel.org,
devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org, kernel@collabora.com,
wenst@chromium.org, igor.belwon@mentallysanemainliners.org
Subject: Re: [PATCH v7 6/9] regulator: Add support for MediaTek MT6373 SPMI PMIC Regulators
Date: Fri, 3 Oct 2025 11:36:03 +0300 [thread overview]
Message-ID: <202510030902.aQS5rL8n-lkp@intel.com> (raw)
In-Reply-To: <20251002090028.1796462-7-angelogioacchino.delregno@collabora.com>
Hi AngeloGioacchino,
kernel test robot noticed the following build warnings:
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/AngeloGioacchino-Del-Regno/dt-bindings-regulator-Document-MediaTek-MT6316-PMIC-Regulators/20251002-170532
base: https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git for-next
patch link: https://lore.kernel.org/r/20251002090028.1796462-7-angelogioacchino.delregno%40collabora.com
patch subject: [PATCH v7 6/9] regulator: Add support for MediaTek MT6373 SPMI PMIC Regulators
config: arm-randconfig-r071-20251003 (https://download.01.org/0day-ci/archive/20251003/202510030902.aQS5rL8n-lkp@intel.com/config)
compiler: arm-linux-gnueabi-gcc (GCC) 8.5.0
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>
| Reported-by: Dan Carpenter <dan.carpenter@linaro.org>
| Closes: https://lore.kernel.org/r/202510030902.aQS5rL8n-lkp@intel.com/
smatch warnings:
drivers/regulator/mt6373-regulator.c:664 mt6373_regulator_probe() warn: passing zero to 'PTR_ERR'
vim +/PTR_ERR +664 drivers/regulator/mt6373-regulator.c
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 645 static int mt6373_regulator_probe(struct platform_device *pdev)
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 646 {
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 647 struct irq_fwspec fwspec = {
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 648 .param_count = 2,
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 649 .param = { 0, IRQ_TYPE_LEVEL_HIGH },
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 650 };
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 651 struct device_node *interrupt_parent;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 652 struct regulator_config config = {};
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 653 struct mt6373_regulator_info *info;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 654 struct device *dev = &pdev->dev;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 655 struct regulator_dev *rdev;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 656 struct irq_domain *domain;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 657 bool is_vbuck4_hw_ctrl;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 658 bool is_cw_variant;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 659 int i, ret;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 660 u32 val;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 661
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 662 config.regmap = mt6373_spmi_register_regmap(dev);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 663 if (!config.regmap)
This should be if (IS_ERR(config.regmap)) ...
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 @664 return dev_err_probe(dev, PTR_ERR(config.regmap)i,
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 665 "Cannot get regmap\n");
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 666 config.dev = dev;
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
WARNING: multiple messages have this Message-ID (diff)
From: kernel test robot <lkp@intel.com>
To: oe-kbuild@lists.linux.dev
Cc: lkp@intel.com, Dan Carpenter <error27@gmail.com>
Subject: Re: [PATCH v7 6/9] regulator: Add support for MediaTek MT6373 SPMI PMIC Regulators
Date: Fri, 3 Oct 2025 10:12:08 +0800 [thread overview]
Message-ID: <202510030902.aQS5rL8n-lkp@intel.com> (raw)
BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
In-Reply-To: <20251002090028.1796462-7-angelogioacchino.delregno@collabora.com>
References: <20251002090028.1796462-7-angelogioacchino.delregno@collabora.com>
TO: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
TO: linux-mediatek@lists.infradead.org
CC: lee@kernel.org
CC: robh@kernel.org
CC: krzk+dt@kernel.org
CC: conor+dt@kernel.org
CC: matthias.bgg@gmail.com
CC: angelogioacchino.delregno@collabora.com
CC: lgirdwood@gmail.com
CC: broonie@kernel.org
CC: devicetree@vger.kernel.org
CC: linux-kernel@vger.kernel.org
CC: linux-arm-kernel@lists.infradead.org
CC: kernel@collabora.com
CC: wenst@chromium.org
CC: igor.belwon@mentallysanemainliners.org
Hi AngeloGioacchino,
kernel test robot noticed the following build warnings:
[auto build test WARNING on broonie-regulator/for-next]
[also build test WARNING on lee-mfd/for-mfd-next jic23-iio/togreg lee-leds/for-leds-next lee-mfd/for-mfd-fixes linus/master v6.17 next-20251002]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/AngeloGioacchino-Del-Regno/dt-bindings-regulator-Document-MediaTek-MT6316-PMIC-Regulators/20251002-170532
base: https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git for-next
patch link: https://lore.kernel.org/r/20251002090028.1796462-7-angelogioacchino.delregno%40collabora.com
patch subject: [PATCH v7 6/9] regulator: Add support for MediaTek MT6373 SPMI PMIC Regulators
:::::: branch date: 17 hours ago
:::::: commit date: 17 hours ago
config: arm-randconfig-r071-20251003 (https://download.01.org/0day-ci/archive/20251003/202510030902.aQS5rL8n-lkp@intel.com/config)
compiler: arm-linux-gnueabi-gcc (GCC) 8.5.0
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>
| Reported-by: Dan Carpenter <error27@gmail.com>
| Closes: https://lore.kernel.org/r/202510030902.aQS5rL8n-lkp@intel.com/
smatch warnings:
drivers/regulator/mt6373-regulator.c:664 mt6373_regulator_probe() warn: passing zero to 'PTR_ERR'
vim +/PTR_ERR +664 drivers/regulator/mt6373-regulator.c
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 644
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 645 static int mt6373_regulator_probe(struct platform_device *pdev)
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 646 {
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 647 struct irq_fwspec fwspec = {
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 648 .param_count = 2,
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 649 .param = { 0, IRQ_TYPE_LEVEL_HIGH },
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 650 };
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 651 struct device_node *interrupt_parent;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 652 struct regulator_config config = {};
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 653 struct mt6373_regulator_info *info;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 654 struct device *dev = &pdev->dev;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 655 struct regulator_dev *rdev;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 656 struct irq_domain *domain;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 657 bool is_vbuck4_hw_ctrl;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 658 bool is_cw_variant;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 659 int i, ret;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 660 u32 val;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 661
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 662 config.regmap = mt6373_spmi_register_regmap(dev);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 663 if (!config.regmap)
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 @664 return dev_err_probe(dev, PTR_ERR(config.regmap),
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 665 "Cannot get regmap\n");
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 666 config.dev = dev;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 667
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 668 interrupt_parent = of_irq_find_parent(dev->of_node);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 669 if (!interrupt_parent)
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 670 return -EINVAL;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 671
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 672 domain = irq_find_host(interrupt_parent);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 673 of_node_put(interrupt_parent);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 674 fwspec.fwnode = domain->fwnode;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 675
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 676 /* Read PMIC variant information */
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 677 ret = regmap_read(config.regmap, MT6373_PLG_CFG_ELR1, &val);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 678 if (ret)
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 679 return dev_err_probe(dev, ret, "Cannot read ID register\n");
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 680
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 681 val = FIELD_GET(MT6373_ELR_VARIANT_MASK, val);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 682 is_cw_variant = (val == MT6373_ELR_VARIANT_MT6373CW);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 683
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 684 /* Read Reserved-SW information */
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 685 ret = regmap_read(config.regmap, MT6373_RG_RSV_SWREG_H, &val);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 686 if (ret)
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 687 return dev_err_probe(dev, ret, "Cannot read RSV_SW register\n");
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 688
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 689 is_vbuck4_hw_ctrl = val & MT6373_RG_RSV_SWREG_VBUCK4_HW_CTRL;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 690
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 691 for (i = 0; i < ARRAY_SIZE(mt6373_regulators); i++) {
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 692 info = &mt6373_regulators[i];
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 693
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 694 /* MT6373CW VBUCK4 constraints are different */
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 695 if (info->desc.id == MT6373_ID_VBUCK4) {
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 696 unsigned int vbuck4_max_uV;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 697
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 698 /* VBUCK4 vreg software control not allowed in hw_ctrl mode */
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 699 if (is_vbuck4_hw_ctrl)
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 700 continue;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 701
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 702 if (is_cw_variant) {
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 703 info->desc.uV_step = 6250;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 704 vbuck4_max_uV = 1193750;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 705 } else {
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 706 info->desc.uV_step = 13875;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 707 vbuck4_max_uV = 2650125;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 708 }
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 709 info->desc.n_voltages = vbuck4_max_uV / info->desc.uV_step + 1;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 710 }
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 711
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 712 fwspec.param[0] = info->hwirq;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 713 info->virq = irq_create_fwspec_mapping(&fwspec);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 714 if (!info->virq)
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 715 return dev_err_probe(dev, -EINVAL,
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 716 "Failed to map IRQ%d\n", info->hwirq);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 717
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 718 ret = devm_add_action_or_reset(dev, mt6373_irq_remove, &info->virq);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 719 if (ret) {
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 720 irq_dispose_mapping(info->virq);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 721 return ret;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 722 }
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 723
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 724 config.driver_data = info;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 725 INIT_DELAYED_WORK(&info->oc_work, mt6373_oc_irq_enable_work);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 726
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 727 rdev = devm_regulator_register(dev, &info->desc, &config);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 728 if (IS_ERR(rdev))
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 729 return dev_err_probe(dev, PTR_ERR(rdev),
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 730 "failed to register %s\n", info->desc.name);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 731 }
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 732 dev_set_drvdata(dev, config.regmap);
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 733
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 734 return 0;
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 735 }
910ce1c7c9122a AngeloGioacchino Del Regno 2025-10-02 736
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next parent reply other threads:[~2025-10-03 8:36 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-03 2:12 kernel test robot [this message]
2025-10-03 8:36 ` [PATCH v7 6/9] regulator: Add support for MediaTek MT6373 SPMI PMIC Regulators Dan Carpenter
-- strict thread matches above, loose matches on Subject: below --
2025-10-02 9:00 [PATCH v7 0/9] Add support MT6316/6363/MT6373 PMICs regulators and MFD AngeloGioacchino Del Regno
2025-10-02 9:00 ` [PATCH v7 1/9] dt-bindings: regulator: Document MediaTek MT6316 PMIC Regulators AngeloGioacchino Del Regno
2025-10-02 9:00 ` [PATCH v7 2/9] regulator: Add support for MediaTek MT6316 SPMI " AngeloGioacchino Del Regno
2025-10-02 9:00 ` [PATCH v7 3/9] dt-bindings: regulator: Document MediaTek MT6363 " AngeloGioacchino Del Regno
2025-10-02 9:00 ` [PATCH v7 4/9] regulator: Add support for MediaTek MT6363 SPMI " AngeloGioacchino Del Regno
2025-10-03 6:38 ` kernel test robot
2025-10-02 9:00 ` [PATCH v7 5/9] dt-bindings: regulator: Document MediaTek MT6373 " AngeloGioacchino Del Regno
2025-10-02 9:00 ` [PATCH v7 6/9] regulator: Add support for MediaTek MT6373 SPMI " AngeloGioacchino Del Regno
2025-10-02 9:00 ` [PATCH v7 7/9] dt-bindings: iio: adc: mt6359: Allow reg for SPMI PMICs AuxADC AngeloGioacchino Del Regno
2025-10-02 9:00 ` [PATCH v7 8/9] dt-bindings: mfd: Add binding for MediaTek MT6363 series SPMI PMIC AngeloGioacchino Del Regno
2025-10-02 9:00 ` [PATCH v7 9/9] drivers: mfd: Add support for MediaTek SPMI PMICs and MT6363/73 AngeloGioacchino Del Regno
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=202510030902.aQS5rL8n-lkp@intel.com \
--to=dan.carpenter@linaro.org \
--cc=angelogioacchino.delregno@collabora.com \
--cc=broonie@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=igor.belwon@mentallysanemainliners.org \
--cc=kernel@collabora.com \
--cc=krzk+dt@kernel.org \
--cc=lee@kernel.org \
--cc=lgirdwood@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=lkp@intel.com \
--cc=matthias.bgg@gmail.com \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=oe-kbuild@lists.linux.dev \
--cc=robh@kernel.org \
--cc=wenst@chromium.org \
/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.