O'Reilly logo

TCP/IP Illustrated by W. Richard Stevens, Gary R. Wright

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 30. TCP User Requests

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.

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.

Table 30.1. Body of tcp_usrreq function.

--------------------------------------------------------------------- tcp_usrreq.c 45 int 46 tcp_usrreq(so, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required