diff --git a/src/tools/fsync/test_fsync.c b/src/tools/fsync/test_fsync.c
index cd2b1f2..562da66 100644
*** /tmp/8wSNdd_test_fsync.c	Sat Jan 15 18:42:58 2011
--- src/tools/fsync/test_fsync.c	Sat Jan 15 18:38:57 2011
*************** void
*** 163,169 ****
  test_sync(int writes_per_op)
  {
  	int			tmpfile, ops, writes;
! 
  	if (writes_per_op == 1)
  		printf("\nCompare file sync methods using one write:\n");
  	else
--- 163,170 ----
  test_sync(int writes_per_op)
  {
  	int			tmpfile, ops, writes;
! 	bool		fs_warning = false;
! 	
  	if (writes_per_op == 1)
  		printf("\nCompare file sync methods using one write:\n");
  	else
*************** test_sync(int writes_per_op)
*** 176,184 ****
  	 */
  #ifdef OPEN_DATASYNC_FLAG
  	if (writes_per_op == 1)
! 		printf(LABEL_FORMAT, "open_datasync 8k write");
  	else
! 	 	printf(LABEL_FORMAT, "2 open_datasync 8k writes");
  	fflush(stdout);
  
  	if ((tmpfile = open(filename, O_RDWR | O_DSYNC, 0)) == -1)
--- 177,193 ----
  	 */
  #ifdef OPEN_DATASYNC_FLAG
  	if (writes_per_op == 1)
! 		printf(LABEL_FORMAT, "open_datasync 8k write"
! #if PG_O_DIRECT != 0
! 		"*"
! #endif
! 		);
  	else
! 	 	printf(LABEL_FORMAT, "2 open_datasync 8k writes"
! #if PG_O_DIRECT != 0
! 		"*"
! #endif
! 		);
  	fflush(stdout);
  
  	if ((tmpfile = open(filename, O_RDWR | O_DSYNC, 0)) == -1)
*************** test_sync(int writes_per_op)
*** 201,207 ****
  	 */
  #if PG_O_DIRECT != 0
  	if ((tmpfile = open(filename, O_RDWR | O_DSYNC | PG_O_DIRECT, 0)) == -1)
! 		printf(NA_FORMAT, "o_direct", "n/a on this filesystem\n");
  	else
  	{
  		if (writes_per_op == 1)
--- 210,219 ----
  	 */
  #if PG_O_DIRECT != 0
  	if ((tmpfile = open(filename, O_RDWR | O_DSYNC | PG_O_DIRECT, 0)) == -1)
! 	{
! 		printf(NA_FORMAT, "o_direct", "n/a**\n");
! 		fs_warning = true;
! 	}
  	else
  	{
  		if (writes_per_op == 1)
*************** test_sync(int writes_per_op)
*** 321,329 ****
   */
  #ifdef OPEN_SYNC_FLAG
  	if (writes_per_op == 1)
! 		printf(LABEL_FORMAT, "open_sync 8k write");
  	else
! 		printf(LABEL_FORMAT, "2 open_sync 8k writes");
  	fflush(stdout);
  
  	if ((tmpfile = open(filename, O_RDWR | OPEN_SYNC_FLAG, 0)) == -1)
--- 333,349 ----
   */
  #ifdef OPEN_SYNC_FLAG
  	if (writes_per_op == 1)
! 		printf(LABEL_FORMAT, "open_sync 8k write"
! #if PG_O_DIRECT != 0
! 		"*"
! #endif
! 		);
  	else
! 		printf(LABEL_FORMAT, "2 open_sync 8k writes"
! #if PG_O_DIRECT != 0
! 		"*"
! #endif
! 		);
  	fflush(stdout);
  
  	if ((tmpfile = open(filename, O_RDWR | OPEN_SYNC_FLAG, 0)) == -1)
*************** test_sync(int writes_per_op)
*** 352,358 ****
  	fflush(stdout);
  
  	if ((tmpfile = open(filename, O_RDWR | OPEN_SYNC_FLAG | PG_O_DIRECT, 0)) == -1)
! 		printf(NA_FORMAT, "o_direct", "n/a on this filesystem\n");
  	else
  	{
  		gettimeofday(&start_t, NULL);
--- 372,381 ----
  	fflush(stdout);
  
  	if ((tmpfile = open(filename, O_RDWR | OPEN_SYNC_FLAG | PG_O_DIRECT, 0)) == -1)
! 	{
! 		printf(NA_FORMAT, "o_direct", "n/a**\n");
! 		fs_warning = true;
! 	}
  	else
  	{
  		gettimeofday(&start_t, NULL);
*************** test_sync(int writes_per_op)
*** 375,380 ****
--- 398,414 ----
  #else
  	printf(NA_FORMAT, "open_sync", "n/a\n");
  #endif
+ 
+ #if defined(OPEN_DATASYNC_FLAG) || defined(OPEN_SYNC_FLAG)
+ 	if (PG_O_DIRECT != 0)
+ 		printf("* This non-direct I/O option is not used by Postgres.\n");
+ #endif
+ 
+ 	if (fs_warning)
+ 	{
+ 		printf("** This file system and its mount options do not support direct\n");
+ 		printf("I/O, e.g. ext4 in journaled mode.\n");
+ 	}
  }
  
  void
*************** test_open_syncs(void)
*** 389,394 ****
--- 423,430 ----
  	printf("(This is designed to compare the cost of one large\n");
  	printf("sync'ed write and two smaller sync'ed writes.)\n");
  
+ 	/* XXX no PG_O_DIRECT */
+ 
  /*
   * Test open_sync with different size files
   */
