vfio: put off the allocation of "minor" in vfio_create_group
authorZhen Lei <thunder.leizhen@huawei.com>
Mon, 16 Mar 2015 20:08:56 +0000 (14:08 -0600)
committerAlex Williamson <alex.williamson@redhat.com>
Mon, 16 Mar 2015 20:08:56 +0000 (14:08 -0600)
commit2f51bf4be99386f49841b6365a85a5cabc148565
tree2c3c9d7c36d2a3b14b577b4f0a09b0df34d11a6b
parenta7fa7c77cf15fb22d0f33fcc88770de0246c5588
vfio: put off the allocation of "minor" in vfio_create_group

The next code fragment "list_for_each_entry" is not depend on "minor". With this
patch, the free of "minor" in "list_for_each_entry" can be reduced, and there is
no functional change.

Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com>
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
drivers/vfio/vfio.c