patches for DPDK stable branches
 help / color / mirror / Atom feed
From: "Burakov, Anatoly" <anatoly.burakov@intel.com>
To: Phil Yang <Phil.Yang@arm.com>, "dev@dpdk.org" <dev@dpdk.org>
Cc: "radoslaw.biernacki@linaro.org" <radoslaw.biernacki@linaro.org>,
	"stable@dpdk.org" <stable@dpdk.org>, nd <nd@arm.com>
Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH 2/2] test/memzone: handle previously allocated memzones
Date: Wed, 31 Jan 2018 10:05:01 +0000	[thread overview]
Message-ID: <1a235b6f-b465-ef04-c941-02b038ac75d5@intel.com> (raw)
In-Reply-To: <AM4PR08MB0913B5E0FEE6D4EE9E968459E9FB0@AM4PR08MB0913.eurprd08.prod.outlook.com>

On 31-Jan-18 7:51 AM, Phil Yang wrote:
> Hi Anatoly,
> 
> I think your fix is elegant, however you can't grantee it doesn't have dirty memzone remained after memzone autotest.
> What if some existed initial memzone released during the test and some dirty memzone remained. The counter cannot illustrate this state.
> 
> My fix just care about the memzone used in memzone autotest. It is rough but it seems more reliable. 😊
> 
> Thanks,
> Phil Yang

We could combine the approaches. That way, we both ensure that no 
memzones were left in that should've been freed, and that total number 
of memzones didn't change as well (i.e. we didn't allocate/free any 
memzones we weren't supposed to allocate/free).

As i side note, i think making a #define with memzone prefix in your 
patch will work better and will be less copypaste-error-prone in the 
long run.

I will prepare a v2 combining both approaches. Is that OK with you?

> 
>> -----Original Message-----
>> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Anatoly Burakov
>> Sent: Saturday, January 27, 2018 1:41 AM
>> To: dev@dpdk.org
>> Cc: radoslaw.biernacki@linaro.org; stable@dpdk.org
>> Subject: [dpdk-dev] [PATCH 2/2] test/memzone: handle previously allocated
>> memzones
>>
>> Currently, memzone autotest expects there to be no memzones present by the
>> time the test is run. Some hardware drivers will allocate memzones for internal
>> use during initialization, resulting in tests failing due to unexpected memzones
>> being allocated before the test was run.
>>
>> Fix this by making callback increment a counter instead. This also doubles as a
>> test for correct operation of memzone_walk().
>>
>> Fixes: 71330483a193 ("test/memzone: fix memory leak")
>> Cc: radoslaw.biernacki@linaro.org
>> Cc: stable@dpdk.org
>>
>> Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>


-- 
Thanks,
Anatoly

  reply	other threads:[~2018-01-31 10:05 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <eb34fe4a841eb19d62523226160b7687bb122fba.1517480079.git.anatoly.burakov@intel.com>
     [not found] ` <dde08b05fd05dfa36350f73b19fb5cf9e5862ce9.1517479347.git.anatoly.burakov@intel.com>
     [not found]   ` <dde08b05fd05dfa36350f73b19fb5cf9e5862ce9.1517412012.git.anatoly.burakov@intel.com>
     [not found]     ` <ec8bf2436653ce9dbbe9e83a364ca44c41bd2a8a.1516988093.git.anatoly.burakov@intel.com>
2018-01-26 17:40       ` [dpdk-stable] " Anatoly Burakov
2018-01-27 14:46         ` Radoslaw Biernacki
2018-01-31  7:51         ` [dpdk-stable] [dpdk-dev] " Phil Yang
2018-01-31 10:05           ` Burakov, Anatoly [this message]
2018-01-31 10:08             ` Phil Yang
2018-01-31 15:29       ` [dpdk-stable] [PATCH v2 " Anatoly Burakov
2018-02-01 10:02     ` [dpdk-stable] [PATCH v3 " Anatoly Burakov
2018-02-01 10:14   ` [dpdk-stable] [PATCH v4 " Anatoly Burakov

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=1a235b6f-b465-ef04-c941-02b038ac75d5@intel.com \
    --to=anatoly.burakov@intel.com \
    --cc=Phil.Yang@arm.com \
    --cc=dev@dpdk.org \
    --cc=nd@arm.com \
    --cc=radoslaw.biernacki@linaro.org \
    --cc=stable@dpdk.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;
as well as URLs for NNTP newsgroup(s).