acpi_cpu.c (209330) | acpi_cpu.c (212413) |
---|---|
1/*- 2 * Copyright (c) 2003-2005 Nate Lawson (SDG) 3 * Copyright (c) 2001 Michael Smith 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 12 unchanged lines hidden (view full) --- 21 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 22 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 23 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 24 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 25 * SUCH DAMAGE. 26 */ 27 28#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 2003-2005 Nate Lawson (SDG) 3 * Copyright (c) 2001 Michael Smith 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 12 unchanged lines hidden (view full) --- 21 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 22 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 23 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 24 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 25 * SUCH DAMAGE. 26 */ 27 28#include <sys/cdefs.h> |
29__FBSDID("$FreeBSD: head/sys/dev/acpica/acpi_cpu.c 209330 2010-06-19 08:46:17Z mav $"); | 29__FBSDID("$FreeBSD: head/sys/dev/acpica/acpi_cpu.c 212413 2010-09-10 11:19:03Z avg $"); |
30 31#include "opt_acpi.h" 32#include <sys/param.h> 33#include <sys/bus.h> 34#include <sys/cpu.h> 35#include <sys/kernel.h> 36#include <sys/malloc.h> 37#include <sys/module.h> --- 105 unchanged lines hidden (view full) --- 143 144static int acpi_cpu_probe(device_t dev); 145static int acpi_cpu_attach(device_t dev); 146static int acpi_cpu_suspend(device_t dev); 147static int acpi_cpu_resume(device_t dev); 148static int acpi_pcpu_get_id(uint32_t idx, uint32_t *acpi_id, 149 uint32_t *cpu_id); 150static struct resource_list *acpi_cpu_get_rlist(device_t dev, device_t child); | 30 31#include "opt_acpi.h" 32#include <sys/param.h> 33#include <sys/bus.h> 34#include <sys/cpu.h> 35#include <sys/kernel.h> 36#include <sys/malloc.h> 37#include <sys/module.h> --- 105 unchanged lines hidden (view full) --- 143 144static int acpi_cpu_probe(device_t dev); 145static int acpi_cpu_attach(device_t dev); 146static int acpi_cpu_suspend(device_t dev); 147static int acpi_cpu_resume(device_t dev); 148static int acpi_pcpu_get_id(uint32_t idx, uint32_t *acpi_id, 149 uint32_t *cpu_id); 150static struct resource_list *acpi_cpu_get_rlist(device_t dev, device_t child); |
151static device_t acpi_cpu_add_child(device_t dev, int order, const char *name, | 151static device_t acpi_cpu_add_child(device_t dev, u_int order, const char *name, |
152 int unit); 153static int acpi_cpu_read_ivar(device_t dev, device_t child, int index, 154 uintptr_t *result); 155static int acpi_cpu_shutdown(device_t dev); 156static void acpi_cpu_cx_probe(struct acpi_cpu_softc *sc); 157static void acpi_cpu_generic_cx_probe(struct acpi_cpu_softc *sc); 158static int acpi_cpu_cx_cst(struct acpi_cpu_softc *sc); 159static void acpi_cpu_startup(void *arg); --- 314 unchanged lines hidden (view full) --- 474 475 ad = device_get_ivars(child); 476 if (ad == NULL) 477 return (NULL); 478 return (&ad->ad_rl); 479} 480 481static device_t | 152 int unit); 153static int acpi_cpu_read_ivar(device_t dev, device_t child, int index, 154 uintptr_t *result); 155static int acpi_cpu_shutdown(device_t dev); 156static void acpi_cpu_cx_probe(struct acpi_cpu_softc *sc); 157static void acpi_cpu_generic_cx_probe(struct acpi_cpu_softc *sc); 158static int acpi_cpu_cx_cst(struct acpi_cpu_softc *sc); 159static void acpi_cpu_startup(void *arg); --- 314 unchanged lines hidden (view full) --- 474 475 ad = device_get_ivars(child); 476 if (ad == NULL) 477 return (NULL); 478 return (&ad->ad_rl); 479} 480 481static device_t |
482acpi_cpu_add_child(device_t dev, int order, const char *name, int unit) | 482acpi_cpu_add_child(device_t dev, u_int order, const char *name, int unit) |
483{ 484 struct acpi_cpu_device *ad; 485 device_t child; 486 487 if ((ad = malloc(sizeof(*ad), M_TEMP, M_NOWAIT | M_ZERO)) == NULL) 488 return (NULL); 489 490 resource_list_init(&ad->ad_rl); --- 726 unchanged lines hidden --- | 483{ 484 struct acpi_cpu_device *ad; 485 device_t child; 486 487 if ((ad = malloc(sizeof(*ad), M_TEMP, M_NOWAIT | M_ZERO)) == NULL) 488 return (NULL); 489 490 resource_list_init(&ad->ad_rl); --- 726 unchanged lines hidden --- |