Module Name: src Committed By: macallan Date: Sat Sep 15 01:05:07 UTC 2018
Modified Files: src/sys/arch/sgimips/hpc: hpc.c Log Message: remove long unused power button handler To generate a diff of this commit: cvs rdiff -u -r1.70 -r1.71 src/sys/arch/sgimips/hpc/hpc.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/arch/sgimips/hpc/hpc.c diff -u src/sys/arch/sgimips/hpc/hpc.c:1.70 src/sys/arch/sgimips/hpc/hpc.c:1.71 --- src/sys/arch/sgimips/hpc/hpc.c:1.70 Sat Sep 15 00:37:53 2018 +++ src/sys/arch/sgimips/hpc/hpc.c Sat Sep 15 01:05:06 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: hpc.c,v 1.70 2018/09/15 00:37:53 macallan Exp $ */ +/* $NetBSD: hpc.c,v 1.71 2018/09/15 01:05:06 macallan Exp $ */ /* * Copyright (c) 2000 Soren S. Jorvang @@ -35,7 +35,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: hpc.c,v 1.70 2018/09/15 00:37:53 macallan Exp $"); +__KERNEL_RCSID(0, "$NetBSD: hpc.c,v 1.71 2018/09/15 01:05:06 macallan Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -347,9 +347,6 @@ static struct hpc_values hpc3_values = { .scsi_dmactl_reset = HPC3_SCSI_DMACTL_RESET }; - -static int powerintr_established; - static int hpc_match(device_t, cfdata_t, void *); static void hpc_attach(device_t, device_t, void *); static int hpc_print(void *, const char *); @@ -547,19 +544,6 @@ hpc_attach(device_t parent, device_t sel } } - /* - * XXX: Only attach the powerfail interrupt once, since the - * interrupt code doesn't let you share interrupt just yet. - * - * Since the powerfail interrupt is hardcoded to read from - * a specific register anyway (XXX#2!), we don't care when - * it gets attached, as long as it only happens once. - */ - if (mach_type == MACH_SGI_IP22 && !powerintr_established) { -// cpu_intr_establish(9, IPL_NONE, hpc_power_intr, sc); - powerintr_established++; - } - #if defined(BLINK) if (mach_type == MACH_SGI_IP12 || mach_type == MACH_SGI_IP20) hpc_blink(sc); @@ -672,24 +656,6 @@ hpc_print(void *aux, const char *pnp) return (UNCONF); } -#if 0 -static int -hpc_power_intr(void *arg) -{ - uint32_t pwr_reg; - - pwr_reg = *((volatile uint32_t *)MIPS_PHYS_TO_KSEG1(0x1fbd9850)); - *((volatile uint32_t *)MIPS_PHYS_TO_KSEG1(0x1fbd9850)) = pwr_reg; - - printf("hpc_power_intr: panel reg = %08x\n", pwr_reg); - - if (pwr_reg & 2) - cpu_reboot(RB_HALT, NULL); - - return 1; -} -#endif - #if defined(BLINK) static void hpc_blink(void *arg)