From 82c28121f770ff4f9c928b3804b9d8b9e25a2d49 Mon Sep 17 00:00:00 2001 From: Mateusz Guzik Date: Tue, 1 Sep 2020 21:32:41 +0000 Subject: [PATCH] acpica: clean up empty lines in .c and .h files --- sys/dev/acpica/Osd/OsdHardware.c | 1 - sys/dev/acpica/acpi.c | 2 +- sys/dev/acpica/acpi_acad.c | 2 +- sys/dev/acpica/acpi_cpu.c | 1 - sys/dev/acpica/acpi_isab.c | 2 +- sys/dev/acpica/acpi_pci.c | 3 +-- sys/dev/acpica/acpi_pci_link.c | 5 +---- sys/dev/acpica/acpi_powerres.c | 1 - sys/dev/acpica/acpi_smbus.h | 1 - sys/dev/acpica/acpi_thermal.c | 2 -- sys/dev/acpica/acpi_timer.c | 4 ++-- sys/dev/acpica/acpivar.h | 1 - 12 files changed, 7 insertions(+), 18 deletions(-) diff --git a/sys/dev/acpica/Osd/OsdHardware.c b/sys/dev/acpica/Osd/OsdHardware.c index 20e2eeaa1f9..67952416f50 100644 --- a/sys/dev/acpica/Osd/OsdHardware.c +++ b/sys/dev/acpica/Osd/OsdHardware.c @@ -119,7 +119,6 @@ AcpiOsReadPciConfiguration(ACPI_PCI_ID *PciId, UINT32 Register, UINT64 *Value, #endif } - ACPI_STATUS AcpiOsWritePciConfiguration (ACPI_PCI_ID *PciId, UINT32 Register, UINT64 Value, UINT32 Width) diff --git a/sys/dev/acpica/acpi.c b/sys/dev/acpica/acpi.c index abe51726370..719c0ae0f97 100644 --- a/sys/dev/acpica/acpi.c +++ b/sys/dev/acpica/acpi.c @@ -1709,7 +1709,7 @@ acpi_device_id_probe(device_t bus, device_t dev, char **ids, char **match) rv = acpi_MatchHid(h, ids[i]); if (rv == ACPI_MATCHHID_NOMATCH) continue; - + if (match != NULL) { *match = ids[i]; } diff --git a/sys/dev/acpica/acpi_acad.c b/sys/dev/acpica/acpi_acad.c index 52cfcc50d9a..25a88714770 100644 --- a/sys/dev/acpica/acpi_acad.c +++ b/sys/dev/acpica/acpi_acad.c @@ -46,7 +46,7 @@ __FBSDID("$FreeBSD$"); #include #include #include - + /* Hooks for the ACPI CA debugging infrastructure */ #define _COMPONENT ACPI_AC_ADAPTER ACPI_MODULE_NAME("AC_ADAPTER") diff --git a/sys/dev/acpica/acpi_cpu.c b/sys/dev/acpica/acpi_cpu.c index e5d02cca974..ce252ab9281 100644 --- a/sys/dev/acpica/acpi_cpu.c +++ b/sys/dev/acpica/acpi_cpu.c @@ -873,7 +873,6 @@ acpi_cpu_cx_cst(struct acpi_cpu_softc *sc) acpi_PkgInt32(pkg, 1, &cx_ptr->type) != 0 || acpi_PkgInt32(pkg, 2, &cx_ptr->trans_lat) != 0 || acpi_PkgInt32(pkg, 3, &cx_ptr->power) != 0) { - device_printf(sc->cpu_dev, "skipping invalid Cx state package\n"); continue; } diff --git a/sys/dev/acpica/acpi_isab.c b/sys/dev/acpica/acpi_isab.c index 605ea673d22..2f9bcd25851 100644 --- a/sys/dev/acpica/acpi_isab.c +++ b/sys/dev/acpica/acpi_isab.c @@ -92,7 +92,7 @@ acpi_isab_probe(device_t dev) { static char *isa_ids[] = { "PNP0A05", "PNP0A06", NULL }; int rv; - + if (acpi_disabled("isab") || devclass_get_device(isab_devclass, 0) != dev) return (ENXIO); diff --git a/sys/dev/acpica/acpi_pci.c b/sys/dev/acpica/acpi_pci.c index 9ae0443ae7e..23261cf060b 100644 --- a/sys/dev/acpica/acpi_pci.c +++ b/sys/dev/acpica/acpi_pci.c @@ -424,7 +424,7 @@ acpi_pci_attach(device_t dev) acpi_pci_bus_notify_handler, dev); AcpiWalkNamespace(ACPI_TYPE_DEVICE, acpi_get_handle(dev), 1, acpi_pci_install_device_notify_handler, NULL, dev, NULL); - + return (0); } @@ -479,4 +479,3 @@ acpi_pci_get_dma_tag(device_t bus, device_t child) return (pci_get_dma_tag(bus, child)); } #endif - diff --git a/sys/dev/acpica/acpi_pci_link.c b/sys/dev/acpica/acpi_pci_link.c index f172382c7fc..ecc4f26d3fb 100644 --- a/sys/dev/acpica/acpi_pci_link.c +++ b/sys/dev/acpica/acpi_pci_link.c @@ -157,7 +157,7 @@ acpi_pci_link_probe(device_t dev) rv = ACPI_ID_PROBE(device_get_parent(dev), dev, pci_link_ids, NULL); if (rv > 0) return (rv); - + if (ACPI_SUCCESS(acpi_short_name(acpi_get_handle(dev), name, sizeof(name)))) { snprintf(descr, sizeof(descr), "ACPI PCI Link %s", name); @@ -811,11 +811,9 @@ acpi_pci_link_srs_from_links(struct acpi_pci_link_softc *sc, srsbuf->Pointer = NULL; link = sc->pl_links; for (i = 0; i < sc->pl_num_links; i++) { - /* Add a new IRQ resource from each link. */ link = &sc->pl_links[i]; if (link->l_prs_template.Type == ACPI_RESOURCE_TYPE_IRQ) { - /* Build an IRQ resource. */ bcopy(&link->l_prs_template, &newres, ACPI_RS_SIZE(newres.Data.Irq)); @@ -828,7 +826,6 @@ acpi_pci_link_srs_from_links(struct acpi_pci_link_softc *sc, } else newres.Data.Irq.Interrupts[0] = 0; } else { - /* Build an ExtIRQ resuorce. */ bcopy(&link->l_prs_template, &newres, ACPI_RS_SIZE(newres.Data.ExtendedIrq)); diff --git a/sys/dev/acpica/acpi_powerres.c b/sys/dev/acpica/acpi_powerres.c index 765825e0ec2..fbde1cd9b55 100644 --- a/sys/dev/acpica/acpi_powerres.c +++ b/sys/dev/acpica/acpi_powerres.c @@ -659,7 +659,6 @@ acpi_pwr_switch_power(void) /* Sweep the list backwards turning things off. */ TAILQ_FOREACH_REVERSE(rp, &acpi_powerresources, acpi_powerresource_list, ap_link) { - if (TAILQ_FIRST(&rp->ap_references) != NULL) { ACPI_DEBUG_PRINT((ACPI_DB_OBJECTS, "%s has references, not turning off\n", diff --git a/sys/dev/acpica/acpi_smbus.h b/sys/dev/acpica/acpi_smbus.h index dd0d9b250cc..527b22700ee 100644 --- a/sys/dev/acpica/acpi_smbus.h +++ b/sys/dev/acpica/acpi_smbus.h @@ -49,7 +49,6 @@ /* Base address */ #define SMBATT_ADDRESS 0x16 - /* access: READ WRITE WORD */ #define SMBATT_CMD_MANUFACTURER_ACCESS 0 diff --git a/sys/dev/acpica/acpi_thermal.c b/sys/dev/acpica/acpi_thermal.c index 73b2de51b38..cd2024be00d 100644 --- a/sys/dev/acpica/acpi_thermal.c +++ b/sys/dev/acpica/acpi_thermal.c @@ -530,7 +530,6 @@ acpi_tz_monitor(void *Context) if (acpi_tz_min_runtime > 0 && sc->tz_active != TZ_ACTIVE_NONE && sc->tz_active != TZ_ACTIVE_UNKNOWN && (newactive == TZ_ACTIVE_NONE || newactive > sc->tz_active)) { - getnanotime(&curtime); timespecsub(&curtime, &sc->tz_cooling_started, &curtime); if (curtime.tv_sec < acpi_tz_min_runtime) @@ -926,7 +925,6 @@ acpi_tz_power_profile(void *arg) /* check that we haven't decided there's no _SCP method */ if ((sc->tz_flags & TZ_FLAG_NO_SCP) == 0) { - /* Call _SCP to set the new profile */ status = acpi_SetInteger(sc->tz_handle, "_SCP", (state == POWER_PROFILE_PERFORMANCE) ? 0 : 1); diff --git a/sys/dev/acpica/acpi_timer.c b/sys/dev/acpica/acpi_timer.c index b15c39ac6bb..763a47a1a95 100644 --- a/sys/dev/acpica/acpi_timer.c +++ b/sys/dev/acpica/acpi_timer.c @@ -354,7 +354,7 @@ acpi_timer_sysctl_freq(SYSCTL_HANDLER_ARGS) { int error; u_int freq; - + if (acpi_timer_timecounter.tc_frequency == 0) return (EOPNOTSUPP); freq = acpi_timer_frequency; @@ -366,7 +366,7 @@ acpi_timer_sysctl_freq(SYSCTL_HANDLER_ARGS) return (error); } - + SYSCTL_PROC(_machdep, OID_AUTO, acpi_timer_freq, CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_NEEDGIANT, 0, sizeof(u_int), acpi_timer_sysctl_freq, "I", diff --git a/sys/dev/acpica/acpivar.h b/sys/dev/acpica/acpivar.h index 69890f15301..80b75f69ff5 100644 --- a/sys/dev/acpica/acpivar.h +++ b/sys/dev/acpica/acpivar.h @@ -377,7 +377,6 @@ int acpi_MatchHid(ACPI_HANDLE h, const char *hid); #define ACPI_MATCHHID_HID 1 #define ACPI_MATCHHID_CID 2 - struct acpi_parse_resource_set { void (*set_init)(device_t dev, void *arg, void **context); void (*set_done)(device_t dev, void *context);