Skip to content

Instantly share code, notes, and snippets.

@ytakano
Last active October 12, 2016 13:05
Show Gist options
  • Save ytakano/adedb80905072ba3ac7f18779bd7cefc to your computer and use it in GitHub Desktop.
Save ytakano/adedb80905072ba3ac7f18779bd7cefc to your computer and use it in GitHub Desktop.
$ systool -v -m netmap
Module = "netmap"

  Attributes:
    coresize            = "143360"
    initsize            = "0"
    initstate           = "live"
    refcnt              = "0"
    srcversion          = "5F4F49C43161A16E4F13BC0"
    taint               = "OE"
    uevent              = <store method only>

  Parameters:
    adaptive_io         = "0"
    admode              = "0"
    bridge_batch        = "1024"
    buf_curr_num        = "163840"
    buf_curr_size       = "2048"
    buf_num             = "163840"
    buf_size            = "2048"
    default_pipes       = "0"
    flags               = "0"
    fwd                 = "0"
    generic_mit         = "100000"
    generic_ringsize    = "1024"
    generic_rings       = "1"
    generic_txqdisc     = "1"
    if_curr_num         = "100"
    if_curr_size        = "1024"
    if_num              = "100"
    if_size             = "1024"
    mitigate            = "1"
    no_pendintr         = "1"
    no_timestamp        = "0"
    priv_buf_num        = "4098"
    priv_buf_size       = "2048"
    priv_if_num         = "2"
    priv_if_size        = "1024"
    priv_ring_num       = "4"
    priv_ring_size      = "20480"
    ring_curr_num       = "200"
    ring_curr_size      = "36864"
    ring_num            = "200"
    ring_size           = "36864"
    txsync_retry        = "2"
    verbose             = "0"

  Sections:
    .bss                = "0x0000000000000000"
    .data               = "0x0000000000000000"
    .data..read_mostly  = "0x0000000000000000"
    .gnu.linkonce.this_module= "0x0000000000000000"
    .note.gnu.build-id  = "0x0000000000000000"
    .rodata             = "0x0000000000000000"
    .rodata.str1.1      = "0x0000000000000000"
    .rodata.str1.8      = "0x0000000000000000"
    .smp_locks          = "0x0000000000000000"
    .strtab             = "0x0000000000000000"
    .symtab             = "0x0000000000000000"
    .text               = "0x0000000000000000"
    __kcrctab           = "0x0000000000000000"
    __ksymtab_strings   = "0x0000000000000000"
    __ksymtab           = "0x0000000000000000"
    __mcount_loc        = "0x0000000000000000"
    __param             = "0x0000000000000000"
$ sudo rmmod netmap.ko
$ sudo insmod /lib/modules/4.4.0-21-generic/netmap.ko buf_num=300000 buf_size=2048 ring_num=400 ring_size=73728 if_num=200 if_size=2048
$ systool -v -m netmap
Module = "netmap"

  Attributes:
    coresize            = "143360"
    initsize            = "0"
    initstate           = "live"
    refcnt              = "290"
    srcversion          = "5F4F49C43161A16E4F13BC0"
    taint               = "OE"
    uevent              = <store method only>

  Parameters:
    adaptive_io         = "0"
    admode              = "0"
    bridge_batch        = "1024"
    buf_curr_num        = "300000"
    buf_curr_size       = "2048"
    buf_num             = "300000"
    buf_size            = "2048"
    default_pipes       = "0"
    flags               = "0"
    fwd                 = "0"
    generic_mit         = "100000"
    generic_ringsize    = "1024"
    generic_rings       = "1"
    generic_txqdisc     = "1"
    if_curr_num         = "200"
    if_curr_size        = "2048"
    if_num              = "200"
    if_size             = "2048"
    mitigate            = "1"
    no_pendintr         = "1"
    no_timestamp        = "0"
    priv_buf_num        = "4098"
    priv_buf_size       = "2048"
    priv_if_num         = "2"
    priv_if_size        = "1024"
    priv_ring_num       = "4"
    priv_ring_size      = "20480"
    ring_curr_num       = "400"
    ring_curr_size      = "73728"
    ring_num            = "400"
    ring_size           = "73728"
    txsync_retry        = "2"
    verbose             = "0"

  Sections:
    .bss                = "0x0000000000000000"
    .data               = "0x0000000000000000"
    .data..read_mostly  = "0x0000000000000000"
    .gnu.linkonce.this_module= "0x0000000000000000"
    .note.gnu.build-id  = "0x0000000000000000"
    .rodata             = "0x0000000000000000"
    .rodata.str1.1      = "0x0000000000000000"
    .rodata.str1.8      = "0x0000000000000000"
    .smp_locks          = "0x0000000000000000"
    .strtab             = "0x0000000000000000"
    .symtab             = "0x0000000000000000"
    .text               = "0x0000000000000000"
    __kcrctab           = "0x0000000000000000"
    __ksymtab_strings   = "0x0000000000000000"
    __ksymtab           = "0x0000000000000000"
    __mcount_loc        = "0x0000000000000000"
    __param             = "0x0000000000000000"
$ ls /sys/module/netmap/parameters
adaptive_io    default_pipes     if_curr_num   priv_buf_num    ring_curr_size
admode         flags             if_curr_size  priv_buf_size   ring_num
bridge_batch   fwd               if_num        priv_if_num     ring_size
buf_curr_num   generic_mit       if_size       priv_if_size    txsync_retry
buf_curr_size  generic_rings     mitigate      priv_ring_num   verbose
buf_num        generic_ringsize  no_pendintr   priv_ring_size
buf_size       generic_txqdisc   no_timestamp  ring_curr_num
$ ethtool -l ixl2
Channel parameters for ixl2:
Pre-set maximums:
RX:		0
TX:		0
Other:		1
Combined:	96
Current hardware settings:
RX:		0
TX:		0
Other:		1
Combined:	96

$ sudo ethtool -L ixl2 combined 8
$ sudo ./getinfo ixl2
nr_name     : ixl2
nr_varsion  : 11
nr_offset   : 0
nr_memsize  : 1242726400
nr_tx_slots : 512
nr_rx_slots : 512
nr_tx_rings : 8
nr_rx_rings : 8
nr_ringid   : 0
nr_cmd      : 0
nr_arg1     : 0
nr_arg2     : 1
nr_arg3     : 0
nr_flags    : 0
nr_spare2[0]: 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment