1/* 2 * Copyright (c) 2014 ETH Zurich. 3 * All rights reserved. 4 * 5 * This file is distributed under the terms in the attached LICENSE file. 6 * If you do not find this file, copies can be found by writing to: 7 * ETH Zurich D-INFK, Universitaetsstrasse 6, CH-8092 Zurich. Attn: Systems Group. 8 */ 9 10#ifndef XEON_PHI_DOMAIN_H_ 11#define XEON_PHI_DOMAIN_H_ 12 13 14#define XEON_PHI_DOMAIN_DONT_CARE 0xFF 15 16#define XEON_PHI_DOMAIN_HOST 0x10 17 18/** 19 * \brief builds the iface name representation 20 * 21 * \param name Name of the domain 22 * \param xid Xeon Phi ID or XEON_PHI_DOMAIN_HOST the domain is runnig on 23 * \param core The core the domain is running on 24 * 25 * \returns string with the proper format 26 */ 27char *xeon_phi_domain_build_iface(const char *name, 28 xphi_id_t xid, 29 coreid_t core); 30 31/** 32 * \brief Non-blocking name service lookup 33 * 34 * \param iface Name of the domain 35 * \param retdomid returns the Xeon Phi Domain ID 36 */ 37errval_t xeon_phi_domain_lookup(const char *iface, 38 xphi_dom_id_t *retdomid); 39 40/** 41 * \brief Blocking name service lookup 42 * 43 * \param iface Name of the domain 44 * \param retdomid returns the Xeon Phi Domain ID 45 */ 46errval_t xeon_phi_domain_blocking_lookup(const char *iface, 47 xphi_dom_id_t *retdomid); 48 49/** 50 * \brief Register with name service 51 * 52 * \param iface Name of the domain 53 * \param retdomid returns the Xeon Phi Domain ID 54 */ 55errval_t xeon_phi_domain_register(const char *iface, 56 xphi_dom_id_t domid); 57 58#endif // XEON_PHI_DOMAIN_H_ 59