include/tube: fix API inconsistency regarding canister declaration

Just like DECLARE_EVL_TUBE_CANISTER() should be used explicitly for
declaring a new canister type for a local tube, the same should be
done with DECLARE_EVL_TUBE_CANISTER_REL() for a shared tube. Stop
calling the latter implicitly from DECLARE_EVL_TUBE_REL(), to remain
consist with DECLARE_EVL_TUBE() usage.
This commit is contained in:
Philippe Gerum 2019-12-03 11:47:06 +01:00
parent 243ce101a3
commit 3985fd94aa
1 changed files with 6 additions and 7 deletions

View File

@ -157,12 +157,6 @@
* Position-independent variant.
*/
#define DECLARE_TUBE_CANISTER_REL(__can_struct, __payload) \
struct __can_struct { \
typeof(__payload) payload; \
uintptr_t next; \
} \
#define DECLARE_CANISTER_QUEUE_REL(__can_struct) \
struct { \
uintptr_t head; \
@ -234,8 +228,13 @@
__next_dq ? __old_dqptr : NULL; \
})
#define DECLARE_EVL_TUBE_CANISTER_REL(__can_struct, __payload) \
struct __can_struct { \
typeof(__payload) payload; \
uintptr_t next; \
} \
#define DECLARE_EVL_TUBE_REL(__name, __can_struct, __payload) \
DECLARE_TUBE_CANISTER_REL(__can_struct, __payload); \
struct __name { \
DECLARE_CANISTER_QUEUE_REL(__can_struct) pending; \
DECLARE_CANISTER_QUEUE_REL(__can_struct) free; \