From mboxrd@z Thu Jan 1 00:00:00 1970 From: John Stultz Subject: Re: [RFC][PATCH 4/5 v2] dma-buf: heaps: Add CMA heap to dmabuf heapss Date: Thu, 21 Mar 2019 13:15:52 -0700 Message-ID: References: <1551819273-640-1-git-send-email-john.stultz@linaro.org> <1551819273-640-5-git-send-email-john.stultz@linaro.org> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Return-path: In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org To: Benjamin Gaignard Cc: lkml , Laura Abbott , Greg KH , Sumit Semwal , Liam Mark , Brian Starkey , "Andrew F . Davis" , Chenbo Feng , Alistair Strachan , ML dri-devel List-Id: dri-devel@lists.freedesktop.org On Wed, Mar 6, 2019 at 8:05 AM Benjamin Gaignard wrote: > Le mar. 5 mars 2019 =C3=A0 21:54, John Stultz a = =C3=A9crit : > > +#define to_cma_heap(x) container_of(x, struct cma_heap, heap) > > Even if I had write this macro years ago, now I would prefer to have a > static inline function > to be able to check the types. > > with that: > Reviewed-by: Benjamin Gaignard Thanks for the suggestion! I've reworked that and the other container_of macro I had in the patch series to be inline functions. thanks again! -john