diff options
author | Linus Torvalds <torvalds@woody.osdl.org> | 2006-12-20 23:59:07 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.osdl.org> | 2006-12-20 23:59:07 -0800 |
commit | ee2fae03d68e702866a8661fbee7ff2f2f3754d7 (patch) | |
tree | 4afb2ab7126d2acb6104fd5b1736b9190775070d /drivers/char/drm/drm_sysfs.c | |
parent | e4ddc9cc62b40a8b08d02379064d5d8fd78e98bc (diff) | |
parent | f9841a8d6018f8bcba77e75c9e368d94f1f22933 (diff) |
Merge branch 'drm-patches' of master.kernel.org:/pub/scm/linux/kernel/git/airlied/drm-2.6
* 'drm-patches' of master.kernel.org:/pub/scm/linux/kernel/git/airlied/drm-2.6:
drm: Stop defining pci_pretty_name
drm: r128: comment aligment with drm git
drm: make kernel context switch same as for drm git tree.
drm: fixup comment header style
drm: savage: compat fix from drm git.
drm: Unify radeon offset checking.
i915_vblank_tasklet: Try harder to avoid tearing.
DRM: handle pci_enable_device failure
drm: fix return value check
Diffstat (limited to 'drivers/char/drm/drm_sysfs.c')
-rw-r--r-- | drivers/char/drm/drm_sysfs.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/char/drm/drm_sysfs.c b/drivers/char/drm/drm_sysfs.c index ba4b8de83cf..cc8e2ebe128 100644 --- a/drivers/char/drm/drm_sysfs.c +++ b/drivers/char/drm/drm_sysfs.c @@ -45,8 +45,8 @@ struct class *drm_sysfs_create(struct module *owner, char *name) int err; class = class_create(owner, name); - if (!class) { - err = -ENOMEM; + if (IS_ERR(class)) { + err = PTR_ERR(class); goto err_out; } @@ -113,8 +113,8 @@ struct class_device *drm_sysfs_device_add(struct class *cs, drm_head_t *head) MKDEV(DRM_MAJOR, head->minor), &(head->dev->pdev)->dev, "card%d", head->minor); - if (!class_dev) { - err = -ENOMEM; + if (IS_ERR(class_dev)) { + err = PTR_ERR(class_dev); goto err_out; } |