def METHOD_NAME(symbol):
    @panda.METHOD_NAME(symbol[0],symbol[1])
    def do_generic_hook(cpu, tb, h):
        global program_name, prevcall, prevtype
        if program_name not in panda.get_process_name(cpu):
            h.enabled = False
            return
        args = symbol[2]
        prevcall = f"[bold yellow]{symbol[1]}[/bold yellow]("
        for i in range(len(args)):
            if i > 0:
                prevcall += ","
            arg_val = panda.arch.get_arg(cpu, i)
            if args[i] == "char*":
                arg_string = try_read_str(cpu, arg_val)
                prevcall += f'{arg_string}'
            elif args[i] == "ptr":
                prevcall += f"0x{arg_val:x}"
            elif args[i] == "int":
                prevcall += f"{arg_val:d}"
        prevcall += ")"
        prevtype = symbol[3]
        ra = panda.arch.get_return_address(cpu)
        if ra != 0:
            panda.hook(ra,enabled=True,kernel=False,asid=panda.current_asid(cpu))(generic_hook_return)