diff options
author | Dan McDonald <danmcd@joyent.com> | 2022-02-22 19:50:49 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-02-22 19:50:49 -0500 |
commit | bc426cb7eeb7a41ef293093a664028214e5d5168 (patch) | |
tree | b48bf23a847eee9fa42163ba9a7155924f3c7a32 | |
parent | 263ea1b63c716f2faa665b9fe7952e018d1110c1 (diff) | |
download | illumos-joyent-bc426cb7eeb7a41ef293093a664028214e5d5168.tar.gz |
OS-8359 Cleanup (KM_NOSLEEP | KM_NORMALPRI) in illumos-joyent
Reviewed by: Brian Bennett <brian.bennett@joyent.com>
Approved by: Brian Bennett <brian.bennett@joyent.com>
-rw-r--r-- | usr/src/uts/common/brand/lx/cgroups/cgrps_node.c | 2 | ||||
-rw-r--r-- | usr/src/uts/common/brand/lx/devfs/lxd_node.c | 2 | ||||
-rw-r--r-- | usr/src/uts/common/brand/lx/devfs/lxd_vnops.c | 2 | ||||
-rw-r--r-- | usr/src/uts/common/fs/hyprlofs/hyprlofs_dir.c | 2 | ||||
-rw-r--r-- | usr/src/uts/common/fs/hyprlofs/hyprlofs_vfsops.c | 3 | ||||
-rw-r--r-- | usr/src/uts/common/fs/tmpfs/tmp_dir.c | 2 | ||||
-rw-r--r-- | usr/src/uts/common/fs/tmpfs/tmp_vfsops.c | 4 | ||||
-rw-r--r-- | usr/src/uts/common/fs/tmpfs/tmp_vnops.c | 2 | ||||
-rw-r--r-- | usr/src/uts/common/inet/tcp/tcp_bind.c | 7 | ||||
-rw-r--r-- | usr/src/uts/common/io/vnd/vnd.c | 4 |
10 files changed, 14 insertions, 16 deletions
diff --git a/usr/src/uts/common/brand/lx/cgroups/cgrps_node.c b/usr/src/uts/common/brand/lx/cgroups/cgrps_node.c index 8e8a581613..d9b7e443dd 100644 --- a/usr/src/uts/common/brand/lx/cgroups/cgrps_node.c +++ b/usr/src/uts/common/brand/lx/cgroups/cgrps_node.c @@ -908,7 +908,7 @@ cgrp_diraddentry(cgrp_node_t *dir, cgrp_node_t *cn, char *name) /* Allocate and initialize directory entry */ namelen = strlen(name) + 1; alloc_size = namelen + sizeof (cgrp_dirent_t); - cdp = kmem_zalloc(alloc_size, KM_NOSLEEP | KM_NORMALPRI); + cdp = kmem_zalloc(alloc_size, KM_NOSLEEP_LAZY); if (cdp == NULL) return (ENOSPC); diff --git a/usr/src/uts/common/brand/lx/devfs/lxd_node.c b/usr/src/uts/common/brand/lx/devfs/lxd_node.c index 8063a82d10..30fdeb82a6 100644 --- a/usr/src/uts/common/brand/lx/devfs/lxd_node.c +++ b/usr/src/uts/common/brand/lx/devfs/lxd_node.c @@ -430,7 +430,7 @@ lxd_diraddentry(lxd_node_t *dir, lxd_node_t *ldn, char *name) /* Allocate and initialize directory entry */ namelen = strlen(name) + 1; alloc_size = namelen + sizeof (lxd_dirent_t); - dp = kmem_zalloc(alloc_size, KM_NOSLEEP | KM_NORMALPRI); + dp = kmem_zalloc(alloc_size, KM_NOSLEEP_LAZY); if (dp == NULL) return (ENOSPC); diff --git a/usr/src/uts/common/brand/lx/devfs/lxd_vnops.c b/usr/src/uts/common/brand/lx/devfs/lxd_vnops.c index 8088ba6174..c291e25797 100644 --- a/usr/src/uts/common/brand/lx/devfs/lxd_vnops.c +++ b/usr/src/uts/common/brand/lx/devfs/lxd_vnops.c @@ -982,7 +982,7 @@ lxd_symlink(vnode_t *dvp, char *nm, struct vattr *tva, char *tnm, } len = strlen(tnm) + 1; - cp = kmem_alloc(len, KM_NOSLEEP | KM_NORMALPRI); + cp = kmem_alloc(len, KM_NOSLEEP_LAZY); if (cp == NULL) { ldnode_rele(self); return (ENOSPC); diff --git a/usr/src/uts/common/fs/hyprlofs/hyprlofs_dir.c b/usr/src/uts/common/fs/hyprlofs/hyprlofs_dir.c index 05ee2c6e09..cc03f41c8d 100644 --- a/usr/src/uts/common/fs/hyprlofs/hyprlofs_dir.c +++ b/usr/src/uts/common/fs/hyprlofs/hyprlofs_dir.c @@ -504,7 +504,7 @@ hldiraddentry( /* Alloc and init dir entry */ namelen = strlen(name) + 1; alloc_size = namelen + sizeof (hldirent_t); - hdp = kmem_zalloc(alloc_size, KM_NORMALPRI | KM_NOSLEEP); + hdp = kmem_zalloc(alloc_size, KM_NOSLEEP_LAZY); if (hdp == NULL) return (ENOSPC); diff --git a/usr/src/uts/common/fs/hyprlofs/hyprlofs_vfsops.c b/usr/src/uts/common/fs/hyprlofs/hyprlofs_vfsops.c index c582a8cac2..bf80da6dbe 100644 --- a/usr/src/uts/common/fs/hyprlofs/hyprlofs_vfsops.c +++ b/usr/src/uts/common/fs/hyprlofs/hyprlofs_vfsops.c @@ -271,8 +271,7 @@ hyprlofs_mount(vfs_t *vfsp, vnode_t *mvp, struct mounta *uap, cred_t *cr) &dpn)) != 0) goto out; - if ((hm = kmem_zalloc(sizeof (hlfsmount_t), - KM_NORMALPRI | KM_NOSLEEP)) == NULL) { + if ((hm = kmem_zalloc(sizeof (hlfsmount_t), KM_NOSLEEP_LAZY)) == NULL) { pn_free(&dpn); error = ENOMEM; goto out; diff --git a/usr/src/uts/common/fs/tmpfs/tmp_dir.c b/usr/src/uts/common/fs/tmpfs/tmp_dir.c index d689c512c1..b28ced7111 100644 --- a/usr/src/uts/common/fs/tmpfs/tmp_dir.c +++ b/usr/src/uts/common/fs/tmpfs/tmp_dir.c @@ -990,7 +990,7 @@ tdiraddentry( tm = TNTOTM(dir); namelen = strlen(name) + 1; alloc_size = namelen + sizeof (struct tdirent); - tdp = tmp_kmem_zalloc(tm, alloc_size, KM_NOSLEEP | KM_NORMALPRI); + tdp = tmp_kmem_zalloc(tm, alloc_size, KM_NOSLEEP_LAZY); if (tdp == NULL) return (ENOSPC); diff --git a/usr/src/uts/common/fs/tmpfs/tmp_vfsops.c b/usr/src/uts/common/fs/tmpfs/tmp_vfsops.c index c52a6f7c77..24310fefe5 100644 --- a/usr/src/uts/common/fs/tmpfs/tmp_vfsops.c +++ b/usr/src/uts/common/fs/tmpfs/tmp_vfsops.c @@ -325,8 +325,8 @@ tmp_mount(vfs_t *vfsp, vnode_t *mvp, struct mounta *uap, cred_t *cr) goto out; } - if ((tm = kmem_zalloc(sizeof (struct tmount), - KM_NOSLEEP | KM_NORMALPRI)) == NULL) { + if ((tm = kmem_zalloc(sizeof (struct tmount), KM_NOSLEEP_LAZY)) == + NULL) { pn_free(&dpn); error = ENOMEM; goto out; diff --git a/usr/src/uts/common/fs/tmpfs/tmp_vnops.c b/usr/src/uts/common/fs/tmpfs/tmp_vnops.c index a356f22750..cbe19aefea 100644 --- a/usr/src/uts/common/fs/tmpfs/tmp_vnops.c +++ b/usr/src/uts/common/fs/tmpfs/tmp_vnops.c @@ -1645,7 +1645,7 @@ tmp_symlink( return (error); } len = strlen(tnm) + 1; - cp = tmp_kmem_zalloc(tm, len, KM_NOSLEEP | KM_NORMALPRI); + cp = tmp_kmem_zalloc(tm, len, KM_NOSLEEP_LAZY); if (cp == NULL) { tmpnode_rele(self); return (ENOSPC); diff --git a/usr/src/uts/common/inet/tcp/tcp_bind.c b/usr/src/uts/common/inet/tcp/tcp_bind.c index 876e7d48e6..18efac7b74 100644 --- a/usr/src/uts/common/inet/tcp/tcp_bind.c +++ b/usr/src/uts/common/inet/tcp/tcp_bind.c @@ -1006,11 +1006,10 @@ tcp_rg_t * tcp_rg_init(tcp_t *tcp) { tcp_rg_t *rg; - rg = kmem_alloc(sizeof (tcp_rg_t), KM_NOSLEEP|KM_NORMALPRI); + rg = kmem_alloc(sizeof (tcp_rg_t), KM_NOSLEEP_LAZY); if (rg == NULL) return (NULL); - rg->tcprg_members = kmem_zalloc(2 * sizeof (tcp_t *), - KM_NOSLEEP|KM_NORMALPRI); + rg->tcprg_members = kmem_zalloc(2 * sizeof (tcp_t *), KM_NOSLEEP_LAZY); if (rg->tcprg_members == NULL) { kmem_free(rg, sizeof (tcp_rg_t)); return (NULL); @@ -1063,7 +1062,7 @@ tcp_rg_insert(tcp_rg_t *rg, tcp_t *tcp) return (EINVAL); } newmembers = kmem_zalloc(newsize * sizeof (tcp_t *), - KM_NOSLEEP|KM_NORMALPRI); + KM_NOSLEEP_LAZY); if (newmembers == NULL) { mutex_exit(&rg->tcprg_lock); return (ENOMEM); diff --git a/usr/src/uts/common/io/vnd/vnd.c b/usr/src/uts/common/io/vnd/vnd.c index 9ed57f30c4..8c05c8aee0 100644 --- a/usr/src/uts/common/io/vnd/vnd.c +++ b/usr/src/uts/common/io/vnd/vnd.c @@ -4457,7 +4457,7 @@ vnd_frameio_read(vnd_dev_t *vdp, intptr_t addr, int mode) vnd_data_queue_t *vqp; mblk_t *mp; - fio = frameio_alloc(KM_NOSLEEP | KM_NORMALPRI); + fio = frameio_alloc(KM_NOSLEEP_LAZY); if (fio == NULL) return (EAGAIN); @@ -4532,7 +4532,7 @@ vnd_frameio_write(vnd_dev_t *vdp, intptr_t addr, int mode) mblk_t *mp_chain, *mp, *nmp; vnd_data_queue_t *vqp; - fio = frameio_alloc(KM_NOSLEEP | KM_NORMALPRI); + fio = frameio_alloc(KM_NOSLEEP_LAZY); if (fio == NULL) return (EAGAIN); |