Skip to content

Commit 479b1f8

Browse files
rfvirgilbroonie
authored andcommitted
firmware: cs_dsp: Add test cases for client_ops == NULL
Add test cases for the client not providing a pointer to a struct cs_dsp_client_ops. This proves that it is safe for the client to leave the client_ops pointer at NULL if it does not need to implement any of the callbacks. Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Link: https://patch.msgid.link/20251128102132.1575177-3-rf@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent af37511 commit 479b1f8

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

drivers/firmware/cirrus/test/cs_dsp_test_callbacks.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -600,6 +600,7 @@ KUNIT_ARRAY_PARAM(cs_dsp_callbacks_ops,
600600

601601
static const struct cs_dsp_callbacks_test_param cs_dsp_no_callbacks_cases[] = {
602602
{ .ops = &cs_dsp_callback_test_empty_client_ops, .case_name = "empty ops" },
603+
{ .ops = NULL, .case_name = "NULL ops" },
603604
};
604605

605606
KUNIT_ARRAY_PARAM(cs_dsp_no_callbacks,

0 commit comments

Comments
 (0)