]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - rpmsg/rpmsg.git/blob - include/linux/pruss.h
remoteproc/pru: add APIs to get and put the PRU cores
[rpmsg/rpmsg.git] / include / linux / pruss.h
1 /* SPDX-License-Identifier: GPL-2.0 */
2 /**
3  * PRU-ICSS Subsystem user interfaces
4  *
5  * Copyright (C) 2015-2019 Texas Instruments Incorporated - http://www.ti.com
6  *      Suman Anna <s-anna@ti.com>
7  */
9 #ifndef __LINUX_PRUSS_H
10 #define __LINUX_PRUSS_H
12 #if IS_ENABLED(CONFIG_TI_PRUSS)
14 int pruss_intc_trigger(unsigned int irq);
16 #else
18 static inline int pruss_intc_trigger(unsigned int irq)
19 {
20         return -ENOTSUPP;
21 }
23 #endif /* CONFIG_TI_PRUSS */
25 #if IS_ENABLED(CONFIG_PRU_REMOTEPROC)
27 struct rproc *pru_rproc_get(struct device_node *node, int index);
28 void pru_rproc_put(struct rproc *rproc);
30 #else
32 static inline struct rproc *pru_rproc_get(struct device_node *node, int index)
33 {
34         return ERR_PTR(-ENOTSUPP);
35 }
37 static inline void pru_rproc_put(struct rproc *rproc) { }
39 #endif /* CONFIG_PRU_REMOTEPROC */
41 #endif /* __LINUX_PRUSS_H */