# 2.11BSD#431 - /usr/src/lib/libc/pdp/net/htonl.s

##### Functions

    _htonl            X
    _ntohl            X

       1: /*
       2:  * Copyright (c) 1987 Regents of the University of California.
       3:  * All rights reserved.  The Berkeley software License Agreement
       4:  * specifies the terms and conditions for redistribution.
       5:  */
       6:
       7: #ifdef LIBC_SCCS
       8:         <@(#)htonl.s	1.1 (Berkeley) 1/25/87\0>
       9:         .even
      10: #endif LIBC_SCCS
      11:
      12: /*
      13:  * netlong = htonl(hostlong);
      14:  *	u_long	netlong,
      15:  *		hostlong;
      16:  *
      17:  * hostlong = ntohl(netlong);
      18:  *	u_long	hostlong,
      19:  *		netlong;
      20:  *
      21:  * Translate from host unsigned long representation to network unsigned
      22:  * long representation and back.  On the PDP-11 all this requires is
      23:  * swapping the bytes within the high and low words of a long, so the
      24:  * two routines are really one ...
      25:  */
      26: #include "DEFS.h"
      27:
      28: .globl  _htonl, _ntohl
      29: _htonl:
      30: _ntohl:
      31:         PROFCODE(_htonl)
      32:         mov     2(sp),r0
      33:         mov     4(sp),r1
      34:         swab    r0
      35:         swab    r1
      36:         rts     pc

#### Defined functions

_htonl declared in line 28; defined in line 29; used 39 times

- in line 28-31(2)
- in /usr/src/games/hunt/connect.c line 20
- in /usr/src/lib/libc/inet/inet_addr.c line 101
- in /usr/src/lib/libc/inet/inet_maddr.c line 30
- in /usr/src/libexec/identd/src/crypto.c line 102-106(2)
- in /usr/src/libexec/talkd/process.c line 41, 74, 83, 136-140(2)
- in /usr/src/libexec/talkd/table.c line 135
- in /usr/src/new/crash/if.c line 120
- in /usr/src/new/nntp/server/subnet.c line 215
- in /usr/src/new/nntp/xmit/get_tcp_conn.c line 48, 120
- in /usr/src/sbin/routed/inet.c line 42
- in /usr/src/sbin/routed/input.c line 79
- in /usr/src/sbin/routed/main.c line 131
- in /usr/src/sbin/routed/output.c line 106
- in /usr/src/sbin/routed/timer.c line 64
- in /usr/src/sys/netinet/in.h line 173
- in /usr/src/sys/netns/ns.h line 116
- in /usr/src/ucb/netstat/if.c line 130
- in /usr/src/ucb/talk/get_addrs.c line 20
- in /usr/src/ucb/talk/invite.c line 45, 72-74(2), 89, 138-143(2)
- in /usr/src/ucb/talk/look_up.c line 69
- in /usr/src/usr.bin/uucp/tio.c line 115
- in /usr/src/usr.sbin/named/named/ns.h line 210
- in /usr/src/usr.sbin/named/named/ns_sort.c line 179, 256
- in /usr/src/usr.sbin/named/tools/nstest.c line 128, 179

_ntohl declared in line 28; defined in line 30; used 35 times

- in line 28
- in /usr/src/games/hunt/answer.c line 72, 79
- in /usr/src/lib/libc/inet/inet_lnaof.c line 23
- in /usr/src/lib/libc/ns/ns_ntoa.c line 29
- in /usr/src/libexec/identd/src/crypto.c line 215
- in /usr/src/libexec/talkd/print.c line 59
- in /usr/src/libexec/talkd/process.c line 47, 62
- in /usr/src/new/crash/if.c line 132
- in /usr/src/new/nntp/server/subnet.c line 141, 151, 198
- in /usr/src/sbin/ifconfig/ifconfig.c line 345
- in /usr/src/sbin/routed/af.c line 51, 111
- in /usr/src/sbin/routed/inet.c line 53, 81, 114, 158-159(2)
- in /usr/src/sbin/routed/input.c line 54, 145
- in /usr/src/sbin/routed/startup.c line 98-100(2)
- in /usr/src/sbin/routed/trace.c line 253
- in /usr/src/sbin/routed/trace.h line 53
- in /usr/src/sys/netinet/in.h line 173
- in /usr/src/sys/netns/ns.h line 116
- in /usr/src/ucb/netstat/if.c line 144
- in /usr/src/ucb/talk/ctl_transact.c line 79
- in /usr/src/usr.bin/uucp/tio.c line 183
- in /usr/src/usr.sbin/named/named/ns.h line 210
- in /usr/src/usr.sbin/named/tools/nstest.c line 111, 241

Last modified: 1987-05-07 Generated: 2016-12-26 | Generated by src2html V0.67 page hit count: 1131 |