From nobody Thu Apr 27 13:13:25 2023 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Q6blV0XJ8z477yf; Thu, 27 Apr 2023 13:13:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Q6blV0521z3wtG; Thu, 27 Apr 2023 13:13:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1682601206; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=rXxn/WiEXp4jLvgA3vPjlaaCGSlSstOsCm20tQfQrIg=; b=vVwHEy2Y169UMn9YUu84GQHQ1hachoyIFOSDc6m0STQMyNv7QM0pui4T2YrBl+VJEvYgNG 1z/kquZB/8LcKoW0Tt2llqweQY7gOsVQ9pnoJy30J8Mw5ecyIiOZiT3VCktw3jHmlEH5K2 FjUP+tE1CqAAXJqegX8OLWO977q0xn9b8kXZ2mbESVtqxo+5x0FL0LC0xw68tvzHCs/fyD +i7S8cgiuEslNZYR2XmR6FPRocFvi8ltCdTyaiFhXfkgiNvlICcHsDp/z9XcJNPwH6l6ce YAczpgObO/wEt4qLO+AjLyO+Wexzd5NNc85twuFkiDl1wVVuWm3N0Y5wynvxKg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1682601206; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=rXxn/WiEXp4jLvgA3vPjlaaCGSlSstOsCm20tQfQrIg=; b=IOLCKMq2vdzK4ZJIquntK9z23RX7OIVo3l/Yll1lnJ1qs5jnUYBJFnItpbXSK4HEN2fAwP 512YIVGZOtQdyBs+3sZegjFI5R5PpNIabKwp65RMd9EjB2cRnrBG5bzE67+B/9zfrTAL+x q/XX9aRnoRr3SY4QptIiPXIYW6grOvg7h+YbHramI0FwjedtR55voj01X/D8RyAHDF/A9s OsIPnsdZNaCOHHc+rLnp0CnbW5CS9w/nF+KIizxhteKKSumw1VQ7tE2b8tZOc949B3aW4o OC0m8y+hasRK84YMJF1+FJwubi9t97sDOEdjIdWx9MbeA8Dy3PnB2sh2WoSMAg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1682601206; a=rsa-sha256; cv=none; b=gR5nMNZkyFD+0LsidWWNpjIWmO8ZCfWXn262vGQ9pJppqvpoq/D31TXOQwjF2ZgsOfCyWp IiiuqVVu6qs0ycqY25QzMHvNoNxhD5LfQTrRhjQ6njBkiYwJy4reNg+II+HIU+tVbdM4PQ Euv3w3TlydDGLeMDbYCotA4MNexprt7nfj09ePGuIX26vfjPE+iaprlKwVlfA1ReSxWCvo UpwtOUJZq/5YZFVr4gy3+3u3v4tQ54bgbEhGEs7EfJY/XZFIE+/j5Q80di5Tqsinx0g/Yr euEobLeILCl6VoxcaYHOwWsqnHMRi5yMrs4imGzyZt9Yfx55xdmNp7w/vpmKHA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Q6blT6FH1zJxy; Thu, 27 Apr 2023 13:13:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 33RDDPZq062440; Thu, 27 Apr 2023 13:13:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 33RDDP67062439; Thu, 27 Apr 2023 13:13:25 GMT (envelope-from git) Date: Thu, 27 Apr 2023 13:13:25 GMT Message-Id: <202304271313.33RDDP67062439@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Guido Falsi Subject: git: 03d3124629e8 - main - bhyve: Disable bhyve HDA debug by default. List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: madpilot X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 03d3124629e886e4721550a659a032b129ee0347 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by madpilot: URL: https://cgit.FreeBSD.org/src/commit/?id=03d3124629e886e4721550a659a032b129ee0347 commit 03d3124629e886e4721550a659a032b129ee0347 Author: Guido Falsi AuthorDate: 2023-04-03 10:45:11 +0000 Commit: Guido Falsi CommitDate: 2023-04-27 13:12:45 +0000 bhyve: Disable bhyve HDA debug by default. Adapt hda_print_cmd_ctl_data() to not generate compiler warnings when DEBUG_HDA is off. Reviewed by: corvink Approved by: corvink Differential Revision: https://reviews.freebsd.org/D39826 --- usr.sbin/bhyve/pci_hda.c | 16 +++++++++------- usr.sbin/bhyve/pci_hda.h | 1 - 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/usr.sbin/bhyve/pci_hda.c b/usr.sbin/bhyve/pci_hda.c index 9e9d7ab5a626..07b0e745b0b9 100644 --- a/usr.sbin/bhyve/pci_hda.c +++ b/usr.sbin/bhyve/pci_hda.c @@ -726,17 +726,19 @@ hda_write(struct hda_softc *sc, uint32_t offset, uint8_t size, uint32_t value) return (0); } +#if DEBUG_HDA == 1 static inline void hda_print_cmd_ctl_data(struct hda_codec_cmd_ctl *p) { -#if DEBUG_HDA == 1 - const char *name = p->name; -#endif - DPRINTF("%s size: %d", name, p->size); - DPRINTF("%s dma_vaddr: %p", name, p->dma_vaddr); - DPRINTF("%s wp: 0x%x", name, p->wp); - DPRINTF("%s rp: 0x%x", name, p->rp); + DPRINTF("%s size: %d", p->name, p->size); + DPRINTF("%s dma_vaddr: %p", p->name, p->dma_vaddr); + DPRINTF("%s wp: 0x%x", p->name, p->wp); + DPRINTF("%s rp: 0x%x", p->name, p->rp); } +#else +static inline void +hda_print_cmd_ctl_data(struct hda_codec_cmd_ctl *p __unused) {} +#endif static int hda_corb_start(struct hda_softc *sc) diff --git a/usr.sbin/bhyve/pci_hda.h b/usr.sbin/bhyve/pci_hda.h index 12d80a92f60a..8b24afac4771 100644 --- a/usr.sbin/bhyve/pci_hda.h +++ b/usr.sbin/bhyve/pci_hda.h @@ -46,7 +46,6 @@ /* * HDA Debug Log */ -#define DEBUG_HDA 1 #if DEBUG_HDA == 1 extern FILE *dbg; #define DPRINTF(fmt, arg...) \