> + if (atomic_read(&root->fs_info->async_delalloc_pages)) > + wait_event(root->fs_info->async_submit_wait, > + !atomic_read(&root->fs_info->async_delalloc_pages)); The very first thing wait_event_*() family does is test the condition. You don't need to guard them with an inverse copy of the condition. Just call them directly and they'll do the right thing and bail cheaply when the condition is already true. - z -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html
