From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 0AEC7EE14D3 for ; Wed, 6 Sep 2023 18:37:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:Content-Type: List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: In-Reply-To:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date: Reply-To:Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date :Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=i6NIxYSlY2A2b/XDHsyizNOrvfN9Y6z6RwjpqSM1MeE=; b=b7V8zoH3l/PvkHe/JebTpN1LAz QJXMi2JQzg5seOg4KS+cX025/YTzSTGirAwR8ZCShpWFugeQ0pRKF3tGjNivtKPEjAnrgPcj4i5+G mIVkhWiXoE+jXRSPTnFSHUDD50U5xXq0xfQYecbTbwJ1+Wx2mDstyN4FNn3/tkRrIRHov/HZj14eX C5UzeAV+OIEIT0kQcnxibhOxicDwqeT3klGikDQ3CAMu4tvH75CxsjVxOOxo8BRRgIawtw+5Z0KTn NLJGElNA4XamaoW68Vt3NkxsECmAMV8eb4Kh/8YVUc1geug7hvZKOLa4L3q7F2E+PR/8D3sRfJf0h asJbJkng==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qdxOW-00AinK-19; Wed, 06 Sep 2023 18:36:52 +0000 Received: from mail-oi1-x22b.google.com ([2607:f8b0:4864:20::22b]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qdxOT-00Aimn-2F for linux-arm-kernel@lists.infradead.org; Wed, 06 Sep 2023 18:36:51 +0000 Received: by mail-oi1-x22b.google.com with SMTP id 5614622812f47-3ab244ef065so106888b6e.0 for ; Wed, 06 Sep 2023 11:36:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1694025408; x=1694630208; darn=lists.infradead.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=R41xuxNyeQCab4RBKOEKbIOBQAQArqGWfJ+WVPjIFUs=; b=EmT95XO05xhTjulei1vqt3+x1vBxGdM+J1xRc79EUoH8B22zcYwybTsM9EX7rivrfr V3NJCceD7xs6YQIj++pIPY596oH9+VeY67LnT27HpkqEKd2ucV/8dJMSFY0UdIC9walW YxghovYupeL0DurDL7akitbvJz5vxVjfMCAu08di6sRSSaNMJ6NJ4wJg/DYN6o8m0ruz rT6+2gdEfnw6Ke94uAn5T5ZgyfcFn+DDhBn6AvcMt1G+pY6aIRJ6jD8SO50KbN7NQwv3 uJTNnbdVDYrv1cuKJo6qewVcoplYB9/D5O55tqWU8xckBZLY0KXxiO7tivZYD6CIXrUM ivlg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1694025408; x=1694630208; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=R41xuxNyeQCab4RBKOEKbIOBQAQArqGWfJ+WVPjIFUs=; b=l5zUiL9rLOLmEHdT6TimSJTixlEwjt0R3z855tQsqYADv0+rtqHoammzEl/zNi7LZ6 q2T9hOLGS5Jh9g/z/yL1v9d4H4Oip96MJ3eElnMkZbDBGB0xM9B406+rDnHnDge2i2lI 7JIS4lXR0tHSiP991JSU2MdIf0LODpbsEeYvCpNS3nrHHDz5Qy1avSoV0W8PwApbgDBG qFCGJKSt6SerwmwbfnoG2MrhsLnZGfy/FnQqfWJSTnMtptlXYOjfLu45NL9Tdhwst8U+ c8bJ/r7a/1SsKMGTf5apOjHAEn9EffzUoQXRuERJU0I0JC9TSpBhTBePs31MfOEkAGwt wr+g== X-Gm-Message-State: AOJu0YyZ4sbNF8LeQglsBumKZsa/rcc2dGCNToMAQNewr2zXVFiGl5O2 hA+UktIjElZaNSmfXnbzM6rC/w== X-Google-Smtp-Source: AGHT+IG9BploV0dwCcQBy3Ie/w4dFRaPVVu7bV3WtqyHoujw3JT0PQHSDxMiMRcpSSeN64E4ac/5zw== X-Received: by 2002:a05:6808:2a47:b0:3a9:cfb5:4637 with SMTP id fa7-20020a0568082a4700b003a9cfb54637mr16328313oib.38.1694025408158; Wed, 06 Sep 2023 11:36:48 -0700 (PDT) Received: from winterfell.papolivre.org (winterfell.papolivre.org. [2600:3c00:e000:341::1]) by smtp.gmail.com with ESMTPSA id t8-20020a056808158800b003a76d7f596esm4918939oiw.54.2023.09.06.11.36.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Sep 2023 11:36:47 -0700 (PDT) Received: from localhost (unknown [IPv6:2804:14d:7224:8468:34c9:cf8b:3384:7414]) by winterfell.papolivre.org (Postfix) with ESMTPSA id 7ADFA1C3AB0; Wed, 6 Sep 2023 15:36:46 -0300 (-03) Date: Wed, 6 Sep 2023 15:36:40 -0300 From: Antonio Terceiro To: Robin Murphy Cc: Takashi Iwai , Jaroslav Kysela , Takashi Iwai , Catalin Marinas , Will Deacon , alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: snd-cmipci oops during probe on arm64 (current mainline, pre-6.6-rc1) Message-ID: References: <877cp3esse.wl-tiwai@suse.de> <4f335dd2-8043-c60e-cf84-c2b01c4fee12@arm.com> MIME-Version: 1.0 In-Reply-To: <4f335dd2-8043-c60e-cf84-c2b01c4fee12@arm.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230906_113649_824620_7F7CD326 X-CRM114-Status: GOOD ( 38.25 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: multipart/mixed; boundary="===============7938154588968327654==" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org --===============7938154588968327654== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="SpMcbUejsrGYVbOX" Content-Disposition: inline --SpMcbUejsrGYVbOX Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Sep 06, 2023 at 01:49:16PM +0100, Robin Murphy wrote: > On 2023-09-06 07:10, Takashi Iwai wrote: > > On Wed, 06 Sep 2023 00:01:01 +0200, > > Antonio Terceiro wrote: > > >=20 > > > Hi, > > >=20 > > > I'm using an arm64 workstation, and wanted to add a sound card to it.= I bought > > > one who was pretty popular around where I live, and it is supported b= y the > > > snd-cmipci driver. > > >=20 > > > It's this one: > > >=20 > > > 0005:02:00.0 Multimedia audio controller: C-Media Electronics Inc CMI= 8738/CMI8768 PCI Audio (rev 10) > > >=20 > > > After building a mailine kernel (post-v6.5, pre-rc1) on Debian testin= g arm64 > > > with localmodconfig + CONFIG_SND_CMIPCI=3Dm, it crashes with "Unable = to handle > > > kernel paging request at virtual address fffffbfffe80000c", and the s= ystem > > > never finishes to boot. The login manager never shows up and the seri= al console > > > never gets to a login prompt. I observed the same issue on a 6.3 Debi= an kernel, > > > after rebuilding with CONFIG_SND_CMIPCI=3Dm. > > >=20 > > > If I stop the module from being automatically loaded by adding > > > `blacklist snd-cmipci` to /etc/modprobe.d/snd-cmipci.conf (or if I > > > remove the card from the PCIe slot), I get the system to boot. But tr= ing > > > to load the module manually causes the same crash (I only tested this > > > with the card on): > > >=20 > > > [ +4,501093] snd_cmipci 0005:02:00.0: stream 512 already in tree > > > [ +0,000155] Unable to handle kernel paging request at virtual addre= ss fffffbfffe80000c > > > [ +0,007927] Mem abort info: > > > [ +0,002793] ESR =3D 0x0000000096000006 > > > [ +0,003743] EC =3D 0x25: DABT (current EL), IL =3D 32 bits > > > [ +0,005307] SET =3D 0, FnV =3D 0 > > > [ +0,003049] EA =3D 0, S1PTW =3D 0 > > > [ +0,003134] FSC =3D 0x06: level 2 translation fault > > > [ +0,004872] Data abort info: > > > [ +0,002873] ISV =3D 0, ISS =3D 0x00000006, ISS2 =3D 0x00000000 > > > [ +0,005479] CM =3D 0, WnR =3D 0, TnD =3D 0, TagAccess =3D 0 > > > [ +0,005047] GCS =3D 0, Overlay =3D 0, DirtyBit =3D 0, Xs =3D 0 > > > [ +0,000003] swapper pgtable: 4k pages, 48-bit VAs, pgdp=3D000008051= 9fe9000 > > > [ +0,000004] [fffffbfffe80000c] pgd=3D000008051a979003, p4d=3D000008= 051a979003, pud=3D000008051a97a003, pmd=3D0000000000000000 > > > [ +0,000009] Internal error: Oops: 0000000096000006 [#1] SMP > > > [ +0,028142] Modules linked in: snd_cmipci(+) snd_mpu401_uart snd_op= l3_lib xt_conntrack xt_MASQUERADE nf_conntrack_netlink xfrm_user xfrm_algo = xt_addrtype nft_compat br_netfilter nft_masq nft_chain_nat nf_nat nf_conntr= ack nf_defrag_ipv6 nf_defrag_ipv4 bridge stp llc nf_tables nfnetlink uvcvid= eo videobuf2_vmalloc videobuf2_memops uvc videobuf2_v4l2 videodev videobuf2= _common snd_seq_dummy snd_hrtimer snd_seq qrtr rfkill overlay ftdi_sio usbs= erial snd_usb_audio snd_usbmidi_lib snd_pcm aes_ce_blk aes_ce_cipher snd_hw= dep polyval_ce snd_rawmidi polyval_generic snd_seq_device joydev snd_timer = ghash_ce hid_generic gf128mul snd usbhid sha2_ce ipmi_ssif soundcore hid mc= sha256_arm64 ipmi_devintf arm_spe_pmu ipmi_msghandler sha1_ce sbsa_gwdt bi= nfmt_misc nls_ascii nls_cp437 vfat fat xgene_hwmon cppc_cpufreq arm_cmn arm= _dsu_pmu evdev nfsd auth_rpcgss nfs_acl lockd grace dm_mod fuse loop efi_ps= tore dax sunrpc configfs ip_tables x_tables autofs4 ext4 crc16 mbcache jbd2= btrfs efivarfs raid10 raid > > 456 async_raid6_recov async_memcpy > > > [ +0,000142] async_pq async_xor async_tx libcrc32c crc32c_generic x= or xor_neon raid6_pq raid1 raid0 multipath linear md_mod nvme nvme_core ast= t10_pi drm_shmem_helper xhci_pci drm_kms_helper xhci_hcd crc64_rocksoft cr= c64 drm crc_t10dif usbcore crct10dif_generic igb crct10dif_ce crct10dif_com= mon usb_common i2c_algo_bit i2c_designware_platform i2c_designware_core > > > [ +0,121670] CPU: 0 PID: 442 Comm: kworker/0:4 Not tainted 6.5.0+ #2 > > > [ +0,006259] Hardware name: ADLINK AVA Developer Platform/AVA Develo= per Platform, BIOS TianoCore 2.04.100.07 (SYS: 2.06.20220308) 09/08/2022 > > > [ +0,012506] Workqueue: events work_for_cpu_fn > > > [ +0,004353] pstate: 80400009 (Nzcv daif +PAN -UAO -TCO -DIT -SSBS B= TYPE=3D--) > > > [ +0,006953] pc : logic_inl+0xa0/0xd8 > > > [ +0,003570] lr : snd_cmipci_probe+0x7a4/0x1140 [snd_cmipci] > > > [ +0,005578] sp : ffff80008287bc70 > > > [ +0,003303] x29: ffff80008287bc70 x28: ffff08008af9d6a0 x27: 000000= 0000000000 > > > [ +0,007128] x26: ffffc4818263c228 x25: 0000000000000000 x24: 000000= 0000000001 > > > [ +0,007127] x23: ffff07ff81a9e000 x22: ffff07ff81a9e0c0 x21: ffff08= 008af9d080 > > > [ +0,007127] x20: ffffc4818263c000 x19: 0000000000000000 x18: ffffff= ffffffffff > > > [ +0,007127] x17: 0000000000000000 x16: ffffc4819ac3cd38 x15: ffff80= 008287ba80 > > > [ +0,007127] x14: 0000000000000001 x13: ffff80008287bbc4 x12: 000000= 0000000000 > > > [ +0,007126] x11: ffff07ff834616d0 x10: ffffffffffffffc0 x9 : ffffc4= 819a61dd18 > > > [ +0,007127] x8 : 0000000000000228 x7 : 0000000000000001 x6 : 000000= 00000000ff > > > [ +0,007127] x5 : ffffc4819adb7998 x4 : 0000000000000000 x3 : 000000= 00000000ff > > > [ +0,007127] x2 : 0000000000ffbffe x1 : 000000000000000c x0 : fffffb= fffe80000c > > > [ +0,007126] Call trace: > > > [ +0,002436] logic_inl+0xa0/0xd8 > > > [ +0,003221] local_pci_probe+0x48/0xb8 > > > [ +0,003744] work_for_cpu_fn+0x24/0x40 > > > [ +0,003741] process_one_work+0x170/0x3a8 > > > [ +0,004002] worker_thread+0x23c/0x460 > > > [ +0,003742] kthread+0xe8/0xf8 > > > [ +0,003047] ret_from_fork+0x10/0x20 > > > [ +0,003569] Code: d2bfd000 f2df7fe0 f2ffffe0 8b000020 (b9400000) > > > [ +0,006083] ---[ end trace 0000000000000000 ]--- > > >=20 > > > Because this sound card chipset seems to be popular (pretty much all = PCI cards > > > I can find to buy locally use that), I'm thinking this might be speci= fic to > > > arm64, otherwise someone would have seen this before. > >=20 > > There is only one change in this driver code itself since 6.5 (commit > > b6ba0aa46138), and judging from the stack trace, it's unrelated with > > your problem. It's more likely a regression in the lower level code, > > e.g. PCI layer or arch/arm64 stuff. > >=20 > > Could you try git bisect? >=20 > Hmm, but has this combination of card and machine *ever* actually worked? That could be it. In trying to find a starting point for the bisection, I tried 6.1.0, 5.15.130, and 5.10.19, and they all fail in exactly the same way. I didn't go further back. > It's blowing up trying to access PCI I/O space, which has apparently ended > up in the indirect access mechanism without that being configured correct= ly. > That is definitely an issue down somewhere between the PCI layer and the > system firmware. Does the system even have an I/O space window? Some arm64 > machines don't. I guess we might not have got as far as probing a driver = if > the I/O BAR couldn't be assigned at all, but either way something's not g= one > right. I'm pretty sure I saw reports of people using PCI GPUs on this machine, but I would need to confirm. What info would I need to gather from the machine in order to figure this out? --SpMcbUejsrGYVbOX Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEst7mYDbECCn80PEM/A2xu81GC94FAmT4xrUACgkQ/A2xu81G C952DBAAipiZmtHVhrMt7eXTx3M7MGPFcBYZb8+n8NJ7+V01hJSuf3mNIIWJVfBr Y9du3v0p35+E+B1dya+I62tq2dv2qY5zM05E8hQLrLNjpJGgoDMGQTyzbR0pMW0x FqBhF9D/Lq6xaTeHiQoLJp0t3wsYl3NgDFkD/fBtqpQ47P4YjdRUi07lVpcwWE8y PSE3icJ9s/pmP63epakd7U+D0a4teMBMPH8SnWTFuU1PG1awRv4uevHZ3IkOrMFt r2V55ACGGHXe1LQ4Awl+dgdqKTJUMmKdjoaetm9/vqo7VnlAgWyzQ0xxyXJejQOC vJWjTml9P9TZtpZw9+r9rS+/sW8DHLev6DnhC/PZ5pYjoSaNIsL17BN3QRU6YlvB C5hld6ImoUa4NwmVRNNbRmOJXvEFPu35dmouPBfzL4h0LZQPneAdeDmVREnovJ5o vfLA5VSlJpB1A1WZcxWWpi6JGQIST2NN9+y8/CVJRTpoh93aInSVpaBv7I8uon7N B6WuzqP5SokLnnXDrVcjLwwB2cvRuXtYTz4hWbgz7eXzfDraBJjkyaqKsCF5iJWZ IR9aphEiJmWLYUJ7k0sJwWg8jP2vCdMYfCIs/lr5JeuhYvNkK/cRFcaTbrsCvJ51 0ebMlBHn8cPuwP7spbq0p9X012MPZ31X90PUAUBLgFhKunE9308= =TQAU -----END PGP SIGNATURE----- --SpMcbUejsrGYVbOX-- --===============7938154588968327654== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel --===============7938154588968327654==--