Skip to content

Create an API for safely accessing BMP header fields

Igor Grinberg u-boot 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest3 of 5 patches 0 repliesNew

3 of 5 patches are in this archive. The cover letter announces 5.

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5Add bmp_layout module for accessing BMP header data+0 -01 reply
1/5Add bmp_layout module for accessing BMP header data+0 -01 reply
1/5Add bmp_layout module for accessing BMP header data+0 -01 reply

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [U-Boot] [PATCH 0/5] Create an API for safely accessing BMP header fields
Quoted 12 lines · Jeroen Hofstee

Hello Wolfgang,

Quoted 9 lines · Wolfgang Denk

Dear Nikita Kiryanov,

Quoted 4 lines · In message <[email protected]> you wrote:

I did mention that I consider that fix as temporary. I believe this fix is better because it addresses the issue everywhere and does so in a more maintainable way (does not require the address fix to be duplicated everywhere there is a problem).

Can you please explain (again) what exactly you consider the problem?

Quoted 8 lines
Quoted 3 lines

That I can load a BMP image to anodd address, and that this will result in odd results?

If you use eldk 5.3, a board will be bricked if you set the load address to not (an aligned address _+ 2_). So anyone who didn't know the +2 requirement, has a bricked board (and can't recover). So this is really a different then md trapping, since resetting the board won't help... it is broken / kaput.

Agreed totally, by anyone we mean any _user_ that don't even need to care about the bmp header structure and uses the perfectly 32 bit aligned address.

Quoted 3 lines

That said, I am not really in favor of this solution. But I do think it needs to be fixed.

I actually like the approach as it gives an abstraction for:
1) different compilers and their default options,
2) architecture specific "problems" like weather it can deal with unaligned accesses

Signature · 2 lines
Regards,
Igor.