From 9baa6d2f372d3e09280e1103d7bfcf048f6457ec Mon Sep 17 00:00:00 2001 From: Miguel Freitas Date: Mon, 13 Jan 2003 23:36:01 +0000 Subject: big vidix driver update by James Stembridge CVS patchset: 3907 CVS date: 2003/01/13 23:36:01 --- src/video_out/libdha/sysdep/pci_alpha.c | 51 +++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) (limited to 'src/video_out/libdha/sysdep/pci_alpha.c') diff --git a/src/video_out/libdha/sysdep/pci_alpha.c b/src/video_out/libdha/sysdep/pci_alpha.c index e968b3e12..74c3eb687 100644 --- a/src/video_out/libdha/sysdep/pci_alpha.c +++ b/src/video_out/libdha/sysdep/pci_alpha.c @@ -27,3 +27,54 @@ static long pci_config_read_long( return retval; } +static long pci_config_read_word( + unsigned char bus, + unsigned char dev, + int func, + unsigned cmd) +{ + unsigned long retval; + pciconfig_read(bus, dev<<3, cmd, 2, &retval); + return retval; +} + +static long pci_config_read_byte( + unsigned char bus, + unsigned char dev, + int func, + unsigned cmd) +{ + unsigned long retval; + pciconfig_read(bus, dev<<3, cmd, 1, &retval); + return retval; +} + +static void pci_config_write_long( + unsigned char bus, + unsigned char dev, + int func, + unsigned cmd, + long val) +{ + pciconfig_write(bus, dev<<3, cmd, 4, val); +} + +static void pci_config_write_word( + unsigned char bus, + unsigned char dev, + int func, + unsigned cmd, + long val) +{ + pciconfig_write(bus, dev<<3, cmd, 2, val); +} + +static void pci_config_write_byte( + unsigned char bus, + unsigned char dev, + int func, + unsigned cmd, + long val) +{ + pciconfig_write(bus, dev<<3, cmd, 1, val); +} -- cgit v1.2.3