mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-25 19:57:43 +03:00
kmem_zalloc with KM_SLEEP will never return NULL
These allocations can never fail. Leaving the error handling code here gives the impression they can so it has been removed. Signed-off-by: luozhengzheng <luo.zhengzheng@zte.com.cn> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes #5048
This commit is contained in:
committed by
Brian Behlendorf
parent
2d96d7aa56
commit
ca8587a517
@@ -426,8 +426,6 @@ zfs_zevent_alloc(void)
|
||||
zevent_t *ev;
|
||||
|
||||
ev = kmem_zalloc(sizeof (zevent_t), KM_SLEEP);
|
||||
if (ev == NULL)
|
||||
return (NULL);
|
||||
|
||||
list_create(&ev->ev_ze_list, sizeof (zfs_zevent_t),
|
||||
offsetof(zfs_zevent_t, ze_node));
|
||||
|
||||
Reference in New Issue
Block a user