From patchwork Mon Feb 22 20:54:30 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ard Biesheuvel X-Patchwork-Id: 62633 Delivered-To: patch@linaro.org Received: by 10.112.43.199 with SMTP id y7csp1472513lbl; Mon, 22 Feb 2016 13:00:44 -0800 (PST) X-Received: by 10.98.14.149 with SMTP id 21mr40967863pfo.79.1456174844839; Mon, 22 Feb 2016 13:00:44 -0800 (PST) Return-Path: Received: from bombadil.infradead.org (bombadil.infradead.org. [2001:1868:205::9]) by mx.google.com with ESMTPS id q5si41969370pap.42.2016.02.22.13.00.44 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 22 Feb 2016 13:00:44 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 2001:1868:205::9 as permitted sender) client-ip=2001:1868:205::9; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 2001:1868:205::9 as permitted sender) smtp.mailfrom=linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org; dkim=neutral (body hash did not verify) header.i=@linaro.org Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1aXxa3-0007n5-TM; Mon, 22 Feb 2016 20:59:43 +0000 Received: from mail-wm0-x22b.google.com ([2a00:1450:400c:c09::22b]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1aXxWF-0004c9-4J for linux-arm-kernel@lists.infradead.org; Mon, 22 Feb 2016 20:55:49 +0000 Received: by mail-wm0-x22b.google.com with SMTP id g62so174275241wme.0 for ; Mon, 22 Feb 2016 12:55:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=2VaykVIEGN34lnQ6/ccktFcdQz2NnW7X1P3l+H1Ar7g=; b=RCtT6MG7qwbVpOT1YTztp9gNxrNtxcfby6ZNyiZhaMkmp3B3jH6rbYrkt3dpxLQzWm KpjBUoPCmm0wh4fDtYInHnQ5RolmsePDd41eSnlvjZrvtJNdEaxl0FMSkWDWecLJJoip XL5Bw3BAaLEuxQ97jM4qZluOQ87z9clGHR1xQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=2VaykVIEGN34lnQ6/ccktFcdQz2NnW7X1P3l+H1Ar7g=; b=MzZ8m+pJGkvPQhrpug5ZK5OY9xRbJX9zewCcc7q+xZQIzPsypvfT/G3/R+R0QGFBSo yavtbCv4n4AcUFnNqu5cN6+40savkmfxoN16yMxY3HE7n+lR9RiybqKgKVS7291rut1m hFi1aAPlmr/ubjER7lW2E5phvVpiTUy40UHwIzyGTB4y1XnHCLIJul/LWeTOTqG6Vfe3 cr6e44KCAXaQCekAy6bJZg9qhenEiLlg5m2+t0t8NdTqdc1OM+qPgot9XM6Jrb1I/dUu l85dHRjM5WpJcd896dAyhp8pgO5RNGK6mbCv/S+AZ8yu1d/xLGVSlPzoKRksAszzIJaH lmPg== X-Gm-Message-State: AG10YOQRIMkjR2ttV/RubVBtDovcuqCipsdsqZQKWBJG/Q/0sPkvAyqMsN9aQ6DcgwVfir7p X-Received: by 10.28.21.21 with SMTP id 21mr13681429wmv.38.1456174525901; Mon, 22 Feb 2016 12:55:25 -0800 (PST) Received: from localhost.localdomain ([195.55.142.58]) by smtp.gmail.com with ESMTPSA id k8sm15012530wjr.38.2016.02.22.12.55.22 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 22 Feb 2016 12:55:25 -0800 (PST) From: Ard Biesheuvel To: linux-arm-kernel@lists.infradead.org, will.deacon@arm.com, catalin.marinas@arm.com, mark.rutland@arm.com Subject: [RFC PATCH 08/10] arm64: vdso: avoid __pa translations Date: Mon, 22 Feb 2016 21:54:30 +0100 Message-Id: <1456174472-30028-9-git-send-email-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.5.0 In-Reply-To: <1456174472-30028-1-git-send-email-ard.biesheuvel@linaro.org> References: <1456174472-30028-1-git-send-email-ard.biesheuvel@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20160222_125547_746246_DE5CA26C X-CRM114-Status: GOOD ( 12.45 ) X-Spam-Score: -2.7 (--) X-Spam-Report: SpamAssassin version 3.4.0 on bombadil.infradead.org summary: Content analysis details: (-2.7 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [2a00:1450:400c:c09:0:0:0:22b listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Ard Biesheuvel MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org Use __pa_symbol() not __pa() when taking the physical address of the VDSO symbols that are part of the kernel text. Signed-off-by: Ard Biesheuvel --- arch/arm64/kernel/vdso.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) -- 2.5.0 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel diff --git a/arch/arm64/kernel/vdso.c b/arch/arm64/kernel/vdso.c index 97bc68f4c689..065756b358b4 100644 --- a/arch/arm64/kernel/vdso.c +++ b/arch/arm64/kernel/vdso.c @@ -131,11 +131,12 @@ static int __init vdso_init(void) return -ENOMEM; /* Grab the vDSO data page. */ - vdso_pagelist[0] = virt_to_page(vdso_data); + vdso_pagelist[0] = phys_to_page(__pa_symbol(vdso_data)); /* Grab the vDSO code pages. */ for (i = 0; i < vdso_pages; i++) - vdso_pagelist[i + 1] = virt_to_page(&vdso_start + i * PAGE_SIZE); + vdso_pagelist[i + 1] = phys_to_page(__pa_symbol(&vdso_start) + + i * PAGE_SIZE); /* Populate the special mapping structures */ vdso_spec[0] = (struct vm_special_mapping) {