2018-03-07 20:57:14 +08:00
|
|
|
/*
|
|
|
|
* Copyright (C) 2018 Intel Corporation. All rights reserved.
|
|
|
|
*
|
2018-05-26 01:49:13 +08:00
|
|
|
* SPDX-License-Identifier: BSD-3-Clause
|
2018-03-07 20:57:14 +08:00
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef SOFTIRQ_H
|
|
|
|
#define SOFTIRQ_H
|
|
|
|
|
2018-07-02 14:05:58 +08:00
|
|
|
#define SOFTIRQ_TIMER 0U
|
|
|
|
#define SOFTIRQ_DEV_ASSIGN 1U
|
|
|
|
#define SOFTIRQ_MAX 2U
|
2018-03-07 20:57:14 +08:00
|
|
|
#define SOFTIRQ_MASK ((1UL<<SOFTIRQ_MAX)-1)
|
|
|
|
|
|
|
|
/* used for atomic value for prevent recursive */
|
2018-06-30 00:17:34 +08:00
|
|
|
#define SOFTIRQ_ATOMIC 63U
|
2018-03-07 20:57:14 +08:00
|
|
|
|
2018-06-20 15:42:52 +08:00
|
|
|
void enable_softirq(uint16_t cpu_id);
|
|
|
|
void disable_softirq(uint16_t cpu_id);
|
2018-03-07 20:57:14 +08:00
|
|
|
void init_softirq(void);
|
2018-07-12 11:47:49 +08:00
|
|
|
void raise_softirq(uint16_t softirq_id);
|
2018-03-07 20:57:14 +08:00
|
|
|
void exec_softirq(void);
|
|
|
|
#endif /* SOFTIRQ_H */
|