Received: by 10.213.65.68 with SMTP id h4csp1763646imn; Mon, 19 Mar 2018 12:35:25 -0700 (PDT) X-Google-Smtp-Source: AG47ELvzoZg7mIv6KOtiaoSylUXjX7VRmOHYE0mTqW2HfpBwdlZTgfegQir0rNAhu3y7Hldy9HM9 X-Received: by 10.98.223.149 with SMTP id d21mr4727422pfl.160.1521488125377; Mon, 19 Mar 2018 12:35:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521488125; cv=none; d=google.com; s=arc-20160816; b=wBMVUayftuNqeXTOkFDzKQaA7kiXGzX0Tn07TxqxbnXkMiuwnqVmlLBqZjmzORZjR+ XgI3y3Mbq74QZkCBlpJtqsi9RejTzocDW4TGjJReqJjVJxD/G3/HdYDwXRG/qAPhpngg Yb9ROTzoQWY+jUfn/KCI4vKJBDL8enT8+rWTffy5ZOXR+cMsAuvg9mRWNzB2qk/+nA3H bJiheT3f5/O36oTt0erUc1iDbeKtv3qubyYIXqNMkWE7OC/B9zzPparf3q7sfN89GEpD HP1l6ePAgoB3tFrlNImwTmH6plWs5mrNbvkeJqkxVuc/FTtXBiu1kAQ+9SoySAmXyoXl VdTQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=FVVgwSxXpzpsx2dZoZl6BBdoq4IoFxWW84z61qZWXn8=; b=we/ZfdYJNcbWIT3mj3EctN9UU4e7uQvsksE1rhVUy1gsFy0ruVEgPpuax5xtBGBEgP 8/PQedmPRluPc6H+yClvn5se2FKsC6gA3uO0UQWKkMUrx8/sS7GzOJgwmQOJN8YiSeq1 ZdaC88R0l64H8oAEPWo1n0b0eip/IbT8sT+90xO1Bmd7HHtYdSYOcYxSDrpOrV7cux41 I9JwxLinpAWkPXFwNQ8LqqzbK/aasSWwF2Es/2y6bgZI4VsvTjKbbDLT/6EJS+rzoOdq AB/1Zm6lWPOGUfMRKqS0FaVtJhZ9Dl7XeKsfNRA4xCLUkukVwYe/I2+NejBOS4PLBYLr OwMw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d2si401851pgc.758.2018.03.19.12.35.09; Mon, 19 Mar 2018 12:35:25 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1031343AbeCSSXB (ORCPT + 99 others); Mon, 19 Mar 2018 14:23:01 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:48670 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1031289AbeCSSWq (ORCPT ); Mon, 19 Mar 2018 14:22:46 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id D56C51279; Mon, 19 Mar 2018 18:22:45 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Takashi Sakamoto , Takashi Iwai , Sasha Levin Subject: [PATCH 4.9 110/241] ALSA: firewire-digi00x: add support for console models of Digi00x series Date: Mon, 19 Mar 2018 19:06:15 +0100 Message-Id: <20180319180755.756089691@linuxfoundation.org> X-Mailer: git-send-email 2.16.2 In-Reply-To: <20180319180751.172155436@linuxfoundation.org> References: <20180319180751.172155436@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.9-stable review patch. If anyone has any objections, please let me know. ------------------ From: Takashi Sakamoto [ Upstream commit 13e005f9f933a35b5e55c9d36f151efe2a8383ec ] Digi00x series includes two types of unit; rack and console. As long as reading information on config rom of Digi 002 console, 'MODEL_ID' field has a different value from the one on Digi 002 rack. We've already got a test report from users with Digi 003 rack. We can assume that console type and rack type has different value in the field. This commit adds a device entry for console type. For following commits, this commit also adds a member to 'struct snd_digi00x' to identify console type. $ cd linux-firewire-utils/src $ python2 ./crpp < /sys/bus/firewire/devices/fw1/config_rom ROM header and bus information block ----------------------------------------------------------------- 400 0404f9d0 bus_info_length 4, crc_length 4, crc 63952 404 31333934 bus_name "1394" 408 60647002 irmc 0, cmc 1, isc 1, bmc 0, cyc_clk_acc 100, max_rec 7 (256) 40c 00a07e00 company_id 00a07e | 410 00a30000 device_id 0000a30000 | EUI-64 00a07e0000a30000 root directory ----------------------------------------------------------------- 414 00058a39 directory_length 5, crc 35385 418 0c0043a0 node capabilities 41c 04000001 hardware version 420 0300a07e vendor 424 81000007 --> descriptor leaf at 440 428 d1000001 --> unit directory at 42c unit directory at 42c ----------------------------------------------------------------- 42c 00046674 directory_length 4, crc 26228 430 120000a3 specifier id 434 13000001 version 438 17000001 model 43c 81000007 --> descriptor leaf at 458 descriptor leaf at 440 ----------------------------------------------------------------- 440 00055913 leaf_length 5, crc 22803 444 000050f2 descriptor_type 00, specifier_ID 50f2 448 80000000 44c 44696769 450 64657369 454 676e0000 descriptor leaf at 458 ----------------------------------------------------------------- 458 0004a6fd leaf_length 4, crc 42749 45c 00000000 textual descriptor 460 00000000 minimal ASCII 464 44696769 "Digi" 468 20303032 " 002" Signed-off-by: Takashi Sakamoto Signed-off-by: Takashi Iwai Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- sound/firewire/digi00x/digi00x.c | 13 +++++++++++-- sound/firewire/digi00x/digi00x.h | 1 + 2 files changed, 12 insertions(+), 2 deletions(-) --- a/sound/firewire/digi00x/digi00x.c +++ b/sound/firewire/digi00x/digi00x.c @@ -13,7 +13,8 @@ MODULE_AUTHOR("Takashi Sakamoto lock); init_waitqueue_head(&dg00x->hwdep_wait); + dg00x->is_console = entry->model_id == MODEL_CONSOLE; + /* Allocate and register this sound card later. */ INIT_DEFERRABLE_WORK(&dg00x->dwork, do_registration); snd_fw_schedule_registration(unit, &dg00x->dwork); @@ -183,7 +186,13 @@ static const struct ieee1394_device_id s .match_flags = IEEE1394_MATCH_VENDOR_ID | IEEE1394_MATCH_MODEL_ID, .vendor_id = VENDOR_DIGIDESIGN, - .model_id = MODEL_DIGI00X, + .model_id = MODEL_CONSOLE, + }, + { + .match_flags = IEEE1394_MATCH_VENDOR_ID | + IEEE1394_MATCH_MODEL_ID, + .vendor_id = VENDOR_DIGIDESIGN, + .model_id = MODEL_RACK, }, {} }; --- a/sound/firewire/digi00x/digi00x.h +++ b/sound/firewire/digi00x/digi00x.h @@ -60,6 +60,7 @@ struct snd_dg00x { /* For asynchronous MIDI controls. */ struct snd_rawmidi_substream *in_control; struct snd_fw_async_midi_port out_control; + bool is_console; }; #define DG00X_ADDR_BASE 0xffffe0000000ull