diff options
author | Eric Anholt <eric@anholt.net> | 2007-08-25 05:22:43 -0400 |
---|---|---|
committer | Dave Airlie <airlied@optimus.(none)> | 2007-10-14 20:38:19 -0400 |
commit | 20caafa6ecb2487d9b223aa33e7cc704f912a758 (patch) | |
tree | 7df033fdee81305dad0a67ceba79f51ead7c1b8b /drivers/char/drm/via_irq.c | |
parent | 23fd50450a34f2558070ceabb0bfebc1c9604af5 (diff) |
drm: Remove DRM_ERR OS macro.
This was used to make all ioctl handlers return -errno on linux and errno on
*BSD. Instead, just return -errno in shared code, and flip sign on return f
shared code to *BSD code.
Signed-off-by: Dave Airlie <airlied@linux.ie>
Diffstat (limited to 'drivers/char/drm/via_irq.c')
-rw-r--r-- | drivers/char/drm/via_irq.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/char/drm/via_irq.c b/drivers/char/drm/via_irq.c index 8dc99b5fbab6..a5297e70f94a 100644 --- a/drivers/char/drm/via_irq.c +++ b/drivers/char/drm/via_irq.c | |||
@@ -205,13 +205,13 @@ via_driver_irq_wait(struct drm_device * dev, unsigned int irq, int force_sequenc | |||
205 | 205 | ||
206 | if (!dev_priv) { | 206 | if (!dev_priv) { |
207 | DRM_ERROR("%s called with no initialization\n", __FUNCTION__); | 207 | DRM_ERROR("%s called with no initialization\n", __FUNCTION__); |
208 | return DRM_ERR(EINVAL); | 208 | return -EINVAL; |
209 | } | 209 | } |
210 | 210 | ||
211 | if (irq >= drm_via_irq_num) { | 211 | if (irq >= drm_via_irq_num) { |
212 | DRM_ERROR("%s Trying to wait on unknown irq %d\n", __FUNCTION__, | 212 | DRM_ERROR("%s Trying to wait on unknown irq %d\n", __FUNCTION__, |
213 | irq); | 213 | irq); |
214 | return DRM_ERR(EINVAL); | 214 | return -EINVAL; |
215 | } | 215 | } |
216 | 216 | ||
217 | real_irq = dev_priv->irq_map[irq]; | 217 | real_irq = dev_priv->irq_map[irq]; |
@@ -219,7 +219,7 @@ via_driver_irq_wait(struct drm_device * dev, unsigned int irq, int force_sequenc | |||
219 | if (real_irq < 0) { | 219 | if (real_irq < 0) { |
220 | DRM_ERROR("%s Video IRQ %d not available on this hardware.\n", | 220 | DRM_ERROR("%s Video IRQ %d not available on this hardware.\n", |
221 | __FUNCTION__, irq); | 221 | __FUNCTION__, irq); |
222 | return DRM_ERR(EINVAL); | 222 | return -EINVAL; |
223 | } | 223 | } |
224 | 224 | ||
225 | masks = dev_priv->irq_masks; | 225 | masks = dev_priv->irq_masks; |
@@ -343,13 +343,13 @@ int via_wait_irq(DRM_IOCTL_ARGS) | |||
343 | int force_sequence; | 343 | int force_sequence; |
344 | 344 | ||
345 | if (!dev->irq) | 345 | if (!dev->irq) |
346 | return DRM_ERR(EINVAL); | 346 | return -EINVAL; |
347 | 347 | ||
348 | DRM_COPY_FROM_USER_IOCTL(irqwait, argp, sizeof(irqwait)); | 348 | DRM_COPY_FROM_USER_IOCTL(irqwait, argp, sizeof(irqwait)); |
349 | if (irqwait.request.irq >= dev_priv->num_irqs) { | 349 | if (irqwait.request.irq >= dev_priv->num_irqs) { |
350 | DRM_ERROR("%s Trying to wait on unknown irq %d\n", __FUNCTION__, | 350 | DRM_ERROR("%s Trying to wait on unknown irq %d\n", __FUNCTION__, |
351 | irqwait.request.irq); | 351 | irqwait.request.irq); |
352 | return DRM_ERR(EINVAL); | 352 | return -EINVAL; |
353 | } | 353 | } |
354 | 354 | ||
355 | cur_irq += irqwait.request.irq; | 355 | cur_irq += irqwait.request.irq; |
@@ -361,13 +361,13 @@ int via_wait_irq(DRM_IOCTL_ARGS) | |||
361 | case VIA_IRQ_ABSOLUTE: | 361 | case VIA_IRQ_ABSOLUTE: |
362 | break; | 362 | break; |
363 | default: | 363 | default: |
364 | return DRM_ERR(EINVAL); | 364 | return -EINVAL; |
365 | } | 365 | } |
366 | 366 | ||
367 | if (irqwait.request.type & VIA_IRQ_SIGNAL) { | 367 | if (irqwait.request.type & VIA_IRQ_SIGNAL) { |
368 | DRM_ERROR("%s Signals on Via IRQs not implemented yet.\n", | 368 | DRM_ERROR("%s Signals on Via IRQs not implemented yet.\n", |
369 | __FUNCTION__); | 369 | __FUNCTION__); |
370 | return DRM_ERR(EINVAL); | 370 | return -EINVAL; |
371 | } | 371 | } |
372 | 372 | ||
373 | force_sequence = (irqwait.request.type & VIA_IRQ_FORCE_SEQUENCE); | 373 | force_sequence = (irqwait.request.type & VIA_IRQ_FORCE_SEQUENCE); |