From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.9 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 432F0C4363D for ; Thu, 24 Sep 2020 10:14:02 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id ABE2421D24 for ; Thu, 24 Sep 2020 10:14:01 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="iTJtSWmq" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org ABE2421D24 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id E0B836B009A; Thu, 24 Sep 2020 06:14:00 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id DBA406B009B; Thu, 24 Sep 2020 06:14:00 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id CA92F6B009C; Thu, 24 Sep 2020 06:14:00 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0022.hostedemail.com [216.40.44.22]) by kanga.kvack.org (Postfix) with ESMTP id B0B116B009A for ; Thu, 24 Sep 2020 06:14:00 -0400 (EDT) Received: from smtpin05.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 72BEB180AD801 for ; Thu, 24 Sep 2020 10:14:00 +0000 (UTC) X-FDA: 77297544240.05.cough71_23177e22715e Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin05.hostedemail.com (Postfix) with ESMTP id 506171826B6AB for ; Thu, 24 Sep 2020 10:14:00 +0000 (UTC) X-HE-Tag: cough71_23177e22715e X-Filterd-Recvd-Size: 4212 Received: from mail-wr1-f68.google.com (mail-wr1-f68.google.com [209.85.221.68]) by imf10.hostedemail.com (Postfix) with ESMTP for ; Thu, 24 Sep 2020 10:13:59 +0000 (UTC) Received: by mail-wr1-f68.google.com with SMTP id g4so3155757wrs.5 for ; Thu, 24 Sep 2020 03:13:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=kU3gnCMAsP2x/I5wCXT3/EKvoa/BON3ipEwTyPLZ/Ks=; b=iTJtSWmqJeU7llzv/rf2LzC0rJBnUIQYVHMUsA9Kd7kAivrPBT6K63Fi8f1slMi4nY EI76gDzdH6EXcJlD5LjQK0rmrKM4gjNPwEzpVa7ChVezK11LJd4bepFr6iALMv7J0cci SInOhF7PIAlVDnDrTmwd8hCE0kQRjfGXAL0bNg49k6BkYdBU4ynxjOqqUDxKlde5c/W2 8Hs6RaSL6YO2t6K66sqH2zb+Ez8PBhPsK2cktrU7DJcUqL5ZVBSNaRXKOWn46As6PFBJ 0JuecfRbRsz9JimHA4i8en4uCflh9w9eY25JOJ1yAn+gRrHUkb9+un2RBh6x+EXPh3ln cz2A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=kU3gnCMAsP2x/I5wCXT3/EKvoa/BON3ipEwTyPLZ/Ks=; b=CaGw1wYM7fwVO0OAO6TTHZFlolOFwrviljpFKX2lT4bkJABnFQJSlOHUnkHkjWAWJm FVtIHXo/jnwkDukhHR7HcJAQ1DXc0Ot6cBNGleu4A9GHjQvX4QQy/1q6M4seZ4zpFB8p XG7sw9148wWadPP4QFONleR1DRhLZ3FmoUG/w2y2FUeAL+i9hmf1W6+tAJU2bW+OziQ0 E46XpP7lfgdNfdM3x7blZH81rXFDtZApCbuRTqxx9ck/nlwbxRI+tiHR6k5wXSAzaMBy XKufY///TPQjJniHrPfHmjqdRJEQlf9LCxEyYcC4Z6oRSO/2bBWhIj//jxCGvhlBSc8+ qzqA== X-Gm-Message-State: AOAM530f/ti4d0qBS4DiBdJBNzhlhXr6s6BcBEeg1mj2musBWYe88g+j jcMYjrpuXJN2h/uXLzGLW1uQqA== X-Google-Smtp-Source: ABdhPJzwvyDtM5EY9cTKbSmfCPd8Ndctc7U1hxoVNhC0cIf/mU53M9YuULxQk3Bj1qzclp1sb8T/Iw== X-Received: by 2002:adf:cd0e:: with SMTP id w14mr4708454wrm.0.1600942438754; Thu, 24 Sep 2020 03:13:58 -0700 (PDT) Received: from myrica ([2001:1715:4e26:a7e0:116c:c27a:3e7f:5eaf]) by smtp.gmail.com with ESMTPSA id x16sm2948499wrq.62.2020.09.24.03.13.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 24 Sep 2020 03:13:58 -0700 (PDT) Date: Thu, 24 Sep 2020 12:13:40 +0200 From: Jean-Philippe Brucker To: Shameerali Kolothum Thodi Cc: "iommu@lists.linux-foundation.org" , "linux-arm-kernel@lists.infradead.org" , "linux-mm@kvack.org" , "fenghua.yu@intel.com" , "catalin.marinas@arm.com" , Suzuki K Poulose , "robin.murphy@arm.com" , "zhangfei.gao@linaro.org" , "will@kernel.org" Subject: Re: [PATCH v10 10/13] iommu/arm-smmu-v3: Check for SVA features Message-ID: <20200924101340.GC170808@myrica> References: <20200918101852.582559-1-jean-philippe@linaro.org> <20200918101852.582559-11-jean-philippe@linaro.org> <753bcd76c21c4ea98ef1d4e492db01f4@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <753bcd76c21c4ea98ef1d4e492db01f4@huawei.com> X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: Hi Shameer, On Mon, Sep 21, 2020 at 08:59:39AM +0000, Shameerali Kolothum Thodi wrote: > > +bool arm_smmu_sva_supported(struct arm_smmu_device *smmu) > > +{ > > + unsigned long reg, fld; > > + unsigned long oas; > > + unsigned long asid_bits; > > + u32 feat_mask = ARM_SMMU_FEAT_BTM | > > ARM_SMMU_FEAT_COHERENCY; > > Why is BTM mandated for SVA? I couldn't find this requirement in SMMU spec > (Sorry if I missed it or this got discussed earlier). But if performance is the only concern here, > is it better just to allow it with a warning rather than limiting SMMUs without BTM? It's a performance concern and requires to support multiple configurations, but the spec allows it. Are there SMMUs without BTM that need it? Thanks, Jean