Whenever I am changing any setting or when I woke my PC from sleep mode than the keyboard and mouse are not working properly

Maybe you can check this thread.
The last post seems to have solved, although, if not working, I definitely think you should apply the steps at post #10.