diff options
author | Helge Deller <deller@gmx.de> | 2023-10-27 17:05:23 +0200 |
---|---|---|
committer | Helge Deller <deller@gmx.de> | 2023-10-31 08:26:22 +0100 |
commit | a9e4d73d31cc8751340c80bf4d544c9a9fe8368e (patch) | |
tree | ed2cd177a3c74f04164064994b3b62ad7008a76a /src/parisc | |
parent | d8614d30d159d0be1a119d680a7405564810fb2e (diff) | |
download | seabios-hppa-a9e4d73d31cc8751340c80bf4d544c9a9fe8368e.zip seabios-hppa-a9e4d73d31cc8751340c80bf4d544c9a9fe8368e.tar.gz seabios-hppa-a9e4d73d31cc8751340c80bf4d544c9a9fe8368e.tar.bz2 |
parisc: Fix graphics output to LASI artist card on PA2.0 machines
This fixes the graphics output, but keyboard is still on serial only.
Signed-off-by: Helge Deller <deller@gmx.de>
Diffstat (limited to 'src/parisc')
-rw-r--r-- | src/parisc/b160l.h | 4 | ||||
-rw-r--r-- | src/parisc/c3700.h | 2 | ||||
-rw-r--r-- | src/parisc/parisc.c | 21 |
3 files changed, 12 insertions, 15 deletions
diff --git a/src/parisc/b160l.h b/src/parisc/b160l.h index c90ec9a..b51a46f 100644 --- a/src/parisc/b160l.h +++ b/src/parisc/b160l.h @@ -407,7 +407,7 @@ static struct pdc_iodc iodc_data_hpa_f4000000 = { #define HPA_f8000000_DESCRIPTION "Gecko GSC Core Graphics" static struct pdc_system_map_mod_info mod_info_hpa_f8000000 = { - .mod_addr = 0xf8000000, + .mod_addr = LASI_GFX_HPA, .mod_pgs = 0x2000, .add_addrs = 0x1, }; @@ -602,7 +602,7 @@ static struct pdc_iodc iodc_data_hpa_fff81000 = { .mod_path = &mod_path_hpa_f4000000,\ .num_addr = HPA_f4000000_num_addr,\ .add_addr = { HPA_f4000000_add_addr } },\ - { .hpa = 0xf8000000,\ + { .hpa = LASI_GFX_HPA,\ .iodc = &iodc_data_hpa_f8000000,\ .mod_info = &mod_info_hpa_f8000000,\ .mod_path = &mod_path_hpa_f8000000,\ diff --git a/src/parisc/c3700.h b/src/parisc/c3700.h index 7962747..e322da2 100644 --- a/src/parisc/c3700.h +++ b/src/parisc/c3700.h @@ -270,7 +270,7 @@ static struct pdc_iodc iodc_data_hpa_fed10200 = { .mod_path = &mod_path_hpa_fed10200,\ .num_addr = HPA_fed10200_num_addr,\ .add_addr = { HPA_fed10200_add_addr } },\ - { .hpa = 0xf8000000, /* HACKED IN: Coral GSC graphics */ \ + { .hpa = LASI_GFX_HPA, /* HACKED IN: Coral GSC graphics */ \ .iodc = &iodc_data_hpa_f8000000,\ .mod_info = &mod_info_hpa_f8000000,\ .mod_path = &mod_path_hpa_f8000000,\ diff --git a/src/parisc/parisc.c b/src/parisc/parisc.c index 2be2a16..66aedd7 100644 --- a/src/parisc/parisc.c +++ b/src/parisc/parisc.c @@ -478,14 +478,15 @@ static int HPA_is_keyboard_device(unsigned long hpa) } #endif -int HPA_is_LASI_graphics(unsigned long hpa) +static int artist_present(void) { - hppa_device_t *dev; + return !!(*(u32 *)0xf8380004 == 0x6dc20006); +} - dev = find_hpa_device(hpa); - if (!dev) - return 0; - return (dev->iodc->sversion_model == 0x003b); /* XXX */ +int HPA_is_LASI_graphics(unsigned long hpa) +{ + /* return true if hpa is LASI graphics (artist graphics card) */ + return (hpa == LASI_GFX_HPA) && artist_present(); } #define GFX_NUM_PAGES 0x2000 int HPA_is_graphics_device(unsigned long hpa) @@ -2564,7 +2565,7 @@ static const struct pz_device mem_cons_sti_boot = { .cl_class = CL_DISPL, }; -static const struct pz_device mem_kbd_sti_boot = { +static struct pz_device mem_kbd_sti_boot = { .hpa = LASI_PS2KBD_HPA, .iodc_io = (unsigned long)&iodc_entry, .cl_class = CL_KEYBD, @@ -2630,6 +2631,7 @@ static void find_serial_pci_card(void) pdev->pci_addr = pmem; mem_cons_boot.hpa = pdev->hpa; mem_kbd_boot.hpa = pdev->hpa; + mem_kbd_sti_boot.hpa = pdev->hpa; } /* find SCSI PCI card (to be used as boot device) */ @@ -2690,11 +2692,6 @@ static void prepare_boot_path(volatile struct pz_device *dest, BUG_ON(sizeof(struct pdc_module_path) != 0x20); } -static int artist_present(void) -{ - return !!(*(u32 *)0xf8380004 == 0x6dc20006); -} - unsigned long _atoul(char *str) { unsigned long val = 0; |