Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp4829180imm; Tue, 21 Aug 2018 01:30:18 -0700 (PDT) X-Google-Smtp-Source: AA+uWPyCz2Zj5CUyOU6KeYTn+ApEIDrpL3JLJhit9Y/o8D0Ohvl29LH14i2E7qvmd07QWv5GJV/l X-Received: by 2002:a17:902:a9ca:: with SMTP id b10-v6mr20730090plr.198.1534840218213; Tue, 21 Aug 2018 01:30:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1534840218; cv=none; d=google.com; s=arc-20160816; b=L0kTjKDj5U65mOPdA9dsqokvk2Pa4foYJJjyzU92O7zxbiTO6e+So8qXhnBoU0Mbut Ds6RCShRM1dpAxh9Tqw+0bSdITcrmma46eYpoflF566XbZEhjKs0Oqk+zUrYwGhjQZxG 0pFRvtHwUPM4doR9ugeNou6aMzPTNs5o3ZUwj/jbMpooqfl1tbRGA/Cjcxm3s4nLw3UH HDifsd/+8Ojrr6T1EKhV7/i7uTFpys7dTwRC2g/zUNmbTiL2NAwmSceGFHJ3tbrMLg+f 3224iwwZ3C1CBkLjA+OBZFq/amb25F0tj3tlDP489lT1P7UfvYHNxFDhTHUNEHuGz7RZ mx1A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:organization:from:references:cc:to:subject :arc-authentication-results; bh=c5cHI4IwDfF2AcYsOoLOuUQX/SukXvmkkCxJ46sXo9I=; b=HbaSsp4pUZIkZWJKl55DnauL49xstebi5Qvjw82LwIPLqLIsh0LrOvhEV0VBmqsOJ1 jTepD5htZs6vARp/JSaRKkOQRFA2IHIBsxx1zMJDkNkFAY8NgkXJhPhZgnSOPHBy34at 1xDdtLy9ATsdw//slhEXDgMOj0vvXyXh4OUnMr5V0JXkmQiaZixR0DNCPLC8jNZD7sqi 9pWWPj23NMI9yzvxUlBT1DbB2NlvJ6lX/057Zh1rDbfUd4wBHoR2nP+ffOKO2tNOjKLY VI+d8+OTdRk8k0WIpfjSbqhWtL+owF/lWLxQrvKugZKETz6jZNgAsK0IEbleLNRFC0/T a1Eg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v25-v6si11575854pgk.555.2018.08.21.01.30.03; Tue, 21 Aug 2018 01:30:18 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726814AbeHULrg (ORCPT + 99 others); Tue, 21 Aug 2018 07:47:36 -0400 Received: from foss.arm.com ([217.140.101.70]:46234 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726315AbeHULrg (ORCPT ); Tue, 21 Aug 2018 07:47:36 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id AA7407A9; Tue, 21 Aug 2018 01:28:24 -0700 (PDT) Received: from [10.4.13.119] (usa-sjc-imap-foss1.foss.arm.com [10.72.51.249]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id D3AA53F739; Tue, 21 Aug 2018 01:28:22 -0700 (PDT) Subject: Re: [PATCH] r8169: don't use MSI-X on RTL8106e To: Bjorn Helgaas , Heiner Kallweit , jian-hong@endlessm.com Cc: David Miller , nic_swsd@realtek.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux@endlessm.com, linux-pci@vger.kernel.org, Thomas Gleixner , Christoph Hellwig References: <20180815062110.16155-1-jian-hong@endlessm.com> <20180816.122131.604270853620318143.davem@davemloft.net> <458efbf9-5971-653a-e7cd-8c56ba055648@gmail.com> <20180816.123958.750435252621963789.davem@davemloft.net> <20180820184438.GA154536@bhelgaas-glaptop.roam.corp.google.com> From: Marc Zyngier Organization: ARM Ltd Message-ID: <02c08346-3901-9c39-a837-f04e283794d5@arm.com> Date: Tue, 21 Aug 2018 09:28:21 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <20180820184438.GA154536@bhelgaas-glaptop.roam.corp.google.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 20/08/18 19:44, Bjorn Helgaas wrote: > [+cc Marc, Thomas, Christoph, linux-pci) > (beginning of thread at [1]) > > On Thu, Aug 16, 2018 at 09:50:48PM +0200, Heiner Kallweit wrote: >> On 16.08.2018 21:39, David Miller wrote: >>> From: Heiner Kallweit >>> Date: Thu, 16 Aug 2018 21:37:31 +0200 >>> >>>> On 16.08.2018 21:21, David Miller wrote: >>>>> From: >>>>> Date: Wed, 15 Aug 2018 14:21:10 +0800 >>>>> >>>>>> Found the ethernet network on ASUS X441UAR doesn't come back on resume >>>>>> from suspend when using MSI-X. The chip is RTL8106e - version 39. >>>>> >>>>> Heiner, please take a look at this. >>>>> >>>>> You recently disabled MSI-X on RTL8168g for similar reasons. >>>>> >>>>> Now that we've seen two chips like this, maybe there is some other >>>>> problem afoot. >>>>> >>>> Thanks for the hint. I saw it already and just contacted Realtek >>>> whether they are aware of any MSI-X issues with particular chip >>>> versions. With the chip versions I have access to MSI-X works fine. >>>> >>>> There's also the theoretical option that the issues are caused by >>>> broken BIOS's. But so far only chip versions have been reported >>>> which are very similar, at least with regard to version number >>>> (2x VER_40, 1x VER_39). So they may share some buggy component. >>>> >>>> Let's see whether Realtek can provide some hint. >>>> If more chip versions are reported having problems with MSI-X, >>>> then we could switch to a whitelist or disable MSI-X in general. >>> >>> It could be that we need to reprogram some register(s) on resume, >>> which normally might not be needed, and that is what is causing the >>> problem with some chips. >>> >> Indeed. That's what I'm checking with Realtek. >> In the register list in the r8169 driver there's one entry which >> seems to indicate that there are MSI-X specific settings. >> However this register isn't used, and the r8168 vendor driver >> uses only MSI. And there are no public datasheets. > > Do we have any information about these chip versions in other systems? > Or other devices using MSI-X in the same ASUS system? It seems > possible that there's some PCI core or suspend/resume issue with MSI-X > and this patch just avoids it without fixing the root cause. > > It might be useful to have a kernel.org bugzilla with the complete > dmesg, "sudo lspci -vv" output, and /proc/interrupts contents archived > for future reference. The one system I have with a Realtek chip seems happy enough with MSI-X, but it never gets suspended. There is comment in the patch that I don't quite get: > It is the IRQ 127 - PCI-MSI used by enp2s0. However, lspci lists MSI is > disabled and MSI-X is enabled which conflicts to the interrupt table. What do you mean by "conflicts"? With what? Another question is whether you've loaded any firmware (some versions of the Realtek HW seem to require it). For the posterity, some data from my own system, which I don't know if it has any relevance to the problem at hand. Thanks, M. [ 2.624963] r8169 0000:02:00.0 eth0: RTL8168g/8111g, 5a:fe:ad:ce:11:00, XID 4c000800, IRQ 26 [ 2.633398] r8169 0000:02:00.0 eth0: jumbo features [frames: 9200 bytes, tx checksumming: ko] 26: 50 997005 0 0 MSI 1048576 Edge enp2s0 02:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 0c) Subsystem: Realtek Semiconductor Co., Ltd. RTL8111/8168 PCI Express Gigabit Ethernet controller Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+ Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- SERR-