4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
23 * Copyright 2010 PathScale Inc. All rights reserved.
24 * Use is subject to license terms.
40 char param_name
[7][15] = {"chipset_id", "vendor", "device", "bus type",
41 "graph units", "ptimer time",
44 tmp
[0] = PSCNV_GETPARAM_CHIPSET_ID
;
45 tmp
[1] = PSCNV_GETPARAM_PCI_VENDOR
;
46 tmp
[2] = PSCNV_GETPARAM_PCI_DEVICE
;
47 tmp
[3] = PSCNV_GETPARAM_BUS_TYPE
;
48 tmp
[4] = PSCNV_GETPARAM_GRAPH_UNITS
;
49 tmp
[5] = PSCNV_GETPARAM_PTIMER_TIME
;
50 tmp
[6] = PSCNV_GETPARAM_FB_SIZE
;
53 for (i
= 0; i
< 7; i
++) {
54 ret
= pscnv_getparam(fd
, tmp
[i
], &value
);
56 printf("%s : 0x%llx\n", param_name
[i
], value
);
58 printf("%s : failed ret = %d\n", param_name
[i
], ret
);
71 fd
= drmOpen("pscnv", 0);