From: Haiyang Zhang <haiyangz@microsoft.com>
To: David Miller <davem@davemloft.net>
Cc: "netdev@vger.kernel.org" <netdev@vger.kernel.org>,
KY Srinivasan <kys@microsoft.com>,
"olaf@aepfle.de" <olaf@aepfle.de>,
"jasowang@redhat.com" <jasowang@redhat.com>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"devel@linuxdriverproject.org" <devel@linuxdriverproject.org>
Subject: RE: [PATCH net-next] hyperv: Fix a compiler warning in netvsc_send()
Date: Mon, 29 Apr 2013 18:30:53 +0000 [thread overview]
Message-ID: <2bef79e083dd4b14adc5e6d3549f8a05@DFM-DB3MBX15-06.exchange.corp.microsoft.com> (raw)
In-Reply-To: <20130429.140932.1477434738582260564.davem@davemloft.net>
> -----Original Message-----
> From: David Miller [mailto:davem@davemloft.net]
> Sent: Monday, April 29, 2013 2:10 PM
> To: Haiyang Zhang
> Cc: netdev@vger.kernel.org; KY Srinivasan; olaf@aepfle.de;
> jasowang@redhat.com; linux-kernel@vger.kernel.org;
> devel@linuxdriverproject.org
> Subject: Re: [PATCH net-next] hyperv: Fix a compiler warning in
> netvsc_send()
>
> From: Haiyang Zhang <haiyangz@microsoft.com>
> Date: Fri, 26 Apr 2013 11:25:55 -0700
>
> > Fixed: warning: cast from pointer to integer of different size
> >
> > The Hyper-V hosts always use 64 bit request id. The guests can have 32
> > or 64 bit pointers which equal to the ulong type size. So we cast it to ulong
> type.
> > And, assigning 32bit integer to 64 bit variable works fine.
> >
> > The VMBus returns the same id in the completion packet. But the value
> > has no effect on the host side.
> >
> > Reported-by: kbuild test robot <fengguang.wu@intel.com>
> > Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
> > Reviewed-by: K. Y. Srinivasan <kys@microsoft.com>
>
> Applied, but:
>
> > - req_id = (u64)packet;
> > + req_id = (ulong)packet;
>
> I really do not like these shorthands for fundamental C types, we generally
> do not use "ulong", "uint" etc. Please expand them out explicitly to
> "unsigned long", "unsigned int", etc.
Thanks for applying it.
Going forward, I will use the long format, like "unsigned long", instead of "ulong", etc.
Thanks,
- Haiyang
prev parent reply other threads:[~2013-04-29 18:31 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-26 18:25 Haiyang Zhang
2013-04-29 18:09 ` David Miller
2013-04-29 18:30 ` Haiyang Zhang [this message]
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=2bef79e083dd4b14adc5e6d3549f8a05@DFM-DB3MBX15-06.exchange.corp.microsoft.com \
--to=haiyangz@microsoft.com \
--cc=davem@davemloft.net \
--cc=devel@linuxdriverproject.org \
--cc=jasowang@redhat.com \
--cc=kys@microsoft.com \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=olaf@aepfle.de \
/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®