From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Boyd Subject: Re: [PATCH v9 02/18] kunit: test: add test resource management API Date: Mon, 15 Jul 2019 13:51:00 -0700 Message-ID: <20190715205101.AB55B2145D@mail.kernel.org> References: <20190712081744.87097-1-brendanhiggins@google.com> <20190712081744.87097-3-brendanhiggins@google.com> <20190715202425.CE64C20665@mail.kernel.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: Brendan Higgins Cc: Frank Rowand , Greg KH , Josh Poimboeuf , Kees Cook , Kieran Bingham , Luis Chamberlain , Peter Zijlstra , Rob Herring , shuah , Theodore Ts'o , Masahiro Yamada , devicetree , dri-devel , kunit-dev@googlegroups.com, "open list:DOCUMENTATION" , linux-fsdevel@vger.kernel.org, linux-kbuild , Linux Kernel Mailing List , open list:KERNEL SELFTEST FRAMEWORK List-Id: dri-devel@lists.freedesktop.org Quoting Brendan Higgins (2019-07-15 13:30:22) > On Mon, Jul 15, 2019 at 1:24 PM Stephen Boyd wrote: > > > > Quoting Brendan Higgins (2019-07-12 01:17:28) > > > diff --git a/kunit/test.c b/kunit/test.c > > > index 571e4c65deb5c..f165c9d8e10b0 100644 >=20 > > One solution would be to piggyback on all the existing devres allocation > > logic we already have and make each struct kunit a device that we pass > > into the devres functions. A far simpler solution would be to just > > copy/paste what devres does and use a spinlock and an allocation > > function that takes GFP flags. >=20 > Yeah, that's what I did originally, but I thought from the discussion > on patch 01 that you thought a spinlock was overkill for struct kunit. > I take it you only meant in that initial patch? Correct. I was only talking about the success bit in there.