#include <l4/env/errno.h>
#include <l4/sys/syscalls.h>
#include <l4/thread/thread.h>
#include <l4/semaphore/semaphore.h>
#include <l4/lock/lock.h>
#include <l4/dde_linux/dde.h>
#include <linux/config.h>
#include <linux/mm.h>
#include <linux/kernel_stat.h>
#include <linux/interrupt.h>
#include <linux/smp_lock.h>
#include <linux/init.h>
#include <linux/tqueue.h>
#include "internal.h"
#include "__config.h"
Go to the source code of this file.
Tasklets | |
This is from kernel/softirq.c and include/linux/interrupt.h) Tasklets are the multithreaded analogue of BHs. Main feature differing them of generic softirqs: one tasklet is running only on one CPU simultaneously. Main feature differing them of BHs: different tasklets may be run simultaneously on different CPUs. Properties:
Tasklet lists are CPU local in Linux and so tasklet related synchonization is. This is not in Linux DDE - local_irq_disable()/enable() is not sufficient. We use our cli()/sti() implementation.
| |
static struct tasklet_head | tasklet_vec [NR_CPUS] |
tasklet list head 1-element vector (NR_CPUS==1) | |
static struct tasklet_head | tasklet_hi_vec [NR_CPUS] |
high prio tasklet list head 1-element vector (NR_CPUS==1) | |
static void | tasklet_action (void) |
Tasklet Execution. | |
static int | tasklet_hi_action (void) |
High-Priority Tasklet Execution. | |
void | tasklet_init (struct tasklet_struct *t, void(*func)(unsigned long), unsigned long data) |
Tasklet Initialization. | |
void | tasklet_kill (struct tasklet_struct *t) |
Tasklet Termination. | |
void | tasklet_schedule (struct tasklet_struct *t) |
Schedule dedicated tasklet. | |
void | tasklet_hi_schedule (struct tasklet_struct *t) |
Schedule dedicated high-priority tasklet. | |
Old-style Bottom Halves and Task Queues | |
This is from kernel/softirq.c All bottom halves run as one tasklet so no two bottom halves can run simultaneously.
| |
spinlock_t | tqueue_lock = SPIN_LOCK_UNLOCKED |
protects tqueue list operation (from kernel/timer.c) | |
void | __run_task_queue (task_queue *list) |
Task Queue Execution
Runs _all_ tasks currently in task queue list. | |
Functions | |
static void | dde_softirq_thread (int num) |
Linux DDE Softirq Thread(s). | |
int | l4dde_softirq_init () |
Initalize Softirq Thread(s). | |
Softirqs | |
This is from include/linux/interrupt.h Softirqs are multithreaded, not serialized BH-like activities. Several softirqs may run on several CPUs simultaneously - no matter if they are of the same type. Properties:
Linux (2.4.20) has only 4 softirqs:
Relevant for Linux DDE are for now only the first and the latter -
| |
void | __cpu_raise_softirq (unsigned cpu, int nr) |
Raise softirq for dedicated CPU / handler thread. | |
void | raise_softirq (int nr) |
Raise Softirq. | |
Variables | |
Module variables | |
static l4thread_t | softirq_tid [SOFTIRQ_THREADS] |
softirq thread ids | |
static l4semaphore_t | softirq_sema = L4SEMAPHORE_LOCKED |
softirq semaphore |
Definition in file softirq.c.
void __cpu_raise_softirq | ( | unsigned | cpu, | |
int | nr | |||
) |
static void dde_softirq_thread | ( | int | num | ) | [static] |
static int tasklet_hi_action | ( | void | ) | [static] |