All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Frank Li <Frank.Li@nxp.com>, robh@kernel.org
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev,
	alexandre.belloni@bootlin.com, conor.culhane@silvaco.com,
	gregkh@linuxfoundation.org, imx@lists.linux.dev,
	jirislaby@kernel.org, joe@perches.com,
	linux-i3c@lists.infradead.org, linux-kernel@vger.kernel.org,
	linux-serial@vger.kernel.org, miquel.raynal@bootlin.com,
	zbigniew.lukwinski@linux.intel.com, devicetree@vger.kernel.org,
	krzysztof.kozlowski+dt@linaro.org,
	krzysztof.kozlowski@linaro.org
Subject: Re: [PATCH v2 4/7] i3c: target: add svc target controller support
Date: Thu, 11 Jan 2024 21:49:22 +0800	[thread overview]
Message-ID: <202401112149.TbWJpRfM-lkp@intel.com> (raw)
In-Reply-To: <20240110175221.2335480-5-Frank.Li@nxp.com>

Hi Frank,

kernel test robot noticed the following build warnings:

[auto build test WARNING on tty/tty-testing]
[also build test WARNING on tty/tty-next tty/tty-linus robh/for-next linus/master v6.7 next-20240111]
[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/Frank-Li/i3c-add-target-mode-support/20240111-015711
base:   https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty.git tty-testing
patch link:    https://lore.kernel.org/r/20240110175221.2335480-5-Frank.Li%40nxp.com
patch subject: [PATCH v2 4/7] i3c: target: add svc target controller support
config: x86_64-allmodconfig (https://download.01.org/0day-ci/archive/20240111/202401112149.TbWJpRfM-lkp@intel.com/config)
compiler: ClangBuiltLinux clang version 17.0.6 (https://github.com/llvm/llvm-project 6009708b4367171ccdbf4b5905cb6a803753fe18)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240111/202401112149.TbWJpRfM-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/202401112149.TbWJpRfM-lkp@intel.com/

All warnings (new ones prefixed by >>):

>> drivers/i3c/target/svc-i3c-target.c:211:40: warning: no previous prototype for function 'svc_i3c_get_features' [-Wmissing-prototypes]
     211 | const struct i3c_target_ctrl_features *svc_i3c_get_features(struct i3c_target_ctrl *ctrl)
         |                                        ^
   drivers/i3c/target/svc-i3c-target.c:211:7: note: declare 'static' if the function is not intended to be used outside of this translation unit
     211 | const struct i3c_target_ctrl_features *svc_i3c_get_features(struct i3c_target_ctrl *ctrl)
         |       ^
         | static 
>> drivers/i3c/target/svc-i3c-target.c:268:63: warning: omitting the parameter name in a function definition is a C2x extension [-Wc2x-extensions]
     268 | static int svc_i3c_target_queue(struct i3c_request *req, gfp_t)
         |                                                               ^
>> drivers/i3c/target/svc-i3c-target.c:666:5: warning: no previous prototype for function 'svc_i3c_fifo_status' [-Wmissing-prototypes]
     666 | int svc_i3c_fifo_status(struct i3c_target_ctrl *ctrl, bool tx)
         |     ^
   drivers/i3c/target/svc-i3c-target.c:666:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
     666 | int svc_i3c_fifo_status(struct i3c_target_ctrl *ctrl, bool tx)
         | ^
         | static 
   3 warnings generated.


vim +/svc_i3c_get_features +211 drivers/i3c/target/svc-i3c-target.c

   210	
 > 211	const struct i3c_target_ctrl_features *svc_i3c_get_features(struct i3c_target_ctrl *ctrl)
   212	{
   213		struct svc_i3c_target *svc;
   214	
   215		svc = dev_get_drvdata(&ctrl->dev);
   216	
   217		if (!svc)
   218			return NULL;
   219	
   220		return &svc->features;
   221	}
   222	
   223	static void svc_i3c_queue_complete(struct svc_i3c_target *svc, struct i3c_request *complete)
   224	{
   225		unsigned long flags;
   226	
   227		spin_lock_irqsave(&svc->cq_lock, flags);
   228		list_add_tail(&complete->list, &svc->cq);
   229		spin_unlock_irqrestore(&svc->cq_lock, flags);
   230		queue_work(svc->workqueue, &svc->work);
   231	}
   232	
   233	static void svc_i3c_fill_txfifo(struct svc_i3c_target *svc)
   234	{
   235		struct i3c_request *req, *complete = NULL;
   236		unsigned long flags;
   237		int val;
   238	
   239		spin_lock_irqsave(&svc->txq_lock, flags);
   240		while ((!!(req = list_first_entry_or_null(&svc->txq, struct i3c_request, list))) &&
   241		       !((readl_relaxed(svc->regs + I3C_SDATACTRL) & I3C_SDATACTRL_TXFULL_MASK))) {
   242			while (!(readl_relaxed(svc->regs + I3C_SDATACTRL)
   243						& I3C_SDATACTRL_TXFULL_MASK)) {
   244				val = *(u8 *)(req->buf + req->actual);
   245	
   246				if (req->actual + 1 == req->length)
   247					writel_relaxed(val, svc->regs + I3C_SWDATAE);
   248				else
   249					writel_relaxed(val, svc->regs + I3C_SWDATAB);
   250	
   251				req->actual++;
   252	
   253				if (req->actual == req->length) {
   254					list_del(&req->list);
   255					complete = req;
   256					spin_unlock_irqrestore(&svc->txq_lock, flags);
   257	
   258					svc_i3c_queue_complete(svc, complete);
   259	
   260					spin_lock_irqsave(&svc->txq_lock, flags);
   261					break;
   262				}
   263			}
   264		}
   265		spin_unlock_irqrestore(&svc->txq_lock, flags);
   266	}
   267	
 > 268	static int svc_i3c_target_queue(struct i3c_request *req, gfp_t)
   269	{
   270		struct svc_i3c_target *svc;
   271		struct list_head *q;
   272		unsigned long flags;
   273		spinlock_t *lk;
   274	
   275		svc = dev_get_drvdata(&req->ctrl->dev);
   276		if (!svc)
   277			return -EINVAL;
   278	
   279		if (req->tx) {
   280			q = &svc->txq;
   281			lk = &svc->txq_lock;
   282		} else {
   283			q = &svc->rxq;
   284			lk = &svc->rxq_lock;
   285		}
   286	
   287		spin_lock_irqsave(lk, flags);
   288		list_add_tail(&req->list, q);
   289		spin_unlock_irqrestore(lk, flags);
   290	
   291		if (req->tx)
   292			svc_i3c_fill_txfifo(svc);
   293	
   294		if (req->tx)
   295			writel_relaxed(I3C_SINT_TXSEND, svc->regs + I3C_SINTSET);
   296		else
   297			writel_relaxed(I3C_SINT_RXPEND, svc->regs + I3C_SINTSET);
   298	
   299		return 0;
   300	}
   301	

-- 
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: Frank Li <Frank.Li@nxp.com>, robh@kernel.org
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev,
	alexandre.belloni@bootlin.com, conor.culhane@silvaco.com,
	gregkh@linuxfoundation.org, imx@lists.linux.dev,
	jirislaby@kernel.org, joe@perches.com,
	linux-i3c@lists.infradead.org, linux-kernel@vger.kernel.org,
	linux-serial@vger.kernel.org, miquel.raynal@bootlin.com,
	zbigniew.lukwinski@linux.intel.com, devicetree@vger.kernel.org,
	krzysztof.kozlowski+dt@linaro.org,
	krzysztof.kozlowski@linaro.org
Subject: Re: [PATCH v2 4/7] i3c: target: add svc target controller support
Date: Thu, 11 Jan 2024 21:49:22 +0800	[thread overview]
Message-ID: <202401112149.TbWJpRfM-lkp@intel.com> (raw)
In-Reply-To: <20240110175221.2335480-5-Frank.Li@nxp.com>

Hi Frank,

kernel test robot noticed the following build warnings:

[auto build test WARNING on tty/tty-testing]
[also build test WARNING on tty/tty-next tty/tty-linus robh/for-next linus/master v6.7 next-20240111]
[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/Frank-Li/i3c-add-target-mode-support/20240111-015711
base:   https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty.git tty-testing
patch link:    https://lore.kernel.org/r/20240110175221.2335480-5-Frank.Li%40nxp.com
patch subject: [PATCH v2 4/7] i3c: target: add svc target controller support
config: x86_64-allmodconfig (https://download.01.org/0day-ci/archive/20240111/202401112149.TbWJpRfM-lkp@intel.com/config)
compiler: ClangBuiltLinux clang version 17.0.6 (https://github.com/llvm/llvm-project 6009708b4367171ccdbf4b5905cb6a803753fe18)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240111/202401112149.TbWJpRfM-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/202401112149.TbWJpRfM-lkp@intel.com/

All warnings (new ones prefixed by >>):

>> drivers/i3c/target/svc-i3c-target.c:211:40: warning: no previous prototype for function 'svc_i3c_get_features' [-Wmissing-prototypes]
     211 | const struct i3c_target_ctrl_features *svc_i3c_get_features(struct i3c_target_ctrl *ctrl)
         |                                        ^
   drivers/i3c/target/svc-i3c-target.c:211:7: note: declare 'static' if the function is not intended to be used outside of this translation unit
     211 | const struct i3c_target_ctrl_features *svc_i3c_get_features(struct i3c_target_ctrl *ctrl)
         |       ^
         | static 
>> drivers/i3c/target/svc-i3c-target.c:268:63: warning: omitting the parameter name in a function definition is a C2x extension [-Wc2x-extensions]
     268 | static int svc_i3c_target_queue(struct i3c_request *req, gfp_t)
         |                                                               ^
>> drivers/i3c/target/svc-i3c-target.c:666:5: warning: no previous prototype for function 'svc_i3c_fifo_status' [-Wmissing-prototypes]
     666 | int svc_i3c_fifo_status(struct i3c_target_ctrl *ctrl, bool tx)
         |     ^
   drivers/i3c/target/svc-i3c-target.c:666:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
     666 | int svc_i3c_fifo_status(struct i3c_target_ctrl *ctrl, bool tx)
         | ^
         | static 
   3 warnings generated.


vim +/svc_i3c_get_features +211 drivers/i3c/target/svc-i3c-target.c

   210	
 > 211	const struct i3c_target_ctrl_features *svc_i3c_get_features(struct i3c_target_ctrl *ctrl)
   212	{
   213		struct svc_i3c_target *svc;
   214	
   215		svc = dev_get_drvdata(&ctrl->dev);
   216	
   217		if (!svc)
   218			return NULL;
   219	
   220		return &svc->features;
   221	}
   222	
   223	static void svc_i3c_queue_complete(struct svc_i3c_target *svc, struct i3c_request *complete)
   224	{
   225		unsigned long flags;
   226	
   227		spin_lock_irqsave(&svc->cq_lock, flags);
   228		list_add_tail(&complete->list, &svc->cq);
   229		spin_unlock_irqrestore(&svc->cq_lock, flags);
   230		queue_work(svc->workqueue, &svc->work);
   231	}
   232	
   233	static void svc_i3c_fill_txfifo(struct svc_i3c_target *svc)
   234	{
   235		struct i3c_request *req, *complete = NULL;
   236		unsigned long flags;
   237		int val;
   238	
   239		spin_lock_irqsave(&svc->txq_lock, flags);
   240		while ((!!(req = list_first_entry_or_null(&svc->txq, struct i3c_request, list))) &&
   241		       !((readl_relaxed(svc->regs + I3C_SDATACTRL) & I3C_SDATACTRL_TXFULL_MASK))) {
   242			while (!(readl_relaxed(svc->regs + I3C_SDATACTRL)
   243						& I3C_SDATACTRL_TXFULL_MASK)) {
   244				val = *(u8 *)(req->buf + req->actual);
   245	
   246				if (req->actual + 1 == req->length)
   247					writel_relaxed(val, svc->regs + I3C_SWDATAE);
   248				else
   249					writel_relaxed(val, svc->regs + I3C_SWDATAB);
   250	
   251				req->actual++;
   252	
   253				if (req->actual == req->length) {
   254					list_del(&req->list);
   255					complete = req;
   256					spin_unlock_irqrestore(&svc->txq_lock, flags);
   257	
   258					svc_i3c_queue_complete(svc, complete);
   259	
   260					spin_lock_irqsave(&svc->txq_lock, flags);
   261					break;
   262				}
   263			}
   264		}
   265		spin_unlock_irqrestore(&svc->txq_lock, flags);
   266	}
   267	
 > 268	static int svc_i3c_target_queue(struct i3c_request *req, gfp_t)
   269	{
   270		struct svc_i3c_target *svc;
   271		struct list_head *q;
   272		unsigned long flags;
   273		spinlock_t *lk;
   274	
   275		svc = dev_get_drvdata(&req->ctrl->dev);
   276		if (!svc)
   277			return -EINVAL;
   278	
   279		if (req->tx) {
   280			q = &svc->txq;
   281			lk = &svc->txq_lock;
   282		} else {
   283			q = &svc->rxq;
   284			lk = &svc->rxq_lock;
   285		}
   286	
   287		spin_lock_irqsave(lk, flags);
   288		list_add_tail(&req->list, q);
   289		spin_unlock_irqrestore(lk, flags);
   290	
   291		if (req->tx)
   292			svc_i3c_fill_txfifo(svc);
   293	
   294		if (req->tx)
   295			writel_relaxed(I3C_SINT_TXSEND, svc->regs + I3C_SINTSET);
   296		else
   297			writel_relaxed(I3C_SINT_RXPEND, svc->regs + I3C_SINTSET);
   298	
   299		return 0;
   300	}
   301	

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

-- 
linux-i3c mailing list
linux-i3c@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-i3c

  parent reply	other threads:[~2024-01-11 13:50 UTC|newest]

Thread overview: 76+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-10 17:52 [PATCH v2 0/7] I3C target mode support Frank Li
2024-01-10 17:52 ` Frank Li
2024-01-10 17:52 ` [PATCH v2 1/7] i3c: add " Frank Li
2024-01-10 17:52   ` Frank Li
2024-01-10 17:52 ` [PATCH v2 2/7] dt-bindings: i3c: svc: add compatible string i3c: silvaco,i3c-target-v1 Frank Li
2024-01-10 17:52   ` Frank Li
2024-01-12  7:38   ` Krzysztof Kozlowski
2024-01-12  7:38     ` Krzysztof Kozlowski
2024-01-12 15:31     ` Frank Li
2024-01-12 15:31       ` Frank Li
2024-01-12 15:50       ` Krzysztof Kozlowski
2024-01-12 15:50         ` Krzysztof Kozlowski
2024-01-12 16:00         ` Krzysztof Kozlowski
2024-01-12 16:00           ` Krzysztof Kozlowski
2024-01-12 16:06         ` Frank Li
2024-01-12 16:06           ` Frank Li
2024-01-15 19:44           ` Frank Li
2024-01-15 19:44             ` Frank Li
2024-01-15 20:38             ` Krzysztof Kozlowski
2024-01-15 20:38               ` Krzysztof Kozlowski
2024-01-16  2:29               ` Frank Li
2024-01-16  2:29                 ` Frank Li
2024-01-16  7:24                 ` Krzysztof Kozlowski
2024-01-16  7:24                   ` Krzysztof Kozlowski
2024-01-16  9:30                   ` Conor Dooley
2024-01-16  9:30                     ` Conor Dooley
2024-01-16  9:33                     ` Krzysztof Kozlowski
2024-01-16  9:33                       ` Krzysztof Kozlowski
2024-01-16  9:48                       ` Conor Dooley
2024-01-16  9:48                         ` Conor Dooley
2024-01-16 17:35                         ` Frank Li
2024-01-16 17:35                           ` Frank Li
2024-01-16 18:23                           ` Conor Dooley
2024-01-16 18:23                             ` Conor Dooley
2024-01-16 19:13                             ` Frank Li
2024-01-16 19:13                               ` Frank Li
2024-01-16 20:30                               ` Krzysztof Kozlowski
2024-01-16 20:30                                 ` Krzysztof Kozlowski
2024-01-16 20:44                                 ` Frank Li
2024-01-16 20:44                                   ` Frank Li
2024-01-16 20:56                                   ` Krzysztof Kozlowski
2024-01-16 20:56                                     ` Krzysztof Kozlowski
2024-01-16 21:01                                     ` Krzysztof Kozlowski
2024-01-16 21:01                                       ` Krzysztof Kozlowski
2024-01-16 22:25                                       ` Frank Li
2024-01-16 22:25                                         ` Frank Li
2024-01-17  6:50                                         ` Krzysztof Kozlowski
2024-01-17  6:50                                           ` Krzysztof Kozlowski
2024-01-17 16:19                                           ` Frank Li
2024-01-17 16:19                                             ` Frank Li
2024-01-17 17:15                                             ` Krzysztof Kozlowski
2024-01-17 17:15                                               ` Krzysztof Kozlowski
2024-01-17 18:06                                               ` Frank Li
2024-01-17 18:06                                                 ` Frank Li
2024-01-19 17:13                                                 ` Frank Li
2024-01-19 17:13                                                   ` Frank Li
2024-01-16 21:31                                     ` Frank Li
2024-01-16 21:31                                       ` Frank Li
2024-01-17  6:45                                       ` Krzysztof Kozlowski
2024-01-17  6:45                                         ` Krzysztof Kozlowski
2024-01-10 17:52 ` [PATCH v2 3/7] Documentation: i3c: Add I3C target mode controller and function Frank Li
2024-01-10 17:52   ` Frank Li
2024-01-11 23:45   ` kernel test robot
2024-01-11 23:45     ` kernel test robot
2024-01-10 17:52 ` [PATCH v2 4/7] i3c: target: add svc target controller support Frank Li
2024-01-10 17:52   ` Frank Li
2024-01-11 10:01   ` kernel test robot
2024-01-11 10:01     ` kernel test robot
2024-01-11 13:49   ` kernel test robot [this message]
2024-01-11 13:49     ` kernel test robot
2024-01-10 17:52 ` [PATCH v2 5/7] i3c: target: func: add tty driver Frank Li
2024-01-10 17:52   ` Frank Li
2024-01-10 17:52 ` [PATCH v2 6/7] i3c: add API i3c_dev_gettstatus_format1() to get target device status Frank Li
2024-01-10 17:52   ` Frank Li
2024-01-10 17:52 ` [PATCH v2 7/7] tty: i3c: add TTY over I3C master support Frank Li
2024-01-10 17:52   ` Frank Li

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=202401112149.TbWJpRfM-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=Frank.Li@nxp.com \
    --cc=alexandre.belloni@bootlin.com \
    --cc=conor.culhane@silvaco.com \
    --cc=devicetree@vger.kernel.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=imx@lists.linux.dev \
    --cc=jirislaby@kernel.org \
    --cc=joe@perches.com \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=krzysztof.kozlowski@linaro.org \
    --cc=linux-i3c@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=llvm@lists.linux.dev \
    --cc=miquel.raynal@bootlin.com \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=robh@kernel.org \
    --cc=zbigniew.lukwinski@linux.intel.com \
    /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.