Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
B
Beam Positoning Monitor - Software
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
Beam Positoning Monitor - Software
Commits
836941d5
Commit
836941d5
authored
Jan 06, 2016
by
Lucas Russo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
include/sm_io_mod_dispatch.h: add macros for declaring structure in linker table
parent
b639279a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
1 deletion
+20
-1
sm_io_mod_dispatch.h
include/sm_io_mod_dispatch.h
+20
-1
No files found.
include/sm_io_mod_dispatch.h
View file @
836941d5
...
@@ -20,7 +20,26 @@ typedef struct {
...
@@ -20,7 +20,26 @@ typedef struct {
const
smio_bootstrap_ops_t
*
bootstrap_ops
;
const
smio_bootstrap_ops_t
*
bootstrap_ops
;
}
smio_mod_dispatch_t
;
}
smio_mod_dispatch_t
;
extern
const
smio_mod_dispatch_t
smio_mod_dispatch
[];
/*
* WARNING! Using SMIO_MOD_DECLARE requires .smio_mod_dispatch section in linker script
* .smio_mod_dispatch : ALIGN(4)
* {
* _smio_mod_dispatch = .;
* KEEP(*(.smio_mod_dispatch))
* _esmio_mod_dispatch = .;
* }
*/
extern
const
smio_mod_dispatch_t
*
_smio_mod_dispatch
;
extern
const
smio_mod_dispatch_t
*
_esmio_mod_dispatch
;
#define SMIO_MOD_DECLARE(mod_id, mod_name, mod_bootstrap_ops) \
const smio_mod_dispatch_t __attribute__ ((section (".smio_mod_dispatch"))) \
smio_mod_ ## mod_id ## _ ## mod_name = { \
.id = mod_id, \
.name = mod_name, \
.bootstrap_ops = &mod_bootstrap_ops \
};
#ifdef __cplusplus
#ifdef __cplusplus
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment