~ubuntu-branches/ubuntu/utopic/eglibc/utopic

« back to all changes in this revision

Viewing changes to ports/sysdeps/unix/sysv/linux/hppa/bits/socket.h

  • Committer: Package Import Robot
  • Author(s): Adam Conrad
  • Date: 2012-10-26 05:14:58 UTC
  • mfrom: (1.5.1) (4.4.22 experimental)
  • Revision ID: package-import@ubuntu.com-20121026051458-oryotr4i03ob5pab
Tags: 2.16-0ubuntu1
* Merge with unreleased 2.16 in Debian experimental, remaining changes:
  - Drop the Breaks line from libc6, which refers to a Debian transition
  - Remove the libc6 recommends on libc6-i686, which we don't build
  - Enable libc6{,-dev}-armel on armhf and libc6{-dev}-armhf on armel
  - Ship update-locale and validlocale in /usr/sbin in libc-bin
  - Don't build locales or locales-all in Ubuntu, we rely on langpacks
  - Heavily mangle the way we do service restarting on major upgrades
  - Use different MIN_KERNEL_SUPPORTED versions than Debian, due to
    buildd needs.  This should be universally bumped to 3.2.0 once all
    our buildds (including the PPA guests) are running precise kernels
  - Build i386 variants as -march=i686, build amd64 with -O3, and build
    ppc64 variants (both 64-bit and 32-bit) with -O3 -fno-tree-vectorize
  - Re-enable unsubmitted-ldconfig-cache-abi.diff and rebuild the cache
    on upgrades from previous versions that used a different constant
  - debian/patches/any/local-CVE-2012-3406.diff: switch to malloc when
    array grows too large to handle via alloca extension (CVE-2012-3406)
  - Build generic i386/i686 flavour with -mno-tls-direct-seg-refs
* Changes added/dropped with this merge while reducing our delta:
  - Stop building glibc docs from the eglibc source, and instead make
    the glibc-docs stub have a hard dependency on glibc-doc-reference
  - Remove outdated conflicts against ancient versions of ia32-libs
  - Drop the tzdata dependency from libc6, it's in required and minimal
  - Use gcc-4.7/g++-4.7 by default on all our supported architectures
  - Save our historical changelog as changelog.ubuntu in the source
  - Drop nscd's libaudit build-dep for now, as libaudit is in universe
  - Drop the unnecessary Breaks from libc6 to locales and locales-all
  - Ship xen's ld.so.conf.d snippet as /etc/ld.so.conf.d/libc6-xen.conf
* Disable hard failures on the test suite for the first upload to raring

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/* System-specific socket constants and types.  Linux version.
2
 
   Copyright (C) 1991, 1992, 1994-2001, 2004, 2006, 2007, 2008, 2009,
3
 
   2010 Free Software Foundation, Inc.
 
2
   Copyright (C) 1991-2012 Free Software Foundation, Inc.
4
3
   This file is part of the GNU C Library.
5
4
 
6
5
   The GNU C Library is free software; you can redistribute it and/or
14
13
   Lesser General Public License for more details.
15
14
 
16
15
   You should have received a copy of the GNU Lesser General Public
17
 
   License along with the GNU C Library; if not, write to the Free
18
 
   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
19
 
   02111-1307 USA.  */
 
16
   License along with the GNU C Library; if not, see
 
17
   <http://www.gnu.org/licenses/>.  */
20
18
 
21
19
#ifndef __BITS_SOCKET_H
22
20
#define __BITS_SOCKET_H
65
63
  SOCK_CLOEXEC = 010000000,     /* Atomically set close-on-exec flag for the
66
64
                                   new descriptor(s).  */
67
65
#define SOCK_CLOEXEC SOCK_CLOEXEC
68
 
#undef SOCK_NONBLOCK
69
66
  SOCK_NONBLOCK = 0x40000000    /* Atomically mark descriptor(s) as
70
67
                                   non-blocking.  */
71
68
#define SOCK_NONBLOCK SOCK_NONBLOCK
110
107
#define PF_ISDN         34      /* mISDN sockets.  */
111
108
#define PF_PHONET       35      /* Phonet sockets.  */
112
109
#define PF_IEEE802154   36      /* IEEE 802.15.4 sockets.  */
113
 
#define PF_MAX          37      /* For now..  */
 
110
#define PF_CAIF         37      /* CAIF sockets.  */
 
111
#define PF_ALG          38      /* Algorithm sockets.  */
 
112
#define PF_NFC          39      /* NFC sockets.  */
 
113
#define PF_MAX          40      /* For now..  */
114
114
 
115
115
/* Address families.  */
116
116
#define AF_UNSPEC       PF_UNSPEC
151
151
#define AF_ISDN         PF_ISDN
152
152
#define AF_PHONET       PF_PHONET
153
153
#define AF_IEEE802154   PF_IEEE802154
 
154
#define AF_CAIF         PF_CAIF
 
155
#define AF_ALG          PF_ALG
 
156
#define AF_NFC          PF_NFC
154
157
#define AF_MAX          PF_MAX
155
158
 
156
159
/* Socket level values.  Others are defined in the appropriate headers.
233
236
#define MSG_NOSIGNAL    MSG_NOSIGNAL
234
237
    MSG_MORE            = 0x8000,  /* Sender will send more.  */
235
238
#define MSG_MORE        MSG_MORE
236
 
    MSG_WAITFORONE     = 0x10000, /* Wait for at least one packet to return.*/
237
 
#define MSG_WAITFORONE MSG_WAITFORONE
 
239
    MSG_WAITFORONE      = 0x10000, /* Wait for at least one packet to return.*/
 
240
#define MSG_WAITFORONE  MSG_WAITFORONE
238
241
 
239
242
    MSG_CMSG_CLOEXEC    = 0x40000000    /* Set close_on_exit for file
240
 
                                           descriptor received through
241
 
                                           SCM_RIGHTS.  */
 
243
                                           descriptor received through
 
244
                                           SCM_RIGHTS.  */
242
245
#define MSG_CMSG_CLOEXEC MSG_CMSG_CLOEXEC
243
246
  };
244
247
 
262
265
    int msg_flags;              /* Flags on received message.  */
263
266
  };
264
267
 
 
268
#ifdef __USE_GNU
 
269
/* For `recvmmsg'.  */
 
270
struct mmsghdr
 
271
  {
 
272
    struct msghdr msg_hdr;      /* Actual message header.  */
 
273
    unsigned int msg_len;       /* Number of received bytes for the entry.  */
 
274
  };
 
275
#endif
 
276
 
265
277
/* Structure used for storage of ancillary data object information.  */
266
278
struct cmsghdr
267
279
  {
304
316
{
305
317
  if ((size_t) __cmsg->cmsg_len < sizeof (struct cmsghdr))
306
318
    /* The kernel header does this so there may be a reason.  */
307
 
    return 0;
 
319
    return (struct cmsghdr *) 0;
308
320
 
309
321
  __cmsg = (struct cmsghdr *) ((unsigned char *) __cmsg
310
322
                               + CMSG_ALIGN (__cmsg->cmsg_len));
313
325
      || ((unsigned char *) __cmsg + CMSG_ALIGN (__cmsg->cmsg_len)
314
326
          > ((unsigned char *) __mhdr->msg_control + __mhdr->msg_controllen)))
315
327
    /* No more entries.  */
316
 
    return 0;
 
328
    return (struct cmsghdr *) 0;
317
329
  return __cmsg;
318
330
}
319
331
#endif  /* Use `extern inline'.  */
406
418
    int l_linger;               /* Time to linger.  */
407
419
  };
408
420
 
 
421
 
 
422
__BEGIN_DECLS
 
423
 
 
424
#ifdef __USE_GNU
 
425
/* Receive up to VLEN messages as described by VMESSAGES from socket FD.
 
426
   Returns the number of bytes read or -1 for errors.
 
427
 
 
428
   This function is a cancellation point and therefore not marked with
 
429
   __THROW.  */
 
430
extern int recvmmsg (int __fd, struct mmsghdr *__vmessages,
 
431
                     unsigned int __vlen, int __flags,
 
432
                     const struct timespec *__tmo);
 
433
 
 
434
/* Send a VLEN messages as described by VMESSAGES to socket FD.
 
435
   Return the number of datagrams successfully written or -1 for errors.
 
436
This function is a cancellation point and therefore not marked with
 
437
   __THROW.  */
 
438
extern int sendmmsg (int __fd, struct mmsghdr *__vmessages,
 
439
                     unsigned int __vlen, int __flags);
 
440
#endif
 
441
 
 
442
__END_DECLS
 
443
 
409
444
#endif  /* bits/socket.h */