1 /*
2  * nldr.h
3  *
4  * DSP-BIOS Bridge driver support functions for TI OMAP processors.
5  *
6  * DSP/BIOS Bridge dynamic loader interface.
7  *
8  * Copyright (C) 2005-2006 Texas Instruments, Inc.
9  *
10  * This package is free software; you can redistribute it and/or modify
11  * it under the terms of the GNU General Public License version 2 as
12  * published by the Free Software Foundation.
13  *
14  * THIS PACKAGE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
15  * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
16  * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
17  */
18 
19 #include <dspbridge/dbdefs.h>
20 #include <dspbridge/dbdcddef.h>
21 #include <dspbridge/dev.h>
22 #include <dspbridge/rmm.h>
23 #include <dspbridge/nldrdefs.h>
24 
25 #ifndef NLDR_
26 #define NLDR_
27 
28 extern int nldr_allocate(struct nldr_object *nldr_obj,
29 				void *priv_ref, const struct dcd_nodeprops
30 				*node_props,
31 				struct nldr_nodeobject **nldr_nodeobj,
32 				bool *pf_phase_split);
33 
34 extern int nldr_create(struct nldr_object **nldr,
35 			      struct dev_object *hdev_obj,
36 			      const struct nldr_attrs *pattrs);
37 
38 extern void nldr_delete(struct nldr_object *nldr_obj);
39 extern void nldr_exit(void);
40 
41 extern int nldr_get_fxn_addr(struct nldr_nodeobject *nldr_node_obj,
42 				    char *str_fxn, u32 * addr);
43 
44 extern int nldr_get_rmm_manager(struct nldr_object *nldr,
45 				       struct rmm_target_obj **rmm_mgr);
46 
47 extern bool nldr_init(void);
48 extern int nldr_load(struct nldr_nodeobject *nldr_node_obj,
49 			    enum nldr_phase phase);
50 extern int nldr_unload(struct nldr_nodeobject *nldr_node_obj,
51 			      enum nldr_phase phase);
52 #ifdef CONFIG_TIDSPBRIDGE_BACKTRACE
53 int nldr_find_addr(struct nldr_nodeobject *nldr_node, u32 sym_addr,
54 	u32 offset_range, void *offset_output, char *sym_name);
55 #endif
56 
57 #endif /* NLDR_ */
58