Skip to contentSkip to conversation

Fixup u32 pretty printing

PATCH In review jamal 1 participant 2 messages Apr 20, 2008

Subsystems (2)
lore
Share & tools
lore

jamal

author
#0 lore raw

PATCH 1/1 Fixup u32 pretty printing

Stephen,

I am going to re-send the original patch i sent (my git skills are limited) along with two others for a total of 3.

With these patches:

1) the default output stays as it was before and only when the user adds a -cooked does the new pretty printing take effect. Example:

--------

hadi@lilsol:~$ tc -c filter ls dev lo parent ffff:

filter protocol ip pref 9 u32 fh 801::802 order 2050 key ht 801 bkt 0 flowid 1:16
match IP src 10.0.0.2/32
match IP protocol 6
match sport 53

hadi@lilsol:~$ tc -c filter ls dev lo parent ffff:

filter protocol ip pref 9 u32 fh 801::802 order 2050 key ht 801 bkt 0 flowid 1:16
match 0a000002/ffffffff at 12
match 00060000/00ff0000 at 8
match 00000035/0000ffff at 20
--------

2) A new infrastructure within u32 classifier to add more pretty printers is added and used for raw and ipv4.

I have at least two more patches lined up, but will wait for the application of these 3 patches or any discussion of these three first before submitting.

cheers,
jamal

author
#1 lore raw
Quoted 10 lines · jamal

--------

hadi@lilsol:~$ tc -c filter ls dev lo parent ffff:

filter protocol ip pref 9 u32 fh 801::802 order 2050 key ht 801 bkt 0 flowid 1:16
match IP src 10.0.0.2/32
match IP protocol 6
match sport 53

hadi@lilsol:~$ tc -c filter ls dev lo parent ffff:

Above, cutnpaste mistake, should be:
"tc filter ls dev lo parent ffff:"

i.e the original way of dumping filters...

Quoted 7 lines

filter protocol ip pref 9 u32 fh 801::802 order 2050 key ht 801 bkt 0 flowid 1:16
match 0a000002/ffffffff at 12
match 00060000/00ff0000 at 8
match 00000035/0000ffff at 20
--------

cheers,
jamal