gdb, btrace: fix wrong #endif comments

Message ID 20260504071636.1571615-1-markus.t.metzger@intel.com
State New
Headers
Series gdb, btrace: fix wrong #endif comments |

Commit Message

Metzger, Markus T May 4, 2026, 7:16 a.m. UTC
  ---
 gdb/btrace.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
  

Comments

Simon Marchi May 4, 2026, 2:44 p.m. UTC | #1
On 5/4/26 3:16 AM, Markus Metzger wrote:
> ---
>  gdb/btrace.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/gdb/btrace.c b/gdb/btrace.c
> index f9c6f0e5b6a..ef152c531fb 100644
> --- a/gdb/btrace.c
> +++ b/gdb/btrace.c
> @@ -1283,7 +1283,7 @@ decode_interrupt_vector (const uint8_t vector)
>  
>    return nullptr;
>  }
> -#endif /* defined (LIBIPT_VERSION >= 0x201) */
> +#endif /* (LIBIPT_VERSION >= 0x201) */
>  
>  /* Handle instruction decode events (libipt-v2).  */
>  
> @@ -1596,7 +1596,7 @@ handle_pt_insn_events (struct btrace_thread_info *btinfo,
>  	    handle_pt_aux_insn (btinfo, aux_string, pc);
>  	    break;
>  	  }
> -#endif /* defined (LIBIPT_VERSION >= 0x201) */
> +#endif /* (LIBIPT_VERSION >= 0x201) */
>  
>  #if (LIBIPT_VERSION >= 0x202)
>  	case ptev_trig:
> @@ -3064,7 +3064,7 @@ pt_print_packet (const struct pt_packet *packet)
>  		  packet->payload.ptw.payload,
>  		  packet->payload.ptw.ip ? (" ip") : (""));
>        break;
> -#endif /* defined (LIBIPT_VERSION >= 0x200)  */
> +#endif /* (LIBIPT_VERSION >= 0x200)  */
>  
>  #if (LIBIPT_VERSION >= 0x201)
>      case ppt_cfe:
> @@ -3077,7 +3077,7 @@ pt_print_packet (const struct pt_packet *packet)
>        gdb_printf (("evd %u: 0x%" PRIx64 ""), packet->payload.evd.type,
>  		  packet->payload.evd.payload);
>        break;
> -#endif /* defined (LIBIPT_VERSION >= 0x201)  */
> +#endif /* (LIBIPT_VERSION >= 0x201)  */
>      }
>  }
>  
> -- 
> 2.34.1
> 
> Intel Deutschland GmbH
> Registered Address: Dornacher Strasse 1, 85622 Feldkirchen, Germany
> Tel: +49 89 991 430, www.intel.de
> Managing Directors: Harry Demas, Jeffrey Schneiderman, Yin Chong Sorrell
> Chairperson of the Supervisory Board: Nicole Lau
> Registered Seat: Munich
> Commercial Register: Amtsgericht Muenchen HRB 186928
> 

Approved-By: Simon Marchi <simon.marchi@efficios.com>

(even though you don't need an approval for this because you're the
maintainer, and I would consider this obvious anyway)

Simon
  

Patch

diff --git a/gdb/btrace.c b/gdb/btrace.c
index f9c6f0e5b6a..ef152c531fb 100644
--- a/gdb/btrace.c
+++ b/gdb/btrace.c
@@ -1283,7 +1283,7 @@  decode_interrupt_vector (const uint8_t vector)
 
   return nullptr;
 }
-#endif /* defined (LIBIPT_VERSION >= 0x201) */
+#endif /* (LIBIPT_VERSION >= 0x201) */
 
 /* Handle instruction decode events (libipt-v2).  */
 
@@ -1596,7 +1596,7 @@  handle_pt_insn_events (struct btrace_thread_info *btinfo,
 	    handle_pt_aux_insn (btinfo, aux_string, pc);
 	    break;
 	  }
-#endif /* defined (LIBIPT_VERSION >= 0x201) */
+#endif /* (LIBIPT_VERSION >= 0x201) */
 
 #if (LIBIPT_VERSION >= 0x202)
 	case ptev_trig:
@@ -3064,7 +3064,7 @@  pt_print_packet (const struct pt_packet *packet)
 		  packet->payload.ptw.payload,
 		  packet->payload.ptw.ip ? (" ip") : (""));
       break;
-#endif /* defined (LIBIPT_VERSION >= 0x200)  */
+#endif /* (LIBIPT_VERSION >= 0x200)  */
 
 #if (LIBIPT_VERSION >= 0x201)
     case ppt_cfe:
@@ -3077,7 +3077,7 @@  pt_print_packet (const struct pt_packet *packet)
       gdb_printf (("evd %u: 0x%" PRIx64 ""), packet->payload.evd.type,
 		  packet->payload.evd.payload);
       break;
-#endif /* defined (LIBIPT_VERSION >= 0x201)  */
+#endif /* (LIBIPT_VERSION >= 0x201)  */
     }
 }