From: Cui Bixuan <cuibixuan@huawei.com>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH] max_map_count: fix error by using runtime check
Date: Tue, 5 Apr 2016 19:47:18 +0800 [thread overview]
Message-ID: <5703A5C6.3000102@huawei.com> (raw)
In-Reply-To: <20160331120726.GB21298@rei.lan>
On 2016/3/31 20:07, Cyril Hrubis wrote:
> Hi!
>> Can we relax the pass condition to allow map_count to be
>> within some tolerance? Then we wouldn't have to worry so much about
>> all arch specifics.
>
> Looking at the code we skip exactly one mapping on some architectures.
> So it looks like allowing the number of mappings to be greater by one
> uncoditionally should solve the problem.
>
> But I'm still undecided if we should go this way as we will weaken the
> test assertion since at the moment we skip exact mappings by their
> label.
I have two ideas:
1. Use strcmp() to replace the strstr() and to check x86_64,x86,ia64,armv7b
and so on.
2. Now we only find the problem in aarch64, we just fix it:
#elif defined(__arm__)
/* Skip it when run it in aarch64 */
if(strcmp(un.machine, "aarch64"))
return false;
/* Older arm kernels didn't label their vdso maps */
if (!strncmp(line, "ffff0000-ffff1000", 17))
return true;
And I think the second is better :-D
Thanks
Cui Bixuan
>
next prev parent reply other threads:[~2016-04-05 11:47 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-07 11:08 [LTP] max_map_count fail in arm64 system which support lib32 Cui Bixuan
2016-03-22 10:29 ` Cyril Hrubis
2016-03-22 13:49 ` Cui Bixuan
2016-03-22 14:28 ` Cyril Hrubis
2016-03-23 8:53 ` [LTP] [PATCH] max_map_count: fix error by using runtime check Cui Bixuan
2016-03-23 10:22 ` Jan Stancek
2016-03-23 11:59 ` Cui Bixuan
2016-03-31 12:07 ` Cyril Hrubis
2016-04-05 11:47 ` Cui Bixuan [this message]
2016-04-11 17:03 ` Cyril Hrubis
2016-04-12 7:15 ` [LTP] [PATCH v2] " Cui Bixuan
2016-04-12 13:07 ` Cyril Hrubis
2016-03-23 9:00 ` [LTP] max_map_count fail in arm64 system which support lib32 Cui Bixuan
2016-12-16 8:25 ` [LTP] [PATCH] max_map_count: fix a mistake and support it for aarch64_be Cui Bixuan
2016-12-16 10:15 ` [LTP] we can ignore it and discuss the problem at 'Fix wrong checking of aarch64' from the_hoang0709@yahoo.com Cui Bixuan
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=5703A5C6.3000102@huawei.com \
--to=cuibixuan@huawei.com \
--cc=ltp@lists.linux.it \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.