]> git.proxmox.com Git - mirror_ovs.git/commit - utilities/gdb/ovs_gdb.py
utilities: Add upcall related commands to the GDB script
authorEelco Chaudron <echaudro@redhat.com>
Mon, 2 Jul 2018 12:00:10 +0000 (14:00 +0200)
committerBen Pfaff <blp@ovn.org>
Fri, 6 Jul 2018 21:18:21 +0000 (14:18 -0700)
commitb23d42a68d756c3ac85b15140909ce0b04c7b242
tree4dd256180a4b4220bbbd53273a16918205a03948
parentb3ed0e1e058cba8eadebaf7fab10d0a6e1219175
utilities: Add upcall related commands to the GDB script

This commit adds ovs_dump_udpif_keys and ovs_show_upcall commands to the GDB script.
Here are some examples of the output:

(gdb) ovs_show_upcall
netdev@ovs-netdev:
  flows         : (current 0) (avg 0) (max 0) (limit 10000)
  dump duration : 1ms
  ufid enabled  : true

  39: (keys 0)
  42: (keys 0)
  41: (keys 0)
  43: (keys 0)
  44: (keys 0)
  45: (keys 0)

system@ovs-system:
  flows         : (current 4000) (avg 4031) (max 4064) (limit 139000)
  dump duration : 4ms
  ufid enabled  : true

  99: (keys 676)
  102: (keys 665)
  101: (keys 656)
  103: (keys 648)
  104: (keys 642)
  105: (keys 713)

(gdb) ovs_dump_udpif_keys
(struct udpif *) 0x1ebb830: name = netdev@ovs-netdev, total keys = 2
(struct udpif *) 0x20c6f00: name = system@ovs-system, total keys = 0

(gdb) ovs_dump_udpif_keys 0x1ebb830
(struct umap *) 0x1ef9328:
  (struct udpif_key *) 0x7f36e0004e40: key_len = 132, mask_len = 144
                                       ufid = 3e529416-83bf-bab4-5c6e-421127a9143a
                                       hash = 0x3d96b11d, pmd_id = 1
                                       state = UKEY_OPERATIONAL
                                       n_packets = 2, n_bytes = 68
                                       used = 1397047436, tcp_flags = 0x0000
(struct umap *) 0x1efb740:
  (struct udpif_key *) 0x7f36dc004c20: key_len = 132, mask_len = 144
                                       ufid = ee98d69f-8298-04dd-844a-4d2abee9f773
                                       hash = 0x2e8077c2, pmd_id = 15
                                       state = UKEY_OPERATIONAL
                                       n_packets = 0, n_bytes = 0
                                       used = 0, tcp_flags = 0x0000

(gdb) ovs_dump_udpif_keys 0x1ebb830 short
(struct umap *) 0x1ef9328:
  (struct udpif_key *) 0x7f36e0004e40:
(struct umap *) 0x1efb740:
  (struct udpif_key *) 0x7f36dc004c20:

Signed-off-by: Eelco Chaudron <echaudro@redhat.com>
Signed-off-by: Ben Pfaff <blp@ovn.org>
utilities/gdb/ovs_gdb.py