This is not really a parser for bulk/isoc, but it helps to see where,
in the stream, the xfers started to occur.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
my $man = 0;
my $help = 0;
my $pcap = 0;
+my $all = 0;
my $device;
GetOptions('debug=i' => \$debug,
'help|?' => \$help,
'pcap' => \$pcap,
+ 'all' => \$all,
'device=s' => \$device,
man => \$man
) or pod2usage(2);
return;
}
+my %frametype = (
+ 0 => "ISOC",
+ 1 => "Interrupt",
+ 2 => "Control",
+ 3 => "Bulk",
+);
+
sub process_frame($) {
my %frame = %{ $_[0] };
}
# For now, we'll take a look only on control frames
- return if ($frame{"TransferType"} ne "2");
+ if ($frame{"TransferType"} ne "2" && $all) {
+ printf "Transfer type: %s\n", $frametype{$frame{"TransferType"}};
+ return;
+ }
if ($frame{"Status"} eq "-115") {
push @pending, \%frame;