Files
system76-coreboot/src/mainboard/google/kukui/panel_krane.c
Julius Werner 1f84b2c025 drivers/mipi: Make orientation a property of the mainboard, not panel
It doesn't make sense to store the orientation field directly in the
panel information structure, which is supposed to be reuseable between
different boards. The thing that determines orientation is how that
panel is built into the board in question, which only the board itself
can know. The same portrait panel could be rotated left to be used as
landscape in one board and rotated right to be used as landscape in
another. This patch moves the orientation field out of the panel
structure back into the mainboards to reflect this.

Signed-off-by: Julius Werner <jwerner@chromium.org>
Change-Id: If2b716aa4dae036515730c12961fdd8a9ac34753
Reviewed-on: https://review.coreboot.org/c/coreboot/+/57324
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2021-09-02 21:43:11 +00:00

19 lines
597 B
C

/* SPDX-License-Identifier: GPL-2.0-only */
#include "panel.h"
static struct panel_description krane_panels[] = {
[0] = { .name = "AUO_KD101N80_45NA", .orientation = LB_FB_ORIENTATION_LEFT_UP},
/* [1] is only Rev3, can be reused. */
[1] = { .name = "BOE_TV101WUM_NL6", .orientation = LB_FB_ORIENTATION_LEFT_UP},
[11] = { .name = "BOE_TV101WUM_NL6", .orientation = LB_FB_ORIENTATION_LEFT_UP},
};
struct panel_description *get_panel_description(int panel_id)
{
if (panel_id < 0 || panel_id >= ARRAY_SIZE(krane_panels))
return NULL;
return get_panel_from_cbfs(&krane_panels[panel_id]);
}