Commit 183f80fd authored by Sean Young's avatar Sean Young Committed by Shuah Khan

selftests/ir: fix build with ancient kernel headers

Since commit e2bcbd77 ("tools headers UAPI: remove stale lirc.h"),
the build of the selftests fails on rhel 8 since its version of
/usr/include/linux/lirc.h has no definition of RC_PROTO_RCMM32, etc [1].

[1] https://lkml.org/lkml/2022/1/28/275

Fixes: e2bcbd77 ("tools headers UAPI: remove stale lirc.h")
Reviewed-by: default avatarShuah Khan <skhan@linuxfoundation.org>
Reported-by: default avatarkernel test robot <oliver.sang@intel.com>
Signed-off-by: default avatarSean Young <sean@mess.org>
Signed-off-by: default avatarShuah Khan <skhan@linuxfoundation.org>
parent e2aa5e65
......@@ -29,6 +29,16 @@
#define SYSFS_PATH_MAX 256
#define DNAME_PATH_MAX 256
/*
* Support ancient lirc.h which does not have these values. Can be removed
* once RHEL 8 is no longer a relevant testing platform.
*/
#if RC_PROTO_MAX < 26
#define RC_PROTO_RCMM12 24
#define RC_PROTO_RCMM24 25
#define RC_PROTO_RCMM32 26
#endif
static const struct {
enum rc_proto proto;
const char *name;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment