Changeset 207 for trunk/kernel/devices


Ignore:
Timestamp:
Jul 17, 2017, 12:51:48 PM (7 years ago)
Author:
max@…
Message:

mask/unmask the IRQ

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/kernel/devices/dev_ioc.c

    r188 r207  
    200200    dev_cmd_t * cmd = (dev_cmd_t *)hal_remote_lpt( XPTR( dev_cxy , &dev_ptr->cmd ) );
    201201
     202    // mask the IRQ
     203    thread_t * server = (thread_t *)hal_remote_lpt( XPTR( dev_cxy , &dev_ptr->server ) );
     204    core_t   * core = (core_t *)hal_remote_lpt( XPTR( dev_cxy , &server->core ) );
     205    lid_t      lid = (lid_t)hal_remote_lw( XPTR( dev_cxy , &core->lid ) );
     206    dev_pic_disable_irq( lid , dev_xp );
     207
    202208    // call directly driver command
    203209    cmd( XPTR( local_cxy , this ) );
     210
     211    // unmask the IRQ
     212    dev_pic_enable_irq( lid , dev_xp );
    204213
    205214    // return I/O operation status from calling thread descriptor
Note: See TracChangeset for help on using the changeset viewer.