Merge tag 'iommu-config-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git...
[cascardo/linux.git] / drivers / xen / evtchn.c
index 5de2063..00f40f0 100644 (file)
@@ -417,7 +417,7 @@ static long evtchn_ioctl(struct file *file,
                        break;
 
                rc = -EINVAL;
-               if (unbind.port >= NR_EVENT_CHANNELS)
+               if (unbind.port >= xen_evtchn_nr_channels())
                        break;
 
                rc = -ENOTCONN;