DPDK patches and discussions
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas.monjalon@6wind.com>
To: Rahul Lakkireddy <rahul.lakkireddy@chelsio.com>
Cc: dev@dpdk.org, Felix Marti <felix@chelsio.com>,
	Nirranjan Kirubaharan <nirranjan@chelsio.com>,
	Kumar Sanghvi <kumaras@chelsio.com>
Subject: Re: [dpdk-dev] [PATCH v3] vfio: Fix overflow while assigning vfio BAR region offset and size
Date: Tue, 14 Jul 2015 10:56:35 +0200	[thread overview]
Message-ID: <2812850.KVDAfLqkr9@xps13> (raw)
In-Reply-To: <b5f3fef8563eab3e0120dfdf3b7a5026a7654b84.1436773804.git.rahul.lakkireddy@chelsio.com>

2015-07-13 14:21, Rahul Lakkireddy:
> When using vfio, the probe fails for BAR > 0 after the
> commit-id 90a1633b2 (eal/linux: allow to map BARs with MSI-X tables).
> 
> While debugging further, found that the BAR region offset and size read from
> vfio are u64, but are assigned to uint32_t variables.  This results in the u64
> value getting truncated to 0 and passing wrong offset and size to mmap for
> subsequent BAR regions.
> 
> The fix is to use unsigned long for the offset and size.
> 
> This is based on patch by Alejandro Lucero <alejandro.lucero@netronome.com>
> posted at below:
> 
> http://dpdk.org/ml/archives/dev/2015-June/020201.html
> 
> and updated with diff from below to fix 32-bit compilation:
> 
> http://dpdk.org/ml/archives/dev/2015-July/020963.html
> 
> Fixes: 90a1633b2347 ("eal/linux: allow to map BARs with MSI-X tables")
> Signed-off-by: Rahul Lakkireddy <rahul.lakkireddy@chelsio.com>
> Signed-off-by: Kumar Sanghvi <kumaras@chelsio.com>

Applied, thanks

      reply	other threads:[~2015-07-14  8:57 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-16 14:16 [dpdk-dev] [PATCH] " Rahul Lakkireddy
2015-06-17 12:09 ` Thomas Monjalon
2015-06-18 14:23   ` Rahul Lakkireddy
2015-06-23 15:00 ` [dpdk-dev] [PATCH v2] " Rahul Lakkireddy
2015-06-30 21:12   ` Thomas Monjalon
2015-07-01  8:34     ` Alejandro Lucero
2015-07-01 10:00       ` Burakov, Anatoly
2015-07-06 15:45         ` Alejandro Lucero
2015-07-07  7:56           ` Rahul Lakkireddy
2015-07-07  9:08           ` Burakov, Anatoly
2015-07-07 10:40             ` Rahul Lakkireddy
2015-07-07 10:50               ` Burakov, Anatoly
2015-07-10  9:54                 ` Rahul Lakkireddy
2015-07-10 17:27                   ` Alejandro Lucero
2015-07-13  8:51   ` [dpdk-dev] [PATCH v3] " Rahul Lakkireddy
2015-07-14  8:56     ` Thomas Monjalon [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=2812850.KVDAfLqkr9@xps13 \
    --to=thomas.monjalon@6wind.com \
    --cc=dev@dpdk.org \
    --cc=felix@chelsio.com \
    --cc=kumaras@chelsio.com \
    --cc=nirranjan@chelsio.com \
    --cc=rahul.lakkireddy@chelsio.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;
as well as URLs for NNTP newsgroup(s).