From patchwork Tue Oct 1 12:45:53 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: You-Sheng Yang X-Patchwork-Id: 1169888 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=canonical.com Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 46jJt35jq2z9s7T; Tue, 1 Oct 2019 22:46:19 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1iFHXk-000526-JI; Tue, 01 Oct 2019 12:46:16 +0000 Received: from mail-pg1-f193.google.com ([209.85.215.193]) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1iFHXi-00051y-UQ for kernel-team@lists.ubuntu.com; Tue, 01 Oct 2019 12:46:15 +0000 Received: by mail-pg1-f193.google.com with SMTP id s1so9567104pgv.8 for ; Tue, 01 Oct 2019 05:46:14 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=PwZJHcIEv3E1YjwMrCSUXHrhyHkrNCD2dNiCIiGHZW0=; b=jv/VcAwP0LJetSKHVLqXHYTi/T7nMJ+Nl9nGEJK2dP7nTPFw1PwLE0WCx/Ugh+1jrC 3SiWKfyW+O91RWPumwufovxUOV4nCsGl6Vrx9Jop7kwA9DAvW4cgtWD1adm6UO2UAFoE Mf1DhhqxluBBc4ZuQey9dk2/1N3/h1h/GisesLwaHBwhl6295jAqnhYsLcPdbbKqOECg wvutUPwE30X3gK2dD2HR7Cq7lruexJE3j7WCO27l0p/8PKnDvrNtHIjQPHYPK0sRO4OF soNA5e2nOoU3htsbzEkU7Pi5ecN+2vspWOWME2jJVbZqCl5gNpgMkuBdfkCBGWt3wI8j bohw== X-Gm-Message-State: APjAAAUhApcvAHJaKzBa0PtVfAj8mCgpois0rcjkK9NZWJPMiQNcIgtt SOa1gH6dXqLAb/E87VGJ8aT9WtRbwCk= X-Google-Smtp-Source: APXvYqxC9imf1uHtfdp0dnYlcwlQa3AYN40n5ZiJzpwF4zLgL/DhA8jV81Haeq6l5ARSCvUl8j3yUQ== X-Received: by 2002:a63:5947:: with SMTP id j7mr14193846pgm.402.1569933972534; Tue, 01 Oct 2019 05:46:12 -0700 (PDT) Received: from localhost (61-220-137-37.HINET-IP.hinet.net. [61.220.137.37]) by smtp.gmail.com with ESMTPSA id g9sm2513332pjl.20.2019.10.01.05.46.11 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 01 Oct 2019 05:46:11 -0700 (PDT) From: You-Sheng Yang To: kernel-team@lists.ubuntu.com Subject: [PATCH 00/17][SRU][OEM-OSP1-B] thunderbolt: ICL support Date: Tue, 1 Oct 2019 20:45:53 +0800 Message-Id: <20191001124610.10587-1-vicamo.yang@canonical.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" From: You-Sheng Yang (楊有勝) BugLink: https://bugs.launchpad.net/bugs/1844680 [Impact] The Thunderbolt controller is integrated into the Ice Lake CPU itself and requires special flows to power it on and off using force power bit in NHI VSEC registers. Currently this is not supported until v5.4-rc1. [Fix] Commit 3cdb9446a117 "thunderbolt: Add support for Intel Ice Lake" along with all the prerequisites should be backported to enable thunderbolt. [Test Case] Tested on two Dell XPS platforms with ICL-U and thunderbolt support. [Regression Risk] Medium. While v5.4 is still under development and there is already an known issue about suspend/resume on ICL platforms with thunderbolt enabled, it is definitely going to have follow-ups for this backport, as well as more regression tests on previous systems before landed. Mika Westerberg (17): thunderbolt: Drop duplicated get_switch_at_route() thunderbolt: Move LC specific functionality into a separate file thunderbolt: Cache adapter specific capability offset into struct port thunderbolt: Rename tunnel_pci to tunnel thunderbolt: Generalize tunnel creation functionality thunderbolt: Add functions for allocating and releasing HopIDs thunderbolt: Assign remote for both ports in case of dual link thunderbolt: Add helper function to iterate from one port to another thunderbolt: Extend tunnel creation to more than 2 adjacent switches thunderbolt: Correct path indices for PCIe tunnel thunderbolt: Move NVM upgrade support flag to struct icm thunderbolt: Use 32-bit writes when writing ring producer/consumer thunderbolt: Do not fail adding switch if some port is not implemented thunderbolt: Hide switch attributes that are not set thunderbolt: Expose active parts of NVM even if upgrade is not supported thunderbolt: Add support for Intel Ice Lake ACPI / property: Add two new Thunderbolt property GUIDs to the list drivers/acpi/property.c | 6 + drivers/thunderbolt/Makefile | 4 +- drivers/thunderbolt/ctl.c | 23 ++- drivers/thunderbolt/eeprom.c | 4 - drivers/thunderbolt/icm.c | 239 ++++++++++++++++++++++----- drivers/thunderbolt/lc.c | 21 +++ drivers/thunderbolt/nhi.c | 137 ++++++++++++++-- drivers/thunderbolt/nhi.h | 22 +++ drivers/thunderbolt/nhi_ops.c | 179 ++++++++++++++++++++ drivers/thunderbolt/nhi_regs.h | 37 +++++ drivers/thunderbolt/path.c | 121 ++++++++++++-- drivers/thunderbolt/switch.c | 270 +++++++++++++++++++++++++------ drivers/thunderbolt/tb.c | 79 +++++---- drivers/thunderbolt/tb.h | 111 +++++++++++-- drivers/thunderbolt/tb_msgs.h | 16 +- drivers/thunderbolt/tb_regs.h | 6 + drivers/thunderbolt/tunnel.c | 249 ++++++++++++++++++++++++++++ drivers/thunderbolt/tunnel.h | 43 +++++ drivers/thunderbolt/tunnel_pci.c | 226 -------------------------- drivers/thunderbolt/tunnel_pci.h | 31 ---- drivers/thunderbolt/xdomain.c | 5 +- include/linux/thunderbolt.h | 2 + 22 files changed, 1384 insertions(+), 447 deletions(-) create mode 100644 drivers/thunderbolt/lc.c create mode 100644 drivers/thunderbolt/nhi_ops.c create mode 100644 drivers/thunderbolt/tunnel.c create mode 100644 drivers/thunderbolt/tunnel.h delete mode 100644 drivers/thunderbolt/tunnel_pci.c delete mode 100644 drivers/thunderbolt/tunnel_pci.h