Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp467169imm; Wed, 26 Sep 2018 01:33:38 -0700 (PDT) X-Google-Smtp-Source: ACcGV60mBh1kowV1nR4Yv0cCqrlegbnJgnWkQ97rX+5s/4fohJzG4tnReA6E1stw7XbBPxWfLZT6 X-Received: by 2002:a17:902:4401:: with SMTP id k1-v6mr4811982pld.97.1537950817991; Wed, 26 Sep 2018 01:33:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537950817; cv=none; d=google.com; s=arc-20160816; b=CUWVeCeKy2qjxkxN4i12MIvwYSZc1pB1GtwNZxfEY5NHWeBvbdO0k+hAdZ6g8a8lGW XKkuLeVWwDdu1G1JmnhzM6PkvjWrFustwKmMP3aeioJjfD5tLxrhS+yTfKBp/GVmRjoq PkAvYB96PVSN676rIP6Cs0Bwp/vObGlll2T50jw6vfztkvBQvMfybkLvFOkN81Q8O3JJ 6LR5N6tjMbE5nKpGrf1YcoKNGueHHMNq3TUl2x9LsE699/LlmhZE62hDqzz7Oamp5w00 bbHctByqbZbFHH41c18a70EHhU1NJfI+zuD7MPcRow4Fh1mDLEBdFc1ERPaxThQ5Hc8F ZsxA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=xILCKLGDFjBBorarrUyjhtvIupooeyobvhfedOgKiyw=; b=KK2F4DYZGcbYmRGO1Gdd++tRTvEJOJOP/557kpAmWYJXnAw+d3mTw2ta6f6P9PwTI1 ygwZ9UwZfVtJhyDVggdsbcxMZMzWKsWKvIml2GVSL5sL226SqjjG+JxOWkzG8Cdn+VHo ewmudzPxsgNFflSGZzZMmM3air5PyvxgLKmLIs3GZdkNHUnhHuNl8zc/BTDhituYjICe 8D8DHPhnScZ++Hgg67q7y7KLYHhy1Cx0u7bL39lS+2B7STH8+18+nZyohv8IafRyS4je JviFvTA12fpSWTYYdqLIa6NLaglaRBe8m/e+uupAiaOIdux5Aqu5zEOH5xp/vRcCSGjC xqQw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=eKADOI2i; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w15-v6si4801224pgg.529.2018.09.26.01.33.22; Wed, 26 Sep 2018 01:33:37 -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=@gmail.com header.s=20161025 header.b=eKADOI2i; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727126AbeIZOot (ORCPT + 99 others); Wed, 26 Sep 2018 10:44:49 -0400 Received: from mail-pl1-f196.google.com ([209.85.214.196]:43776 "EHLO mail-pl1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726841AbeIZOot (ORCPT ); Wed, 26 Sep 2018 10:44:49 -0400 Received: by mail-pl1-f196.google.com with SMTP id 30-v6so2940598plb.10 for ; Wed, 26 Sep 2018 01:33:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=xILCKLGDFjBBorarrUyjhtvIupooeyobvhfedOgKiyw=; b=eKADOI2i6nQICaHFJh3wmyCW+X+ZHYMLQaRN3PDajAUf6fPpb0Mtm2d1gWZx19RkoJ DsXhnuLL7njhs9H2WZbPtggcWsDcTHKoh+T53trD+5yozNttKdhwxRcI16VlRz7cstzw iIfmtT2DGc7uIT07IGvmfePn1ntx8sy7DmlRG6EPRjKPz0Yk1A5cfUYrOFvHoUhTk5S7 0IC3lHPQxjP29QZocR95TNOhxwOt/4ZAB3uC6B6S8+NnYlMq4Bn5MEfvi8K2C7QbbeCM kiMSHZVRZAyS22nkzM8WyxEPhTw27NOvDYt1fhrxGzRdxPDMoubhcZmL7wwqp3QJYAqP d2DQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=xILCKLGDFjBBorarrUyjhtvIupooeyobvhfedOgKiyw=; b=s2LI5MU0wuQ3c76pE+xp8z/ve61/3iumgjIyerZw/iRGy6VcbWLlQJGj0fIwrEvVTk LrVRGbDxqA05tMk2pi24tw/30UVDPtmJeU9QBXGpzfOmtjMMYDmEIt2PdZm47h6jUh7v aohM+y7EXjNDAJXVbdGo6ZO8v5bW5Xgy5ThixD/utGA1p7cxEbPvpREqpeEwXjDTKyo0 4itpTJ3LclISQDNVV8/aj9PLE7bkuF/jZTU8fy7OOl//qrC8QOkWoRf/nNqLC156dKCz VxkJ9ELmxiaxs7v/LW2DINIyjf9Czg9/9reig3Egs81W45clQXXdzrIPbVP6jE8O8GM4 +xSQ== X-Gm-Message-State: ABuFfoiAeAI3/YOnElmZG51TZeFQkY87LoUtWiw4Ka+805VGhnINoyBZ GnXXNDsQpbHFHedeUJgRZac= X-Received: by 2002:a17:902:5e3:: with SMTP id f90-v6mr5088400plf.286.1537950781300; Wed, 26 Sep 2018 01:33:01 -0700 (PDT) Received: from app09.andestech.com ([118.163.51.199]) by smtp.gmail.com with ESMTPSA id f15-v6sm5530764pgv.66.2018.09.26.01.32.59 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 26 Sep 2018 01:33:00 -0700 (PDT) From: Zong Li To: palmer@sifive.com, aou@eecs.berkeley.edu Cc: hch@infradead.org, zong@andestech.com, vincentc@andestech.com, linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, Zong Li Subject: [PATCH v2 2/5] RISC-V: Use swiotlb on RV64 only Date: Wed, 26 Sep 2018 16:31:11 +0800 Message-Id: X-Mailer: git-send-email 2.18.0 In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Only RV64 supports swiotlb. Signed-off-by: Zong Li --- arch/riscv/kernel/setup.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/riscv/kernel/setup.c b/arch/riscv/kernel/setup.c index aee6031..872a280 100644 --- a/arch/riscv/kernel/setup.c +++ b/arch/riscv/kernel/setup.c @@ -227,7 +227,10 @@ void __init setup_arch(char **cmdline_p) setup_bootmem(); paging_init(); unflatten_device_tree(); + +#ifdef CONFIG_64bit swiotlb_init(1); +#endif #ifdef CONFIG_SMP setup_smp(); -- 2.7.4