Received: by 2002:a25:ef43:0:0:0:0:0 with SMTP id w3csp736415ybm; Wed, 27 May 2020 06:53:10 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxx8fOvxAbCSaiEPZTUYPMYoNg/DiDHGYcRchUTA3CiIZ+cR3NMU9dzxcq8nscMl/ozXE3r X-Received: by 2002:a17:906:2810:: with SMTP id r16mr144079ejc.434.1590587590276; Wed, 27 May 2020 06:53:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1590587590; cv=none; d=google.com; s=arc-20160816; b=Xv95HJB/FUg0L+ZPEpKjcVFqWCLqRodgQrigrpcCci/qFLnsTkpHWTl6mB431+Ia47 /IfW7uOOHYJjxh3KIRS+ZbHFz601VxUcDGNk3lm6jPmImATFo8zCaE3jNr0ykhaZrsl/ uyk5fzXI7oBg365nrLQchLM40tTL56gxG0YBLLAJm4L9lNPcvrRaokE+pgid+s6jnn8U 7B4uu+PPlkXTC0ryv/I1abRvDP4joZCYsxDP3GP2WIiVQCUIxtZ/ddEJEWouTKyQ5LjZ nfplcTzkeaQc96fHaElRDX0qwo5zChClG8aoRPbGbWcrjON+bBn5+JW7fAcA6OVa43fR n4Gw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=sVOrxsk18BnSFATyAjPbeo6+7yMbRqTwIElwDUYrAFk=; b=mbElrJxvwL4cYsDEL1Mbwr+Kc6OFy+Glp375/CawcOrXrwQYnPb2uD1wYXmJWIoUpz hxXMp/tc2CkSJwqn5YfP4aqWE8/ZFqPEUqGHPo/nBycZvkiuZGelnRTt4B6V2ENl6VA/ VzZF7JRPFqS33mdf/0BkwNozJzQ81rQymW3fbKVXwec9/Y7/7f7XpOBv6gbwF1Qm3cil loiH23/1qWvhknqgdKfKi1JEMPCcPYbz94Op5Wuos9WYI5pJ/o9PUw9BnNA7YjTmHsfN ETFxAfd8Yc9pRK2m6YqIHfBNMHG+9e7D8lhOukv2cwMBP8WRPcHu/rj0eTol4ZaiKL81 aNIg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=IQd9QRIu; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id oy11si1966870ejb.386.2020.05.27.06.52.42; Wed, 27 May 2020 06:53:10 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-crypto-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=@linaro.org header.s=google header.b=IQd9QRIu; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388900AbgE0NwJ (ORCPT + 99 others); Wed, 27 May 2020 09:52:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38558 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388760AbgE0NwJ (ORCPT ); Wed, 27 May 2020 09:52:09 -0400 Received: from mail-pl1-x643.google.com (mail-pl1-x643.google.com [IPv6:2607:f8b0:4864:20::643]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1251FC08C5C2 for ; Wed, 27 May 2020 06:52:09 -0700 (PDT) Received: by mail-pl1-x643.google.com with SMTP id x18so9038174pll.6 for ; Wed, 27 May 2020 06:52:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding:content-language; bh=sVOrxsk18BnSFATyAjPbeo6+7yMbRqTwIElwDUYrAFk=; b=IQd9QRIugzIzBpTvp3+gDmqldfXigO2E49gsEa4gWjkW8zQ7okCePzzME85lMseCYp C6UogWhM76FwGK5GWiG8mRjoqMxQAiVMmmfU32mB1clNfA4oHsd9jNVbdkKq9iRLaZ6o /GSx8wknomZEweg/pRNTs5AEyhz2TlPsVfIh1FVWAsub3p7gsfYfKsWEW0GjuGLOSeH3 JX/KrTERHguXCxqwKCC2l18gU5RD125PFLl4ooOSVZXxkfqWDt3XB8oULXtxbINGB7jy IZ+Ys2oL0/yBtqmoT9wOKg1LwOZXfABmxwNOY7WVGXRfz3jB/ahveiTxn+3ArAeBKNsp azNw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding :content-language; bh=sVOrxsk18BnSFATyAjPbeo6+7yMbRqTwIElwDUYrAFk=; b=ly6X6YpLRH0nC18ufO5ZU/V17RNJBPkQA4rULdLHJz+hb2Lm74Ihv7vXCNH6um9A5F ee0KVE4XaXUXUJbiLF7b+kbaLcoO54PvCC7JZhdXdQN4vwS4ZmrnsLIRLnCVuoqh5BeO l4BsmwqUwZ6JBMJdWQRYeDQqqy+gqQVv+yJvycnm54yAx7Bf63kG8IrqYyrpJUR56CmR WNzlMA70Ons8Fqp1B1KOdErtlb3xkRcesva8Z35eY+ecaapUPxuIumAF9r+dTa9IgIsM 8RLaZyHPBB0EXiof4RFGfWXeSim/YHaI/Gi3bHfhe0PBNBpcxp7RMuvBM4862dX0+Mq3 hIYA== X-Gm-Message-State: AOAM530cVsbrAuiUWZE4recJmJ1AlZ+qDpcvGBq6z4dF3B87++Cm/929 PiHpqzdw1vKyWHWVtcuJ+SHi6Q== X-Received: by 2002:a17:90a:2ac2:: with SMTP id i2mr5055611pjg.80.1590587528565; Wed, 27 May 2020 06:52:08 -0700 (PDT) Received: from [192.168.11.133] (li1566-229.members.linode.com. [139.162.86.229]) by smtp.gmail.com with ESMTPSA id s15sm2106775pgv.5.2020.05.27.06.51.46 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 27 May 2020 06:52:07 -0700 (PDT) Subject: Re: [PATCH 0/2] Introduce PCI_FIXUP_IOMMU To: Arnd Bergmann , Greg Kroah-Hartman Cc: Joerg Roedel , Bjorn Helgaas , Lorenzo Pieralisi , Hanjun Guo , Sudeep Holla , "Rafael J. Wysocki" , Len Brown , jean-philippe , Herbert Xu , kenneth-lee-2012@foxmail.com, Wangzhou , "linux-kernel@vger.kernel.org" , "open list:HARDWARE RANDOM NUMBER GENERATOR CORE" , "open list:IOMMU DRIVERS" , ACPI Devel Maling List , Linux ARM , linux-pci References: <1590493749-13823-1-git-send-email-zhangfei.gao@linaro.org> <20200527090007.GA179718@kroah.com> From: Zhangfei Gao Message-ID: Date: Wed, 27 May 2020 21:51:13 +0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org On 2020/5/27 下午5:53, Arnd Bergmann wrote: > On Wed, May 27, 2020 at 11:00 AM Greg Kroah-Hartman > wrote: >> On Tue, May 26, 2020 at 07:49:07PM +0800, Zhangfei Gao wrote: >>> Some platform devices appear as PCI but are actually on the AMBA bus, >> Why would these devices not just show up on the AMBA bus and use all of >> that logic instead of being a PCI device and having to go through odd >> fixes like this? > There is a general move to having hardware be discoverable even with > ARM processors. Having on-chip devices be discoverable using PCI config > space is how x86 SoCs usually do it, and that is generally a good thing > as it means we don't need to describe them in DT > > I guess as the hardware designers are still learning about it, this is not > always done correctly. In general, we can also describe PCI devices on > DT and do fixups during the probing there, but I suspect that won't work > as easily using ACPI probing, so the fixup is keyed off the hardware ID, > again as is common for x86 on-chip devices. > > Yes, thanks Arnd :) In order to use pasid, io page fault has to be supported, either by PCI PRI feature (from pci device) or stall mode from smmu (platform device). Here is letting system know the platform device can support smmu stall mode, as a result support pasid. While stall is not a pci capability, so we use a fixup here. Thanks