On Tue, Nov 15, 2022 at 05:46:28PM +0200, Jani Nikula wrote:
> On Mon, 14 Nov 2022, Andy Shevchenko
> wrote:
> > Some of the existing users, and definitely will be new ones, want to
> > count existing nodes in the list. Provide a generic API for that by
> > moving code from i915 to list.h.
>
>
On Mon, 14 Nov 2022, Andy Shevchenko wrote:
> Some of the existing users, and definitely will be new ones, want to
> count existing nodes in the list. Provide a generic API for that by
> moving code from i915 to list.h.
I think I'd find list_length() a much more natural name for this.
*shrug*
On Mon, Nov 14, 2022 at 06:11:51PM +, Ruhl, Michael J wrote:
...
> So all of the non-list_for_each code appears to be an inline.
This is not true.
> This which, resembles the non-list_for_each pattern is a macro?
>
> Just curious as to why the macro rather than inline?
See above.
inux-ker...@vger.kernel.org; linux-
>u...@vger.kernel.org
>Cc: Tvrtko Ursulin ; Kevin Cernekee
>; Nyman, Mathias ; Vivi,
>Rodrigo ; Andrew Morton foundation.org>
>Subject: [PATCH v2 1/4] i915: Move list_count() to list.h for broader use
>
>Some of the existing users, and definit
Some of the existing users, and definitely will be new ones, want to
count existing nodes in the list. Provide a generic API for that by
moving code from i915 to list.h.
Signed-off-by: Andy Shevchenko
---
v2: dropped the duplicate code in i915 (LKP)
drivers/gpu/drm/i915/gt/intel_engine_cs.c |