mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Pavel Begunkov <asml.silence@gmail.com>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org
Subject: [isilence:zc_v3 24/28] io_uring/net.c:862:41: warning: cast from pointer to integer of different size
Date: Tue, 28 Jun 2022 02:16:25 +0800	[thread overview]
Message-ID: <202206280255.6yEuIf06-lkp@intel.com> (raw)

tree:   https://github.com/isilence/linux zc_v3
head:   cd0bc816ae8dbc546df5c09cee92459ad759c4d1
commit: d9672980cdc25db17837152a58f2fea95c2c8e99 [24/28] io_uring: sendzc with fixed buffers
config: um-i386_defconfig (https://download.01.org/0day-ci/archive/20220628/202206280255.6yEuIf06-lkp@intel.com/config)
compiler: gcc-11 (Debian 11.3.0-3) 11.3.0
reproduce (this is a W=1 build):
        # https://github.com/isilence/linux/commit/d9672980cdc25db17837152a58f2fea95c2c8e99
        git remote add isilence https://github.com/isilence/linux
        git fetch --no-tags isilence zc_v3
        git checkout d9672980cdc25db17837152a58f2fea95c2c8e99
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        make W=1 O=build_dir ARCH=um SUBARCH=i386 SHELL=/bin/bash

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 >>):

   io_uring/net.c: In function 'io_sendzc':
>> io_uring/net.c:862:41: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
     862 |                                         (u64)zc->buf, zc->len);
         |                                         ^


vim +862 io_uring/net.c

   827	
   828	int io_sendzc(struct io_kiocb *req, unsigned int issue_flags)
   829	{
   830		struct sockaddr_storage address;
   831		struct io_ring_ctx *ctx = req->ctx;
   832		struct io_sendzc *zc = io_kiocb_to_cmd(req);
   833		struct io_notif_slot *notif_slot;
   834		struct io_notif *notif;
   835		struct msghdr msg;
   836		struct iovec iov;
   837		struct socket *sock;
   838		unsigned msg_flags;
   839		int ret, min_ret = 0;
   840	
   841		if (issue_flags & IO_URING_F_UNLOCKED)
   842			return -EAGAIN;
   843		sock = sock_from_file(req->file);
   844		if (unlikely(!sock))
   845			return -ENOTSOCK;
   846	
   847		notif_slot = io_get_notif_slot(ctx, zc->slot_idx);
   848		if (!notif_slot)
   849			return -EINVAL;
   850		notif = io_get_notif(ctx, notif_slot);
   851		if (!notif)
   852			return -ENOMEM;
   853	
   854		msg.msg_name = NULL;
   855		msg.msg_control = NULL;
   856		msg.msg_controllen = 0;
   857		msg.msg_namelen = 0;
   858		msg.msg_managed_data = 1;
   859	
   860		if (zc->zc_flags & IORING_SENDZC_FIXED_BUF) {
   861			ret = io_import_fixed(WRITE, &msg.msg_iter, req->imu,
 > 862						(u64)zc->buf, zc->len);

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

                 reply	other threads:[~2022-06-27 18:16 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=202206280255.6yEuIf06-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=asml.silence@gmail.com \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-kernel@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®