brintos

brintos / linux-shallow public Read only

0
0
Text · 1.1 KiB · 022b4c6 Raw
53 lines · plain
1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later2.. c:namespace:: DTV.net3 4.. _NET_ADD_IF:5 6****************7ioctl NET_ADD_IF8****************9 10Name11====12 13NET_ADD_IF - Creates a new network interface for a given Packet ID.14 15Synopsis16========17 18.. c:macro:: NET_ADD_IF19 20``int ioctl(int fd, NET_ADD_IF, struct dvb_net_if *net_if)``21 22Arguments23=========24 25``fd``26    File descriptor returned by :c:func:`open()`.27 28``net_if``29    pointer to struct :c:type:`dvb_net_if`30 31Description32===========33 34The NET_ADD_IF ioctl system call selects the Packet ID (PID) that35contains a TCP/IP traffic, the type of encapsulation to be used (MPE or36ULE) and the interface number for the new interface to be created. When37the system call successfully returns, a new virtual network interface is38created.39 40The struct :c:type:`dvb_net_if`::ifnum field will be41filled with the number of the created interface.42 43Return Value44============45 46On success 0 is returned, and :c:type:`ca_slot_info` is filled.47 48On error -1 is returned, and the ``errno`` variable is set49appropriately.50 51The generic error codes are described at the52:ref:`Generic Error Codes <gen-errors>` chapter.53