Received: by 2002:a05:7412:bbc7:b0:fc:a2b0:25d7 with SMTP id kh7csp3313554rdb; Tue, 6 Feb 2024 13:49:42 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCWKY2eWCZ1rvwABwo571TZPn2+TWd2kGHmhd+GvBl7uCXTEfwWjuKQDL9hfJ+LK38NsMuEDDQ5wzGk/dtoS3ZV4EObkVUXFKcWSVYCRNA== X-Google-Smtp-Source: AGHT+IEI2A3ZM20tk2Zzjg9gFI3xgak6H7U66X7yvW3swqyUyTYVWzsUMEVyxFRQK2SoKoBRoHtV X-Received: by 2002:a05:620a:2988:b0:785:8d41:14a8 with SMTP id r8-20020a05620a298800b007858d4114a8mr4009291qkp.3.1707256182452; Tue, 06 Feb 2024 13:49:42 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707256182; cv=pass; d=google.com; s=arc-20160816; b=FxTfUhMdN7a21dmQOYsm22xl7rQ9CZr4gpvL7ait1jn0ygKh5uUuevl7VehUHJsb07 vL5KNRPFynbkiPpLPqcyfOPR1GKpj3QznKsOOA22X41i843by4q+O6rpm0CokNoUGEWA is/JF9C5cSSAH1BFJejfuOCn9Sh5DXb3WxJEg+luKM6iqvJgZcb0HBj4fpC+HxmTYGqT m4IyKR8tZTtJaXjbbvQKrjcuH1nFZrOZkYjid7fNCfc9Z2MwimlM6IOb4G32vdCd28zq yAprARXyTNeUHZiGIkeDVOZf2pOyP2a1MNe1l1ubiNYE0eP97cdHT2zzc5UoNb6KWea2 AiMQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from; bh=i3v/dyzd+gcY6/xl5X6fJLdn3ePFgtUbM32q8Y6lT44=; fh=ZVjqv93ekDV0OgQhvGQSg32Bp/cbzv/9DxTQVY/7Aw8=; b=ki1xvqcloVq/bujzaHvMsk5j/5WEpqSZBylqOHSz7FfU6o3WXgFrDI95Z0UJiCKrYv R+9Yxt0BmyLmZ8MX/yruJXNE315cBuiqGwCX09zEzQ0iqx55ihwJk1wKtvpsY/EmbRe+ 0fgqWX8LgU/tzn8xgouwssTd+OwO6s+2SlasotzYlfGNZoWVFPZqtezVtJ3ENc8miRa5 /sbKroU4IqeszL8G2kvPdNAAhV7H9Fx70emqtTthpO9PPo5R1gX0dXQBJ2fngQhTMIXN KlOyJCDtIoPYPWaPiICxfNIdPJgEncCrBapBzDiV6U2ENl2Jaz8KutiiIMlMk6hO7Q+6 Gj3Q==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=irl.hu dmarc=pass fromdomain=irl.hu); spf=pass (google.com: domain of linux-kernel+bounces-55655-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-55655-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=irl.hu X-Forwarded-Encrypted: i=1; AJvYcCWp2/nel3Lg7f7ty7/hiptvTBv+F/XR4391X7//NDcPEh+8pqEhDYvI3xMVOoac0urGvBGeXSqOlngrBjAPX/tK+0YHSwdUq2DO8uHX+w== Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id vw21-20020a05620a565500b0078552f53b80si3163710qkn.50.2024.02.06.13.49.42 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Feb 2024 13:49:42 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-55655-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=irl.hu dmarc=pass fromdomain=irl.hu); spf=pass (google.com: domain of linux-kernel+bounces-55655-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-55655-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=irl.hu Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id EB3931C222A8 for ; Tue, 6 Feb 2024 21:49:41 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 60C941BC35; Tue, 6 Feb 2024 21:49:35 +0000 (UTC) Received: from irl.hu (irl.hu [95.85.9.111]) (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 35E601B948; Tue, 6 Feb 2024 21:49:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=95.85.9.111 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707256174; cv=none; b=YWMOZJCWjUjHN/aDAWhKZcldAdhplryz0mpikyTKq8IRlFCQAYPtd/2S7rOH/6iFnQYdxnD2XqdJXNwNxxSabYM/B4debQdpz9b1JdhpmuXs8KMsedypIPB2PNTYGe1oQFdj/+hj/R2YSaW59AOFqGpwNuGZwzU6gVl7/d6oIIM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707256174; c=relaxed/simple; bh=LiKVYTVwfhGFPEJc6YnATjTVvQnxnW94uIPI7ylSso4=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: Mime-Version:Content-Type; b=cvVs9geX2o3T9wMVpaF1N4uWR/2zxL46oleV6nYu54uscxQc21m8Qb1MsCB4dfrMp//QPb1AvJ/G8XWreejZFl0IAN/5+y7uxpUe6Ol+JxCDJZcALO2reGcCpUqFf1j/u9XFGzHci1nSFdA8nZM4uTnhuPviRXeqg026mBWsT8M= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=irl.hu; spf=pass smtp.mailfrom=irl.hu; arc=none smtp.client-ip=95.85.9.111 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=irl.hu Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=irl.hu Received: from fedori.lan (51b69e54.dsl.pool.telekom.hu [::ffff:81.182.158.84]) (AUTH: CRAM-MD5 soyer@irl.hu, ) by irl.hu with ESMTPSA id 00000000000737A5.0000000065C2A96A.001AD717; Tue, 06 Feb 2024 22:49:30 +0100 From: Gergo Koteles To: Shenghao Ding , Kevin Lu , Baojun Xu , Jaroslav Kysela , Takashi Iwai , Liam Girdwood , Mark Brown Cc: linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org, alsa-devel@alsa-project.org, Gergo Koteles , stable@vger.kernel.org Subject: [PATCH v3] ASoC: tas2781: remove unused acpi_subysystem_id Date: Tue, 6 Feb 2024 22:49:29 +0100 Message-ID: <7f056a4148fec176812ff6cc490860bf565b161c.1707255917.git.soyer@irl.hu> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Mime-Autoconverted: from 8bit to 7bit by courier 1.0 The acpi_subysystem_id is only written and freed, not read, so unnecessary. Fixes: ef3bcde75d06 ("ASoC: tas2781: Add tas2781 driver") CC: stable@vger.kernel.org Signed-off-by: Gergo Koteles --- Changes since v2: remove sub from tas2781_read_acpi Changes since v1: remove physdev from tas2781_read_acpi --- include/sound/tas2781.h | 1 - sound/pci/hda/tas2781_hda_i2c.c | 12 ------------ sound/soc/codecs/tas2781-comlib.c | 1 - 3 files changed, 14 deletions(-) diff --git a/include/sound/tas2781.h b/include/sound/tas2781.h index 9aff384941de..99ca3e401fd1 100644 --- a/include/sound/tas2781.h +++ b/include/sound/tas2781.h @@ -103,7 +103,6 @@ struct tasdevice_priv { struct tm tm; enum device_catlog_id catlog_id; - const char *acpi_subsystem_id; unsigned char cal_binaryname[TASDEVICE_MAX_CHANNELS][64]; unsigned char crc8_lkp_tbl[CRC8_TABLE_SIZE]; unsigned char coef_binaryname[64]; diff --git a/sound/pci/hda/tas2781_hda_i2c.c b/sound/pci/hda/tas2781_hda_i2c.c index 1bfb00102a77..4c9a788c3501 100644 --- a/sound/pci/hda/tas2781_hda_i2c.c +++ b/sound/pci/hda/tas2781_hda_i2c.c @@ -111,9 +111,7 @@ static int tas2781_get_i2c_res(struct acpi_resource *ares, void *data) static int tas2781_read_acpi(struct tasdevice_priv *p, const char *hid) { struct acpi_device *adev; - struct device *physdev; LIST_HEAD(resources); - const char *sub; int ret; adev = acpi_dev_get_first_match_dev(hid, NULL, -1); @@ -129,18 +127,8 @@ static int tas2781_read_acpi(struct tasdevice_priv *p, const char *hid) acpi_dev_free_resource_list(&resources); strscpy(p->dev_name, hid, sizeof(p->dev_name)); - physdev = get_device(acpi_get_first_physical_node(adev)); acpi_dev_put(adev); - /* No side-effect to the playback even if subsystem_id is NULL*/ - sub = acpi_get_subsystem_id(ACPI_HANDLE(physdev)); - if (IS_ERR(sub)) - sub = NULL; - - p->acpi_subsystem_id = sub; - - put_device(physdev); - return 0; err: diff --git a/sound/soc/codecs/tas2781-comlib.c b/sound/soc/codecs/tas2781-comlib.c index 5d0e5348b361..3aa81514dad7 100644 --- a/sound/soc/codecs/tas2781-comlib.c +++ b/sound/soc/codecs/tas2781-comlib.c @@ -408,7 +408,6 @@ void tasdevice_remove(struct tasdevice_priv *tas_priv) { if (gpio_is_valid(tas_priv->irq_info.irq_gpio)) gpio_free(tas_priv->irq_info.irq_gpio); - kfree(tas_priv->acpi_subsystem_id); mutex_destroy(&tas_priv->codec_lock); } EXPORT_SYMBOL_GPL(tasdevice_remove); base-commit: 610010737f74482a61896596a0116876ecf9e65c -- 2.43.0