common/cnxk: add BPHY communication with atf
[dpdk.git] / drivers / common / cnxk / roc_bphy_cgx.h
1 /* SPDX-License-Identifier: BSD-3-Clause
2  * Copyright(C) 2021 Marvell.
3  */
4
5 #ifndef _ROC_BPHY_CGX_H_
6 #define _ROC_BPHY_CGX_H_
7
8 #include <pthread.h>
9
10 #include "roc_api.h"
11
12 struct roc_bphy_cgx {
13         uint64_t bar0_pa;
14         void *bar0_va;
15         uint64_t lmac_bmap;
16         unsigned int id;
17         /* serialize access to the whole structure */
18         pthread_mutex_t lock;
19 } __plt_cache_aligned;
20
21 __roc_api int roc_bphy_cgx_dev_init(struct roc_bphy_cgx *roc_cgx);
22 __roc_api int roc_bphy_cgx_dev_fini(struct roc_bphy_cgx *roc_cgx);
23
24 #endif /* _ROC_BPHY_CGX_H_ */