/* This function seraches for gluebi device corresponding to UBI device @ubi_num and UBI volume @vol_id. Returns the gluebi device description object in case of success and NULL in case of failure. The caller has to have the &devices_mutex locked.  */
static struct gluebi_device* find_gluebi_nolock(int ubi_num, int vol_id)
/* This function seraches for gluebi device corresponding to UBI device @ubi_num and UBI volume @vol_id. Returns the gluebi device description object in case of success and NULL in case of failure. The caller has to have the &devices_mutex locked.  */
static struct gluebi_device* find_gluebi_nolock(int ubi_num, int vol_id)
{
	struct gluebi_device *gluebi;
	list_for_each_entry(gluebi, &gluebi_devices, list)
		if (gluebi->ubi_num == ubi_num && gluebi->vol_id == vol_id)
			return gluebi;
	return NULL;
}