On Tue, Aug 27, 2013 at 10:01 AM, Fei Yang <phar...@gmail.com> wrote:

> We ran into a CTS problem where testTrafficStatsForLocalhost failed in
> "android.net.cts.TrafficStatsTest", and reverting the following patch seems
> to fix the problem.
Most of the time, it comes from a discrepancy between what changes are
sync'd in the various projects.
See below for the list.

> Have you seen the same problem from Google side?

No. :) But only because all the needed patches were somewhat bundled.

> I'm
> trying to understand if this is a CTS or kernel problem, I would appreciate
> if anyone could provide background of this patch.

The background for that patch is to allow testing the
Quota-socketTAGger-UIDtracker netfilter module without the need of
some random networking interface.


The kernel changes need the matching user space changes.
Here is a list of all the 4 needed changes (JNI, system/netd, kernel,
cts TrafficStats):

* system/netd

https://android.googlesource.com/platform/system/netd/+/92009c8effc75c2d70a6c9a1ac33ba2c60b78820

commit92009c8effc75c2d70a6c9a1ac33ba2c60b78820[log][tgz]
authorJP Abgrall <j...@google.com>Wed Feb 06 18:01:24 2013 -0800
committerJP Abgrall <j...@google.com>Wed Feb 06 18:01:24 2013 -0800
treef0d9fb13f8a9ab3953af2f0ed9bf96a11d402c23
parent0894b1cf502bc1824bc38368d7c6a21d71cc73dc[diff]

netd: BandwidthController: Allow tracking loopback interfaces

In the past, loopback interfaces were of no use for bandwidth/datausage.
We now don't treat loopback interfaces any differently.
This will helps with CTS tests that checking the kernel's qtaguid functionality
and the matching user-space handling.

Change-Id: If307ceebc10f89269d1b051f666ec666e5e38d41


* kernel/common
https://android.googlesource.com/kernel/common/+/ab3801efc6d2e7b4610071ac87c6977ac9042ad9
 commit        ab3801efc6d2e7b4610071ac87c6977ac9042ad9[log][tgz]
 author        JP Abgrall <j...@google.com>     Wed Feb 06 17:40:07 2013 -0800
 committer     JP Abgrall <j...@google.com>     Wed Feb 06 18:02:29 2013 -0800
 tree  5eeb74748e9c3b761a79c32b427c50e13bf5f746
 parent        3afcb73627439d0d9d95ca31f2f6512809da0c30[diff]
 netfilter: xt_qtaguid: Allow tracking loopback

 In the past it would always ignore interfaces with loopback addresses.
 Now we just treat them like any other.
 This also helps with writing tests that check for the presence
 of the qtaguid module.

 Signed-off-by: JP Abgrall <j...@google.com>

* traffic stats api fixup
https://android.googlesource.com/platform/frameworks/base/+/62f16bfc5e90f0320ab68b66b5b5b125cada1867

commit62f16bfc5e90f0320ab68b66b5b5b125cada1867[log][tgz]
authorJP Abgrall <j...@google.com>Fri Mar 01 23:38:40 2013 -0800
committerAndroid (Google) Code Review <android-ger...@google.com>Mon
Mar 04 18:53:07 2013 +0000
treeaf1343498563473a79cd3ea51f1bd6c2f0d28770
parentd2bfa3bdc0a5d3c06cde2711d8572a8141e45fe2[diff]

jni: net.TrafficStats: fix getIfaceStat, have it use the iface.

Missing iface8 in call to parseIfaceStats().

Bug: 8304054
Change-Id: Ibb01d86a0f7241cdd8f23401973840673f847efb


* cts test fixup/update

https://android.googlesource.com/platform/cts/+/19c4de99455200ab6d54135aef8c00cdf0876f5d

commit19c4de99455200ab6d54135aef8c00cdf0876f5d[log][tgz]
authorJP Abgrall <j...@google.com>Fri Mar 01 16:41:16 2013 -0800
committerAndroid (Google) Code Review <android-ger...@google.com>Mon
Mar 04 18:58:07 2013 +0000
tree2d0491c94fbe586401c988e7e99b896406dcdd3e
parent9b132549753631b4eb18a16c802efbf6c3b1ad79[diff]

Fixup TrafficStats test wrt mobile vs total vs loopback

- Use getMobileBlabla() instead of getTotalBlabla()
- Have getTotalBlabla() reflect the fact that it includes loopback.
- Adjust checks to take headers, acks, and packet counts into account.

Change-Id: I9e1dfbbbdb9a6f932a14a2e3baee7a34469b9008


--

-- 
-- 
unsubscribe: android-kernel+unsubscr...@googlegroups.com
website: http://groups.google.com/group/android-kernel
--- 
You received this message because you are subscribed to the Google Groups 
"Android Linux Kernel Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-kernel+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to