From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 36B8DC47257 for ; Fri, 1 May 2020 18:40:30 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id C383E21835 for ; Fri, 1 May 2020 18:40:29 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="i4V/eLGR" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org C383E21835 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 3681E8E0005; Fri, 1 May 2020 14:40:29 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 317658E0001; Fri, 1 May 2020 14:40:29 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 22D1D8E0005; Fri, 1 May 2020 14:40:29 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0212.hostedemail.com [216.40.44.212]) by kanga.kvack.org (Postfix) with ESMTP id 0AD4C8E0001 for ; Fri, 1 May 2020 14:40:29 -0400 (EDT) Received: from smtpin29.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id BF975180AD804 for ; Fri, 1 May 2020 18:40:28 +0000 (UTC) X-FDA: 76769015736.29.mass22_3e59fad7aca43 X-HE-Tag: mass22_3e59fad7aca43 X-Filterd-Recvd-Size: 6273 Received: from mail-ot1-f65.google.com (mail-ot1-f65.google.com [209.85.210.65]) by imf30.hostedemail.com (Postfix) with ESMTP for ; Fri, 1 May 2020 18:40:28 +0000 (UTC) Received: by mail-ot1-f65.google.com with SMTP id g14so3255997otg.10 for ; Fri, 01 May 2020 11:40:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=K/pyc9ZSgvlCPxWaLAF7Dj+DR/uYkULUKmz0lI2apjM=; b=i4V/eLGRRDB/t5gS34y6x6FmiullhpKMPXQe+E4ih2swc8cRlFluseSUU+ZBlGBsVx 61I7Slgf9kEu2+57x9aRxp2pbshiXeln7PzqLgZ8StlqgrETFcszmRQc2uLXVEMteQ6K WsYkV5FgsGL/gaiLMtLVGEpi+XxrbCiGTar5uBAafBCi4QpOfA9Ni7juUOMrqIhbSw7o dZS3eNr/bYB9rwBwJ2jIOGXujjaVcW3kUbQSmah72Fi3rxxcPKtEKdeb09cydPN0RUkH fI/cGT05sjeH8Cg+EjNafozZoyY1nh057jxvYMba1UKDryTI5OjZu/ptlgnjY6feBp+0 805A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=K/pyc9ZSgvlCPxWaLAF7Dj+DR/uYkULUKmz0lI2apjM=; b=AHcY9tDJqqUcl+9QnOJycJy+TV11s/hAiVaKA7Ke+XFCU1iU4bTrnUBxQTi47AIuv8 RtUWNp54R4pOJHumKpeUClKVAoVkwg0MB7C+eXqtrku/FEtDNYmuXhJ3b/jewdsqekAo 6LepT48MUjaLVmsRPA27uv89b4Q1RQy0w82PyavCgIiRc9qdEdvmWBjAXhjKkDQYfrOh U0Lcl9kVwwgkZOyon+mk2qcZKT+utxjoB2XK129FDUIkLEFFU7ydYiyUKHyE9vjYRcai 8r+fNmWrOeQbjnUpg5jYd0Pa7XRe2Rtx1z+tC3ApFKUjH63KgOBLYdlXT8XCXtEk++ad k/YQ== X-Gm-Message-State: AGi0PubFWZMEt33ZlCn308O6Flgax5cGB1aEAd2igpRstZWkxkm2tRmG 7lVT7/QliARZE+MYP5e8SJYycixpcRI8onrBcECEuA== X-Google-Smtp-Source: APiQypL4ruHab7XImHLBHWXSGsuiDyI+02igUD+AFcOYMG/0olXknNi2MzN7TA4/gZzBZl34o0E6oBDOCG/6nNaBtVo= X-Received: by 2002:a05:6830:1589:: with SMTP id i9mr4941206otr.102.1588358427674; Fri, 01 May 2020 11:40:27 -0700 (PDT) MIME-Version: 1.0 References: <20200501073949.120396-1-john.stultz@linaro.org> <20200501073949.120396-2-john.stultz@linaro.org> <20200501104216.4f226c2a7bzval5o@DESKTOP-E1NTVVP.localdomain> In-Reply-To: <20200501104216.4f226c2a7bzval5o@DESKTOP-E1NTVVP.localdomain> From: John Stultz Date: Fri, 1 May 2020 11:40:16 -0700 Message-ID: Subject: Re: [RFC][PATCH 1/4] devicetree: bindings: Add linux,cma-heap tag for reserved memory To: Brian Starkey Cc: lkml , Rob Herring , Sumit Semwal , "Andrew F. Davis" , Benjamin Gaignard , Liam Mark , Pratik Patel , Laura Abbott , Chenbo Feng , Alistair Strachan , Sandeep Patil , Hridya Valsaraju , Christoph Hellwig , Marek Szyprowski , Robin Murphy , Andrew Morton , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , dri-devel , linux-mm , nd Content-Type: text/plain; charset="UTF-8" X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Fri, May 1, 2020 at 3:42 AM Brian Starkey wrote: > > Hi, > > On Fri, May 01, 2020 at 07:39:46AM +0000, John Stultz wrote: > > This patch adds a linux,cma-heap property for CMA reserved memory > > regions, which will be used to allow the region to be exposed via > > the DMA-BUF Heaps interface > > > > Cc: Rob Herring > > Cc: Sumit Semwal > > Cc: "Andrew F. Davis" > > Cc: Benjamin Gaignard > > Cc: Liam Mark > > Cc: Pratik Patel > > Cc: Laura Abbott > > Cc: Brian Starkey > > Cc: Chenbo Feng > > Cc: Alistair Strachan > > Cc: Sandeep Patil > > Cc: Hridya Valsaraju > > Cc: Christoph Hellwig > > Cc: Marek Szyprowski > > Cc: Robin Murphy > > Cc: Andrew Morton > > Cc: devicetree@vger.kernel.org > > Cc: dri-devel@lists.freedesktop.org > > Cc: linux-mm@kvack.org > > Signed-off-by: John Stultz > > --- > > .../devicetree/bindings/reserved-memory/reserved-memory.txt | 3 +++ > > 1 file changed, 3 insertions(+) > > > > diff --git a/Documentation/devicetree/bindings/reserved-memory/reserved-memory.txt b/Documentation/devicetree/bindings/reserved-memory/reserved-memory.txt > > index bac4afa3b197..e97b6a4c3bc0 100644 > > --- a/Documentation/devicetree/bindings/reserved-memory/reserved-memory.txt > > +++ b/Documentation/devicetree/bindings/reserved-memory/reserved-memory.txt > > @@ -68,6 +68,9 @@ Linux implementation note: > > - If a "linux,cma-default" property is present, then Linux will use the > > region for the default pool of the contiguous memory allocator. > > > > +- If a "linux,cma-heap" property is present, then Linux will expose the > > + the CMA region via the DMA-BUF Heaps interface. > > + > > Would it be useful or even possible to give some indication of what > the heap will end up being called? I'm afraid I don't remember what if > any conclusions came out of previous discussions on UAPI for heap > enumeration. So the name we expose is the CMA name itself. So with dt it will be the name of the reserved memory node that the flag property is added to. > I suppose CMA names haven't been relevant to userspace before, but > they perhaps would be with this change. > > Alternatively, leaving it effectively undefined doesn't tie us down, > and something like links in sysfs can be added as a richer API in the > future. Hrm. Mind expanding on what you're thinking here? thanks -john