<p>I am slightly curious about this as well; I have a device with only YUV scanout and was considering KMS, but don't know what the best approach is.</p>
<p>At least one KMS driver, nouveau, has to wrap all accesses to its scanout buffers on certain chipsets for tiling reasons, so the same strategy might work.</p>
<p>Sending from a mobile, pardon the brevity. ~ C.</p>
<div class="gmail_quote">On Mar 1, 2011 12:22 PM, "Geert Uytterhoeven" <<a href="mailto:geert@linux-m68k.org">geert@linux-m68k.org</a>> wrote:<br type="attribution">> On Tue, Mar 1, 2011 at 09:25, Magnus Damm <<a href="mailto:magnus.damm@gmail.com">magnus.damm@gmail.com</a>> wrote:<br>
>> On Thu, Feb 24, 2011 at 3:05 PM, Geert Uytterhoeven<br>>> <<a href="mailto:geert@linux-m68k.org">geert@linux-m68k.org</a>> wrote:<br>>>> On Thu, Feb 24, 2011 at 00:28, Magnus Damm <<a href="mailto:magnus.damm@gmail.com">magnus.damm@gmail.com</a>> wrote:<br>
>>>> Please ditch the SH_FB_YUV constant all together. No need to build<br>>>>> some abstraction on top of a hackish interface. Just check if nonstd<br>>>>> is non-zero in the driver and assume that means YUV for now. That's<br>
>>>> good enough.<br>>>><br>>>> For YUV (do you mean YCbCr?), I'm inclined to suggest adding a new FB_VISUAL_*<br>>>> type instead, which indicates the fb_var_screeninfo.{red,green,blue} fields are<br>
>>> YCbCr instead of RGB.<br>>>> Depending on the frame buffer organization, you also need new FB_TYPE_*/FB_AUX_*<br>>>> types.<br>>><br>>> I'm all for extending the common code instead of hiding code in<br>
>> drivers. But I wonder how much overlap there is with V4L2 for<br>>> instance. I remember adding support for some NVxx formats for V4L2<br>>> some years ago. It's mainly used for Video input on Renesas SoCs<br>
>> though:<br>>><br>>> <a href="http://kerneltrap.org/mailarchive/git-commits-head/2008/12/31/4560474">http://kerneltrap.org/mailarchive/git-commits-head/2008/12/31/4560474</a><br>>><br>>> So I was hoping that something like the above could be added to fbdev<br>
>> too, but it looks like more code is needed.<br>>><br>>> Do you have any idea on how to tie in the valid range of each color<br>>> channel? The LCDC hardware block can select between 0->255 range or<br>
>> 16->235/240 for the YUV channels. In V4L2 this is handled by<br>>> v4l2_colorspace, the 0->255 maps directly to V4L2_COLORSPACE_JPEG.<br>> <br>> Unfortunately not. Unlike for the YCbCr visual, I don't see a field we<br>
> can easily<br>> (ab)use for that. Except if it's limited to standard 16-235/240 Y vs.<br>> full 0-255 Y,<br>> for which we could just have 2 different visual types.<br>> <br>>> And how does all this relate to KMS? I'd prefer to keep this code in<br>
>> one place if possible.<br>> <br>> Good question!<br>> <br>> I'm still puzzled about this KMS thing. If the name "Kernel Mode Setting"<br>> covers it, then how does it compare to plain fbdev? Just additional frame buffer<br>
> memory management?<br>> <br>> Furthermore, everybody states that "future X/desktop" will require KMS drivers.<br>> How do/will we handle this on dumb frame buffers? It's not like we can't do<br>
> "advanced" things like compositing using the CPU. Transparency may stretch<br>> it a bit on lower end CPUs, but you don't always need that.<br>> <br>> Gr{oetje,eeting}s,<br>> <br>> Geert<br>
> <br>> --<br>> Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- <a href="mailto:geert@linux-m68k.org">geert@linux-m68k.org</a><br>> <br>> In personal conversations with technical people, I call myself a hacker. But<br>
> when I'm talking to journalists I just say "programmer" or something like that.<br>> -- Linus Torvalds<br>> _______________________________________________<br>> dri-devel mailing list<br>
> <a href="mailto:dri-devel@lists.freedesktop.org">dri-devel@lists.freedesktop.org</a><br>> <a href="http://lists.freedesktop.org/mailman/listinfo/dri-devel">http://lists.freedesktop.org/mailman/listinfo/dri-devel</a><br>
</div>