Loading...
Searching...
No Matches
irq.h
Go to the documentation of this file.
/*
* (c) 2008-2009 Adam Lackorzynski <adam@os.inf.tu-dresden.de>,
* Henning Schild <hschild@os.inf.tu-dresden.de>
* economic rights: Technische Universität Dresden (Germany)
*
* This file is part of TUD:OS and distributed under the terms of the
* GNU General Public License 2.
* Please see the COPYING-GPL-2 file for details.
*/
#pragma once
#include <l4/sys/compiler.h>
#include <l4/sys/types.h>
__BEGIN_DECLS
struct l4irq_t;
typedef struct l4irq_t l4irq_t;
L4_CV l4irq_t *
l4irq_attach(int irqnum);
L4_CV l4irq_t *
l4irq_attach_ft(int irqnum, unsigned mode);
L4_CV l4irq_t *
l4irq_attach_thread(int irqnum, l4_cap_idx_t to_thread);
L4_CV l4irq_t *
l4irq_attach_thread_ft(int irqnum, l4_cap_idx_t to_thread,
unsigned mode);
L4_CV long
l4irq_wait(l4irq_t *irq);
L4_CV long
l4irq_unmask_and_wait_any(l4irq_t *unmask_irq, l4irq_t **ret_irq);
L4_CV long
l4irq_wait_any(l4irq_t **irq);
L4_CV long
l4irq_unmask(l4irq_t *irq);
L4_CV long
l4irq_detach(l4irq_t *irq);
/***********************************************************************/
L4_CV l4irq_t *
l4irq_request(int irqnum, void (*isr_handler)(void *), void *isr_data,
int irq_thread_prio, unsigned mode);
L4_CV long
l4irq_release(l4irq_t *irq);
/***********************************************************************/
/***********************************************************************/
L4_CV l4irq_t *
l4irq_attach_cap(l4_cap_idx_t irqcap);
L4_CV l4irq_t *
l4irq_attach_cap_ft(l4_cap_idx_t irqcap, unsigned mode);
L4_CV l4irq_t *
l4irq_attach_thread_cap(l4_cap_idx_t irqcap, l4_cap_idx_t to_thread);
L4_CV l4irq_t *
l4irq_attach_thread_cap_ft(l4_cap_idx_t irqcap, l4_cap_idx_t to_thread,
unsigned mode);
/***********************************************************************/
L4_CV l4irq_t *
l4irq_request_cap(l4_cap_idx_t irqcap,
void (*isr_handler)(void *), void *isr_data,
int irq_thread_prio, unsigned mode);
__END_DECLS
compiler.h
L4 compiler related defines.
l4_cap_idx_t
unsigned long l4_cap_idx_t
Capability selector type.
Definition types.h:336
l4irq_request_cap
l4irq_t * l4irq_request_cap(l4_cap_idx_t irqcap, void(*isr_handler)(void *), void *isr_data, int irq_thread_prio, unsigned mode)
Attach asychronous ISR handler to IRQ.
l4irq_request
l4irq_t * l4irq_request(int irqnum, void(*isr_handler)(void *), void *isr_data, int irq_thread_prio, unsigned mode)
Attach asychronous ISR handler to IRQ.
l4irq_release
long l4irq_release(l4irq_t *irq)
Release asynchronous ISR handler and free resources.
l4irq_attach_cap
l4irq_t * l4irq_attach_cap(l4_cap_idx_t irqcap)
Attach/connect to IRQ.
l4irq_attach_thread_cap
l4irq_t * l4irq_attach_thread_cap(l4_cap_idx_t irqcap, l4_cap_idx_t to_thread)
Attach/connect to IRQ.
l4irq_attach_thread_cap_ft
l4irq_t * l4irq_attach_thread_cap_ft(l4_cap_idx_t irqcap, l4_cap_idx_t to_thread, unsigned mode)
Attach/connect to IRQ using given type.
l4irq_attach_cap_ft
l4irq_t * l4irq_attach_cap_ft(l4_cap_idx_t irqcap, unsigned mode)
Attach/connect to IRQ using given type.
l4irq_attach_thread_ft
l4irq_t * l4irq_attach_thread_ft(int irqnum, l4_cap_idx_t to_thread, unsigned mode)
Attach/connect to IRQ using given type.
l4irq_wait_any
long l4irq_wait_any(l4irq_t **irq)
Wait for any attached IRQ.
l4irq_attach_thread
l4irq_t * l4irq_attach_thread(int irqnum, l4_cap_idx_t to_thread)
Attach/connect to IRQ.
l4irq_unmask_and_wait_any
long l4irq_unmask_and_wait_any(l4irq_t *unmask_irq, l4irq_t **ret_irq)
Unmask a specific IRQ and wait for any attached IRQ.
l4irq_attach
l4irq_t * l4irq_attach(int irqnum)
Attach/connect to IRQ.
l4irq_detach
long l4irq_detach(l4irq_t *irq)
Detach from IRQ.
l4irq_wait
long l4irq_wait(l4irq_t *irq)
Wait for specified IRQ.
l4irq_attach_ft
l4irq_t * l4irq_attach_ft(int irqnum, unsigned mode)
Attach/connect to IRQ using given type.
l4irq_unmask
long l4irq_unmask(l4irq_t *irq)
Unmask a specific IRQ.
L4_CV
#define L4_CV
Define calling convention.
Definition linkage.h:33
types.h
Common L4 ABI Data Types.