summaryrefslogtreecommitdiff
path: root/drivers/video/skeletonfb.c
diff options
context:
space:
mode:
authorMichal Januszewski <spock@gentoo.org>2009-04-13 21:39:41 (GMT)
committerLinus Torvalds <torvalds@linux-foundation.org>2009-04-13 22:04:29 (GMT)
commitebde441177da3bad156701d351509f34295282ab (patch)
tree816eca54fcde1e42d4ba81ab80533188724a64ee /drivers/video/skeletonfb.c
parent513adb58685615b0b1d47a3f0d40f5352beff189 (diff)
downloadlinux-ebde441177da3bad156701d351509f34295282ab.tar.xz
fbdev: fix color component field length documentation
The documentation about the meaning of the color component bitfield lengths in pseudocolor modes is inconsistent. Fix it, so that it indicates the correct interpretation everywhere, i.e. that 1 << length is the number of palette entries. Signed-off-by: Michal Januszewski <spock@gentoo.org> Acked-by: Krzysztof Helt <krzysztof.h1@poczta.fm> Cc: <syrjala@sci.fi> Acked-by: Geert Uytterhoeven <geert.uytterhoeven@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/video/skeletonfb.c')
-rw-r--r--drivers/video/skeletonfb.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/video/skeletonfb.c b/drivers/video/skeletonfb.c
index a439159..89158bc 100644
--- a/drivers/video/skeletonfb.c
+++ b/drivers/video/skeletonfb.c
@@ -308,9 +308,11 @@ static int xxxfb_setcolreg(unsigned regno, unsigned red, unsigned green,
* color depth = SUM(var->{color}.length)
*
* Pseudocolor:
- * var->{color}.offset is 0
- * var->{color}.length contains width of DAC or the number of unique
- * colors available (color depth)
+ * var->{color}.offset is 0 unless the palette index takes less than
+ * bits_per_pixel bits and is stored in the upper
+ * bits of the pixel value
+ * var->{color}.length is set so that 1 << length is the number of
+ * available palette entries
* pseudo_palette is not used
* RAMDAC[X] is programmed to (red, green, blue)
* color depth = var->{color}.length