All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: Re: [RFC PATCH 07/11] net: Introduce global queues
Date: Thu, 25 Jun 2020 07:58:14 +0800	[thread overview]
Message-ID: <202006250712.agVoufFI%lkp@intel.com> (raw)
In-Reply-To: <20200624171749.11927-8-tom@herbertland.com>

[-- Attachment #1: Type: text/plain, Size: 6204 bytes --]

Hi Tom,

[FYI, it's a private test report for your RFC patch.]
[auto build test WARNING on net/master]
[also build test WARNING on ipvs/master net-next/master linus/master v5.8-rc2 next-20200624]
[cannot apply to cgroup/for-next]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use  as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/Tom-Herbert/ptq-Per-Thread-Queues/20200625-012135
base:   https://git.kernel.org/pub/scm/linux/kernel/git/davem/net.git 0275875530f692c725c6f993aced2eca2d6ac50c
config: s390-randconfig-s031-20200624 (attached as .config)
compiler: s390-linux-gcc (GCC) 9.3.0
reproduce:
        # apt-get install sparse
        # sparse version: v0.6.2-dirty
        # save the attached .config to linux build tree
        make W=1 C=1 ARCH=s390 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__'

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>


sparse warnings: (new ones prefixed by >>)

>> net/core/net-sysfs.c:901:18: sparse: sparse: incompatible types in comparison expression (different address spaces):
   net/core/net-sysfs.c:901:18: sparse:    struct netdev_queue_map [noderef] <asn:4> *
>> net/core/net-sysfs.c:901:18: sparse:    struct netdev_queue_map *
   net/core/net-sysfs.c:915:33: sparse: sparse: incompatible types in comparison expression (different address spaces):
   net/core/net-sysfs.c:915:33: sparse:    struct netdev_queue_map [noderef] <asn:4> *
   net/core/net-sysfs.c:915:33: sparse:    struct netdev_queue_map *
   net/core/net-sysfs.c:976:17: sparse: sparse: incompatible types in comparison expression (different address spaces):
   net/core/net-sysfs.c:976:17: sparse:    struct netdev_queue_map [noderef] <asn:4> *
   net/core/net-sysfs.c:976:17: sparse:    struct netdev_queue_map *
   net/core/net-sysfs.c:1017:46: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected struct netdev_queue_map **pmap @@     got struct netdev_queue_map [noderef] <asn:4> ** @@
   net/core/net-sysfs.c:1050:40: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected struct netdev_queue_map **pmap @@     got struct netdev_queue_map [noderef] <asn:4> ** @@
   net/core/net-sysfs.c:1335:46: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected struct netdev_queue_map **pmap @@     got struct netdev_queue_map [noderef] <asn:4> ** @@
   net/core/net-sysfs.c:1693:40: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected struct netdev_queue_map **pmap @@     got struct netdev_queue_map [noderef] <asn:4> ** @@

vim +901 net/core/net-sysfs.c

   884	
   885	static int set_device_queue_mapping(struct netdev_queue_map **pmap,
   886					    u16 gqid, u16 dqid, u16 *p_gqid)
   887	{
   888		static DEFINE_MUTEX(global_mapping_table);
   889		struct netdev_queue_map *gq_map, *old_gq_map;
   890		u16 old_gqid;
   891		int ret = 0;
   892	
   893		mutex_lock(&global_mapping_table);
   894	
   895		old_gqid = *p_gqid;
   896		if (old_gqid == gqid) {
   897			/* Nothing changing */
   898			goto out;
   899		}
   900	
 > 901		gq_map = rcu_dereference_protected(*pmap,
   902						   lockdep_is_held(&global_mapping_table));
   903		old_gq_map = gq_map;
   904	
   905		if (gqid == NO_QUEUE) {
   906			/* Remove any old mapping (we know that old_gqid cannot be
   907			 * NO_QUEUE from above)
   908			 */
   909			if (!WARN_ON(!gq_map || old_gqid > gq_map->max_ents ||
   910				     gq_map->map[old_gqid] != dqid)) {
   911				/* Unset old mapping */
   912				gq_map->map[old_gqid] = NO_QUEUE;
   913				if (--gq_map->set_count == 0) {
   914					/* Done with map so free */
   915					rcu_assign_pointer(*pmap, NULL);
   916					call_rcu(&gq_map->rcu, queue_map_release);
   917				}
   918			}
   919			*p_gqid = NO_QUEUE;
   920	
   921			goto out;
   922		}
   923	
   924		if (!gq_map || gqid >= gq_map->max_ents) {
   925			unsigned int max_queues;
   926			int i = 0;
   927	
   928			/* Need to create or expand queue map */
   929	
   930			max_queues = QUEUE_MAP_ALLOC_NUMBER(gqid + 1);
   931	
   932			gq_map = vmalloc(QUEUE_MAP_ALLOC_SIZE(max_queues));
   933			if (!gq_map) {
   934				ret = -ENOMEM;
   935				goto out;
   936			}
   937	
   938			gq_map->max_ents = max_queues;
   939	
   940			if (old_gq_map) {
   941				/* Copy old map entries */
   942	
   943				memcpy(gq_map->map, old_gq_map->map,
   944				       old_gq_map->max_ents * sizeof(gq_map->map[0]));
   945				gq_map->set_count = old_gq_map->set_count;
   946				i = old_gq_map->max_ents;
   947			} else {
   948				gq_map->set_count = 0;
   949			}
   950	
   951			/* Initialize entries not copied from old map */
   952			for (; i < max_queues; i++)
   953				gq_map->map[i] = NO_QUEUE;
   954		} else if (gq_map->map[gqid] != NO_QUEUE) {
   955			/* The global qid is already mapped to another device qid */
   956			ret = -EBUSY;
   957			goto out;
   958		}
   959	
   960		/* Set map entry */
   961		gq_map->map[gqid] = dqid;
   962		gq_map->set_count++;
   963	
   964		if (old_gqid != NO_QUEUE) {
   965			/* We know old_gqid is not equal to gqid */
   966			if (!WARN_ON(!old_gq_map ||
   967				     old_gqid > old_gq_map->max_ents ||
   968				     old_gq_map->map[old_gqid] != dqid)) {
   969				/* Unset old mapping in (new) table */
   970				gq_map->map[old_gqid] = NO_QUEUE;
   971				gq_map->set_count--;
   972			}
   973		}
   974	
   975		if (gq_map != old_gq_map) {
   976			rcu_assign_pointer(*pmap, gq_map);
   977			if (old_gq_map)
   978				call_rcu(&old_gq_map->rcu, queue_map_release);
   979		}
   980	
   981		/* Save for caller */
   982		*p_gqid = gqid;
   983	
   984	out:
   985		mutex_unlock(&global_mapping_table);
   986	
   987		return ret;
   988	}
   989	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 19564 bytes --]

  parent reply	other threads:[~2020-06-24 23:58 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-24 17:17 [RFC PATCH 00/11] ptq: Per Thread Queues Tom Herbert
2020-06-24 17:17 ` [RFC PATCH 01/11] cgroup: Export cgroup_{procs,threads}_start and cgroup_procs_next Tom Herbert
2020-06-24 17:17 ` [RFC PATCH 02/11] net: Create netqueue.h and define NO_QUEUE Tom Herbert
2020-06-24 17:17 ` [RFC PATCH 03/11] arfs: Create set_arfs_queue Tom Herbert
2020-06-24 17:17 ` [RFC PATCH 04/11] net-sysfs: Create rps_create_sock_flow_table Tom Herbert
2020-06-24 17:17 ` [RFC PATCH 05/11] net: Infrastructure for per queue aRFS Tom Herbert
2020-06-28  8:55   ` kernel test robot
2020-06-24 17:17 ` [RFC PATCH 06/11] net: Function to check against maximum number for RPS queues Tom Herbert
2020-06-24 17:17 ` [RFC PATCH 07/11] net: Introduce global queues Tom Herbert
2020-06-24 23:00   ` kernel test robot
2020-06-24 23:58   ` kernel test robot [this message]
2020-06-25  0:23   ` kernel test robot
2020-06-30 21:06   ` Jonathan Lemon
2020-06-24 17:17 ` [RFC PATCH 08/11] ptq: Per Thread Queues Tom Herbert
2020-06-24 21:20   ` kernel test robot
2020-06-25  1:50   ` [RFC PATCH] ptq: null_pcdesc can be static kernel test robot
2020-06-25  7:26   ` [RFC PATCH 08/11] ptq: Per Thread Queues kernel test robot
2020-06-24 17:17 ` [RFC PATCH 09/11] ptq: Hook up transmit side of Per Queue Threads Tom Herbert
2020-06-24 17:17 ` [RFC PATCH 10/11] ptq: Hook up receive " Tom Herbert
2020-06-24 17:17 ` [RFC PATCH 11/11] doc: Documentation for Per Thread Queues Tom Herbert
2020-06-25  2:20   ` kernel test robot
2020-06-25 23:00   ` Jacob Keller
2020-06-29  6:28   ` Saeed Mahameed
2020-06-29 15:10     ` Tom Herbert

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=202006250712.agVoufFI%lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kbuild-all@lists.01.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.