All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: kbuild@lists.01.org
Subject: net/ceph/messenger_v1.c:403 prepare_write_connect() error: uninitialized symbol 'proto'.
Date: Tue, 26 Oct 2021 23:38:31 +0800	[thread overview]
Message-ID: <202110262328.Cb8Ple0S-lkp@intel.com> (raw)

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

CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Ilya Dryomov <idryomov@gmail.com>

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   3906fe9bb7f1a2c8667ae54e967dc8690824f4ea
commit: 2f713615ddd9d805b6c5e79c52e0e11af99d2bf1 libceph: move msgr1 protocol implementation to its own file
date:   11 months ago
:::::: branch date: 21 hours ago
:::::: commit date: 11 months ago
config: ia64-randconfig-m031-20211013 (attached as .config)
compiler: ia64-linux-gcc (GCC) 11.2.0

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

New smatch warnings:
net/ceph/messenger_v1.c:403 prepare_write_connect() error: uninitialized symbol 'proto'.

Old smatch warnings:
net/ceph/messenger_v1.c:1111 read_partial_message() error: we previously assumed 'con->in_msg' could be null (see line 1090)

vim +/proto +403 net/ceph/messenger_v1.c

2f713615ddd9d8 Ilya Dryomov 2020-11-12  374  
2f713615ddd9d8 Ilya Dryomov 2020-11-12  375  static int prepare_write_connect(struct ceph_connection *con)
2f713615ddd9d8 Ilya Dryomov 2020-11-12  376  {
2f713615ddd9d8 Ilya Dryomov 2020-11-12  377  	unsigned int global_seq = ceph_get_global_seq(con->msgr, 0);
2f713615ddd9d8 Ilya Dryomov 2020-11-12  378  	int proto;
2f713615ddd9d8 Ilya Dryomov 2020-11-12  379  	int ret;
2f713615ddd9d8 Ilya Dryomov 2020-11-12  380  
2f713615ddd9d8 Ilya Dryomov 2020-11-12  381  	switch (con->peer_name.type) {
2f713615ddd9d8 Ilya Dryomov 2020-11-12  382  	case CEPH_ENTITY_TYPE_MON:
2f713615ddd9d8 Ilya Dryomov 2020-11-12  383  		proto = CEPH_MONC_PROTOCOL;
2f713615ddd9d8 Ilya Dryomov 2020-11-12  384  		break;
2f713615ddd9d8 Ilya Dryomov 2020-11-12  385  	case CEPH_ENTITY_TYPE_OSD:
2f713615ddd9d8 Ilya Dryomov 2020-11-12  386  		proto = CEPH_OSDC_PROTOCOL;
2f713615ddd9d8 Ilya Dryomov 2020-11-12  387  		break;
2f713615ddd9d8 Ilya Dryomov 2020-11-12  388  	case CEPH_ENTITY_TYPE_MDS:
2f713615ddd9d8 Ilya Dryomov 2020-11-12  389  		proto = CEPH_MDSC_PROTOCOL;
2f713615ddd9d8 Ilya Dryomov 2020-11-12  390  		break;
2f713615ddd9d8 Ilya Dryomov 2020-11-12  391  	default:
2f713615ddd9d8 Ilya Dryomov 2020-11-12  392  		BUG();
2f713615ddd9d8 Ilya Dryomov 2020-11-12  393  	}
2f713615ddd9d8 Ilya Dryomov 2020-11-12  394  
2f713615ddd9d8 Ilya Dryomov 2020-11-12  395  	dout("prepare_write_connect %p cseq=%d gseq=%d proto=%d\n", con,
2f713615ddd9d8 Ilya Dryomov 2020-11-12  396  	     con->connect_seq, global_seq, proto);
2f713615ddd9d8 Ilya Dryomov 2020-11-12  397  
2f713615ddd9d8 Ilya Dryomov 2020-11-12  398  	con->out_connect.features =
2f713615ddd9d8 Ilya Dryomov 2020-11-12  399  	    cpu_to_le64(from_msgr(con->msgr)->supported_features);
2f713615ddd9d8 Ilya Dryomov 2020-11-12  400  	con->out_connect.host_type = cpu_to_le32(CEPH_ENTITY_TYPE_CLIENT);
2f713615ddd9d8 Ilya Dryomov 2020-11-12  401  	con->out_connect.connect_seq = cpu_to_le32(con->connect_seq);
2f713615ddd9d8 Ilya Dryomov 2020-11-12  402  	con->out_connect.global_seq = cpu_to_le32(global_seq);
2f713615ddd9d8 Ilya Dryomov 2020-11-12 @403  	con->out_connect.protocol_version = cpu_to_le32(proto);
2f713615ddd9d8 Ilya Dryomov 2020-11-12  404  	con->out_connect.flags = 0;
2f713615ddd9d8 Ilya Dryomov 2020-11-12  405  
2f713615ddd9d8 Ilya Dryomov 2020-11-12  406  	ret = get_connect_authorizer(con);
2f713615ddd9d8 Ilya Dryomov 2020-11-12  407  	if (ret)
2f713615ddd9d8 Ilya Dryomov 2020-11-12  408  		return ret;
2f713615ddd9d8 Ilya Dryomov 2020-11-12  409  
2f713615ddd9d8 Ilya Dryomov 2020-11-12  410  	__prepare_write_connect(con);
2f713615ddd9d8 Ilya Dryomov 2020-11-12  411  	return 0;
2f713615ddd9d8 Ilya Dryomov 2020-11-12  412  }
2f713615ddd9d8 Ilya Dryomov 2020-11-12  413  

---
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: 39277 bytes --]

             reply	other threads:[~2021-10-26 15:38 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-26 15:38 kernel test robot [this message]
  -- strict thread matches above, loose matches on Subject: below --
2021-11-25 18:33 net/ceph/messenger_v1.c:403 prepare_write_connect() error: uninitialized symbol 'proto' kernel test robot
2021-10-15  2:37 kernel test robot
2021-07-08 11:20 kernel test robot
2021-05-13 19:13 kernel test robot
2021-02-27 21:49 kernel test robot

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=202110262328.Cb8Ple0S-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kbuild@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.