[PATCH v7 11/11] iommu/arm-smmu-v3: Add KUnit unit tests for Runtime PM

Pranjal Shrivastava praan at google.com
Thu May 28 16:33:42 PDT 2026


On Thu, May 28, 2026 at 04:21:08PM -0700, Nicolin Chen wrote:
> On Thu, May 28, 2026 at 11:10:50PM +0000, Pranjal Shrivastava wrote:
> > On Thu, May 28, 2026 at 02:43:57PM -0700, Nicolin Chen wrote:
> > > On Wed, May 27, 2026 at 10:14:07PM +0000, Pranjal Shrivastava wrote:
> > > > Introduce a kunit selftests to verify the Runtime PM elision gating,
> > > > post-suspend elisions and progress on resumption under active
> > > > invalidation load. Simulate concurrent HW suspension using a timer.
> > > > Mock all HW registers and CMDQ buffers by allocating them on RAM.
> > > > Make the mock CMDQ self-consuming to avoid hitting queue_full scenarios.
> > > > 
> > > > Signed-off-by: Pranjal Shrivastava <praan at google.com>
> > > 
> > > Maybe I am wrong, yet this reads like an entirely AI-generated code.
> > > So, should it have an Assisted-by?
> > > 
> > 
> > Agh, It appears I made an error during the final send and mistakenly
> > posted an old WIP version of this patch! I created a patch file before
> > committing the final changes. This has remnants of older experiments and 
> > lacks severals other cleanups!
> > 
> > I'm aware of the AI usage guidelines. However, this is not an entirely AI
> > generated patch, it's a pre-cleanup snapshot of a WIP version where I had
> > multiple rpm tests (an attempt to use kthreads to simulate races) that
> > were using shared functions like the mock_cmdq etc. remnants of which 
> > are seen in this patch. *FACEPALM*.
> 
> It'd be still very nice to have a KUNIT coverage.

Yes, I plan to add a few RPM tests to the KUNIT. 

This however was a WIP version that went into the v7 patches *before* I 
commited the final version of this. Basically git format-patch *before*
committing the final version..

Thanks,
Praan



More information about the linux-arm-kernel mailing list