64 Commits

Author SHA1 Message Date
Enrico Weigelt, metux IT consult
981597e170 replace obsolete "pointer" typedef by plain void*
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2026-01-05 18:49:31 +01:00
Enrico Weigelt, metux IT consult
d4ae052f5c drop obsolete #ifdef XFree86LOADER
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-18 13:44:33 +01:00
Enrico Weigelt, metux IT consult
9ad20b641d drop #ifdef HAVE_CONFIG_H
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-17 19:44:47 +01:00
Enrico Weigelt, metux IT consult
a20a8cba89 i128_driver: fix wrong const assignment
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-15 16:51:28 +01:00
Enrico Weigelt, metux IT consult
cddfa3e18f drop ancient pre-pciaccess code pathes
The Xserver has moved to libpciaccess for aeons now, so those
old code pathes aren't needed anymore.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-15 16:51:26 +01:00
Alan Coopersmith
4bdc47dd79 Strip trailing whitespace from source files
Performed with: `git ls-files | xargs perl -i -p -e 's{[ \t]+$}{}'`

`git diff -w` & `git diff -b` show no diffs from this change

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Part-of: <https://gitlab.freedesktop.org/xorg/driver/xf86-video-i128/-/merge_requests/11>
2025-12-15 16:33:20 +01:00
Enrico Weigelt, metux IT consult
4fd0309834 drop compat with ancient xservers
Relying on >= 1.18 now, so no need for compat with older ones anymore.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/driver/xf86-video-i128/-/merge_requests/9>
2024-05-28 17:16:26 +02:00
Alan Coopersmith
49f6ef91b0 Raise minimum supported Xserver version to 1.18 (ABI_VIDEODRV_VERSION 20.0)
Already effectively required by use of XNFcallocarray() introduced in
xorg/xserver@b96dc999 - xserver-1.18.0, released in Nov. 2015.

Allows dropping remnants of code for XAA and pre-pciaccess X servers

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Part-of: <https://gitlab.freedesktop.org/xorg/driver/xf86-video-i128/-/merge_requests/8>
2024-05-14 12:15:53 -07:00
Enrico Weigelt, metux IT consult
ed5ffd13ee use XNFcallocarray() instead of xnfcalloc macro
xnfcalloc is just an alias for XNFcallocarray() that doesn't seem to serve
any practical purpose, so it can go away once all drivers stopped using it.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/driver/xf86-video-i128/-/merge_requests/6>
2024-05-08 15:58:39 +02:00
Alan Coopersmith
8fd006f2e1 Fix warning: declaration of ‘from’ shadows a previous local [-Wshadow]
i128_driver.c: In function ‘I128PreInit’:
i128_driver.c:582:13: warning: declaration of ‘from’ shadows a previous local [-Wshadow]
  582 |         int from = X_DEFAULT;
      |             ^~~~
i128_driver.c:440:17: note: shadowed declaration is here
  440 |     MessageType from;
      |                 ^~~~

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2024-01-07 09:46:17 -08:00
Alan Coopersmith
6f3bbdbbee Add X.Org's standard C warning flags to AM_CFLAGS
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2024-01-07 09:41:41 -08:00
Alan Coopersmith
2a0606ca9d Handle -Wempty-body warnings
Repeated for each call of the CACHED_UPDATE macro:

i128exa.c: In function ‘i128SetBufCtrl’:
i128exa.c:66:74: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
         if (CACHE_DEBUG) I128_EXA_DEBUG(("Updated cache for " #reg "\n")); \
                                                                          ^
i128exa.c:89:5: note: in expansion of macro ‘CACHED_UPDATE’
     CACHED_UPDATE(buf_ctrl, BUF_CTRL);
     ^~~~~~~~~~~~~

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2023-04-09 10:28:37 -07:00
Alan Coopersmith
4e5a23aa55 Handle -Wdiscarded-qualifiers warnings
i128_driver.c: In function ‘I128PreInit’:
i128_driver.c:857:18: warning: assignment discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
           ramdac = "TI3025";
                  ^
i128_driver.c:894:18: warning: assignment discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
           ramdac = "IBM526";
                  ^
i128_driver.c:928:18: warning: assignment discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
           ramdac = "IBM528";
                  ^
i128_driver.c:962:18: warning: assignment discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
           ramdac = "SilverHammer";
                  ^

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2023-04-09 10:28:23 -07:00
Alan Coopersmith
fc8f4fd967 Handle -Wunused-const-variable warnings
i128accel.c:95:18: warning: ‘split_size’ defined but not used [-Wunused-const-variable=]
 static const int split_size[] = { 0x20,  0x10,  0x08, 0x00 };
                  ^~~~~~~~~~
i128accel.c:94:18: warning: ‘max_size’ defined but not used [-Wunused-const-variable=]
 static const int max_size[]   = { 0x80,  0x40,  0x20, 0x00 };
                  ^~~~~~~~
i128accel.c:93:18: warning: ‘min_size’ defined but not used [-Wunused-const-variable=]
 static const int min_size[]   = { 0x62,  0x32,  0x1A, 0x00 };
                  ^~~~~~~~
i128accel.c:73:21: warning: ‘i128alu’ defined but not used [-Wunused-const-variable=]
 static const CARD32 i128alu[16] =
                     ^~~~~~~
i128exa.c:450:33: warning: ‘dest_formats’ defined but not used [-Wunused-const-variable=]
 static const struct dest_format dest_formats[] = {
                                 ^~~~~~~~~~~~

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2023-04-09 10:19:46 -07:00
Alan Coopersmith
ce6d6a8b60 Fix spelling/wording issues
Found by using:
    codespell --builtin clear,rare,usage,informal,code,names

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2022-01-22 11:51:33 -08:00
Kevin Brace
a1aa486041 Use const char for xf86GetOptValString return type
Apparently, xf86GetOptValString changed their return type from char
to const char between X Server 1.15 and 1.16. In particular, X Server
commit e1e01d2e33c632e395d7e396f73fba8ae606b15a made the change. This
commit will suppress the compilation warning.

Signed-off-by: Kevin Brace <kevinbrace@gmx.com>
2018-12-07 15:07:44 -08:00
Laurent Carlier
b532708b75 Stop using deprecated xf86PciInfo.h
v2: Remove empty lines
Signed-off-by: Laurent Carlier <lordheavym@gmail.com>
Reviewed-by: Connor Behan <connor.behan@gmail.com>
2018-12-06 21:06:42 -08:00
Adam Jackson
c87753733a Remove mibstore.h
Signed-off-by: Adam Jackson <ajax@redhat.com>
2012-09-25 08:54:40 -04:00
Adam Jackson
3226d66c95 Don't bother to include vbe.h
Just copied from xf86 boilerplate afaict.

Signed-off-by: Adam Jackson <ajax@redhat.com>
2012-08-15 13:03:11 -04:00
Dave Airlie
c829ff7002 i128: build against xaa-less server.
Signed-off-by: Dave Airlie <airlied@redhat.com>
2012-07-16 18:23:39 +10:00
Dave Airlie
659390ecdb i128: convert to compat API.
convert i128 to new compat API.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2012-06-06 12:44:53 +01:00
Adam Jackson
3b23ca1d03 Fix for new vgaHW ABI
Signed-off-by: Adam Jackson <ajax@redhat.com>
2011-12-19 17:48:13 -05:00
Adam Jackson
0a46285e07 Make failure to XAA non-fatal
No shadowfb support in this driver yet.

Signed-off-by: Adam Jackson <ajax@redhat.com>
2011-12-19 16:29:49 -05:00
Jeremy Huddleston
0e357623bc Build fix for ABI Version 12
ABI Version 12 removes support for multiple PCI domains.  If you need to
use this driver on a system with more than one PCI domain, you should
either port this driver to using libpciaccess directly or stick with an
older server.

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2011-10-19 00:24:00 -07:00
Jeremy Huddleston
c3eb2c3f05 Use unsigned long rather than deprecated IOADDRESS
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2011-10-19 00:23:12 -07:00
Jeremy Huddleston
f5c6593c93 Use malloc/calloc/realloc/free directly
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2011-10-19 00:22:09 -07:00
Adam Jackson
6fb5733ca0 Don't mess with the blender unit on chips that don't have it
Where your typical x86 machine silently ignores writes to non-existing
registers, UltraSPARC machines generate a bus error.  So we shouldn't
write to the alpha blender setup register on the Imagine 1 and Imagine 2
that don't seem to have the blender unit.

Reviewed-by: Adam Jackson <ajax@redhat.com>
Signed-off-by: Mark Kettenis <mark.kettenis@xs4all.nl>
2009-11-12 09:50:58 -05:00
Mark Kettenis
cc0682924e Use hardware byteswap on big-endian platforms
Fixes 16 and 32 bit-per-pixel modes with a Tech Source Raptor GFX-8M
board on OpenBSD/sparc64

Signed-off-by: Adam Jackson <ajax@redhat.com>
2009-11-02 11:09:03 -05:00
Gaetan Nadon
5b60ef6cbc xf86-video-i128: Remove unused .cvsignore file #23776
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-09-08 10:42:11 +10:00
Dave Airlie
6a5098d0f2 i128: change to using ABI version check 2009-07-28 15:22:40 +10:00
Dave Airlie
ec37c2ec02 i128: update for resources/RAC API removal 2009-07-28 13:32:30 +10:00
Mark Kettenis
b690e9f84e Fix endianness bugs in cursor realization code.
The default cursor realization code seems to work just fine.  We just
have to set the HARDWARE_CURSOR_NIBBLE_SWAPPED flag on big endian
platforms.

This isn't really surprising since these cards use fairly standard IBM
or TI RAMDACs.

Signed-off-by: Matthieu Herrb <matthieu.herrb@laas.fr>
2009-06-04 11:46:18 -06:00
Adam Jackson
f42dd67d93 Remove useless loader symbol lists. 2009-05-28 14:59:53 -04:00
Mark Kettenis
cee4cdf061 Properly unmap things with libpciaccess.
If the xf86-vide-i128 is compiled with XSERVER_LIBPCIACCESS, registers and
frmaebuffer memory are mapped through libpciaccess.  However, I128UnmapMem
tried to unmap things vy using xf86UnmapVidMem.  This failed because the memory
wasn't registered (which only happens if you mapped the memory using
xf86MapPciMem.

Fixes bugzilla #20541

Signed-off-by: Matthieu Herrb <matthieu.herrb@laas.fr>
2009-05-04 21:57:20 +02:00
Thomas Jaeger
8bd4dc99bb CheckComposite: Add a few checks
It looks like the driver doesn't support any form of repeating and only
nearest-neighbor interpolation.
2009-03-06 12:54:17 -08:00
Adam Jackson
ab11b4bd9e Don't store pScrn->monitor->DDC manually, let xf86SetDDCproperties do it. 2008-08-15 15:30:19 -04:00
Paulo Cesar Pereira de Andrade
3b1d9fe869 Replace calls to xf86usleep with calls to usleep and include unistd.h. 2008-03-20 14:41:52 -04:00
Paulo Cesar Pereira de Andrade
6327ba52ba Compile warning fixes.
The casts for printf format are really required to pass
proper arguments, as pciaddr_t is a 64 bit integer.
2008-03-20 14:41:40 -04:00
Adam Jackson
560fc83e29 Fix distcheck 2008-03-19 14:15:14 -04:00
Adam Jackson
a85f46b433 Death to RCS tags. 2008-03-19 14:12:45 -04:00
Dave Airlie
64987900b7 i128: fixup typo 2008-02-29 16:00:53 +10:00
Dave Airlie
7273b0f586 i128: drop ansi C wrapper 2008-02-27 13:45:31 +10:00
Dave Airlie
8c8779a65f i128: pciaccess conversion 2008-02-27 13:18:57 +10:00
Brice Goglin
6b837746d1 Define I128_*_VERSION* using PACKAGE_VERSION_* 2007-08-07 11:26:28 +02:00
Adam Jackson
f9996f11e9 Fix version number to 1.2.1 2006-12-01 17:32:11 -05:00
Eric Anholt
14062aa41f Don't forget to zero the xf86ModReqInfo before using it. Noticed by Alex
Deucher.
2006-04-07 04:15:34 +00:00
Eric Anholt
daf6a54ec8 Update drivers that support EXA for the new EXA ABI. This consists of
moving all the accel and card members into the driver ptr, filling in
    the exa_major/ exa_minor fields, and always using LoadSubModule so we
    can check the module version up front. Only tested on ATI.
2006-03-09 06:06:25 +00:00
Eric Anholt
3e173f114c Add .cvsignores for drivers. 2005-11-21 10:49:14 +00:00
Adam Jackson
5368b5439c Build system fixes for EXA support; reflect the 1.1 bump. 2005-09-11 21:52:37 +00:00
Adam Jackson
3e6793ec11 Bump driver version to 1.1.0 for EXA support. 2005-09-11 21:51:46 +00:00