arch: cxd56xx: Fix parameter check of hostif buffer

Fix a parameter check of the buffer attribute in opening hostif driver.
This commit is contained in:
SPRESENSE 2021-05-19 17:04:54 +09:00 committed by Alin Jerpelea
parent db9c94962b
commit 6b5a4cbfd3

View File

@ -211,7 +211,7 @@ static int hif_open(FAR struct file *filep)
}
if ((filep->f_oflags & O_WRONLY) &&
((priv->flags & HOSTIF_BUFF_ATTR_WRITE) != 0))
((priv->flags & HOSTIF_BUFF_ATTR_READ) != 0))
{
return -EINVAL;
}