net-remove-if.rst 833 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. .. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
  2. .. c:namespace:: DTV.net
  3. .. _NET_REMOVE_IF:
  4. *******************
  5. ioctl NET_REMOVE_IF
  6. *******************
  7. Name
  8. ====
  9. NET_REMOVE_IF - Removes a network interface.
  10. Synopsis
  11. ========
  12. .. c:macro:: NET_REMOVE_IF
  13. ``int ioctl(int fd, NET_REMOVE_IF, int ifnum)``
  14. Arguments
  15. =========
  16. ``fd``
  17. File descriptor returned by :c:func:`open()`.
  18. ``net_if``
  19. number of the interface to be removed
  20. Description
  21. ===========
  22. The NET_REMOVE_IF ioctl deletes an interface previously created via
  23. :ref:`NET_ADD_IF <net>`.
  24. Return Value
  25. ============
  26. On success 0 is returned, and :c:type:`ca_slot_info` is filled.
  27. On error -1 is returned, and the ``errno`` variable is set
  28. appropriately.
  29. The generic error codes are described at the
  30. :ref:`Generic Error Codes <gen-errors>` chapter.