Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 4D360EE49A0 for ; Wed, 23 Aug 2023 08:09:31 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 4FF03950; Wed, 23 Aug 2023 10:08:39 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 4FF03950 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1692778169; bh=iB3uazZYeoZCECjbN043tKQgzjYej+bFUsdYgjIYkMM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=MfJqfVYEqgFGo0N8yyOndPoW6O0iiFsbdG0OKOJhos40/K9jVjANTB9rs5XHa5Zif giSzIRBo1YaucZ/V9NDfGVq/ZrJILLVsnme8NOz7cEIOKY3UYSdf3RFDgmdvDqHNBY evgViE8oGCrB0XN/Nw4Ee9tLbW9YC9UKVK0fR6oY= Received: by alsa1.perex.cz (Postfix, from userid 50401) id 71C6DF8057B; Wed, 23 Aug 2023 10:07:33 +0200 (CEST) Received: from mailman-core.alsa-project.org (mailman-core.alsa-project.org [10.254.200.10]) by alsa1.perex.cz (Postfix) with ESMTP id B28ACF8057A; Wed, 23 Aug 2023 10:07:32 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 21AC0F804DA; Wed, 23 Aug 2023 10:06:27 +0200 (CEST) Received: from mgamail.intel.com (mgamail.intel.com [192.55.52.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id B186AF804F3 for ; Wed, 23 Aug 2023 10:06:21 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz B186AF804F3 Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key, unprotected) header.d=intel.com header.i=@intel.com header.a=rsa-sha256 header.s=Intel header.b=VrGCoqDV DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1692777984; x=1724313984; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=iB3uazZYeoZCECjbN043tKQgzjYej+bFUsdYgjIYkMM=; b=VrGCoqDVrICMPvZSZDW7HKuPgxoDu792Oig7mB11jRRou1DN+IKOYtCu Lv87WhlSLbfivH8Roq1Fbn5N8x2aSLR/9pN0jFyIIsZBES13N2GK4wgr0 /ZSF+9gZNt5a8vhU0jfWgj+U1pW7D7lrjy6djJpMUAYBqoJ+aa6EmYo/3 JNstWpR8itt1hMk4ezoF7X1svP2Hipqifnb7nZRQ+9V33jOvjLv/xuqJ2 liRw5t22cXHx6Y2WW4ZDny8C2zkb1sEVTnSu9SpBLpt+jiUpmpftbNkRn aYjHTfa+rp86EwXlZLAGOSUB2ye8mxKa4eqtdAwfBBpWBO/00AYOMwPKp Q==; X-IronPort-AV: E=McAfee;i="6600,9927,10810"; a="372988069" X-IronPort-AV: E=Sophos;i="6.01,195,1684825200"; d="scan'208";a="372988069" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 23 Aug 2023 01:06:21 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10810"; a="766042709" X-IronPort-AV: E=Sophos;i="6.01,195,1684825200"; d="scan'208";a="766042709" Received: from crojewsk-ctrl.igk.intel.com ([10.102.9.28]) by orsmga008.jf.intel.com with ESMTP; 23 Aug 2023 01:06:18 -0700 From: Cezary Rojewski To: broonie@kernel.org, tiwai@suse.com, perex@perex.cz Cc: alsa-devel@alsa-project.org, amadeuszx.slawinski@linux.intel.com, pierre-louis.bossart@linux.intel.com, hdegoede@redhat.com, Cezary Rojewski Subject: [PATCH 07/17] ALSA: hda/hdmi: Switch to new stream-format interface Date: Wed, 23 Aug 2023 10:05:36 +0200 Message-Id: <20230823080546.2224713-8-cezary.rojewski@intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230823080546.2224713-1-cezary.rojewski@intel.com> References: <20230823080546.2224713-1-cezary.rojewski@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Message-ID-Hash: HOLWCH6ZU3L2QU2W5666BRNVKUN42SEC X-Message-ID-Hash: HOLWCH6ZU3L2QU2W5666BRNVKUN42SEC X-MailFrom: cezary.rojewski@intel.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-alsa-devel.alsa-project.org-0; header-match-alsa-devel.alsa-project.org-1; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.8 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: To provide option for selecting different bit-per-sample than just the maximum one, use the new format calculation mechanism. Signed-off-by: Cezary Rojewski --- sound/pci/hda/patch_hdmi.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c index c476b16144cb..de8da647465f 100644 --- a/sound/pci/hda/patch_hdmi.c +++ b/sound/pci/hda/patch_hdmi.c @@ -1655,7 +1655,6 @@ static void hdmi_present_sense_via_verbs(struct hdmi_spec_per_pin *per_pin, #define I915_SILENT_RATE 48000 #define I915_SILENT_CHANNELS 2 -#define I915_SILENT_FORMAT SNDRV_PCM_FORMAT_S16_LE #define I915_SILENT_FORMAT_BITS 16 #define I915_SILENT_FMT_MASK 0xf @@ -1668,8 +1667,8 @@ static void silent_stream_enable_i915(struct hda_codec *codec, per_pin->dev_id, I915_SILENT_RATE); /* trigger silent stream generation in hw */ - format = snd_hdac_calc_stream_format(I915_SILENT_RATE, I915_SILENT_CHANNELS, - I915_SILENT_FORMAT, I915_SILENT_FORMAT_BITS, 0); + format = snd_hdac_stream_format(I915_SILENT_CHANNELS, I915_SILENT_FORMAT_BITS, + I915_SILENT_RATE); snd_hda_codec_setup_stream(codec, per_pin->cvt_nid, I915_SILENT_FMT_MASK, I915_SILENT_FMT_MASK, format); usleep_range(100, 200); -- 2.25.1