/* See what I mean about userspace being boring?  */
static struct device* new_device(const char *name, u16 type)
/* See what I mean about userspace being boring?  */
static struct device* new_device(const char *name, u16 type)
{
	struct device *dev = malloc(sizeof(*dev));
	dev->desc = new_dev_desc(type);
	dev->name = name;
	dev->vq = NULL;
	dev->feature_len = 0;
	dev->num_vq = 0;
	dev->running = false;
	if (devices.lastdev)
		devices.lastdev->next = dev;
	else
		devices.dev = dev;
	devices.lastdev = dev;
	return dev;
}