From nobody Wed Nov 27 04:55:53 2024 Received: from sender4-op-o15.zoho.com (sender4-op-o15.zoho.com [136.143.188.15]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 681E41876; Sun, 13 Oct 2024 01:47:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=pass smtp.client-ip=136.143.188.15 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728784066; cv=pass; b=GmNM/FwGKjtpjjV0gSP6KuU3A4LVIDAOm0mp/lXNGwtYGFNpTyva88fN0dRB12Fg4C3agYKMW13i3TUgakQwVufYJfTLAT0tOj3Vh+LIsiBG29hWNhQIWQNjdCUZgPDzU38LdL857iW+WvE4z/qT/swyRVTKCoduydlT7mvDqOE= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728784066; c=relaxed/simple; bh=BbOxdWKhpLVzaYXvnM8PyOpEFG0kwbdh/Uc0c81WyqM=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=tNEtRBGO4dtj6JOWmAprWQXxNPLOlWFfvTMS8IRMTtktJqYXhM2TpqirE/qjcy7JnhohmjeHWBNpKe1vCHhh3QEOrUFLGIsbmRLoFRxpPvKkqza3C8YYePabr7eUnfFarXyq70L5qov14xInAbKdOTi8r3eMsG7xfpZv/dsUbXw= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=icenowy.me; spf=pass smtp.mailfrom=icenowy.me; dkim=pass (2048-bit key) header.d=icenowy.me header.i=uwu@icenowy.me header.b=de/j69qd; arc=pass smtp.client-ip=136.143.188.15 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=icenowy.me Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=icenowy.me Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=icenowy.me header.i=uwu@icenowy.me header.b="de/j69qd" ARC-Seal: i=1; a=rsa-sha256; t=1728784058; cv=none; d=zohomail.com; s=zohoarc; b=NRO3vf2rcxXnRP3nDngSxzzlP7HPphu9WLsxal3CQv/s3zh6QYT560Cn1JB9paiJ7AVp2FFLw+LTwch0YqvHAp2WH1vFE2yz5nnp0kcRKzC7pLp6qeoal5l+fSsxzILWP38ZKKHa4wHDB0RkmC4n15E/jRehdusWScvUWPN/fyQ= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1728784058; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:Subject:To:To:Message-Id:Reply-To; bh=CUYtkfv8mbtLw7Sh5EkronI+TRK5znHbED/xa2TUKFc=; b=jCo95K744kYsZkb1ierupyYbyxQJ5LiUpf27qgIzuV/ua/2Ki+u4lX2FljrNGW01wsIPoC8rK2iUZnEYKuQLABy3G0tdq1ytk3lThXmGTPQEJY7CpM0anPsQjKmk9MF3ZAAIRkJAD5hqb+g8fU3HUpO7T0bUogqIUJiXdn1OXZk= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass header.i=icenowy.me; spf=pass smtp.mailfrom=uwu@icenowy.me; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1728784058; s=zmail2; d=icenowy.me; i=uwu@icenowy.me; h=From:From:To:To:Cc:Cc:Subject:Subject:Date:Date:Message-ID:In-Reply-To:References:MIME-Version:Content-Transfer-Encoding:Message-Id:Reply-To; bh=CUYtkfv8mbtLw7Sh5EkronI+TRK5znHbED/xa2TUKFc=; b=de/j69qdONX9YBvP9R6TsHg+964XeNt2UmDkavj4Q+H4bCfpdMd0uAzY/CNE21nA eCkzALnSroJHIfVUF4LVMivbBjmSeDmZDz/ibTF04jTBZiopPLpfoClMjpBJ/Z2C/C6 S5RUcxGPOZjrbkeavZqrmrr4WhHdiMCmzz0nP1OFo7LZRXefFgcyACX3ui9GAYpiIIw Jg9yIKCEeJurIPq8Evcp7VRalnCqzAXi/sQ8MlRX4L4UEvxutSgHoqmRUpRM0ErAHAj L6380cv4PeQ/BjslukxQnThIhFc+gxs6l5pryWWjO0x6VcSqfMYfBZyChQXLWW1hhGR e0q7qIVvxg== Received: by mx.zohomail.com with SMTPS id 1728784056489318.16807738624493; Sat, 12 Oct 2024 18:47:36 -0700 (PDT) From: Icenowy Zheng To: Jaroslav Kysela , Takashi Iwai Cc: Oswald Buddenhagen , linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org, Icenowy Zheng Subject: [PATCH 1/2] ALSA: emu10k1: add a capability bit for no MIDI Date: Sun, 13 Oct 2024 09:47:12 +0800 Message-ID: <20241013014714.7686-2-uwu@icenowy.me> X-Mailer: git-send-email 2.47.0 In-Reply-To: <20241013014714.7686-1-uwu@icenowy.me> References: <20241013014714.7686-1-uwu@icenowy.me> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ZohoMailClient: External Content-Type: text/plain; charset="utf-8" Audigy Rx is a card born in the era that USB MIDI has been the mainstream form of PC MIDI interface, and no external MIDI I/O is made available on Audigy Rx. Add a capability bit for emu10k1 driver to be able to hide the MPU-401 ports. Signed-off-by: Icenowy Zheng --- include/sound/emu10k1.h | 1 + sound/pci/emu10k1/emu10k1.c | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/include/sound/emu10k1.h b/include/sound/emu10k1.h index 38db50b280eba..9172674838627 100644 --- a/include/sound/emu10k1.h +++ b/include/sound/emu10k1.h @@ -1673,6 +1673,7 @@ struct snd_emu_chip_details { unsigned int i2c_adc:1; /* I2C interface for ADC; requires ca0108_chip */ unsigned int adc_1361t:1; /* Use Philips 1361T ADC */ unsigned int invert_shared_spdif:1; /* analog/digital switch inverted */ + unsigned int no_midi:1; /* Has no MIDI */ const char *driver; const char *name; const char *id; /* for backward compatibility - can be NULL if not neede= d */ diff --git a/sound/pci/emu10k1/emu10k1.c b/sound/pci/emu10k1/emu10k1.c index dadeda7758cee..d323ebbc0368f 100644 --- a/sound/pci/emu10k1/emu10k1.c +++ b/sound/pci/emu10k1/emu10k1.c @@ -133,7 +133,9 @@ static int snd_card_emu10k1_probe(struct pci_dev *pci, if (err < 0) return err; } - if (emu->audigy) { + if (emu->card_capabilities->no_midi) { + dev_info(emu->card->dev, "Card has no ext. MIDI ports.\n"); + } else if (emu->audigy) { err =3D snd_emu10k1_audigy_midi(emu); if (err < 0) return err; --=20 2.47.0 From nobody Wed Nov 27 04:55:53 2024 Received: from sender4-op-o15.zoho.com (sender4-op-o15.zoho.com [136.143.188.15]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id F39AC1870; Sun, 13 Oct 2024 01:48:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=pass smtp.client-ip=136.143.188.15 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728784088; cv=pass; b=VYwevKZ/JRpUo90AplZYoHskoyPL9YFS5hwDXYtW6kSOBZYMLlgmXb1MMwvkmgsH3fP3I0o8kRHBotsycMlFt5igVQF3QF/7bxxySebZw/z/VNhkL6ch8Z8lhfdrnU9LWk9D550eA+3JgjHSECvfHhoOl+dVkT1FPLNJHp4iNAE= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1728784088; c=relaxed/simple; bh=v5m3CTNEW+D9aVXVPGDzbpijpDQQIxbYHoED16eC4KE=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=gRn5PD1zmnm4OL7Sxbruhvj1DXPeqnxjmg+e1jYM2yL4qtFxAfoQF7KjU+3ZgRph8frTGOeNe51YtpJOoG6u+o8m3pDxFCdbLpO5vtQhbu0vRn0ZI6ofVc0v3hzx0JsI2YufIVdqeunLg0VXc9fWbCF6lA9cH9+Nve4ZVitU8oI= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=icenowy.me; spf=pass smtp.mailfrom=icenowy.me; dkim=pass (2048-bit key) header.d=icenowy.me header.i=uwu@icenowy.me header.b=PkSZTkAT; arc=pass smtp.client-ip=136.143.188.15 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=icenowy.me Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=icenowy.me Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=icenowy.me header.i=uwu@icenowy.me header.b="PkSZTkAT" ARC-Seal: i=1; a=rsa-sha256; t=1728784080; cv=none; d=zohomail.com; s=zohoarc; b=jTjwkYQBfW8q21wC2MrNWLVLsHKui8uzTo5yWxayBdznMS3gc/SwlKZJCZjYwLBwzQ55cbBUNOoibk0Rtj0JconSGZNXWd5Rru1R1MQ5iNmujdm+XWqspcVpY1UE1xDW3NWdBcDHUQz/Oh3iouosp0Sg23h6sRxtA1RaZby9b+k= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1728784080; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:Subject:To:To:Message-Id:Reply-To; bh=xMA0Ve0ifeE4zJVgDILKH1JZGeu87x9vinIyWiXeifc=; b=jDxNw4n9esCeTUR6t9UYT/2KrD83co9F+CJd9F5NfFoxfv8YNRcClQJ7/dtfU6ypZUpHPgRT983u69gvaRRu4dBmTgY0frGUzkhLHQmrH88iYYSBHYi8TDUKxeuJ2y/MLJ05QQ65X2Kmv7LbKm2rL0M7gP9Iwd3a7cS6ik/ZsWI= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass header.i=icenowy.me; spf=pass smtp.mailfrom=uwu@icenowy.me; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1728784080; s=zmail2; d=icenowy.me; i=uwu@icenowy.me; h=From:From:To:To:Cc:Cc:Subject:Subject:Date:Date:Message-ID:In-Reply-To:References:MIME-Version:Content-Transfer-Encoding:Message-Id:Reply-To; bh=xMA0Ve0ifeE4zJVgDILKH1JZGeu87x9vinIyWiXeifc=; b=PkSZTkATw3X9gm1E4R6+hafqWzY+/S8zjk9YLoicQDn3Or686pk7DQzBXSUBPTfL fVeazm09aa2ocWes2SjL/RuVq4njMRukIs/dhIm7aMfiJbylbd2Zorp7jWCUCeuoGdG XnF1uL9admqUH3mTDzhzGs2eiAIeP61Jr5MoBhCy6NGChBL745U+8g4gQoW2kDoldsU pi6AzEoumrI99HtgkXtGMYkT7Uvq21tZFqLRrpuhtMVijjfSzM3KCgGMlMjHlQwo/gP lNUvTFI1Tov+s6+T7pVR+vvxpIjL59MyogquiWLvn0znVIT6EXDQAQ00Ox9NgZIQ75Y i10+oiP3VA== Received: by mx.zohomail.com with SMTPS id 1728784077958241.1142985847348; Sat, 12 Oct 2024 18:47:57 -0700 (PDT) From: Icenowy Zheng To: Jaroslav Kysela , Takashi Iwai Cc: Oswald Buddenhagen , linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org, Icenowy Zheng Subject: [PATCH 2/2] ALSA: emu10k1: hide ext. MIDI ports for Audigy Rx Date: Sun, 13 Oct 2024 09:47:13 +0800 Message-ID: <20241013014714.7686-3-uwu@icenowy.me> X-Mailer: git-send-email 2.47.0 In-Reply-To: <20241013014714.7686-1-uwu@icenowy.me> References: <20241013014714.7686-1-uwu@icenowy.me> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ZohoMailClient: External Content-Type: text/plain; charset="utf-8" Audigy Rx is a card w/o any external MIDI ports available. Set the capability bit to hide its MPU-401 ports to prevent confusion. Signed-off-by: Icenowy Zheng --- sound/pci/emu10k1/emu10k1_main.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sound/pci/emu10k1/emu10k1_main.c b/sound/pci/emu10k1/emu10k1_m= ain.c index 5b8a5ba825bdb..c9240126f78e3 100644 --- a/sound/pci/emu10k1/emu10k1_main.c +++ b/sound/pci/emu10k1/emu10k1_main.c @@ -947,6 +947,7 @@ static const struct snd_emu_chip_details emu_chip_detai= ls[] =3D { .id =3D "Audigy2", .emu10k2_chip =3D 1, .ca0108_chip =3D 1, + .no_midi =3D 1, .spk71 =3D 1, .adc_1361t =3D 1, /* 24 bit capture instead of 16bit */ .ac97_chip =3D 1}, --=20 2.47.0