1 /* $OpenBSD: gscpmreg.h,v 1.1 2004/09/15 20:28:53 grange Exp $ */ 2 /* 3 * Copyright (c) 2004 Alexander Yurchenko <grange@openbsd.org> 4 * 5 * Permission to use, copy, modify, and distribute this software for any 6 * purpose with or without fee is hereby granted, provided that the above 7 * copyright notice and this permission notice appear in all copies. 8 * 9 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 10 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 11 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 12 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 13 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 14 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 15 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 16 */ 17 18 #ifndef _DEV_PCI_GSCPMREG_H_ 19 #define _DEV_PCI_GSCPMREG_H_ 20 21 /* 22 * National Semiconductor Geode SC1100 SMI/ACPI module register definitions. 23 */ 24 25 /* PCI configuration space */ 26 #define GSCPM_ACPIBASE 0x40 /* ACPI I/O space base address */ 27 #define GSCPM_ACPISIZE 256 /* ACPI I/O space size */ 28 29 /* ACPI I/O space */ 30 #define GSCPM_P_CNT 0x00 /* processor control */ 31 #define GSCPM_P_CNT_CLK(val) ((val) & 0x7) 32 #define GSCPM_P_CNT_THTEN (1 << 4) /* throttle enable */ 33 #define GSCPM_PM_TMR 0x1c /* PM timer */ 34 35 /* CPU throttling values */ 36 static const struct { 37 int level; 38 int value; 39 } gscpm_tht[] = { 40 { 88, 1 }, 41 { 75, 2 }, 42 { 63, 3 }, 43 { 50, 4 }, 44 { 38, 5 }, 45 { 25, 6 }, 46 { 13, 7 } 47 }; 48 49 #define GSCPM_THT_LEVELS (sizeof(gscpm_tht) / sizeof(gscpm_tht[0])) 50 51 #endif /* !_DEV_PCI_GSCPMREG_H_ */ 52