From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from fllv0015.ext.ti.com (fllv0015.ext.ti.com [198.47.19.141]) (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 B2DDB481C6 for ; Sun, 19 May 2024 15:06:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.47.19.141 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716131193; cv=none; b=P2pLVyHOk7OPS8A01mmWmjxmlvV/mFcY/XOiSxGlh7gyNahu027K77QlsVH1w75FCykhMm34DqNMUH4k7fR5zXbhlpTsQCJuUletYnYCBkV8tgat5nWHoLh3l25nzfCviyPI+Tm2ZUH4cbs9MvMk5RVJ10YGqsd0Vd9veMz/rC0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716131193; c=relaxed/simple; bh=PWlBkt8hrc3yRUjuDGOwehNTi6Z2Iv1ZIjowVOxeb4I=; h=From:To:CC:Subject:Date:Message-ID:MIME-Version:Content-Type; b=j8Ez9tasAJ4ypRSZONTYX2f1DSFrpExi1xhc3+MlGSksYWWTYztUbOHw+RSEMyqR4LxllEsOLVg8zLfrcZZAHRnBaM0sk0VvurlkCs7FC1yD9LASSdxKiBVsCBx3zHFlBgC4BbCs3fHpvkiqJuEueprGFFS1cPRxd98O/GsrVNM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com; spf=pass smtp.mailfrom=ti.com; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b=Kb6rh2Lb; arc=none smtp.client-ip=198.47.19.141 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ti.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="Kb6rh2Lb" Received: from fllv0035.itg.ti.com ([10.64.41.0]) by fllv0015.ext.ti.com (8.15.2/8.15.2) with ESMTP id 44JF57U7115518; Sun, 19 May 2024 10:05:07 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1716131107; bh=Qncl48aX7pAcHQ1zL87QVnUocwPrehIzUGi9a9KR9HU=; h=From:To:CC:Subject:Date; b=Kb6rh2LbA4VK2PfEb6AiLUn/7kpL0TExJR6iaus4UuVfAYYi2vlkygJnud6uLXFgy hpY9QBH9kKLG4Q0z1lpO62FVH9GmIFW9+IpGwsYfbAw0ZWu0nQnRwW12uYXvlFnzaQ 1fLnwypz+qiK9yCckuZIDg9QrhK0i5bFph7g1KBs= Received: from DFLE101.ent.ti.com (dfle101.ent.ti.com [10.64.6.22]) by fllv0035.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 44JF57PY119203 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Sun, 19 May 2024 10:05:07 -0500 Received: from DFLE109.ent.ti.com (10.64.6.30) by DFLE101.ent.ti.com (10.64.6.22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Sun, 19 May 2024 10:05:06 -0500 Received: from lelvsmtp6.itg.ti.com (10.180.75.249) by DFLE109.ent.ti.com (10.64.6.30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Sun, 19 May 2024 10:05:07 -0500 Received: from lelvsmtp6.itg.ti.com ([10.250.165.138]) by lelvsmtp6.itg.ti.com (8.15.2/8.15.2) with ESMTP id 44JF4xbC074474; Sun, 19 May 2024 10:04:59 -0500 From: Baojun Xu To: CC: , , , , , , , , <13916275206@139.com>, , , , , , , , , Subject: [PATCH v5 0/1] Add tas2781 driver for SPI. Date: Sun, 19 May 2024 23:04:31 +0800 Message-ID: <20240519150433.760-1-baojun.xu@ti.com> X-Mailer: git-send-email 2.43.0.windows.1 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 This patch was used to add TAS2781 devices on SPI support in sound/pci/hda. It use ACPI node descript about parameters of TAS2781 on SPI, it like: Scope (_SB.PC00.SPI0) { Device (GSPK) { Name (_HID, "TXNW2781") // _HID: Hardware ID Method (_CRS, 0, NotSerialized) { Name (RBUF, ResourceTemplate () { SpiSerialBusV2 (...) SpiSerialBusV2 (...) } } } } And in platform/x86/serial-multi-instantiate.c, those spi devices will be added into system as a single SPI device, so TAS2781 SPI driver will probe twice for every single SPI device. And driver will also parser mono DSP firmware binary and RCA binary for itself. Signed-off-by: Baojun Xu Baojun Xu (1): ALSA: hda/tas2781: Add tas2781 hda driver based on SPI drivers/acpi/scan.c | 1 + .../platform/x86/serial-multi-instantiate.c | 12 + sound/pci/hda/Kconfig | 14 + sound/pci/hda/Makefile | 2 + sound/pci/hda/patch_realtek.c | 13 + sound/pci/hda/tas2781-spi.h | 148 ++ sound/pci/hda/tas2781_hda_spi.c | 1234 +++++++++ sound/pci/hda/tas2781_spi_fwlib.c | 2247 +++++++++++++++++ 8 files changed, 3671 insertions(+) create mode 100644 sound/pci/hda/tas2781-spi.h create mode 100644 sound/pci/hda/tas2781_hda_spi.c create mode 100644 sound/pci/hda/tas2781_spi_fwlib.c -- 2.40.1