Message ID | 20230319044733.327091-1-sensor1010@163.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:604a:0:0:0:0:0 with SMTP id j10csp589488wrt; Sat, 18 Mar 2023 22:19:21 -0700 (PDT) X-Google-Smtp-Source: AK7set8Jm5oDGtOAZFUHanxC4+uqS34pShgnecftYmCH67tpTek5kDEOPc5mWQZpfpT4eSxojKh0 X-Received: by 2002:a17:90b:4d8a:b0:23b:4bf6:bbed with SMTP id oj10-20020a17090b4d8a00b0023b4bf6bbedmr14669725pjb.24.1679203161248; Sat, 18 Mar 2023 22:19:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679203161; cv=none; d=google.com; s=arc-20160816; b=E48VlAgXGmYkkJCNJQewZx1Yq2LJTgD5Rle5XFxHnk2Yz+yJgdaNwBiXEDTH24MkF9 Nz8ME2FvUjewvP2/LowlgYb0sfcPnEqFOalXPTL14LoDl/qBxTBC6z28fCKgsukqhR3z /cjvcGKFAYJxTZ2CIkzksT0a3MxSZcF8DF5FwdkDBtytPLBAJz6yz0ebvybSOah1UVii oZRWWqurk/DnLKTuGSDP+Gh7wpVoqHFVDWUq8+B6oCeOcopDbx/MGLWERf207dObonHJ a3fkTtprRHf0Jcfn1N9x0FauJXhIVThRiHb0jJcWh47GLuWq23k0wIVoRB34QeRcrAcz RCHw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=3Prsu7D2KQBP4G5c2iSTA7jTUpywbihS7wu+b9c1Iis=; b=NiLQkAd+G7TWWAbQXkZk74fiRv8zFsZX/2so2NNKM554PVOOdGXp5MbezqCvKx/cgH jU7NBHI3IoCIJTLdQEjHlbkJEa7smwgt6LM5vhZzUg4Ha04jHYb9yjCfe2+duJ1bU/G7 oVFdvbBgLY5Tcsju7uzkjJ1aXvutEn9Fc+ifJX0FJ/ieA3OF2Fu2mSM75sfA1JQ48Ukq iYD04A2sosVsFYPktrDimttJ/INFpPQm2/xDkGdQ/P5/Wnl8oGAFb2AT1tXGmewmQ9U2 ip/e2ug9bVyQhcpL0D+CzLcfIDE1Reh0AeRZnLFFhbIppPutJEr4eLSECObveZr2FHu0 TUbA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@163.com header.s=s110527 header.b=on2MgYbt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=163.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id w11-20020a17090abc0b00b00233c73769dfsi11991367pjr.120.2023.03.18.22.19.08; Sat, 18 Mar 2023 22:19:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@163.com header.s=s110527 header.b=on2MgYbt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=163.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229876AbjCSEsc (ORCPT <rfc822;pusanteemu@gmail.com> + 99 others); Sun, 19 Mar 2023 00:48:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33070 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229593AbjCSEsb (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Sun, 19 Mar 2023 00:48:31 -0400 Received: from m12.mail.163.com (m12.mail.163.com [220.181.12.196]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id B58C522DD7 for <linux-kernel@vger.kernel.org>; Sat, 18 Mar 2023 21:48:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com; s=s110527; h=From:Subject:Date:Message-Id:MIME-Version; bh=3Prsu 7D2KQBP4G5c2iSTA7jTUpywbihS7wu+b9c1Iis=; b=on2MgYbtd3b9nE73RE50e 7TCsvg8FKBAX7IKZet14VqDrlb1wCXD/+sJtjUmwEcx0DWrnjlofaNCOAL30TDb/ xQo2vDL4Hi6qv51JLcLDjtd9wLY77ewruAdSnPrU7R6Zbb+JMZmhy9yaHeR4nQAC 3fLB6ep3yVAZ77cG+AKqsY= Received: from lizhe.. (unknown [120.245.132.192]) by zwqz-smtp-mta-g2-2 (Coremail) with SMTP id _____wCHtzfnkxZkBrnyAQ--.4626S4; Sun, 19 Mar 2023 12:47:55 +0800 (CST) From: Lizhe <sensor1010@163.com> To: perex@perex.cz, tiwai@suse.com, alsa-devel@alsa-project.org Cc: linux-kernel@vger.kernel.org, Lizhe <sensor1010@163.com> Subject: [PATCH v1] ALSA:ac97: Remove redundant driver match function Date: Sun, 19 Mar 2023 12:47:33 +0800 Message-Id: <20230319044733.327091-1-sensor1010@163.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-CM-TRANSID: _____wCHtzfnkxZkBrnyAQ--.4626S4 X-Coremail-Antispam: 1Uf129KBjvdXoW7Jr1kAr4DtrykWF4rKF4rXwb_yoWkWrg_Ca y7ZFs7Xr17KF1fJw4fXw47AF97Ka1qvw1kKrs5t398KFyfXw4UWw4kJrsxAFn5urn2yFsx WryUXrWIy347XjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUvcSsGvfC2KfnxnUUI43ZEXa7xRNmhFDUUUUU== X-Originating-IP: [120.245.132.192] X-CM-SenderInfo: 5vhq20jurqiii6rwjhhfrp/xtbBohw3q1aEHrnIhQAAsa X-Spam-Status: No, score=-0.5 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM,RCVD_IN_MSPIKE_H2,RCVD_IN_VALIDITY_RPBL,SPF_HELO_NONE, SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1760772134277156452?= X-GMAIL-MSGID: =?utf-8?q?1760772134277156452?= |
Series |
[v1] ALSA:ac97: Remove redundant driver match function
|
|
Commit Message
Lizhe
March 19, 2023, 4:47 a.m. UTC
If there is no driver match function, the driver core assumes that each
candidate pair (driver, device) matches, see driver_match_device()
Drop the bus's match function that always returned 1 and so
implements the same behaviour as when there is no match function.
Signed-off-by: Lizhe <sensor1010@163.com>
---
sound/ac97_bus.c | 11 -----------
1 file changed, 11 deletions(-)
Comments
On Sun, 19 Mar 2023 05:47:33 +0100, Lizhe wrote: > > If there is no driver match function, the driver core assumes that each > candidate pair (driver, device) matches, see driver_match_device() > > Drop the bus's match function that always returned 1 and so > implements the same behaviour as when there is no match function. > > Signed-off-by: Lizhe <sensor1010@163.com> Is Lizeh your real full name? (i.e. your name is "Li Zhe" ?) I'm asking because the Signed-off-by line is a legal requirement. thanks, Takashi
On Sun, 19 Mar 2023 11:47:51 +0100, lizhe wrote: > > > HI : > my name is li Zhe, I am Chinese OK, then applied the patch now. thanks, Takashi > At 2023-03-19 16:16:15, "Takashi Iwai" <tiwai@suse.de> wrote: > >On Sun, 19 Mar 2023 05:47:33 +0100, > >Lizhe wrote: > >> > >> If there is no driver match function, the driver core assumes that each > >> candidate pair (driver, device) matches, see driver_match_device() > >> > >> Drop the bus's match function that always returned 1 and so > >> implements the same behaviour as when there is no match function. > >> > >> Signed-off-by: Lizhe <sensor1010@163.com> > > > >Is Lizeh your real full name? (i.e. your name is "Li Zhe" ?) > >I'm asking because the Signed-off-by line is a legal requirement. > > > > > >thanks, > > > >Takashi > >
diff --git a/sound/ac97_bus.c b/sound/ac97_bus.c index b4685c53ff11..c7aee8c42c55 100644 --- a/sound/ac97_bus.c +++ b/sound/ac97_bus.c @@ -75,19 +75,8 @@ int snd_ac97_reset(struct snd_ac97 *ac97, bool try_warm, unsigned int id, } EXPORT_SYMBOL_GPL(snd_ac97_reset); -/* - * Let drivers decide whether they want to support given codec from their - * probe method. Drivers have direct access to the struct snd_ac97 - * structure and may decide based on the id field amongst other things. - */ -static int ac97_bus_match(struct device *dev, struct device_driver *drv) -{ - return 1; -} - struct bus_type ac97_bus_type = { .name = "ac97", - .match = ac97_bus_match, }; static int __init ac97_bus_init(void)