linux-fbdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Geert Uytterhoeven <geert@linux-m68k.org>
To: linux-fbdev@vger.kernel.org
Subject: Re: Question abouf FB actual size
Date: Sun, 19 Apr 2015 20:15:57 +0000	[thread overview]
Message-ID: <CAMuHMdWd7rDFvUewR-yvzmwz793onPWhL6yo9UZX6C8Hu8tk-w@mail.gmail.com> (raw)
In-Reply-To: <CAFAVkqVPVG_h+Kwq-KjdivMWh+2WthJdJvQqRcf1m-qjHTpX1A@mail.gmail.com>

On Sun, Apr 19, 2015 at 10:01 PM, Paolo Niccolò Giubelli
<paoloniccolo.giubelli@gmail.com> wrote:
> On Sun, Apr 19, 2015 at 9:29 PM, Geert Uytterhoeven
> <geert@linux-m68k.org> wrote:
>> On Sun, Apr 19, 2015 at 7:39 PM, Paolo Niccolò Giubelli
>> <paoloniccolo.giubelli@gmail.com> wrote:
>>> There's something wrong with the math, because i have a 1366x768x32
>>> FB, but my finfo.line_length (finfo is obtained via
>>> FBIOGET_FSCREENINFO) is 5504 bytes. Well, 5504/4 (4 is 4 bytes per
>>> pixel) is 1376 that is 10 pixels more than 1366.
>>
>> 1366 * 4 is not a multiple of 64. 5504 is.
>> I guess your hardware requires each line to start at an address which is a
>> multiple of 64.
>
> Thank you Geert! So I guess there's some kind of padding after the end
> of the line, where I can write anything that has no effect. Do you
> know if there's something to check into fb.h so to guess the alignment
> requirements?

The only way to find out is to look at fb_fix_screeninfo.line_length.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

  parent reply	other threads:[~2015-04-19 20:15 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-19 17:39 Question abouf FB actual size Paolo Niccolò Giubelli
2015-04-19 19:29 ` Geert Uytterhoeven
2015-04-19 20:01 ` Paolo Niccolò Giubelli
2015-04-19 20:15 ` Geert Uytterhoeven [this message]
2015-04-19 20:20 ` Paolo Niccolò Giubelli

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAMuHMdWd7rDFvUewR-yvzmwz793onPWhL6yo9UZX6C8Hu8tk-w@mail.gmail.com \
    --to=geert@linux-m68k.org \
    --cc=linux-fbdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).