blob: 4dec4ed138cd7fdc8a7f5fb74a55b6c708e29528 [file] [log] [blame]
Thomas Gleixnerb886d832019-06-01 10:08:55 +02001/* SPDX-License-Identifier: GPL-2.0-only */
Hoan Tran866ae692016-06-16 14:09:38 -07002/*
3 * PCC (Platform Communications Channel) methods
Hoan Tran866ae692016-06-16 14:09:38 -07004 */
5
6#ifndef _PCC_H
7#define _PCC_H
8
9#include <linux/mailbox_controller.h>
10#include <linux/mailbox_client.h>
11
George Cherianc4b766c2017-10-11 08:54:57 +000012#define MAX_PCC_SUBSPACES 256
Hoan Tran866ae692016-06-16 14:09:38 -070013#ifdef CONFIG_PCC
14extern struct mbox_chan *pcc_mbox_request_channel(struct mbox_client *cl,
15 int subspace_id);
16extern void pcc_mbox_free_channel(struct mbox_chan *chan);
17#else
18static inline struct mbox_chan *pcc_mbox_request_channel(struct mbox_client *cl,
19 int subspace_id)
20{
Hoan Trand0679cf2016-10-14 16:20:21 -070021 return ERR_PTR(-ENODEV);
Hoan Tran866ae692016-06-16 14:09:38 -070022}
23static inline void pcc_mbox_free_channel(struct mbox_chan *chan) { }
24#endif
25
26#endif /* _PCC_H */