From: Dave Jones Date: Wed, 18 Oct 2006 04:26:39 +0000 (-0400) Subject: fix return code in error case. X-Git-Tag: v3.12-rc1~32144^2~7^2~70^2~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=0d960d26c42888cf327df7faa1a8aa62bab53fa4;p=kernel%2Fkernel-generic.git fix return code in error case. The other failure returns in this function are negative, so make this one do the same. Signed-off-by: Dave Jones Signed-off-by: Dave Airlie --- diff --git a/drivers/char/drm/savage_state.c b/drivers/char/drm/savage_state.c index ef2581d..1ca1e9c 100644 --- a/drivers/char/drm/savage_state.c +++ b/drivers/char/drm/savage_state.c @@ -994,7 +994,7 @@ int savage_bci_cmdbuf(DRM_IOCTL_ARGS) if (cmdbuf.size) { kcmd_addr = drm_alloc(cmdbuf.size * 8, DRM_MEM_DRIVER); if (kcmd_addr == NULL) - return ENOMEM; + return DRM_ERR(ENOMEM); if (DRM_COPY_FROM_USER(kcmd_addr, cmdbuf.cmd_addr, cmdbuf.size * 8))