qemu-e2k/hw/net
Vladimir Sementsov-Ogievskiy 8908eb1a4a trace-events: fix code style: print 0x before hex numbers
The only exception are groups of numers separated by symbols
'.', ' ', ':', '/', like 'ab.09.7d'.

This patch is made by the following:

> find . -name trace-events | xargs python script.py

where script.py is the following python script:
=========================
 #!/usr/bin/env python

import sys
import re
import fileinput

rhex = '%[-+ *.0-9]*(?:[hljztL]|ll|hh)?(?:x|X|"\s*PRI[xX][^"]*"?)'
rgroup = re.compile('((?:' + rhex + '[.:/ ])+' + rhex + ')')
rbad = re.compile('(?<!0x)' + rhex)

files = sys.argv[1:]

for fname in files:
    for line in fileinput.input(fname, inplace=True):
        arr = re.split(rgroup, line)
        for i in range(0, len(arr), 2):
            arr[i] = re.sub(rbad, '0x\g<0>', arr[i])

        sys.stdout.write(''.join(arr))
=========================

Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Acked-by: Cornelia Huck <cohuck@redhat.com>
Message-id: 20170731160135.12101-5-vsementsov@virtuozzo.com
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
2017-08-01 12:13:07 +01:00
..
fsl_etsec
rocker net/rocker: Cleanup the useless return value check 2017-06-07 10:58:31 +08:00
allwinner_emac.c
cadence_gem.c
dp8393x.c memory: Rename memory_region_init_ram() to memory_region_init_ram_nomigrate() 2017-07-14 17:59:42 +01:00
e1000_regs.h
e1000.c
e1000e_core.c
e1000e_core.h
e1000e.c pci: Make errp the last parameter of pci_add_capability() 2017-07-03 22:29:49 +03:00
e1000x_common.c
e1000x_common.h
eepro100.c pci: Make errp the last parameter of pci_add_capability() 2017-07-03 22:29:49 +03:00
etraxfs_eth.c
ftgmac100.c
imx_fec.c
lan9118.c
lance.c
Makefile.objs
mcf_fec.c
milkymist-minimac2.c memory: Rename memory_region_init_ram() to memory_region_init_ram_nomigrate() 2017-07-14 17:59:42 +01:00
mipsnet.c
ne2000-isa.c
ne2000.c
ne2000.h
net_rx_pkt.c
net_rx_pkt.h
net_tx_pkt.c
net_tx_pkt.h
opencores_eth.c
pcnet-pci.c
pcnet.c
pcnet.h
rtl8139.c
smc91c111.c
spapr_llan.c
stellaris_enet.c
trace-events trace-events: fix code style: print 0x before hex numbers 2017-08-01 12:13:07 +01:00
vhost_net.c
virtio-net.c virtio-net: fix offload ctrl endian 2017-07-17 20:13:56 +08:00
vmware_utils.h
vmxnet3.c migration: Split registration functions from vmstate.h 2017-06-13 11:00:44 +02:00
vmxnet3.h
vmxnet_debug.h
xen_nic.c
xgmac.c
xilinx_axienet.c xilinx: Fix latent error handling bug 2017-07-13 13:45:53 +02:00
xilinx_ethlite.c