diff options
-rw-r--r-- | drivers/gpu/drm/nouveau/nouveau_bios.c | 25 |
1 files changed, 8 insertions, 17 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_bios.c b/drivers/gpu/drm/nouveau/nouveau_bios.c index 7b7a18493b46..8314a49b6b9a 100644 --- a/drivers/gpu/drm/nouveau/nouveau_bios.c +++ b/drivers/gpu/drm/nouveau/nouveau_bios.c | |||
@@ -5950,6 +5950,11 @@ apply_dcb_connector_quirks(struct nvbios *bios, int idx) | |||
5950 | } | 5950 | } |
5951 | } | 5951 | } |
5952 | 5952 | ||
5953 | static const u8 hpd_gpio[16] = { | ||
5954 | 0xff, 0x07, 0x08, 0xff, 0xff, 0x51, 0x52, 0xff, | ||
5955 | 0xff, 0xff, 0xff, 0xff, 0xff, 0x5e, 0x5f, 0x60, | ||
5956 | }; | ||
5957 | |||
5953 | static void | 5958 | static void |
5954 | parse_dcb_connector_table(struct nvbios *bios) | 5959 | parse_dcb_connector_table(struct nvbios *bios) |
5955 | { | 5960 | { |
@@ -5986,23 +5991,9 @@ parse_dcb_connector_table(struct nvbios *bios) | |||
5986 | 5991 | ||
5987 | cte->type = (cte->entry & 0x000000ff) >> 0; | 5992 | cte->type = (cte->entry & 0x000000ff) >> 0; |
5988 | cte->index2 = (cte->entry & 0x00000f00) >> 8; | 5993 | cte->index2 = (cte->entry & 0x00000f00) >> 8; |
5989 | switch (cte->entry & 0x00033000) { | 5994 | |
5990 | case 0x00001000: | 5995 | cte->gpio_tag = ffs((cte->entry & 0x07033000) >> 12); |
5991 | cte->gpio_tag = 0x07; | 5996 | cte->gpio_tag = hpd_gpio[cte->gpio_tag]; |
5992 | break; | ||
5993 | case 0x00002000: | ||
5994 | cte->gpio_tag = 0x08; | ||
5995 | break; | ||
5996 | case 0x00010000: | ||
5997 | cte->gpio_tag = 0x51; | ||
5998 | break; | ||
5999 | case 0x00020000: | ||
6000 | cte->gpio_tag = 0x52; | ||
6001 | break; | ||
6002 | default: | ||
6003 | cte->gpio_tag = 0xff; | ||
6004 | break; | ||
6005 | } | ||
6006 | 5997 | ||
6007 | if (cte->type == 0xff) | 5998 | if (cte->type == 0xff) |
6008 | continue; | 5999 | continue; |