summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tests/kms_content_protection.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/kms_content_protection.c b/tests/kms_content_protection.c
index a0a136da..bab61817 100644
--- a/tests/kms_content_protection.c
+++ b/tests/kms_content_protection.c
@@ -296,6 +296,8 @@ static bool write_srm_as_fw(const __u8 *srm, int len)
fd = open("/lib/firmware/display_hdcp_srm.bin",
O_WRONLY | O_CREAT, S_IRWXU);
+ igt_require_f(fd >= 0, "Cannot write SRM binary to /lib/firmware\n");
+
do {
ret = write(fd, srm + total, len - total);
if (ret < 0)