lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Thu, 10 Nov 2016 19:38:41 +0000
From:   "Alex Ng (LIS)" <alexng@...rosoft.com>
To:     Dan Carpenter <dan.carpenter@...cle.com>,
        KY Srinivasan <kys@...rosoft.com>
CC:     "gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "devel@...uxdriverproject.org" <devel@...uxdriverproject.org>,
        "olaf@...fle.de" <olaf@...fle.de>,
        "apw@...onical.com" <apw@...onical.com>,
        "vkuznets@...hat.com" <vkuznets@...hat.com>,
        "jasowang@...hat.com" <jasowang@...hat.com>,
        "leann.ogasawara@...onical.com" <leann.ogasawara@...onical.com>,
        Stephen Hemminger <sthemmin@...rosoft.com>
Subject: RE: [PATCH V2 08/14] Drivers: hv: balloon: Fix info request to show
 max page count

> -----Original Message-----
> From: Dan Carpenter [mailto:dan.carpenter@...cle.com]
> Sent: Thursday, November 10, 2016 11:09 AM
> To: KY Srinivasan <kys@...rosoft.com>
> Cc: gregkh@...uxfoundation.org; linux-kernel@...r.kernel.org;
> devel@...uxdriverproject.org; olaf@...fle.de; apw@...onical.com;
> vkuznets@...hat.com; jasowang@...hat.com;
> leann.ogasawara@...onical.com; Stephen Hemminger
> <sthemmin@...rosoft.com>; Alex Ng (LIS) <alexng@...rosoft.com>; Alex
> Ng (LIS) <alexng@...rosoft.com>
> Subject: Re: [PATCH V2 08/14] Drivers: hv: balloon: Fix info request to show
> max page count
> 
> On Tue, Nov 01, 2016 at 01:07:28PM -0700, kys@...hange.microsoft.com
> wrote:
> > From: Alex Ng <alexng@...sages.microsoft.com>
> >
> > Balloon driver was only printing the size of the info blob and not the
> > actual content. This fixes it so that the info blob (max page count as
> > configured in Hyper-V) is printed out.
> >
> > Signed-off-by: Alex Ng <alexng@...rosoft.com>
> > Signed-off-by: K. Y. Srinivasan <kys@...rosoft.com>
> > ---
> >  drivers/hv/hv_balloon.c |    9 +++++++--
> >  1 files changed, 7 insertions(+), 2 deletions(-)
> >
> > diff --git a/drivers/hv/hv_balloon.c b/drivers/hv/hv_balloon.c
> > index 8cac29a..14c3dc4 100644
> > --- a/drivers/hv/hv_balloon.c
> > +++ b/drivers/hv/hv_balloon.c
> > @@ -1034,8 +1034,13 @@ static void process_info(struct
> hv_dynmem_device *dm, struct dm_info_msg *msg)
> >
> >  	switch (info_hdr->type) {
> >  	case INFO_TYPE_MAX_PAGE_CNT:
> > -		pr_info("Received INFO_TYPE_MAX_PAGE_CNT\n");
> > -		pr_info("Data Size is %d\n", info_hdr->data_size);
> > +		if (info_hdr->data_size == sizeof(__u64)) {
> > +			__u64 *max_page_count = (__u64 *)&info_hdr[1];
> 
> Why __u64 instead of u64?  Is this code shared with user space?

__u64 was being used in other parts of this code already and I decided to follow that.

I wasn't aware of this distinction between the two.
This code is not shared in user-space, so perhaps we should clean up this file in a future patch.

Thanks for bringing it up.

> 
> regards,
> dan carpenter
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ