Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp598090imm; Fri, 1 Jun 2018 06:31:17 -0700 (PDT) X-Google-Smtp-Source: ADUXVKIiEYxrumX9X9qTAhMky7H5jnZxqbTpxkT2bLD6+ULkFGllbshlVWCFhya2+A9rXv6NO3/Z X-Received: by 2002:a65:590e:: with SMTP id f14-v6mr8961116pgu.282.1527859877469; Fri, 01 Jun 2018 06:31:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527859877; cv=none; d=google.com; s=arc-20160816; b=EMqiqSWXwE2u33wpl62EgzYUbuNEpSf9mrZR3GB/H+uXMVhWyyTkZbYYLvbNZYhV8u kEDqIf5z8I9a2z0npGYNR1VoIwiI/YGUwWfbO4DQ8NWwuPJzXd7RsS5apRNnEFaBk6nu CwbiIux5EIq9E/z9iSRo5GVKKoACpxl9mlNd1qFNEZuziTiQdsoeVx/Pq0KYqh6QZALu aSrrqnhG5dfOWqhNOZE/dUjP/NOiGmo93SvaYAwtHgUAtd8zGboklryTh1yc4aFaoHWJ 5qBfHk9g+xaQbGHo8uQfR6uSf9qpacbCdvsMVO+k+0GVGFS/JdZVFl+C41ZeCKr7jAwD roAg== 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:from:references:cc:to:subject:dmarc-filter :dkim-signature:dkim-signature:arc-authentication-results; bh=716+YNqGoKlz6YKBh8Z/nrFGLoWEGeQBR8kEEnmrieA=; b=D1NqrJgiTdrk+hHappiwy9kH/eH9v+io7kV6SaAuUjoVZwf6QIi8aSZ4f2EqwMtN5p 5vmJPE4iUuCqX7Nkn87stcA909XpVossc6Q/GVpDkrDid4UvA+iu88kYDgwKCoPieSU5 D31QCRBLeESORLEnudauZMm+hZRjcExDD3WoLiTZ1oNSjttrr0iRR58nscaVgPyNLEDE lf3K6QBz6zS4ZhmItXkL1csIDgJLW/iMYrWuDk9ZyzDlO+PvuN8ze+3eatCVSA7NeJfz btTcNWOsqTAnWTaq0piFFCRebCg+QmAySXKVbwh1ZVnpIf7kdajnSlmT0In71undirQ+ 6GNA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=DTr9G/o1; dkim=pass header.i=@codeaurora.org header.s=default header.b=pIdb4NCv; 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 w66-v6si41117918pfj.144.2018.06.01.06.31.00; Fri, 01 Jun 2018 06:31:17 -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; dkim=pass header.i=@codeaurora.org header.s=default header.b=DTr9G/o1; dkim=pass header.i=@codeaurora.org header.s=default header.b=pIdb4NCv; 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 S1751835AbeFANad (ORCPT + 99 others); Fri, 1 Jun 2018 09:30:33 -0400 Received: from smtp.codeaurora.org ([198.145.29.96]:33448 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751342AbeFANab (ORCPT ); Fri, 1 Jun 2018 09:30:31 -0400 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 7928660261; Fri, 1 Jun 2018 13:30:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1527859831; bh=faRIhOab3UvGaKOSFrWXXkfm0Xoq+P//L1lGL4jK6Pw=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=DTr9G/o1O/0E+w9g3tBUe3XDxeVXCrxRKof/ptFKxLraSLfabEuOrpJrK6KkuzATZ vfOVOgd3Ac2ghwY7NuFNOa7uBJuaxg+qKn89iCAEhzuHBsP+EUAA6PZiltPHd2xqd/ KOX/9swEbrkbxyppQunhfZsa8akDcMctItuLkmfs= X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on pdx-caf-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.8 required=2.0 tests=ALL_TRUSTED,BAYES_00, DKIM_SIGNED,T_DKIM_INVALID autolearn=no autolearn_force=no version=3.4.0 Received: from [10.235.228.150] (global_nat1_iad_fw.qualcomm.com [129.46.232.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: okaya@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 1613B60261; Fri, 1 Jun 2018 13:30:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1527859830; bh=faRIhOab3UvGaKOSFrWXXkfm0Xoq+P//L1lGL4jK6Pw=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=pIdb4NCvEXZt1Otq2XmPuGWGoJ1rL7bI21Tp7tD1O9YVkyoaVQW+HtNFYdSwIrdwl 8LIl6ZOXdf2U5sUD2PrKg4ou8ixf1Yf+kC0qK+dEq5F8NAWL2AKzwWi/q6Dzk18mpl ABzY2/SWrFRp+YWmwkbM22V9Ar7WEHOdCTW9apls= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 1613B60261 Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=okaya@codeaurora.org Subject: Re: [PATCH] PCI: Check for PCIe downtraining conditions To: "Alex G." , bhelgaas@google.com Cc: alex_gagniuc@dellteam.com, austin_bolen@dell.com, shyam_iyer@dell.com, keith.busch@intel.com, linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org References: <20180531150535.9684-1-mr.nuke.me@gmail.com> <3e0ddec1-649b-3e97-65e5-073dd9d45a1c@gmail.com> From: Sinan Kaya Message-ID: <874b9b90-ae6a-ef88-ebd8-671f277443ab@codeaurora.org> Date: Fri, 1 Jun 2018 09:30:29 -0400 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0 MIME-Version: 1.0 In-Reply-To: <3e0ddec1-649b-3e97-65e5-073dd9d45a1c@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 5/31/2018 5:44 PM, Alex G. wrote: > On 05/31/2018 10:30 AM, Sinan Kaya wrote: >> On 5/31/2018 11:05 AM, Alexandru Gagniuc wrote: >>> + if (dev_cur_speed < max_link_speed) >>> + pci_warn(dev, "PCIe downtrain: link speed is %s (%s capable)", >>> + pcie_bus_speed_name(dev_cur_speed), >>> + pcie_bus_speed_name(max_link_speed)); >>> + >> >> Also this isn't quite correct. Target link speed is what the device tries to >> train. A device can try to train to much lower speed than the maximum on purpose. >> >> It makes sense to print this if the speed that platform wants via target link >> speed is different from what is actually established though. > > After seeing Gen 3 devices that train above the speed in the target link > speed field, I talked to one the spec writers today. There is some > ambiguity with the target link speed field. In PCIe 4.0 they are > clarifying that to state that this field is "permitted to have no effect". Good to know. Probably, some company screwed up implementing this register... All these flexible terminology in the spec is an indication of such a failure. > > Alex > > -- Sinan Kaya Qualcomm Datacenter Technologies, Inc. as an affiliate of Qualcomm Technologies, Inc. Qualcomm Technologies, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project.