Repository navigation
ARM: apple: Drive every 32-bit board's screen with simpledrm - #110
Merged
Merged
Conversation
…pledrm Build simpledrm in and drop simplefb, as the 64-bit boards do. FB_SIMPLE depends on !DRM_SIMPLEDRM, so the two cannot both be built. simpledrm binds the same simple-framebuffer node, from its memory-region, and its fbdev emulation (DRM_FBDEV_EMULATION, on by default with FB) still gives fbcon a framebuffer, /dev/fb0, so the boot console keeps showing. With simpledrm the iPad 3's scanout is presented upright by the driver (the framebuffer node's rotation = <90>), and fbcon draws on that upright framebuffer: drop fbcon=rotate:1 from the iPad 3 command line, or the console would be turned twice. earlycon=j1fb still stops drawing once a framebuffer is registered, now simpledrm's. Assisted-by: LLM Signed-off-by: Henrik Klee <henrik@goat-code.com>
The iPad 4 has the iPad 3's 2048 x 1536 panel behind the same eDP block (its ADT's edp node is "edp,s5l8955x", "edp,s5l8945x"). The iPad 3's iBoot scans it out landscape and simpledrm presents it portrait with rotation = <90>; set the same on the A6X's framebuffer node, so the iPad 4 comes up upright as well. Assisted-by: LLM Signed-off-by: Henrik Klee <henrik@goat-code.com>
Comments that named simplefb now name simpledrm. The K93's framebuffer node says why it has no rotation: its desktop is the landscape screen, and its touch and motion sensors are described in that screen's axes. apple-sgx's fbcon acceleration (debugfs "fbcon", fbcon_gpu, off by default) drew fbcon's fills and copies straight into the boot framebuffer, which simplefb's fbdev was. simpledrm's fbdev draws into a shadow in system memory instead; the hook already refused it (smem_start differs), and now says so in the log. Assisted-by: LLM Signed-off-by: Henrik Klee <henrik@goat-code.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Every 32-bit board now shows its screen through simpledrm, as the 64-bit boards do, instead of the old simplefb driver. For the iPad 3 this turns on the upright desktop from #103: simpledrm turns iBoot's sideways scanout as it copies it, so the console and the desktop both come up in portrait.
What each board family gets
rotation = <90>(from #103).fbcon=rotate:1is dropped from the command line, or the console would be turned twicerotation = <90>. The iPad 4 has the iPad 3's panel and the same eDP block (its Apple device tree calls it "edp,s5l8945x" too). Not booted yet: if iBoot hands over a portrait size there, this is the one line to dropOn every board the boot console still shows: simpledrm's fbdev emulation gives fbcon
/dev/fb0(DRM_FBDEV_EMULATION and FRAMEBUFFER_CONSOLE stay on by default with FB=y). Every framebuffer node already has thesimple-framebuffercompatible, amemory-regionand width/height/stride/format. m1n1's 32-bit kboot (src/arm32/a32_kboot.c) writes the reservation and reg, width, height and stride from iBoot's boot arguments, keeps the format, and leavesrotationalone. So the nodes it hands over work with simpledrm, and simpledrm maps the memory region write-combined.Things only the 32-bit path got from simplefb, and what happens to them now
earlycon=j1fb, orchard#79): it stops drawing as soon as any framebuffer is registered, now simpledrm's, and hands the panel to fbcon. That works the same way; only its comments change.fbcon_gpu, off by default): it drew straight into the scanout that simplefb's fbdev used. simpledrm's fbdev draws into a shadow buffer in system memory, so the hook does not attach (it already checkedsmem_start) and now logs why. fbcon draws with the CPU, as it does by default anyway.Half-size presentation (
simpledrm.zoom)It is not turned on anywhere. It only works on a turned scanout, so the boards that could set it are the iPad 3 and the iPad 4:
simpledrm.zoom=2on the command line presents their desktop at 768 x 1024, with a quarter of the pixels to draw without the GPU. Comments in the shared iPad 3 and A6X files say so.Config
orchard_applearmv7_defconfig:DRM_SIMPLEDRM=yandFB_SIMPLEdropped (the two cannot both be built). Expanded withmake orchard_applearmv7_defconfig, the config differs from orchard's current one in exactly those two lines.Not booted: device trees compiled with dtc for all ten boards. CI builds the kernel.