[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202509031942.reUez3UI-lkp@intel.com>
Date: Wed, 3 Sep 2025 20:05:03 +0800
From: kernel test robot <lkp@...el.com>
To: MD Danish Anwar <danishanwar@...com>,
Andrew Lunn <andrew+netdev@...n.ch>,
"David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
Rob Herring <robh@...nel.org>,
Krzysztof Kozlowski <krzk@...nel.org>,
Conor Dooley <conor+dt@...nel.org>,
Bjorn Andersson <andersson@...nel.org>,
Mathieu Poirier <mathieu.poirier@...aro.org>,
Simon Horman <horms@...nel.org>, Jonathan Corbet <corbet@....net>,
Nishanth Menon <nm@...com>, Vignesh Raghavendra <vigneshr@...com>,
Mengyuan Lou <mengyuanlou@...-swift.com>,
Xin Guo <guoxin09@...wei.com>, Lei Wei <quic_leiwei@...cinc.com>,
Lee Trager <lee@...ger.us>, Michael Ellerman <mpe@...erman.id.au>,
Fan Gong <gongfan1@...wei.com>,
Lorenzo Bianconi <lorenzo@...nel.org>,
Geert Uytterhoeven <geert+renesas@...der.be>,
Lukas Bulwahn <lukas.bulwahn@...hat.com>,
Parthiban Veerasooran <Parthiban.Veerasooran@...rochip.com>,
Suman Anna <s-anna@...com>
Cc: oe-kbuild-all@...ts.linux.dev, netdev@...r.kernel.org,
Tero Kristo <kristo@...nel.org>, devicetree@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH net-next v2 5/8] net: rpmsg-eth: Register device as netdev
Hi MD,
kernel test robot noticed the following build warnings:
[auto build test WARNING on 2fd4161d0d2547650d9559d57fc67b4e0a26a9e3]
url: https://github.com/intel-lab-lkp/linux/commits/MD-Danish-Anwar/dt-bindings-net-ti-rpmsg-eth-Add-DT-binding-for-RPMSG-ETH/20250902-171411
base: 2fd4161d0d2547650d9559d57fc67b4e0a26a9e3
patch link: https://lore.kernel.org/r/20250902090746.3221225-6-danishanwar%40ti.com
patch subject: [PATCH net-next v2 5/8] net: rpmsg-eth: Register device as netdev
config: m68k-allyesconfig (https://download.01.org/0day-ci/archive/20250903/202509031942.reUez3UI-lkp@intel.com/config)
compiler: m68k-linux-gcc (GCC) 15.1.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250903/202509031942.reUez3UI-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@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202509031942.reUez3UI-lkp@intel.com/
All warnings (new ones prefixed by >>):
In file included from include/linux/device.h:15,
from include/linux/of_reserved_mem.h:5,
from drivers/net/ethernet/rpmsg_eth.c:8:
drivers/net/ethernet/rpmsg_eth.c: In function 'rpmsg_eth_validate_handshake':
>> drivers/net/ethernet/rpmsg_eth.c:26:44: warning: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'unsigned int' [-Wformat=]
26 | dev_err(port->common->dev, "Buffer configuration mismatch in handshake: expected_buf_size=%lu, received_buf_size=%d\n",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/dev_printk.h:110:30: note: in definition of macro 'dev_printk_index_wrap'
110 | _p_func(dev, fmt, ##__VA_ARGS__); \
| ^~~
include/linux/dev_printk.h:154:56: note: in expansion of macro 'dev_fmt'
154 | dev_printk_index_wrap(_dev_err, KERN_ERR, dev, dev_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~
drivers/net/ethernet/rpmsg_eth.c:26:17: note: in expansion of macro 'dev_err'
26 | dev_err(port->common->dev, "Buffer configuration mismatch in handshake: expected_buf_size=%lu, received_buf_size=%d\n",
| ^~~~~~~
drivers/net/ethernet/rpmsg_eth.c:26:109: note: format string is defined here
26 | dev_err(port->common->dev, "Buffer configuration mismatch in handshake: expected_buf_size=%lu, received_buf_size=%d\n",
| ~~^
| |
| long unsigned int
| %u
>> drivers/net/ethernet/rpmsg_eth.c:42:44: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 5 has type 'phys_addr_t' {aka 'unsigned int'} [-Wformat=]
42 | dev_err(port->common->dev, "TX/RX offset out of range in handshake: tx_offset=0x%x, rx_offset=0x%x, size=0x%llx\n",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/dev_printk.h:110:30: note: in definition of macro 'dev_printk_index_wrap'
110 | _p_func(dev, fmt, ##__VA_ARGS__); \
| ^~~
include/linux/dev_printk.h:154:56: note: in expansion of macro 'dev_fmt'
154 | dev_printk_index_wrap(_dev_err, KERN_ERR, dev, dev_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~
drivers/net/ethernet/rpmsg_eth.c:42:17: note: in expansion of macro 'dev_err'
42 | dev_err(port->common->dev, "TX/RX offset out of range in handshake: tx_offset=0x%x, rx_offset=0x%x, size=0x%llx\n",
| ^~~~~~~
drivers/net/ethernet/rpmsg_eth.c:42:127: note: format string is defined here
42 | dev_err(port->common->dev, "TX/RX offset out of range in handshake: tx_offset=0x%x, rx_offset=0x%x, size=0x%llx\n",
| ~~~^
| |
| long long unsigned int
| %x
vim +26 drivers/net/ethernet/rpmsg_eth.c
> 8 #include <linux/of_reserved_mem.h>
9 #include <linux/remoteproc.h>
10 #include "rpmsg_eth.h"
11
12 /**
13 * rpmsg_eth_validate_handshake - Validate handshake parameters from remote
14 * @port: Pointer to rpmsg_eth_port structure
15 * @shm_info: Pointer to shared memory info received from remote
16 *
17 * Checks buffer size, magic numbers, and TX/RX offsets in the handshake
18 * response to ensure they match expected values and are within valid ranges.
19 *
20 * Return: 0 on success, -EINVAL on validation failure.
21 */
22 static int rpmsg_eth_validate_handshake(struct rpmsg_eth_port *port,
23 struct rpmsg_eth_shm *shm_info)
24 {
25 if (shm_info->buff_slot_size != RPMSG_ETH_BUFFER_SIZE) {
> 26 dev_err(port->common->dev, "Buffer configuration mismatch in handshake: expected_buf_size=%lu, received_buf_size=%d\n",
27 RPMSG_ETH_BUFFER_SIZE,
28 shm_info->buff_slot_size);
29 return -EINVAL;
30 }
31
32 if (readl(port->shm + port->tx_offset + HEAD_MAGIC_NUM_OFFSET) != RPMSG_ETH_SHM_MAGIC_NUM ||
33 readl(port->shm + port->rx_offset + HEAD_MAGIC_NUM_OFFSET) != RPMSG_ETH_SHM_MAGIC_NUM ||
34 readl(port->shm + port->tx_offset + TAIL_MAGIC_NUM_OFFSET(port->tx_max_buffers)) != RPMSG_ETH_SHM_MAGIC_NUM ||
35 readl(port->shm + port->rx_offset + TAIL_MAGIC_NUM_OFFSET(port->rx_max_buffers)) != RPMSG_ETH_SHM_MAGIC_NUM) {
36 dev_err(port->common->dev, "Magic number mismatch in handshake at head/tail\n");
37 return -EINVAL;
38 }
39
40 if (shm_info->tx_offset >= port->buf_size ||
41 shm_info->rx_offset >= port->buf_size) {
> 42 dev_err(port->common->dev, "TX/RX offset out of range in handshake: tx_offset=0x%x, rx_offset=0x%x, size=0x%llx\n",
43 shm_info->tx_offset,
44 shm_info->rx_offset,
45 port->buf_size);
46 return -EINVAL;
47 }
48
49 return 0;
50 }
51
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Powered by blists - more mailing lists