haiku: Merge changes from 8c60a6716d