예제 #1
0
int vnic_dev_notify_unset(struct vnic_dev *vdev)
{
#ifdef __VMKLNX__	
	struct vnic_devcmd_notify *notify_tmp = vdev->notify;
	dma_addr_t notify_pa_tmp = vdev->notify_pa;
	int r;
	
	r = vnic_dev_notify_unsetcmd(vdev);
	if (notify_tmp) {
		pci_free_consistent(vdev->pdev,
			sizeof(struct vnic_devcmd_notify),
			notify_tmp,
			notify_pa_tmp);
	}

	return r;
#else 
	if (vdev->notify) {
		pci_free_consistent(vdev->pdev,
			sizeof(struct vnic_devcmd_notify),
			vdev->notify,
			vdev->notify_pa);
	}

	return vnic_dev_notify_unsetcmd(vdev);
#endif       	
}
예제 #2
0
int vnic_dev_notify_unset(struct vnic_dev *vdev)
{
	if (vdev->notify) {
		pci_free_consistent(vdev->pdev,
			sizeof(struct vnic_devcmd_notify),
			vdev->notify,
			vdev->notify_pa);
	}

	return vnic_dev_notify_unsetcmd(vdev);
}