Received: by 2002:a05:7412:b995:b0:f9:9502:5bb8 with SMTP id it21csp504208rdb; Thu, 21 Dec 2023 16:36:36 -0800 (PST) X-Google-Smtp-Source: AGHT+IEY5H308VGjul5/E8zK7e9+9McNVKRPUL0l3l90HjVlgypXPuIWVRHjNJk8tHdDnR+hUbqx X-Received: by 2002:a17:906:11a:b0:a23:5b48:40e3 with SMTP id 26-20020a170906011a00b00a235b4840e3mr198493eje.250.1703205396399; Thu, 21 Dec 2023 16:36:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703205396; cv=none; d=google.com; s=arc-20160816; b=BANjGXB9m4S6Mw/W8ItYHquoyPtgZ+7XWAc6tZbw+sTgghwqz2Xrk7Qyy4zq+jXaOz Sq13y/LoeMbpgLwsIjfB+xVT1su50y2t2+lGJUbceJDKkRWIUiIxFh6AuL+FX8/+zraV AOdoAPMIHMo0fll4lTU4OuOVfjMCF4uqeOI3sckDrVLLe370pRcFI4GSo85miMyes25b /35xq2EQlD/EAdX33ujppKLj7vufDhq7VEjLgKP9+VDfeJG1cli3k6KFbS7+ZMh0T9zq YVQ2pisOMkx+1Lf8Ly7EbUKr363OROJanNbZewSRIr8saAg1OL4wakN3btVQrA+brxCt jclg== ARC-Message-Signature: i=1; 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:message-id:date:subject:cc:to :from; bh=S+Z2y7pq0IbVU7zX0MhJjM1hwP8WfX6fNLBlU59Q9X4=; fh=cjaX+DUs7az5vN8HIYN3aIrprDtIcSvNx1Ki9B3X5LQ=; b=fyoLluBCFIZQFz755TYEYqWjOjVljMtd+qvERBU9LAWnylFZIRwyLvGPhFwGVpvQst KCys/e8YgZcdMC5pqQxvHGZ4DY8dBb+xWCV1rRds80EsacvG4HVivxPnXfAup95PAJay dFNLIBVPUXgopksjTNvRfxKvZH+rxsFdF2ShX7qQgaGnM/AkyVwyUHlNOXFcPnKHS+Y5 LNdpcdiEdpzPKUPPb6WFcN5bj5H9PMDBbkz7LvehZ93B1NeiQl118PHk2q7KUitg0hny M/8Vx44+AzL5UvbnFEpnMdhm3lfuUmXQEKhn2h9AeEoFUfeCsbtViRvWDuyfoiiP9z0I ii+g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel+bounces-9211-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-9211-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=irl.hu Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id ci16-20020a170906c35000b00a232c959eaasi1301591ejb.651.2023.12.21.16.36.36 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 21 Dec 2023 16:36:36 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-9211-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel+bounces-9211-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-9211-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 am.mirrors.kernel.org (Postfix) with ESMTPS id 241791F24BFC for ; Fri, 22 Dec 2023 00:36:36 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 99B02A5D; Fri, 22 Dec 2023 00:36:27 +0000 (UTC) X-Original-To: linux-kernel@vger.kernel.org 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 41523A23; Fri, 22 Dec 2023 00:36:24 +0000 (UTC) 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 (51b681e3.dsl.pool.telekom.hu [::ffff:81.182.129.227]) (AUTH: CRAM-MD5 soyer@irl.hu, ) by irl.hu with ESMTPSA id 0000000000071EE7.000000006584DA06.0013B20D; Fri, 22 Dec 2023 01:36:22 +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 1/2] ALSA: hda/tas2781: move set_drv_data outside tasdevice_init Date: Fri, 22 Dec 2023 01:34:47 +0100 Message-ID: <1398bd8bf3e935b1595a99128320e4a1913e210a.1703204848.git.soyer@irl.hu> X-Mailer: git-send-email 2.43.0 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 allow driver specific driver data in tas2781-hda-i2c and tas2781-i2c Fixes: ef3bcde75d06 ("ASoC: tas2781: Add tas2781 driver") CC: stable@vger.kernel.org Signed-off-by: Gergo Koteles --- sound/pci/hda/tas2781_hda_i2c.c | 2 ++ sound/soc/codecs/tas2781-comlib.c | 2 -- sound/soc/codecs/tas2781-i2c.c | 2 ++ 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/sound/pci/hda/tas2781_hda_i2c.c b/sound/pci/hda/tas2781_hda_i2c.c index e4c54b2a012c..769604375745 100644 --- a/sound/pci/hda/tas2781_hda_i2c.c +++ b/sound/pci/hda/tas2781_hda_i2c.c @@ -659,6 +659,8 @@ static int tas2781_hda_i2c_probe(struct i2c_client *clt) if (!tas_priv) return -ENOMEM; + dev_set_drvdata(&clt->dev, tas_priv); + tas_priv->irq_info.irq = clt->irq; ret = tas2781_read_acpi(tas_priv, device_name); if (ret) diff --git a/sound/soc/codecs/tas2781-comlib.c b/sound/soc/codecs/tas2781-comlib.c index 933cd008e9f5..00e35169ae49 100644 --- a/sound/soc/codecs/tas2781-comlib.c +++ b/sound/soc/codecs/tas2781-comlib.c @@ -316,8 +316,6 @@ int tasdevice_init(struct tasdevice_priv *tas_priv) tas_priv->tasdevice[i].cur_conf = -1; } - dev_set_drvdata(tas_priv->dev, tas_priv); - mutex_init(&tas_priv->codec_lock); out: diff --git a/sound/soc/codecs/tas2781-i2c.c b/sound/soc/codecs/tas2781-i2c.c index 55cd5e3c23a5..917b1c15f71d 100644 --- a/sound/soc/codecs/tas2781-i2c.c +++ b/sound/soc/codecs/tas2781-i2c.c @@ -689,6 +689,8 @@ static int tasdevice_i2c_probe(struct i2c_client *i2c) if (!tas_priv) return -ENOMEM; + dev_set_drvdata(&i2c->dev, tas_priv); + if (ACPI_HANDLE(&i2c->dev)) { acpi_id = acpi_match_device(i2c->dev.driver->acpi_match_table, &i2c->dev); base-commit: 916d051730ae48aef8b588fd096fefca4bc0590a prerequisite-patch-id: da39452ca686d78e5accad1c2c4aa22a5f5a6a65 -- 2.43.0