Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 24372
b: refs/heads/master
c: db77ec2
h: refs/heads/master
v: v3
  • Loading branch information
Alan Curry authored and Linus Torvalds committed Mar 27, 2006
1 parent 87b83c0 commit 9906614
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 59153f7d7effdb5b3c81eb6d03914a866157b319
refs/heads/master: db77ec270d00098ff4fbf15f62f4506f6efb25d2
6 changes: 3 additions & 3 deletions trunk/drivers/video/aty/radeon_base.c
Original file line number Diff line number Diff line change
Expand Up @@ -1067,7 +1067,7 @@ static int radeon_setcolreg (unsigned regno, unsigned red, unsigned green,


if (regno > 255)
return 1;
return -EINVAL;

red >>= 8;
green >>= 8;
Expand All @@ -1086,9 +1086,9 @@ static int radeon_setcolreg (unsigned regno, unsigned red, unsigned green,
pindex = regno * 8;

if (rinfo->depth == 16 && regno > 63)
return 1;
return -EINVAL;
if (rinfo->depth == 15 && regno > 31)
return 1;
return -EINVAL;

/* For 565, the green component is mixed one order
* below
Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/video/fbcmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ static struct fb_cmap default_16_colors = {
* Allocates memory for a colormap @cmap. @len is the
* number of entries in the palette.
*
* Returns -1 errno on error, or zero on success.
* Returns negative errno on error, or zero on success.
*
*/

Expand Down Expand Up @@ -116,7 +116,7 @@ int fb_alloc_cmap(struct fb_cmap *cmap, int len, int transp)

fail:
fb_dealloc_cmap(cmap);
return -1;
return -ENOMEM;
}

/**
Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/video/fbsysfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ static ssize_t store_cmap(struct class_device *class_device, const char *buf,
fb_copy_cmap(&umap, &fb_info->cmap);
fb_dealloc_cmap(&umap);

return rc;
return rc ?: count;
}
for (i = 0; i < length; i++) {
u16 red, blue, green, tsp;
Expand All @@ -367,7 +367,7 @@ static ssize_t store_cmap(struct class_device *class_device, const char *buf,
if (transp)
fb_info->cmap.transp[i] = tsp;
}
return 0;
return count;
}

static ssize_t show_cmap(struct class_device *class_device, char *buf)
Expand Down

0 comments on commit 9906614

Please sign in to comment.