Changeset 46577995 in mainline for uspace/drv/intctl/i8259/i8259.c


Ignore:
Timestamp:
2018-01-04T20:50:52Z (7 years ago)
Author:
Jiří Zárevúcky <zarevucky.jiri@…>
Children:
e211ea04
Parents:
facacc71
git-author:
Jiří Zárevúcky <zarevucky.jiri@…> (2018-01-04 20:47:53)
git-committer:
Jiří Zárevúcky <zarevucky.jiri@…> (2018-01-04 20:50:52)
Message:

Use errno_t in all uspace and kernel code.

Change type of every variable, parameter and return value that holds an
<errno.h> constant to either errno_t (the usual case), or sys_errno_t
(some places in kernel). This is for the purpose of self-documentation,
as well as for type-checking with a bit of type definition hackery.

After this commit, HelenOS is free of code that mixes error codes with non-error
values on the assumption that error codes are negative.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/intctl/i8259/i8259.c

    rfacacc71 r46577995  
    6464#define PIC_MAX_IRQ  15
    6565
    66 static int pic_enable_irq(i8259_t *i8259, sysarg_t irq)
     66static errno_t pic_enable_irq(i8259_t *i8259, sysarg_t irq)
    6767{
    6868        if (irq > PIC_MAX_IRQ)
     
    136136
    137137/** Add i8259 device. */
    138 int i8259_add(i8259_t *i8259, i8259_res_t *res)
     138errno_t i8259_add(i8259_t *i8259, i8259_res_t *res)
    139139{
    140140        sysarg_t have_i8259;
     
    142142        ioport8_t *regs1;
    143143        ddf_fun_t *fun_a = NULL;
    144         int rc;
     144        errno_t rc;
    145145       
    146146        if ((sysinfo_get_value("i8259", &have_i8259) != EOK) || (!have_i8259)) {
     
    187187
    188188/** Remove i8259 device */
    189 int i8259_remove(i8259_t *i8259)
     189errno_t i8259_remove(i8259_t *i8259)
    190190{
    191191        return ENOTSUP;
     
    193193
    194194/** i8259 device gone */
    195 int i8259_gone(i8259_t *i8259)
     195errno_t i8259_gone(i8259_t *i8259)
    196196{
    197197        return ENOTSUP;
Note: See TracChangeset for help on using the changeset viewer.