Changeset 948911d in mainline for uspace/drv/bus/isa/isa.c


Ignore:
Timestamp:
2012-01-24T02:27:43Z (12 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
230385c
Parents:
8afeb04 (diff), 2df6f6fe (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Mainline changes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/bus/isa/isa.c

    r8afeb04 r948911d  
    5252#include <dirent.h>
    5353#include <fcntl.h>
     54#include <ipc/irc.h>
     55#include <ipc/services.h>
     56#include <sysinfo.h>
     57#include <ns.h>
    5458#include <sys/stat.h>
    5559#include <ipc/irc.h>
     
    109113        sysarg_t apic;
    110114        sysarg_t i8259;
    111        
     115
    112116        async_sess_t *irc_sess = NULL;
    113        
     117
    114118        if (((sysinfo_get_value("apic", &apic) == EOK) && (apic))
    115119            || ((sysinfo_get_value("i8259", &i8259) == EOK) && (i8259))) {
     
    117121                    SERVICE_IRC, 0, 0);
    118122        }
    119        
     123
    120124        if (!irc_sess)
    121125                return false;
    122        
     126
    123127        assert(isa_fun);
    124128        const hw_resource_list_t *res = &isa_fun->hw_resources;
     
    127131                if (res->resources[i].type == INTERRUPT) {
    128132                        const int irq = res->resources[i].res.interrupt.irq;
    129                        
     133
    130134                        async_exch_t *exch = async_exchange_begin(irc_sess);
    131135                        const int rc =
    132136                            async_req_1_0(exch, IRC_ENABLE_INTERRUPT, irq);
    133137                        async_exchange_end(exch);
    134                        
     138
    135139                        if (rc != EOK) {
    136140                                async_hangup(irc_sess);
     
    139143                }
    140144        }
    141        
     145
    142146        async_hangup(irc_sess);
    143147        return true;
     
    397401
    398402        val = skip_spaces(val);
    399         irq = (int)strtol(val, &end, 0x10);
     403        irq = (int)strtol(val, &end, 10);
    400404
    401405        if (val != end)
Note: See TracChangeset for help on using the changeset viewer.