Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp1969752rwd; Thu, 15 Jun 2023 19:26:13 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ54VFj4iV5DDchVHpFLVbGv6u/xlLQqXEAfPqzpl8gWPX7NLEdPKcK2OsmNjWvCoRJAHQTG X-Received: by 2002:a05:6a20:a122:b0:11c:fd2d:ea75 with SMTP id q34-20020a056a20a12200b0011cfd2dea75mr1311184pzk.14.1686882373531; Thu, 15 Jun 2023 19:26:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686882373; cv=none; d=google.com; s=arc-20160816; b=akUfDsup3lZDStnMX6moY4O4mxMAPmI2/Sk0IMoi6JX5rXk5cyMqtB8ouTE+Log4ke dRz9Jc1xRxpJH1hlJ3zxGMTtLQBkPhujgT/h1EH42TFZfZKMsTicgietooaiLnrTO81g x7rDmN5n0PSyrQHxK63iUvyKexBCnbDXw1gEEGmNLXVr/frq6jS2qU1j+nptjpc9boXn QTM8JnFhygg+TkwZR4BSGiBs1+Xgv1CF9zMgeeZgRLvLhgi/+Pincf+RI9yXA2XtCwM5 w+2gfsD45ZQrs0+1X+rU4VfNgoUMW3tgFk63JlrARsjhkibaRHvVS0k+vhE/rQthz9O+ ouGg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:to:content-language:subject:cc:user-agent:mime-version :date:message-id:dkim-signature; bh=K2ceBVIUGM+uZ1K4BjmPif+hTvIDMOz7H5U+7PiyPjU=; b=ke+tgeAtRUK4ribQlefwc9WObqQRXhXP8AoHf527E06bo0yU9vup1WjscgOAYiS0p7 D+kx69pzfhiFGRNQTYGYIrztGmSwQCu/I/Nr0+NqBcmPnnB9vyuWwFB9t96xfySUny1D poMlS9o9jkLNWl5EDIW5S4uZszihpyYoNiBqu8EPAfRDbBgRQaPKPDbonQ1lgsZiDU0G her1STZYO++MMoQBNx2F8s7qSU15GKQgdZ1LvnzJBSeZw0P8psgVpQxPHMgOtJJCiXvJ gRELdgiAedkfj0SKPPOWQgT3Zm14d497dY0rJcZWahx5M2bf69cIeGZpC13+ewyKVC7r 9uDA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=Y7YSkg2c; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c15-20020a170903234f00b001ab09a66f8dsi14288439plh.106.2023.06.15.19.25.59; Thu, 15 Jun 2023 19:26:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=Y7YSkg2c; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229581AbjFPCQM (ORCPT + 99 others); Thu, 15 Jun 2023 22:16:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41732 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240288AbjFPCQK (ORCPT ); Thu, 15 Jun 2023 22:16:10 -0400 Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B8E78296B for ; Thu, 15 Jun 2023 19:16:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1686881766; x=1718417766; h=message-id:date:mime-version:cc:subject:to:references: from:in-reply-to:content-transfer-encoding; bh=fU0lLudBphp5iZvj7Ivutn5Srt0z2bVmbg0LGVBVbGM=; b=Y7YSkg2c/IlI2yB2Wk7f+sNvM8/g4tzw0qx9UGyoUr/yPyqrOiOld7dD nofPb6yQNO7YKoKjFYMTZbeuMblbhLnmfZmYBgw2H+4YpfFlBjOf0rN5o WC6i5dhbTGT8+cGwkvXRhUtQpBqyW1wdSe3E56hKb2hXOjEs2A8yKdojm e5/M6TfX8/+JahinRJVTv7Ov7RH2O6LYyYbfyrUaqhucsRg53XxZhMzcL 6Bz43pvUJUQKUrqL5z2LnlgmI4ldXNu94Z9WHPhWGlBwRBxL9bnzwzoCQ iZJvKUF7xi5P7D9meDCnKnRDRTIaYRZ1mHl4HWLjk532Egfpnd8MlCIbD w==; X-IronPort-AV: E=McAfee;i="6600,9927,10742"; a="343833750" X-IronPort-AV: E=Sophos;i="6.00,246,1681196400"; d="scan'208";a="343833750" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Jun 2023 19:16:06 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10742"; a="1042909682" X-IronPort-AV: E=Sophos;i="6.00,246,1681196400"; d="scan'208";a="1042909682" Received: from allen-box.sh.intel.com (HELO [10.239.159.127]) ([10.239.159.127]) by fmsmga005.fm.intel.com with ESMTP; 15 Jun 2023 19:16:03 -0700 Message-ID: Date: Fri, 16 Jun 2023 10:14:53 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 Cc: baolu.lu@linux.intel.com, iommu@lists.linux.dev, linux-kernel@vger.kernel.org, Venkata Rao Kakani , Vagdhan Kumar Subject: Re: [PATCH] iommu: export iommu_set_default_translated function Content-Language: en-US To: Anvesh Jain P , Joerg Roedel , Will Deacon , Robin Murphy References: <20230615093308.24989-1-quic_ajainp@quicinc.com> From: Baolu Lu In-Reply-To: <20230615093308.24989-1-quic_ajainp@quicinc.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_MSPIKE_H2, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 6/15/23 5:33 PM, Anvesh Jain P wrote: > export iommu_set_default_translated function to be used by other modules. > > Signed-off-by: Anvesh Jain P > Signed-off-by: Venkata Rao Kakani > Signed-off-by: Vagdhan Kumar > --- > drivers/iommu/iommu.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/iommu/iommu.c b/drivers/iommu/iommu.c > index f1dcfa3f1a1b..1b4a5db58d66 100644 > --- a/drivers/iommu/iommu.c > +++ b/drivers/iommu/iommu.c > @@ -2730,6 +2730,7 @@ void iommu_set_default_translated(bool cmd_line) > iommu_cmd_line |= IOMMU_CMD_LINE_DMA_API; > iommu_def_domain_type = IOMMU_DOMAIN_DMA; > } > +EXPORT_SYMBOL_GPL(iommu_set_default_translated); Exporting a symbol without using it is meaningless. It is better to export and use it in a single series. Additionally, there is a restriction on the use of this helper. Calling it after the iommu probe has no effect. > > bool iommu_default_passthrough(void) > { > > base-commit: b6dad5178ceaf23f369c3711062ce1f2afc33644 Best regards, baolu