From patchwork Fri Feb 15 20:24:08 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: kernel test robot via dri-devel X-Patchwork-Id: 10816713 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id DFFDE922 for ; Sat, 16 Feb 2019 20:15:57 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id CF0D22AB7E for ; Sat, 16 Feb 2019 20:15:57 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id C32AC2AE96; Sat, 16 Feb 2019 20:15:57 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 7E1842AB7E for ; Sat, 16 Feb 2019 20:15:57 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 676506ED21; Sat, 16 Feb 2019 20:12:30 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-pf1-x444.google.com (mail-pf1-x444.google.com [IPv6:2607:f8b0:4864:20::444]) by gabe.freedesktop.org (Postfix) with ESMTPS id 07AE16E100 for ; Fri, 15 Feb 2019 20:24:16 +0000 (UTC) Received: by mail-pf1-x444.google.com with SMTP id u6so5334321pfh.11 for ; Fri, 15 Feb 2019 12:24:16 -0800 (PST) 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; bh=LamQ54kVZjG48WaTIUkT/9kd7y0axdOv0sLcyu9DjBY=; b=Az+8Ep493sgv5x/u99dEzkoI7zYZV3Ex8XyciC4ruxo0UkqoOPv/jedOux4pnNRBIg uCBfuk1aSp/9z1W7aasg732Bt1i+EMQXEjd5XlommleT/m1d9v2SIl3riIE2+T2hcyZ9 HOX05X5b2XeT1ZdC7H0t/BZCzKorZTpXafDaAlNCRRW/BalEdms+oc++tdTUVPf5jLNb Z+BuK57M18NJ8mT0a4CQ7/IPotgdgQiMQhqqzAPQN6BdH3IFRiINc8Hdqso5XG3Myy+b c0p3d1HolmNOgkgFXcijzQv4O78lFQE4N/jrgPA+moEq9K3rVKxHH7cacfbB9ovSeNS0 PxXA== X-Gm-Message-State: AHQUAubhSj1TKlpLkAimz20L1f1MuyTVss18ivA8RZa9TLMHQpixEfLD cAM6Vy4y4hqnhZqQzLPhq7/bTw== X-Google-Smtp-Source: AHgI3IbnFNCcHtUKgvTxktlLqhWeAB1xUeuLL8/eT0bp0nFttVK0GO40cIUWedWzKNsdVcSXs88Z/w== X-Received: by 2002:a63:5462:: with SMTP id e34mr6522672pgm.97.1550262255412; Fri, 15 Feb 2019 12:24:15 -0800 (PST) Received: from localhost.localdomain ([2601:1c2:680:1319:4e72:b9ff:fe99:466a]) by smtp.gmail.com with ESMTPSA id l2sm7593340pgn.52.2019.02.15.12.24.14 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 15 Feb 2019 12:24:14 -0800 (PST) To: Laura Abbott Subject: [EARLY RFC][PATCH 0/4] ION per heap devices Date: Fri, 15 Feb 2019 12:24:08 -0800 Message-Id: <1550262252-15558-1-git-send-email-john.stultz@linaro.org> X-Mailer: git-send-email 2.7.4 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=LamQ54kVZjG48WaTIUkT/9kd7y0axdOv0sLcyu9DjBY=; b=yliwTcWnjTtwiuoABaiwKz5nqztV1ntGGYr7LSaZlbez+7P1axEWd0afoolC81BUKN f6Zx8Ye94Qoe0x3zkjsiE7eOYSgwBLP95lMAyf9LWiFMBfbN7LWF20EHY8+jK+IuqVKO RbmkBaftIXuKDnDmnynIOpZmT/ls6YTz6EN9nuDTJwT0olYfHGFQZdHejWdz6ijPersq w0QWSU6KByNAQbwVZRWbZe4ZfekjHBxGiLMCQepvwU/2hVi8WrRa0wQJyNbLUMg9Dfij vwLb10g+QAXfiOuXF16FRbJK9eReAplLKMtZQG03pPMcEDWpAaGKKrJK0aYjqZhjBnw5 W4Pg== X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: John Stultz via dri-devel From: kernel test robot via dri-devel Reply-To: John Stultz Cc: Alistair Strachan , Liam Mark , "Andrew F . Davis" , dri-devel@lists.freedesktop.org MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP This is a *very early RFC* (it builds, that's all I'll say :) but I wanted to share it to get some initial feedback before I go down the rabit hole of trying to adapt the Android userland code to get this fully validated. This patchset tries to implement the per-heap devices for ION. The main benefit is that it avoids multiplexing heap operations through the /dev/ion interface, and allows for each heap to have its own permissions/sepolicy rules. Feedback would be greatly appreciated! thanks -john Cc: Laura Abbott Cc: Sumit Semwal Cc: Liam Mark Cc: Brian Starkey Cc: Andrew F. Davis Cc: Alistair Strachan Cc: dri-devel@lists.freedesktop.org John Stultz (4): ion: Add ION_VERSION ioctl ion: Initial hack to create per heap devices ion: Add HEAP_INFO ioctl to be able to fetch heap type ion: Make "legacy" /dev/ion support optional drivers/staging/android/ion/Kconfig | 7 +++ drivers/staging/android/ion/ion-ioctl.c | 80 +++++++++++++++++++++++++++++++++ drivers/staging/android/ion/ion.c | 51 ++++++++++++++++----- drivers/staging/android/ion/ion.h | 6 +++ drivers/staging/android/uapi/ion.h | 57 +++++++++++++++++++++++ 5 files changed, 191 insertions(+), 10 deletions(-)