def METHOD_NAME(self):
    optprobes_file = "/proc/sys/debug/kprobes-optimization"
    if not self.check_kernel_support():
        self.log.info("No support available for optprobes, skipping optprobes test")
        return
    if not os.path.exists(optprobes_file):
        self.log.info("optprobes control file %s missing, skipping optprobes test",
                      optprobes_file)
        return
    cur_val = genio.read_one_line(optprobes_file)
    genio.write_one_line(optprobes_file, "0")
    self.log.info("================= Disabling optprobes ==================")
    if "0" not in genio.read_one_line(optprobes_file):
        self.fail("Not able to disable optprobes")
    self.execute_test()
    self.log.info("================= Restoring optprobes ==================")
    genio.write_one_line(optprobes_file, cur_val)
    if cur_val not in genio.read_one_line(optprobes_file):
        self.fail("Not able to restore optprobes to %s", cur_val)