From 6ed7e36f4c6933cc29b0f5c8cb810490dd93a8fc Mon Sep 17 00:00:00 2001 From: Dave Airlie Date: Thu, 22 Jul 2004 12:07:13 +0000 Subject: [PATCH] another logic error returns 0 or greater for success --- linux-core/drm_stub.c | 2 +- linux/drm_stub.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/linux-core/drm_stub.c b/linux-core/drm_stub.c index b278bcbd..fb6c2f81 100644 --- a/linux-core/drm_stub.c +++ b/linux-core/drm_stub.c @@ -206,7 +206,7 @@ int DRM(stub_register)(const char *name, struct file_operations *fops, if (DRM(stub_info).info_register) { ret2 = DRM(stub_info).info_register(name, fops, dev); - if (ret2) { + if (ret2 < 0) { if (!i) { inter_module_unregister("drm"); unregister_chrdev(DRM_MAJOR, "drm"); diff --git a/linux/drm_stub.h b/linux/drm_stub.h index b278bcbd..fb6c2f81 100644 --- a/linux/drm_stub.h +++ b/linux/drm_stub.h @@ -206,7 +206,7 @@ int DRM(stub_register)(const char *name, struct file_operations *fops, if (DRM(stub_info).info_register) { ret2 = DRM(stub_info).info_register(name, fops, dev); - if (ret2) { + if (ret2 < 0) { if (!i) { inter_module_unregister("drm"); unregister_chrdev(DRM_MAJOR, "drm");