Received: by 2002:a05:6a10:9e8c:0:0:0:0 with SMTP id y12csp2283900pxx; Sat, 31 Oct 2020 14:52:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw3GaIRXsL4ajxgfVHsKfRHLzyRmqoaUEbiPaOcVs+IbKI2yi5rPDcfoyaj62VT6IDc53Z4 X-Received: by 2002:a50:8d48:: with SMTP id t8mr9575768edt.228.1604181174331; Sat, 31 Oct 2020 14:52:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1604181174; cv=none; d=google.com; s=arc-20160816; b=gMUN3CkX09ulQwYF6K0jPkYUSMMk5WxSzKyOAiJhxW2G6ss4Qq51uSzV4Q3FZF8923 F0E+5Ox01Oi8HqJhloW07xg5pnKHmKxp6iaXOzhnDDroZco24pijJBvSOQ9I/8EqTahN o0olIRaemHiiz9j1LIUzQIePKFmyHoH8qEVOCIT/E6TYQpUiakElzDsx/d8GBNIfRs44 WniYaafGGRPfU1/tgMpPqsHC6prigVslV/K94pZJouYNuf5R/2bf2B0avRUtHUNyimFz IlYHSSySVuQjtsdeD7q1VyGWePORhTUycgq/tqScfFkzQ4nmoIMylf97BVV7aW0jGHGo eI8Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:references :in-reply-to:subject:cc:to:dkim-signature:dkim-signature:from; bh=qkyGG23d8Oju/T6dnuYTqANlxTDymnqLTSvkubtS9gg=; b=pBwgXt5CjP1ljVoxpnQhXWarR95OFHA3LqbumVmFfPugjiDCAT8fXbDbdNvofFId0Z +tL3f38fL7LFkISehF++XZOaRLAG/NI36Risw886w6WrMR8J3xdTZrEdWJ8w4YljAXY9 wVUBz/u0SfTDJbmwzAvnlYdHaf0Izwbd1iHdz5vPhLrreAVl84EedMnQMi/w7Wh21SKn MgBBVsqjk1+eY7OBbt8tc6ChMbwfF84bXi28b03fI4xNEV6V2L8tQ6xjXbwBDk0lXPgz t8d1E4fJL+s2j4/BlubJ5leMhhHd+u+IK8RW6JqEmeMg93B6gO3P55AdypgbwNCdukHD UUJA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=vsliVRnt; dkim=neutral (no key) header.i=@linutronix.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g8si8970899ejm.497.2020.10.31.14.52.31; Sat, 31 Oct 2020 14:52:54 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=vsliVRnt; dkim=neutral (no key) header.i=@linutronix.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726069AbgJaVtR (ORCPT + 99 others); Sat, 31 Oct 2020 17:49:17 -0400 Received: from Galois.linutronix.de ([193.142.43.55]:50284 "EHLO galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725782AbgJaVtR (ORCPT ); Sat, 31 Oct 2020 17:49:17 -0400 From: Thomas Gleixner DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1604180955; h=from:from:reply-to:subject:subject: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=qkyGG23d8Oju/T6dnuYTqANlxTDymnqLTSvkubtS9gg=; b=vsliVRntutM0GOE3hoVVmu/ViFK7VmgZQP2wNyCzCpGdrt0qNofOwIMEPXaJ8iQodzXlSk HEjRYOxuR3Bc8odVZRARR9iZng+XdMVQ09CbkALJBnfTGAVpGC/SW6BRY591pzGCoSCS6j XT8wZRRpGZRtFlWTr2roNQTditYoerX6nw0yjimKlqMwicO6Od1wxUxKeL+qsUtpCKybJ0 ckRRqM6s7y5PbyYodgT4K9CxJFKft0VtbF/oXj1I07SVDdLwG5lNv+aoCpW0+oBhc976d6 OpGPIXkyYsKi9E7in3lwwHurMXjvcVivPjnIXWQYSN3nHhiXatva6m7Gv31S8g== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1604180955; h=from:from:reply-to:subject:subject: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=qkyGG23d8Oju/T6dnuYTqANlxTDymnqLTSvkubtS9gg=; b=ng5hsa/ui4rhHNPKLXo4Fp1L0eC1dpYDz4IzhYF9wy/FkMRl6UZ8zDMPm11TZFcaoAbz4Q izrr+3daBzIRU/Dg== To: Frank Wunderlich , linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org Cc: Frank Wunderlich , Marc Zyngier , Bjorn Helgaas , Matthias Brugger , linux-pci@vger.kernel.org, Ryder Lee Subject: Re: [PATCH] pci: mediatek: fix warning in msi.h In-Reply-To: <20201031140330.83768-1-linux@fw-web.de> References: <20201031140330.83768-1-linux@fw-web.de> Date: Sat, 31 Oct 2020 22:49:14 +0100 Message-ID: <878sbm9icl.fsf@nanos.tec.linutronix.de> MIME-Version: 1.0 Content-Type: text/plain Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Frank, On Sat, Oct 31 2020 at 15:03, Frank Wunderlich wrote: > From: Frank Wunderlich > > 5.10 shows these warnings on bootup while enabling pcie > at least on bananapi-r2: > > [ 6.161730] WARNING: CPU: 2 PID: 73 at include/linux/msi.h:213 pci_msi_setup_ > msi_irqs.constprop.0+0x78/0x80 > .... > [ 6.724607] WARNING: CPU: 2 PID: 73 at include/linux/msi.h:219 free_msi_irqs+ > > fix this by selecting PCI_MSI_ARCH_FALLBACKS for MTK PCIe driver That's not a fix. It's just supressing the warning. PCI_MSI_ARCH_FALLBACKS is only valid for 1) Architectures which implement the fallbacks 2) Outdated PCI controller drivers on architectures without #1 which implement the deprecated msi_controller mechanism. That is handled in the weak arch fallback implementation. The mediatek PCIE driver does not qualify for #2. It's purely irq domain based. So there is something else going wrong. The PCI device which tries to allocate MSIs does not have an irq domain associated which makes it run into that warning. If you enable PCI_MSI_ARCH_FALLBACKS then the MSI allocation fails silently. So it's just papering over the underlying problem. So it needs to be figured out why the domain association is not there. Thanks, tglx