svn commit: r360105 - head/sys/dev/sound/pci/hda

Ed Maste emaste at FreeBSD.org
Sun Apr 19 17:53:45 UTC 2020


Author: emaste
Date: Sun Apr 19 17:53:44 2020
New Revision: 360105
URL: https://svnweb.freebsd.org/changeset/base/360105

Log:
  snd_hda: whitespace and style(9) cleanups

Modified:
  head/sys/dev/sound/pci/hda/hdac.c
  head/sys/dev/sound/pci/hda/hdacc.c

Modified: head/sys/dev/sound/pci/hda/hdac.c
==============================================================================
--- head/sys/dev/sound/pci/hda/hdac.c	Sun Apr 19 17:28:42 2020	(r360104)
+++ head/sys/dev/sound/pci/hda/hdac.c	Sun Apr 19 17:53:44 2020	(r360105)
@@ -360,8 +360,7 @@ hdac_poll_callback(void *arg)
 		hdac_unlock(sc);
 		return;
 	}
-	callout_reset(&sc->poll_callout, sc->poll_ival,
-	    hdac_poll_callback, sc);
+	callout_reset(&sc->poll_callout, sc->poll_ival, hdac_poll_callback, sc);
 	hdac_unlock(sc);
 
 	hdac_intr_handler(sc);
@@ -412,7 +411,7 @@ hdac_reset(struct hdac_softc *sc, int wakeup)
 		if (!(gctl & HDAC_GCTL_CRST))
 			break;
 		DELAY(10);
-	} while	(--count);
+	} while (--count);
 	if (gctl & HDAC_GCTL_CRST) {
 		device_printf(sc->dev, "Unable to put hdac in reset\n");
 		return (ENXIO);
@@ -446,7 +445,6 @@ hdac_reset(struct hdac_softc *sc, int wakeup)
 	return (0);
 }
 
-
 /****************************************************************************
  * int hdac_get_capabilities(struct hdac_softc *);
  *
@@ -620,11 +618,10 @@ hdac_dma_alloc_fail:
 	return (result);
 }
 
-
 /****************************************************************************
  * void hdac_dma_free(struct hdac_softc *, struct hdac_dma *)
  *
- * Free a struct dhac_dma that has been previously allocated via the
+ * Free a struct hdac_dma that has been previously allocated via the
  * hdac_dma_alloc function.
  ****************************************************************************/
 static void
@@ -1041,8 +1038,7 @@ hdac_probe(device_t dev)
 		if (HDA_DEV_MATCH(hdac_devices[i].model, model) &&
 		    class == PCIC_MULTIMEDIA &&
 		    subclass == PCIS_MULTIMEDIA_HDA) {
-			snprintf(desc, sizeof(desc),
-			    "%s (0x%04x)",
+			snprintf(desc, sizeof(desc), "%s (0x%04x)",
 			    hdac_devices[i].desc, pci_get_device(dev));
 			result = BUS_PROBE_GENERIC;
 			break;
@@ -1700,20 +1696,17 @@ hdac_print_child(device_t dev, device_t child)
 	int retval;
 
 	retval = bus_print_child_header(dev, child);
-	retval += printf(" at cad %d",
-	    (int)(intptr_t)device_get_ivars(child));
+	retval += printf(" at cad %d", (int)(intptr_t)device_get_ivars(child));
 	retval += bus_print_child_footer(dev, child);
 
 	return (retval);
 }
 
 static int
-hdac_child_location_str(device_t dev, device_t child, char *buf,
-    size_t buflen)
+hdac_child_location_str(device_t dev, device_t child, char *buf, size_t buflen)
 {
 
-	snprintf(buf, buflen, "cad=%d",
-	    (int)(intptr_t)device_get_ivars(child));
+	snprintf(buf, buflen, "cad=%d", (int)(intptr_t)device_get_ivars(child));
 	return (0);
 }
 
@@ -1724,8 +1717,8 @@ hdac_child_pnpinfo_str_method(device_t dev, device_t c
 	struct hdac_softc *sc = device_get_softc(dev);
 	nid_t cad = (uintptr_t)device_get_ivars(child);
 
-	snprintf(buf, buflen, "vendor=0x%04x device=0x%04x revision=0x%02x "
-	    "stepping=0x%02x",
+	snprintf(buf, buflen,
+	    "vendor=0x%04x device=0x%04x revision=0x%02x stepping=0x%02x",
 	    sc->codecs[cad].vendor_id, sc->codecs[cad].device_id,
 	    sc->codecs[cad].revision_id, sc->codecs[cad].stepping_id);
 	return (0);
@@ -1901,8 +1894,8 @@ hdac_stream_free(device_t dev, device_t child, int dir
 }
 
 static int
-hdac_stream_start(device_t dev, device_t child,
-    int dir, int stream, bus_addr_t buf, int blksz, int blkcnt)
+hdac_stream_start(device_t dev, device_t child, int dir, int stream,
+    bus_addr_t buf, int blksz, int blkcnt)
 {
 	struct hdac_softc *sc = device_get_softc(dev);
 	struct hdac_bdle *bdle;

Modified: head/sys/dev/sound/pci/hda/hdacc.c
==============================================================================
--- head/sys/dev/sound/pci/hda/hdacc.c	Sun Apr 19 17:28:42 2020	(r360104)
+++ head/sys/dev/sound/pci/hda/hdacc.c	Sun Apr 19 17:53:44 2020	(r360105)
@@ -434,7 +434,8 @@ hdacc_probe(device_t dev)
 	int i;
 
 	id = ((uint32_t)hda_get_vendor_id(dev) << 16) + hda_get_device_id(dev);
-	revid = ((uint32_t)hda_get_revision_id(dev) << 8) + hda_get_stepping_id(dev);
+	revid = ((uint32_t)hda_get_revision_id(dev) << 8) +
+	    hda_get_stepping_id(dev);
 
 	for (i = 0; i < nitems(hdacc_codecs); i++) {
 		if (!HDA_DEV_MATCH(hdacc_codecs[i].id, id))
@@ -525,8 +526,7 @@ hdacc_detach(device_t dev)
 }
 
 static int
-hdacc_child_location_str(device_t dev, device_t child, char *buf,
-    size_t buflen)
+hdacc_child_location_str(device_t dev, device_t child, char *buf, size_t buflen)
 {
 	struct hdacc_fg *fg = device_get_ivars(child);
 
@@ -645,8 +645,8 @@ hdacc_stream_free(device_t dev, device_t child, int di
 }
 
 static int
-hdacc_stream_start(device_t dev, device_t child,
-    int dir, int stream, bus_addr_t buf, int blksz, int blkcnt)
+hdacc_stream_start(device_t dev, device_t child, int dir, int stream,
+    bus_addr_t buf, int blksz, int blkcnt)
 {
 
 	return (HDAC_STREAM_START(device_get_parent(dev), dev,


More information about the svn-src-all mailing list