Changeset 0fb1755 in mainline for abi/include/abi/errno.h


Ignore:
Timestamp:
2017-12-04T19:37:27Z (6 years ago)
Author:
Jiří Zárevúcky <zarevucky.jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
9a09212
Parents:
bde5c04
git-author:
Jiří Zárevúcky <zarevucky.jiri@…> (2017-12-04 19:35:04)
git-committer:
Jiří Zárevúcky <zarevucky.jiri@…> (2017-12-04 19:37:27)
Message:

Fold all error codes into a single enum type named errno_t.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • abi/include/abi/errno.h

    rbde5c04 r0fb1755  
    4141 */
    4242
    43 #define EOK             0   /* No error */
    44 #define ENOENT         -1   /* No such entry */
    45 #define ENOMEM         -2   /* Not enough memory */
    46 #define ELIMIT         -3   /* Limit exceeded */
    47 #define EREFUSED       -4   /* Connection refused */
    48 #define EFORWARD       -5   /* Forward error */
    49 #define EPERM          -6   /* Permission denied */
     43typedef enum {
     44        EOK           =  0,   /* No error */
     45        ENOENT        = -1,   /* No such entry */
     46        ENOMEM        = -2,   /* Not enough memory */
     47        ELIMIT        = -3,   /* Limit exceeded */
     48        EREFUSED      = -4,   /* Connection refused */
     49        EFORWARD      = -5,   /* Forward error */
     50        EPERM         = -6,   /* Permission denied */
    5051
    5152/*
     
    5455 * Used by answerbox to close the connection.
    5556 */
    56 #define EHANGUP        -7
     57        EHANGUP       = -7,
    5758
    5859/*
     
    6061 * receiving the call.
    6162 */
    62 #define EPARTY         -8
     63        EPARTY        = -8,
    6364
    64 #define EEXIST         -9   /* Entry already exists */
    65 #define EBADMEM        -10  /* Bad memory pointer */
    66 #define ENOTSUP        -11  /* Not supported */
    67 #define EADDRNOTAVAIL  -12  /* Address not available. */
    68 #define ETIMEOUT       -13  /* Timeout expired */
    69 #define EINVAL         -14  /* Invalid value */
    70 #define EBUSY          -15  /* Resource is busy */
    71 #define EOVERFLOW      -16  /* The result does not fit its size. */
    72 #define EINTR          -17  /* Operation was interrupted. */
     65        EEXIST        = -9,   /* Entry already exists */
     66        EBADMEM       = -10,  /* Bad memory pointer */
     67        ENOTSUP       = -11,  /* Not supported */
     68        EADDRNOTAVAIL = -12,  /* Address not available. */
     69        ETIMEOUT      = -13,  /* Timeout expired */
     70        EINVAL        = -14,  /* Invalid value */
     71        EBUSY         = -15,  /* Resource is busy */
     72        EOVERFLOW     = -16,  /* The result does not fit its size. */
     73        EINTR         = -17,  /* Operation was interrupted. */
     74
     75        EMFILE        = -18,
     76        ENAMETOOLONG  = -256,
     77        EISDIR        = -257,
     78        ENOTDIR       = -258,
     79        ENOSPC        = -259,
     80        ENOTEMPTY     = -261,
     81        EBADF         = -262,
     82        EDOM          = -263,
     83        ERANGE        = -264,
     84        EXDEV         = -265,
     85        EIO           = -266,
     86        EMLINK        = -267,
     87        ENXIO         = -268,
     88        ENOFS         = -269,
     89
     90/** Bad checksum. */
     91        EBADCHECKSUM  = -300,
     92
     93/** USB: stalled operation. */
     94        ESTALL        = -301,
     95
     96/** Empty resource (no data). */
     97        EEMPTY        = -302,
     98
     99/** Negative acknowledgment. */
     100        ENAK          = -303,
     101
     102/** The requested operation was not performed. Try again later. */
     103        EAGAIN        = -11002,
     104} errno_t;
     105
    73106
    74107#endif
Note: See TracChangeset for help on using the changeset viewer.