Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp3339674rdb; Sun, 10 Dec 2023 01:20:49 -0800 (PST) X-Google-Smtp-Source: AGHT+IHbwqY49FsmB7NhE1yXltAuFoOjJoqDu5/uLbZzHhUnnbQzgI7C0xJqgYIfL89ChcpuJlmB X-Received: by 2002:a05:6808:d4b:b0:3b8:4d7b:9259 with SMTP id w11-20020a0568080d4b00b003b84d7b9259mr3440314oik.35.1702200049059; Sun, 10 Dec 2023 01:20:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702200049; cv=none; d=google.com; s=arc-20160816; b=KshBsonO9i3Dg9NVBNg/a/dMsI9XhV6hzCQXNePSmTofQIbexbfPYWk7GKCULZZ9RO 0/qTuL6LT15MPWVbldsHufxHRiyhG4t7Kt10ZVRUyZCUNSH4Z/hL0+wQqezV60+g+Gy5 Sy9P7iebCJJ8s89qZwWBXrRVBUXtlkPADq4PEV/U2W9QnGgM/G/ZoF6bQq5rjzmQ6PkM os5VlrCVPNpjx6q5VxnSSoeGWH4tCF6S0G61s+JI/m8VoxTZnZx21J6B2Yo2kLk/8pzf WUn4tjwrz89gP3kG/1mOIcsbCMT7NTmnTsaPrSpS1bI519SRx7wznb3Hel52KzdMgC1/ fwqA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:user-agent:references:in-reply-to :subject:cc:to:from:message-id:date:dkim-signature:dkim-signature :dkim-signature:dkim-signature; bh=auUupgAjZ8IXUgoHrCzFJV3FieXQ2tOxGY/y2JKnUJM=; fh=BKtipKovsCGcWnDysz6K+aSHDcfhPOHqPEDNW3phKx8=; b=MvLH0uRXzltzLT3SGDXoBboq8pFiCbd1eyCyodpNjIcz4AC7oZE0BB3C49bOZXFtIz szEIS4JI16HWlzuVTUoVOOyGNCYNKSLz2D/0Xw+ATPEzfEvRjMwYSyxu8i+OytTbmmzU U+Ndinr7OoWVgxuuPiNhEPyoYZOBWP9ziJ/AqSX0X6OiSznOZa05ycYhbrEsm63YuiLp PrIwY1JO14j7BEyvQe2XmqKarkSJSm7cMYOUroGEkl+BWhgxUqng+WJg6mcRhUyQm8DE XZVqO/bu0kSmq/VPknAQ+xIHSXgKFL4FuBQZp5N442moLt/NWwJD6DF4SVaRA2IpnilD uerg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=EHaSAi6v; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519 header.b="lLZu/D9a"; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=E+ch+QtL; dkim=neutral (no key) header.i=@suse.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Return-Path: Received: from pete.vger.email (pete.vger.email. [23.128.96.36]) by mx.google.com with ESMTPS id y24-20020a634958000000b005c6faf0a66csi3088203pgk.247.2023.12.10.01.20.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 10 Dec 2023 01:20:49 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) client-ip=23.128.96.36; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=EHaSAi6v; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519 header.b="lLZu/D9a"; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=E+ch+QtL; dkim=neutral (no key) header.i=@suse.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id 3D664807FD41; Sun, 10 Dec 2023 01:20:14 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231751AbjLJJG1 (ORCPT + 99 others); Sun, 10 Dec 2023 04:06:27 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42126 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231739AbjLJJGZ (ORCPT ); Sun, 10 Dec 2023 04:06:25 -0500 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E4FBF106; Sun, 10 Dec 2023 01:06:29 -0800 (PST) Received: from imap1.dmz-prg2.suse.org (imap1.dmz-prg2.suse.org [10.150.64.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id F1E7821CAD; Sun, 10 Dec 2023 09:06:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1702199188; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=auUupgAjZ8IXUgoHrCzFJV3FieXQ2tOxGY/y2JKnUJM=; b=EHaSAi6vqN79BtcMYy2DsZehJiFc2Skr+Aul5ISOulZpfbc+Jm1hlTnP2f5IZn4kQJ8tmG DdRHskIhEDXrv2Y/dyqUvpz3Wrq1Epx/tRpxZaSw8MLFj61MvdAJMpUdLu9slUI6toKWSM 6Am8OX+S8xL/kZ3Rwmi+BNISnBAiPhY= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1702199188; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=auUupgAjZ8IXUgoHrCzFJV3FieXQ2tOxGY/y2JKnUJM=; b=lLZu/D9ajZLkUd7nY1MZJmEKvo50YX0Iyk4pqhLqrjtldSdY2Qa/1kJRXrRlBjZEC9fURZ ON6lswGFNHqKESAw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1702199187; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=auUupgAjZ8IXUgoHrCzFJV3FieXQ2tOxGY/y2JKnUJM=; b=E+ch+QtLS4RZ3jXqqSKJrESOnmXactI0IAmr1U8zN40eiZoZSTLIKa8RIkgd9aEMI1RNKU r+0qglLWvnoSWKZvF2F/9QhrsUEStNs/mq8YXB6chel13nvwkaQ9ScPhpJyKmLsK87HR37 rF+49DUjHlu5WMdoi7HfjUuuzysGjEM= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1702199187; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=auUupgAjZ8IXUgoHrCzFJV3FieXQ2tOxGY/y2JKnUJM=; b=Ig9Ehg1k29XfvFVyMbPNAK6Lazk0rd4Z8KRututqyJavGub8Y3kcPVnCqshChyRb8jgEyo zPqtI0mDDr6BVXCQ== Received: from imap1.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap1.dmz-prg2.suse.org (Postfix) with ESMTPS id ADF3A137D2; Sun, 10 Dec 2023 09:06:27 +0000 (UTC) Received: from dovecot-director2.suse.de ([10.150.64.162]) by imap1.dmz-prg2.suse.org with ESMTPSA id k/4cKZN/dWUVVQAAD6G6ig (envelope-from ); Sun, 10 Dec 2023 09:06:27 +0000 Date: Sun, 10 Dec 2023 10:06:27 +0100 Message-ID: <87fs0a5svg.wl-tiwai@suse.de> From: Takashi Iwai To: Gergo Koteles Cc: Shenghao Ding , Kevin Lu , Baojun Xu , Jaroslav Kysela , Takashi Iwai , linux-kernel@vger.kernel.org, alsa-devel@alsa-project.org, stable@vger.kernel.org Subject: Re: [PATCH v3] ALSA: hda/tas2781: leave hda_component in usable state In-Reply-To: <8b8ed2bd5f75fbb32e354a3226c2f966fa85b46b.1702156522.git.soyer@irl.hu> References: <8b8ed2bd5f75fbb32e354a3226c2f966fa85b46b.1702156522.git.soyer@irl.hu> User-Agent: Wanderlust/2.15.9 (Almost Unreal) Emacs/27.2 Mule/6.0 MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII X-Spam-Level: X-Spam-Score: -0.03 Authentication-Results: smtp-out1.suse.de; none X-Spam-Level: X-Spam-Score: -0.02 X-Spamd-Result: default: False [-0.02 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-0.94)[-0.941]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_SHORT(2.99)[0.998]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.de:s=susede2_rsa,suse.de:s=susede2_ed25519]; RCPT_COUNT_SEVEN(0.00)[9]; MID_CONTAINS_FROM(1.00)[]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[]; BAYES_HAM(-2.98)[99.90%] X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (pete.vger.email [0.0.0.0]); Sun, 10 Dec 2023 01:20:14 -0800 (PST) On Sat, 09 Dec 2023 22:18:29 +0100, Gergo Koteles wrote: > > Unloading then loading the module causes a NULL ponter dereference. > > The hda_unbind zeroes the hda_component, later the hda_bind tries > to dereference the codec field. > > The hda_component is only initialized once by tas2781_generic_fixup. > > Set only previously modified fields to NULL. > > BUG: kernel NULL pointer dereference, address: 0000000000000322 > Call Trace: > > ? __die+0x23/0x70 > ? page_fault_oops+0x171/0x4e0 > ? exc_page_fault+0x7f/0x180 > ? asm_exc_page_fault+0x26/0x30 > ? tas2781_hda_bind+0x59/0x140 [snd_hda_scodec_tas2781_i2c] > component_bind_all+0xf3/0x240 > try_to_bring_up_aggregate_device+0x1c3/0x270 > __component_add+0xbc/0x1a0 > tas2781_hda_i2c_probe+0x289/0x3a0 [snd_hda_scodec_tas2781_i2c] > i2c_device_probe+0x136/0x2e0 > > Fixes: 5be27f1e3ec9 ("ALSA: hda/tas2781: Add tas2781 HDA driver") > CC: stable@vger.kernel.org > Signed-off-by: Gergo Koteles Thanks, applied now. Takashi