On Aug 8, 2013, at 3:56 PM, Andrew Morton wrote:
> On Wed, 7 Aug 2013 20:50:09 -0400 Ed Cashin <[email protected]> wrote:
...
>> When the workaround was created, it was with the assumption that the
>> zero-count pages are not always tail pages, and that seemed to be the case
>> in 2007, but as I said, I don't have a mechanism for detecting that now, so
>> I cannot say whether it really happens with today's kernel.
>
> It sounds we should pull out all that code and retest. It shouldn't be
> needed - if this results in some failure then I suspect core MM will
> need changes.
OK. I'll look into that. It sure would be nice to get rid of it.
> Why don't you have a "mechanism for detecting that"? It's a matter of
> pointing AOE at some hugetlb pages?
No, I was testing with hugetlb pages already. But there are many use case
combinations, and I meant that aoe has no mechanism that has been in the aoe
code all these years to catch specific (possibly rare) use cases that result in
zero-count pages. It would be something like this:
+static void
+check_page_counts(struct bio *bio)
+{
+ struct bio_vec *bv;
+ int n;
+ int i;
+
+ bio_for_each_segment(bv, bio, i) {
+ n = page_count(bv->bv_page);
+ WARN_ONCE(n <= 0,
+ "aoe: page %d in bio has non-positive count %d\n",
+ i, n);
+ }
+}
I'll add that when I try testing without the page count manipulation.
--
Ed Cashin
[email protected]
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/