Replace calls to minor() with dev2unit(). Ed already fixed this once,
but I inadvertently overwrote the change when I synced to git. Commit the fix in both places, so this doesn't happen again. Approved by: jhb (mentor) MFC after: 2 weeks
This commit is contained in:
parent
fd3c63db72
commit
cdab8377da
@ -537,7 +537,7 @@ int drm_open(struct cdev *kdev, int flags, int fmt, DRM_STRUCTPROC *p)
|
|||||||
struct drm_device *dev = NULL;
|
struct drm_device *dev = NULL;
|
||||||
int retcode = 0;
|
int retcode = 0;
|
||||||
|
|
||||||
dev = DRIVER_SOFTC(minor(kdev));
|
dev = DRIVER_SOFTC(dev2unit(kdev));
|
||||||
|
|
||||||
DRM_DEBUG("open_count = %d\n", dev->open_count);
|
DRM_DEBUG("open_count = %d\n", dev->open_count);
|
||||||
|
|
||||||
|
@ -44,7 +44,7 @@ int drm_open_helper(struct cdev *kdev, int flags, int fmt, DRM_STRUCTPROC *p,
|
|||||||
struct drm_device *dev)
|
struct drm_device *dev)
|
||||||
{
|
{
|
||||||
struct drm_file *priv;
|
struct drm_file *priv;
|
||||||
int m = minor(kdev);
|
int m = dev2unit(kdev);
|
||||||
int retcode;
|
int retcode;
|
||||||
|
|
||||||
if (flags & O_EXCL)
|
if (flags & O_EXCL)
|
||||||
|
Loading…
Reference in New Issue
Block a user