diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 1b47256ea3d629ca56fbc92a80bf19b2fd48cd76..f761dccbf10b5b458d09a52ba08fa41bfc476103 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2007-03-16  Richard Sandiford  <richard@codesourcery.com>
+
+	* gcc.dg/intmax_t-1.c: Restrict XFAIL to VxWorks kernels;
+	exclude RTPs.
+
 2007-03-16  Richard Guenther  <rguenther@suse.de>
 
 	PR tree-optimization/31146
diff --git a/gcc/testsuite/gcc.dg/intmax_t-1.c b/gcc/testsuite/gcc.dg/intmax_t-1.c
index 8357aa961db49779adb90f2eade9459d750de0db..65bca7698297467c3251b45935f4a695c24134f4 100644
--- a/gcc/testsuite/gcc.dg/intmax_t-1.c
+++ b/gcc/testsuite/gcc.dg/intmax_t-1.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-Wall" } */
-/* { dg-error "" "" { target *-*-solaris2.5.1 *arm*-*-*elf* xscale*-*-elf* xtensa-*-elf* *-*-vxworks* } 0 } */
+/* { dg-error "" "" { target { { *-*-solaris2.5.1 *arm*-*-*elf* xscale*-*-elf* xtensa-*-elf* } || vxworks_kernel } } 0 } */
 
 /* Compile with -Wall to get a warning if built-in and system intmax_t don't
    match.  */