1*4bac2208Snarayan /* 2*4bac2208Snarayan * CDDL HEADER START 3*4bac2208Snarayan * 4*4bac2208Snarayan * The contents of this file are subject to the terms of the 5*4bac2208Snarayan * Common Development and Distribution License (the "License"). 6*4bac2208Snarayan * You may not use this file except in compliance with the License. 7*4bac2208Snarayan * 8*4bac2208Snarayan * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 9*4bac2208Snarayan * or http://www.opensolaris.org/os/licensing. 10*4bac2208Snarayan * See the License for the specific language governing permissions 11*4bac2208Snarayan * and limitations under the License. 12*4bac2208Snarayan * 13*4bac2208Snarayan * When distributing Covered Code, include this CDDL HEADER in each 14*4bac2208Snarayan * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 15*4bac2208Snarayan * If applicable, add the following below this CDDL HEADER, with the 16*4bac2208Snarayan * fields enclosed by brackets "[]" replaced with your own identifying 17*4bac2208Snarayan * information: Portions Copyright [yyyy] [name of copyright owner] 18*4bac2208Snarayan * 19*4bac2208Snarayan * CDDL HEADER END 20*4bac2208Snarayan */ 21*4bac2208Snarayan /* 22*4bac2208Snarayan * Copyright 2006 Sun Microsystems, Inc. All rights reserved. 23*4bac2208Snarayan * Use is subject to license terms. 24*4bac2208Snarayan */ 25*4bac2208Snarayan 26*4bac2208Snarayan #ifndef _PCP_UTILS_H 27*4bac2208Snarayan #define _PCP_UTILS_H 28*4bac2208Snarayan 29*4bac2208Snarayan #pragma ident "%Z%%M% %I% %E% SMI" 30*4bac2208Snarayan 31*4bac2208Snarayan #ifdef __cplusplus 32*4bac2208Snarayan extern "C" { 33*4bac2208Snarayan #endif 34*4bac2208Snarayan 35*4bac2208Snarayan /* 36*4bac2208Snarayan * Enum to differentiate supported transport types 37*4bac2208Snarayan */ 38*4bac2208Snarayan typedef enum { 39*4bac2208Snarayan GLVC_NON_STREAM, 40*4bac2208Snarayan VLDC_STREAMING 41*4bac2208Snarayan } pcp_xport_t; 42*4bac2208Snarayan 43*4bac2208Snarayan /* 44*4bac2208Snarayan * This file contains some auxiliary routines to enable libpcp to 45*4bac2208Snarayan * automatically find the device pathname of a given SP service 46*4bac2208Snarayan * (e.g. SUNW,sun4v-fma). In addition, glvc pathnames are 47*4bac2208Snarayan * converted to a service name and then a device path to maintain 48*4bac2208Snarayan * backward compatibility for applications still using full glvc 49*4bac2208Snarayan * device paths. The routines are defined in a separate source 50*4bac2208Snarayan * file, so any program can separately link with the .o file 51*4bac2208Snarayan * directly instead of using libpcp. 52*4bac2208Snarayan */ 53*4bac2208Snarayan 54*4bac2208Snarayan char *platsvc_extract_svc_name(char *devname); 55*4bac2208Snarayan char *platsvc_name_to_path(char *, pcp_xport_t *); 56*4bac2208Snarayan 57*4bac2208Snarayan #ifdef __cplusplus 58*4bac2208Snarayan } 59*4bac2208Snarayan #endif 60*4bac2208Snarayan 61*4bac2208Snarayan #endif /* _PCP_UTILS_H */ 62