/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef _SYS_PCIE_PWR_H
#define _SYS_PCIE_PWR_H
#ifdef __cplusplus
extern "C" {
#endif
/* index of counters for each level */
/*
* PCIe nexus power management data structure
*/
typedef struct pcie_pwr {
/*
* general data structure fields
*/
/* power level change */
/*
* counters to keep track of child's power level.
* D3,D2,D1,D0 and unknown respectively.
*/
} pcie_pwr_t;
typedef struct pcie_pwr_child {
/*
* Per child dip counters decsribing
* a child's components
*/
typedef struct pcie_pm {
} pcie_pm_t;
/*
* pmcap field: device power management capability.
* First 4 bits must indicate support for D3, D2, D1 and D0
* respectively. Their bit position matches with their index
* into the counters array.
*/
/*
* flags field
*/
#define PM_LEVEL_L3 0
/* ioctl definitions for ppm drivers */
/* settle time in microseconds before PCI operation */
/*
* Interface with other parts of the driver(s) code
*/
/*
* We link pcie_pwr.o into several drivers (px, pcieb, pcieb_bcm, pcieb_plx),
* which causes the symbols below to be duplicated. This isn't an issue in
* practice, since they aren't used from outside the module that they're
* part of. However, lint does not know this, and when it does global
* crosschecks for the kernel, it complains. To prevent this, we rename the
* symbols to driver-specific names when we're doing a lint run.
*/
#if defined(lint)
#if defined(PX_MOD_NAME)
#endif /* PX_MOD_NAME */
#if defined(PX_PLX)
#endif /* PX_PLX */
#endif /* lint */
#ifdef __cplusplus
}
#endif
#endif /* _SYS_PCIE_PWR_H */