public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Binbin Zhou <zhoubinbin@loongson.cn>,
	Binbin Zhou <zhoubb.aaron@gmail.com>,
	Huacai Chen <chenhuacai@loongson.cn>, Lee Jones <lee@kernel.org>,
	Corey Minyard <minyard@acm.org>,
	Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	Maxime Ripard <mripard@kernel.org>,
	Thomas Zimmermann <tzimmermann@suse.de>,
	David Airlie <airlied@gmail.com>, Simona Vetter <simona@ffwll.ch>
Cc: oe-kbuild-all@lists.linux.dev, linux-kernel@vger.kernel.org,
	openipmi-developer@lists.sourceforge.net,
	dri-devel@lists.freedesktop.org, Xuerui Wang <kernel@xen0n.name>,
	loongarch@lists.linux.dev, Chong Qiao <qiaochong@loongson.cn>
Subject: Re: [PATCH v1 2/4] ipmi: Add Loongson-2K BMC support
Date: Tue, 31 Dec 2024 20:37:10 +0800	[thread overview]
Message-ID: <202412311950.Ij7v1vKv-lkp@intel.com> (raw)
In-Reply-To: <a4cfdeed1a91a7a12c7ebe56bed2ba94991c4065.1735550269.git.zhoubinbin@loongson.cn>

Hi Binbin,

kernel test robot noticed the following build warnings:

[auto build test WARNING on linus/master]
[also build test WARNING on v6.13-rc5]
[cannot apply to cminyard-ipmi/for-next lee-mfd/for-mfd-next lee-mfd/for-mfd-fixes next-20241220]
[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/Binbin-Zhou/mfd-ls2kbmc-Introduce-Loongson-2K-BMC-MFD-Core-driver/20241230-174205
base:   linus/master
patch link:    https://lore.kernel.org/r/a4cfdeed1a91a7a12c7ebe56bed2ba94991c4065.1735550269.git.zhoubinbin%40loongson.cn
patch subject: [PATCH v1 2/4] ipmi: Add Loongson-2K BMC support
config: loongarch-randconfig-r123-20241231 (https://download.01.org/0day-ci/archive/20241231/202412311950.Ij7v1vKv-lkp@intel.com/config)
compiler: loongarch64-linux-gcc (GCC) 14.2.0
reproduce: (https://download.01.org/0day-ci/archive/20241231/202412311950.Ij7v1vKv-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/202412311950.Ij7v1vKv-lkp@intel.com/

sparse warnings: (new ones prefixed by >>)
>> drivers/char/ipmi/ipmi_si_ls2k.c:110:38: sparse: sparse: incorrect type in initializer (different address spaces) @@     expected struct ls2k_kcs_data *ik @@     got void [noderef] __iomem *const addr @@
   drivers/char/ipmi/ipmi_si_ls2k.c:110:38: sparse:     expected struct ls2k_kcs_data *ik
   drivers/char/ipmi/ipmi_si_ls2k.c:110:38: sparse:     got void [noderef] __iomem *const addr
   drivers/char/ipmi/ipmi_si_ls2k.c:168:38: sparse: sparse: incorrect type in initializer (different address spaces) @@     expected struct ls2k_kcs_data *ik @@     got void [noderef] __iomem *const addr @@
   drivers/char/ipmi/ipmi_si_ls2k.c:168:38: sparse:     expected struct ls2k_kcs_data *ik
   drivers/char/ipmi/ipmi_si_ls2k.c:168:38: sparse:     got void [noderef] __iomem *const addr
>> drivers/char/ipmi/ipmi_si_ls2k.c:226:24: sparse: sparse: symbol 'ipmi_ls2k_platform_driver' was not declared. Should it be static?

vim +110 drivers/char/ipmi/ipmi_si_ls2k.c

   106	
   107	static unsigned char ls2k_mem_inb(const struct si_sm_io *io,
   108					  unsigned int offset)
   109	{
 > 110		struct ls2k_kcs_data *ik = io->addr;
   111		int inb = 0;
   112	
   113		if (ik->version == 0)
   114			inb = intf_sim_inb_v0(ik, offset);
   115		else if (ik->version == 1)
   116			inb = intf_sim_inb_v1(ik, offset);
   117	
   118		return inb;
   119	}
   120	
   121	static void intf_sim_outb_v0(struct ls2k_kcs_data *ik, unsigned int offset,
   122				     unsigned char val)
   123	{
   124		if (ls2k_get_ibf(ik))
   125			return;
   126	
   127		switch (offset & BIT(0)) {
   128		case 0:
   129			ik->reg.data_in = val;
   130			ik->reg.status &= ~LS2K_KCS_STS_CMD;
   131			break;
   132	
   133		case 1:
   134			ik->reg.cmd = val;
   135			ik->reg.status |= LS2K_KCS_STS_CMD;
   136			break;
   137		}
   138	
   139		ls2k_set_ibf(ik, 1);
   140		ik->write_req++;
   141	}
   142	
   143	static void intf_sim_outb_v1(struct ls2k_kcs_data *ik, unsigned int offset,
   144				     unsigned char val)
   145	{
   146		if (ik->fifo.ibfh != ik->fifo.ibft)
   147			return;
   148	
   149		switch (offset & BIT(0)) {
   150		case 0:
   151			ik->reg.data_in = val;
   152			ik->cmd_data = 0;
   153			break;
   154	
   155		case 1:
   156			ik->reg.cmd = val;
   157			ik->cmd_data = 1;
   158			break;
   159		}
   160	
   161		ik->fifo.ibfh = !ik->fifo.ibft;
   162		ik->write_req++;
   163	}
   164	
   165	static void ls2k_mem_outb(const struct si_sm_io *io, unsigned int offset,
   166				  unsigned char val)
   167	{
   168		struct ls2k_kcs_data *ik = io->addr;
   169	
   170		if (ik->version == 0)
   171			intf_sim_outb_v0(ik, offset, val);
   172		else if (ik->version == 1)
   173			intf_sim_outb_v1(ik, offset, val);
   174	}
   175	
   176	static void ls2k_mem_cleanup(struct si_sm_io *io)
   177	{
   178		if (io->addr)
   179			iounmap(io->addr);
   180	}
   181	
   182	static int ipmi_ls2k_sim_setup(struct si_sm_io *io)
   183	{
   184		io->addr = ioremap(io->addr_data, io->regspacing);
   185		if (!io->addr)
   186			return -EIO;
   187	
   188		io->inputb = ls2k_mem_inb;
   189		io->outputb = ls2k_mem_outb;
   190		io->io_cleanup = ls2k_mem_cleanup;
   191	
   192		return 0;
   193	}
   194	
   195	static int ipmi_ls2k_probe(struct platform_device *pdev)
   196	{
   197		struct si_sm_io io;
   198	
   199		dev_info(&pdev->dev, "probing via ls2k platform");
   200		memset(&io, 0, sizeof(io));
   201	
   202		io.addr_source	= SI_PLATFORM;
   203		io.si_type	= SI_KCS;
   204		io.addr_space	= IPMI_MEM_ADDR_SPACE;
   205		io.io_setup	= ipmi_ls2k_sim_setup;
   206		io.addr_data	= pdev->resource[0].start;
   207		io.regspacing	= pdev->resource[0].end - pdev->resource[0].start + 1;
   208		io.regsize	= DEFAULT_REGSIZE;
   209		io.regshift	= 0;
   210		io.dev		= &pdev->dev;
   211		io.irq		= 0;
   212		if (io.irq)
   213			io.irq_setup = ipmi_std_irq_setup;
   214	
   215		dev_info(&pdev->dev, "%pR regsize %d spacing %d irq %d\n",
   216			 &pdev->resource[0], io.regsize, io.regspacing, io.irq);
   217	
   218		return ipmi_si_add_smi(&io);
   219	}
   220	
   221	static void ipmi_ls2k_remove(struct platform_device *pdev)
   222	{
   223		ipmi_si_remove_by_dev(&pdev->dev);
   224	}
   225	
 > 226	struct platform_driver ipmi_ls2k_platform_driver = {
   227		.driver = {
   228			.name = "ls2k-ipmi-si",
   229		},
   230		.probe	= ipmi_ls2k_probe,
   231		.remove	= ipmi_ls2k_remove,
   232	};
   233	

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

  reply	other threads:[~2024-12-31 12:38 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-30  9:31 [PATCH v1 0/4] LoongArch: Add Loongson-2K0500 BMC support Binbin Zhou
2024-12-30  9:31 ` [PATCH v1 1/4] mfd: ls2kbmc: Introduce Loongson-2K BMC MFD Core driver Binbin Zhou
2024-12-30  9:31 ` [PATCH v1 2/4] ipmi: Add Loongson-2K BMC support Binbin Zhou
2024-12-31 12:37   ` kernel test robot [this message]
2025-01-03  4:29   ` kernel test robot
2024-12-30  9:31 ` [PATCH v1 3/4] drm/ls2kbmc: Add support for Loongson-2K BMC display Binbin Zhou
2025-01-02  9:07   ` Thomas Zimmermann
2025-01-02 12:55     ` Binbin Zhou
2025-01-02 13:32       ` Thomas Zimmermann
2025-01-06  1:56         ` Binbin Zhou
2025-01-06  7:03         ` Binbin Zhou
2025-01-06 14:10           ` Thomas Zimmermann
2025-01-09 12:56             ` Binbin Zhou
2025-01-15  8:48   ` Thomas Zimmermann
2024-12-30  9:31 ` [PATCH v1 4/4] drm/ls2kbmc: Add Loongson-2K BMC reset function support Binbin Zhou
2025-01-15  8:57   ` Thomas Zimmermann
2025-02-11 11:27     ` Binbin Zhou
2025-03-25 12:39       ` Binbin Zhou
2025-03-31  7:53       ` Thomas Zimmermann

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=202412311950.Ij7v1vKv-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=airlied@gmail.com \
    --cc=chenhuacai@loongson.cn \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=kernel@xen0n.name \
    --cc=lee@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=loongarch@lists.linux.dev \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=minyard@acm.org \
    --cc=mripard@kernel.org \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=openipmi-developer@lists.sourceforge.net \
    --cc=qiaochong@loongson.cn \
    --cc=simona@ffwll.ch \
    --cc=tzimmermann@suse.de \
    --cc=zhoubb.aaron@gmail.com \
    --cc=zhoubinbin@loongson.cn \
    /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