Block creation of the new nodes for read-only tmpfs mounts.
Tested by: pho Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Differential revision: https://reviews.freebsd.org/D19737
This commit is contained in:
parent
8581fc9ad5
commit
ae26575394
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=345799
@ -218,6 +218,8 @@ tmpfs_alloc_node(struct mount *mp, struct tmpfs_mount *tmp, enum vtype type,
|
||||
*/
|
||||
return (EBUSY);
|
||||
}
|
||||
if ((mp->mnt_kern_flag & MNT_RDONLY) != 0)
|
||||
return (EROFS);
|
||||
|
||||
nnode = (struct tmpfs_node *)uma_zalloc_arg(tmp->tm_node_pool, tmp,
|
||||
M_WAITOK);
|
||||
|
Loading…
Reference in New Issue
Block a user