Hi. Thank you for your question and reaching out. I’d be more than happy to help you with your query.
The error "ApiValidation: Error: XXX.sys has unsupported API call to 'ntoskrnl.exe!KeGetCurrentIrql'" in the Windows Hardware Lab Kit (HLK) environment means that your system driver is making a call to an unsupported API in the Windows operating system. The API in question, "KeGetCurrentIrql", is a kernel-mode API that retrieves the current IRQL (Interrupt Request Level) of the system.
To resolve this issue, you need to change your driver code to use a supported API or find an alternative solution that doesn't involve the unsupported API. You can check the Windows Driver Kit (WDK) documentation for a list of supported APIs and their usage.
If you believe that the API in question is necessary for your driver's functionality and should be supported, you can provide feedback to Microsoft through the Windows Feedback Hub or through the Windows Insider Program.
Note: Using unsupported APIs in your driver can cause stability and compatibility issues, and may prevent your driver from passing the HLK tests and being certified for use in Windows 10.
If the reply was helpful, please don’t forget to upvote or accept as answer, thank you.