From: kernel test robot <lkp@intel.com>
To: Enzo Matsumiya <ematsumiya@suse.de>, linux-cifs@vger.kernel.org
Cc: llvm@lists.linux.dev, kbuild-all@lists.01.org,
smfrench@gmail.com, pc@cjr.nz, ronniesahlberg@gmail.com,
nspmangalore@gmail.com
Subject: Re: [PATCH] cifs: remove some more dead code
Date: Sun, 24 Jul 2022 06:51:00 +0800 [thread overview]
Message-ID: <202207240645.7IYWNiqd-lkp@intel.com> (raw)
In-Reply-To: <20220723205901.16678-1-ematsumiya@suse.de>
Hi Enzo,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on cifs/for-next]
[also build test WARNING on linus/master v5.19-rc7 next-20220722]
[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/Enzo-Matsumiya/cifs-remove-some-more-dead-code/20220724-050054
base: git://git.samba.org/sfrench/cifs-2.6.git for-next
config: i386-randconfig-a006 (https://download.01.org/0day-ci/archive/20220724/202207240645.7IYWNiqd-lkp@intel.com/config)
compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project 12fbd2d377e396ad61bce56d71c98a1eb1bebfa9)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/intel-lab-lkp/linux/commit/6e3f3b9d1abb0ac9a6b161af9ac835d32eed006f
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Enzo-Matsumiya/cifs-remove-some-more-dead-code/20220724-050054
git checkout 6e3f3b9d1abb0ac9a6b161af9ac835d32eed006f
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=i386 SHELL=/bin/bash fs/cifs/
If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@intel.com>
All warnings (new ones prefixed by >>):
>> fs/cifs/connect.c:2739:24: warning: variable 'saddr4' set but not used [-Wunused-but-set-variable]
struct sockaddr_in *saddr4;
^
1 warning generated.
--
>> fs/cifs/misc.c:366:9: warning: unused variable 'mid' [-Wunused-variable]
__u16 mid = get_mid(smb);
^
>> fs/cifs/misc.c:413:35: warning: variable 'pnotify' set but not used [-Wunused-but-set-variable]
struct file_notify_information *pnotify;
^
>> fs/cifs/misc.c:520:21: warning: variable 'tcon' set but not used [-Wunused-but-set-variable]
struct cifs_tcon *tcon = NULL;
^
3 warnings generated.
--
>> fs/cifs/sess.c:364:22: warning: unused variable 'ipv4' [-Wunused-variable]
struct sockaddr_in *ipv4 = (struct sockaddr_in *)&iface->sockaddr;
^
>> fs/cifs/sess.c:365:23: warning: unused variable 'ipv6' [-Wunused-variable]
struct sockaddr_in6 *ipv6 = (struct sockaddr_in6 *)&iface->sockaddr;
^
2 warnings generated.
--
>> fs/cifs/smb2misc.c:512:6: warning: variable 'rc' set but not used [-Wunused-but-set-variable]
int rc = 0;
^
>> fs/cifs/smb2misc.c:812:27: warning: variable 'server' set but not used [-Wunused-but-set-variable]
struct TCP_Server_Info *server = NULL;
^
2 warnings generated.
--
>> fs/cifs/cifs_swn.c:261:7: warning: variable 'ret' set but not used [-Wunused-but-set-variable]
int ret;
^
fs/cifs/cifs_swn.c:271:7: warning: variable 'ret' set but not used [-Wunused-but-set-variable]
int ret;
^
>> fs/cifs/cifs_swn.c:511:22: warning: unused variable 'ipv4' [-Wunused-variable]
struct sockaddr_in *ipv4 = (struct sockaddr_in *)addr;
^
>> fs/cifs/cifs_swn.c:512:23: warning: unused variable 'ipv6' [-Wunused-variable]
struct sockaddr_in6 *ipv6 = (struct sockaddr_in6 *)addr;
^
4 warnings generated.
--
>> fs/cifs/sess.c:365:23: warning: unused variable 'ipv6' [-Wunused-variable]
struct sockaddr_in6 *ipv6 = (struct sockaddr_in6 *)&iface->sockaddr;
^
>> fs/cifs/sess.c:364:22: warning: unused variable 'ipv4' [-Wunused-variable]
struct sockaddr_in *ipv4 = (struct sockaddr_in *)&iface->sockaddr;
^
2 warnings generated.
vim +/saddr4 +2739 fs/cifs/connect.c
^1da177e4c3f41 Linus Torvalds 2005-04-16 2727
3eb9a8893a76cf Ben Greear 2010-09-01 2728 static int
3eb9a8893a76cf Ben Greear 2010-09-01 2729 bind_socket(struct TCP_Server_Info *server)
3eb9a8893a76cf Ben Greear 2010-09-01 2730 {
3eb9a8893a76cf Ben Greear 2010-09-01 2731 int rc = 0;
3eb9a8893a76cf Ben Greear 2010-09-01 2732 if (server->srcaddr.ss_family != AF_UNSPEC) {
3eb9a8893a76cf Ben Greear 2010-09-01 2733 /* Bind to the specified local IP address */
3eb9a8893a76cf Ben Greear 2010-09-01 2734 struct socket *socket = server->ssocket;
3eb9a8893a76cf Ben Greear 2010-09-01 2735 rc = socket->ops->bind(socket,
3eb9a8893a76cf Ben Greear 2010-09-01 2736 (struct sockaddr *) &server->srcaddr,
3eb9a8893a76cf Ben Greear 2010-09-01 2737 sizeof(server->srcaddr));
3eb9a8893a76cf Ben Greear 2010-09-01 2738 if (rc < 0) {
3eb9a8893a76cf Ben Greear 2010-09-01 @2739 struct sockaddr_in *saddr4;
3eb9a8893a76cf Ben Greear 2010-09-01 2740 struct sockaddr_in6 *saddr6;
3eb9a8893a76cf Ben Greear 2010-09-01 2741 saddr4 = (struct sockaddr_in *)&server->srcaddr;
3eb9a8893a76cf Ben Greear 2010-09-01 2742 saddr6 = (struct sockaddr_in6 *)&server->srcaddr;
3eb9a8893a76cf Ben Greear 2010-09-01 2743 if (saddr6->sin6_family == AF_INET6)
afe6f65353b644 Ronnie Sahlberg 2019-08-28 2744 cifs_server_dbg(VFS, "Failed to bind to: %pI6c, error: %d\n",
3eb9a8893a76cf Ben Greear 2010-09-01 2745 &saddr6->sin6_addr, rc);
3eb9a8893a76cf Ben Greear 2010-09-01 2746 else
afe6f65353b644 Ronnie Sahlberg 2019-08-28 2747 cifs_server_dbg(VFS, "Failed to bind to: %pI4, error: %d\n",
3eb9a8893a76cf Ben Greear 2010-09-01 2748 &saddr4->sin_addr.s_addr, rc);
3eb9a8893a76cf Ben Greear 2010-09-01 2749 }
3eb9a8893a76cf Ben Greear 2010-09-01 2750 }
3eb9a8893a76cf Ben Greear 2010-09-01 2751 return rc;
3eb9a8893a76cf Ben Greear 2010-09-01 2752 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 2753
--
0-DAY CI Kernel Test Service
https://01.org/lkp
next prev parent reply other threads:[~2022-07-23 22:52 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-23 20:59 [PATCH] cifs: remove some more dead code Enzo Matsumiya
2022-07-23 22:51 ` kernel test robot [this message]
2022-07-23 22:51 ` 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=202207240645.7IYWNiqd-lkp@intel.com \
--to=lkp@intel.com \
--cc=ematsumiya@suse.de \
--cc=kbuild-all@lists.01.org \
--cc=linux-cifs@vger.kernel.org \
--cc=llvm@lists.linux.dev \
--cc=nspmangalore@gmail.com \
--cc=pc@cjr.nz \
--cc=ronniesahlberg@gmail.com \
--cc=smfrench@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox