diff --git a/include/linux/kermit.h b/include/linux/kermit.h new file mode 100644 index 00000000000000..331760851a3c37 --- /dev/null +++ b/include/linux/kermit.h @@ -0,0 +1,18 @@ +/* SPDX-License-Identifier: GPL-2.0-or-later */ +/* + * kermit.h - KernMLOps Insertion Interface + * + * Copyright (C) 2025 Aditya Tewari + */ + +#ifndef _LINUX_KERMIT_H_ +#define _LINUX_KERMIT_H_ + +#define ML_REPLACE_FUNCTION(type, mlfunc, mlinvoke, normal_expression) ({\ + type r; \ + if (mlfunc) r = (mlinvoke); \ + else r = ({normal_expression}); \ + r; \ +}) + +#endif //_LINUX_KERMIT_H_