sync with FreeBSD