p To use an .Nm device, the administrator must first create the interface. This can be done by using the .Xr ifconfig 8 .Cm create command. An .Xr open 2 call on
a /dev/srt Ns Sy N will also create a network interface with a unit number the same as the minor device number of that device if the interface doesn't exist yet.
p To be useful, the .Nm interface needs to be configured using .Xr srtconfig 1 which uses the associated .Nm character device
p The network interfaces should be named .Sy srt Ns Ar 0 , .Sy srt Ns Ar 1 , etc. The .Nm interface supports only the .Xr open 2 , .Xr close 2 , and .Xr ioctl 2 operations; other operations such as .Xr read 2 and .Xr write 2 are not supported.
p All standard network interface .Xr ioctl 2 calls are supported by the .Nm interface. In addition, the following .Xr ioctl 2 calls
q defined in Aq Pa net/if_srt.h are supported on the .Nm character device: l -tag -width SRT_SGFLAGS -offset 4n t Dv SRT_GETNRT The argument is a pointer to an integer, in which the number of entries in the device's routing table is returned. t Dv SRT_GETRT The argument is the address of a .Fa struct srt_rt . The routing table entry specified by the .Dq inx member is returned. t Dv SRT_SETRT The argument is the address of a .Fa struct srt_rt . The routing entry is placed into the device's routing table at the index specified by the .Dq inx member. t Dv SRT_DELRT The argument is the address of a .Fa struct srt_rt . The routing entry specified by the .Dq inx member is deleted from the device's routing table. (Any entries in the device's routing table with higher index values are renumbered.) t Dv SRT_SFLAGS The argument is a pointer to an integer containing any of the following flags to be set: l -tag -width SSF_MTULOCK t Dv SSF_MTULOCK If set, do not automatically update the interface's MTU. .El t Dv SRT_GFLAGS The argument is a pointer to an integer in which the current flags are returned. t Dv SRT_SGFLAGS This call updates the flags in the same manner as .Dv SRT_SFLAGS . The original flags are returned in the integer pointed to by the argument. t Dv SRT_DEBUG Currently this is a no-op. .El .Sh SEE ALSO .Xr srtconfig 1 , .Xr inet 4 , .Xr intro 4 .Sh HISTORY .An -nosplit The .Nm device was added in .Nx 5.0 by .An der Mouse Aq Mt mouse (at] NetBSD.org . This manual page was prepared by .An Paul Goyette Aq Mt pgoyette (at] NetBSD.org .