Chapter 30. TCP User Requests

30.1. Introduction

This chapter looks at the TCP user-request function tcp_usrreq, which is called as the protocol’s pr_usrreq function to handle many of the system calls that reference a TCP socket. We also look at tcp_ctloutput, which is called when the process calls setsockopt for a TCP socket.

30.2. tcp_usrreq Function

TCP’s user-request function is called for a variety of operations. Figure 30.1 shows the beginning and end of tcp_usrreq. The body of the switch is shown in following figures. The function arguments, some of which differ depending on the request, are described in Figure 15.17.

Figure 30.1. Body of tcp_usrreq function.

in_control processes ioctl requests ...

Get TCP/IP Illustrated now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.