Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp1257117imm; Tue, 5 Jun 2018 11:29:26 -0700 (PDT) X-Google-Smtp-Source: ADUXVKKOL9TZ7wCyKTf+C+nYDnr6vCUFr9noCh3Mre0+kN4GzjfxibCNIjO3F3AD5I1lGoFLYnlE X-Received: by 2002:a62:bca:: with SMTP id 71-v6mr21362465pfl.234.1528223366470; Tue, 05 Jun 2018 11:29:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1528223366; cv=none; d=google.com; s=arc-20160816; b=WOkyIoAWOT+wKyX8j/Y2tjAq375ETrpg8qaVabxrGV7C6oW39DErObAwo2FhtyasS5 8AY6QWN+exhfYDRLGedFZljrnZHpzSHXcCB3OU6414292hJzxPOb8pLJ4QtJLYJvxJY6 fblq4mr7ZV0f33OMsUo9QQjtW4Gvgko1keYzAtagR2K7xZC8YIH01kFiLRnFISlV3j/Z PcRKtsI8nkGWbXancRc7y/PIVujmNbg4OnKum2L2w2GSi5YN1pRIy4uF/jw+jL3lgmAS dNMM1FHavUHDOfS4ioSFIXxxNBCZeCU/XLFrj9MAKRQnuLRVDU1BLKJIFi6+Di9lTH9n xrYA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:from:subject:cc:to:message-id:date :arc-authentication-results; bh=SaEK5IwGNFZkdMWA1ossC4oxxm9UgGFsoR1wpm4VtXY=; b=u1wI7DIfo25x+7nBY1fVZ1HPRczEKCJfqDsXbmWTrO2pZgs5CJICgBEiVpi03LTu4c iLpJ32CWYZt3UCdj4X5cb8wPdOUkJgqF94JXk9HB5H/bOiGy1NNkh0ZvfDBN7Le73LHX jwC8D40/lDa4Ogb2lu6ht+k819LR4DoGTLffTrWw2T5qVJzM1pZ/iix4hNGIwC/TX0U8 voWN2YDR097gmTk9zcDLhh2MPexc+ncsKlor8yH8BWZ2y4r+zEbbiczRM03ftcVU53r2 YO0ZJbq38dX80Ux/wC11Hg1alGz5fXC9paDj1p5qJ2rxJfgYQzPNL33CwpSc66qQNX6s G+jw== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z8-v6si16504639pgp.259.2018.06.05.11.29.11; Tue, 05 Jun 2018 11:29:26 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751836AbeFES2s (ORCPT + 99 others); Tue, 5 Jun 2018 14:28:48 -0400 Received: from shards.monkeyblade.net ([184.105.139.130]:40746 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751769AbeFES2q (ORCPT ); Tue, 5 Jun 2018 14:28:46 -0400 Received: from localhost (unknown [66.187.232.66]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) (Authenticated sender: davem-davemloft) by shards.monkeyblade.net (Postfix) with ESMTPSA id F33A910866C81; Tue, 5 Jun 2018 11:28:43 -0700 (PDT) Date: Tue, 05 Jun 2018 14:28:40 -0400 (EDT) Message-Id: <20180605.142840.2277897500494503602.davem@davemloft.net> To: tom.hromatka@oracle.com Cc: sparclinux@vger.kernel.org, arnd@arndb.de, gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org, shuah@kernel.org, linux-kselftest@vger.kernel.org, allen.pais@oracle.com, khalid.aziz@oracle.com, shannon.nelson@oracle.com, anthony.yznaga@oracle.com Subject: Re: [PATCH v6 0/2] sparc64: Add privileged ADI driver From: David Miller In-Reply-To: <20180426165409.716764-1-tom.hromatka@oracle.com> References: <20180426165409.716764-1-tom.hromatka@oracle.com> X-Mailer: Mew version 6.7 on Emacs 25.3 / Mule 6.0 (HANACHIRUSATO) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Tue, 05 Jun 2018 11:28:45 -0700 (PDT) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Tom Hromatka Date: Thu, 26 Apr 2018 10:54:07 -0600 > ADI is a feature supported on SPARC M7 and newer processors to allow > hardware to catch rogue accesses to memory. ADI is supported for data > fetches only and not instruction fetches. An app can enable ADI on its > data pages, set version tags on them and use versioned addresses to > access the data pages. Upper bits of the address contain the version > tag. On M7 processors, upper four bits (bits 63-60) contain the version > tag. If a rogue app attempts to access ADI enabled data pages, its > access is blocked and processor generates an exception. Please see > Documentation/sparc/adi.txt for further details. > > This patchset implements a char driver to read/write ADI versions from > privileged user space processes. Intended consumers are makedumpfile > and crash. Series applied, but there is one thing I am not happy with. The hard coded ADI block size. This value is at least theoretically dynamic, and that is why it is passed into userspace programs via the ELF AUX vector at exec() time. So they should really fetch it from there.