Age | Commit message (Collapse) | Author |
|
This code is an adaptation of SMI sample implementation.
CSCVideo is an alternate way to render video, that should reduce memory
bandwidth usage, and uses the color space conversion hardware to render
video directly to the framebuffer memory.
When using randr dual head mode, currently only XAA is supported. As it
has a fixed format framebuffer (when using the Virtual xorg.conf option).
This patch also ensures that pScrn->displayWidth, pScrn->virtualX and
pScrn->virtualY are only changed by the driver when using EXA.
|
|
pSmi->IsSecondary was not used, and there should not exist two
instances of the driver managing the same card.
Macro CHECK_SECONDARY() was dependant on a second instance of the driver
for the same card, and also removed.
Some rework should still be done in the cursor code, as it sometimes,
when displaying different data, will leave the hw cursor visible, while
using an argb cursor.
|
|
Also done some clean up, like removing unused/redundant members of the
screen private structure, and removing now unused configuration file
options.
|
|
WaitQueue() did receive an unused parameter, that was removed. The
parameter was unused since version 1.0 in XFree86 CVS, so probably
nobody knows for what it was used.
WaitIdle() now also replaces WaitIdleEmpty(), as an idle engine
should also have an empty fifo.
SMI_SubsequentScreenToScreenCopy() was changed to use WaitIdle()
instead of WaitQueue() before submitting the commands to the engine.
This fixes a nasty lockup when using XaaOffscreenPixmaps (what is
desired/wanted to help improve performance), and the lockup in the
MSOC was clearly due to an engine overrun, when sending commands
faster then the engine could process.
|
|
The values that should be used, should also have a more meaningful name,
as something like:
doesn't help much, and the fact that these "ports" can be accessed from
several "bases" may be confusing also, as there is SCRBase, DCRBase,
FPRBase, DPRBase, CPRBase (and IOBase). The 501 code should probably be
changed to just use IOBase, as currently it uses SCRBase, that happens
to be at pSmi->MapBase + 0x0000.
This patch also completely transforms the WaitQueue macro in a noop
for the MSOC. In SMI sample code it is almost the current code, just
that the macro body is commented out. Hopefully this will be addressed
soon.
|
|
Instead of cut&paste of the name of the current function everywhere,
just use cpp's __FUNCTION__ predefined macro.
Create two macros to exit a function, named LEAVE() and RETURN().
Functions returning void should call LEAVE() and then explicitly return
for now. "Logged" function calls are indented, so a review was done to
ensure functions with a ENTER() also have the proper exit macro.
The DEBUG macro was changed to have variadic arguments, and this way
it is no longer required to prefix arguments with VERBLEV, but now it
also is not possible to use another "verbosity value", but it wasn't used
in any of the DEBUG macro calls.
|
|
This also adds some simplification for the driver code, by adding
some function pointers to avoid the need to check the chipset everywhere.
The new SMI_DetectMCLK function doesn't actually change pSmi->MCLK to
avoid chances of it stoping working on non MSOC chipsets, as it
previously not did set it, and for the MSOC, for the moment, default to
whatever value is already set, i.e. doesn't reprogram it.
Added new memory detection code for the MSOC, that better matches the
documentation.
|
|
Functions renamed were setDPMS -> SMI501_SetDPMS,
regRead32 -> SMI501_Read32 and regWrite32 -> SMI501_Write32.
Also moved SMI_SetDPMS to start of smi_501.c to have extern
functions at start of the file.
|
|
Currently, the support for EXA is not functional, neither is
ShadowFB or bpp/depth other than 16.
|
|
This should be the biggest patch in the "merge". Done in a single chunk
to have it compilable at all stages.
|
|
* I added the configuration file option "RandRRotation".
* I replaced pSmi->ShadowPitch with pSmi->screenStride, it seems it
makes more sense because the lower word of ShadowPitch may change
independently.
* I moved the SMI_DEDataFormat to smi_accel.c because it seems it is
a piece of code repeated many times in the driver.
* At some places, it is assumed the framebuffer is at FBOffset:
when using a shadow framebuffer, FBOffset is the location of the
on-screen framebuffer (0 should be used). This made e.g. EXA
completly useless with ShadowFB enabled (it crashed).
* In the FBManager initialization, I have replaced xf86InitFBManager
with xf86InitFBManagerRegion to reserve some additional space as
screen fb: it's unlikely to be the case, but a less efficient
alignment in the rotated mode could make the rotated mode need more
memory than the unrotated one.
This is not a problem with EXA as the offscreen memory parameters
can be easily modified when doing the rotation.
* In SMI_RefreshArea it's assumed that some DE registers are already
in some state, this is specially not true when using EXA.
* SMI_ValidMode rejects a rotated mode with different dimensions
than the panel. This seems to work now.
Signed-off-by: Paulo Cesar Pereira de Andrade <pcpa@mandriva.com.br>
|
|
|
|
Based on Dennis' code from bug 8721 with some minor
changes by me.
|
|
|
|
limitations -- I'll improve it a bit at some point)
- small driver clean ups
|
|
|
|
framebuffer formats except cfb and the overlay modes should work, and
r128 and radeon need to be loaded from the ati driver (both issues to
be fixed soon). Tested on i740, s3virge, mach64, tdfx, vesa, and vga
drivers. elfloader users shouldn't be affected.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|