1. 23 Mar, 2017 1 commit
  2. 12 Jan, 2014 1 commit
  3. 11 Jul, 2012 1 commit
    • Maarten Lankhorst's avatar
      xfree86: Strip dangling pointers from desiredMode · deb08658
      Maarten Lankhorst authored
      Based on the original patch by Chris Wilson, which was a better fix than mine.
      
      We stash a copy of the desiredMode on the crtc so that we can restore it
      after a vt switch. This copy is a simple memcpy and so also stashes a
      references to the pointers contained within the desiredMode. Those
      pointers are freed the next time the outputs are probed and mode list
      rebuilt, resulting in us chasing those dangling pointers on the next
      mode switch.
      
      ==22787== Invalid read of size 1
      ==22787==    at 0x40293C2: __GI_strlen (in
      /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
      ==22787==    by 0x668F875: strdup (strdup.c:42)
      ==22787==    by 0x5DBA00: XNFstrdup (utils.c:1124)
      ==22787==    by 0x4D72ED: xf86DuplicateMode (xf86Modes.c:209)
      ==22787==    by 0x4CA848: xf86CrtcSetModeTransform (xf86Crtc.c:276)
      ==22787==    by 0x4D05B4: xf86SetDesiredModes (xf86Crtc.c:2677)
      ==22787==    by 0xA7479D0: sna_create_screen_resources
      (sna_driver.c:220)
      ==22787==    by 0x4CB914: xf86CrtcCreateScreenResources (xf86Crtc.c:725)
      ==22787==    by 0x425498: main (main.c:216)
      ==22787==  Address 0x72c60e0 is 0 bytes inside a block of size 9 free'd
      ==22787==    at 0x4027AAE: free (in
      /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
      ==22787==    by 0x4A547E: xf86DeleteMode (xf86Mode.c:1984)
      ==22787==    by 0x4CD84F: xf86ProbeOutputModes (xf86Crtc.c:1578)
      ==22787==    by 0x4DC405: xf86RandR12GetInfo12 (xf86RandR12.c:1537)
      ==22787==    by 0x518119: RRGetInfo (rrinfo.c:202)
      ==22787==    by 0x51D997: rrGetScreenResources (rrscreen.c:335)
      ==22787==    by 0x51E0D0: ProcRRGetScreenResources (rrscreen.c:475)
      ==22787==    by 0x513852: ProcRRDispatch (randr.c:493)
      ==22787==    by 0x4346DB: Dispatch (dispatch.c:439)
      ==22787==    by 0x4256E4: main (main.c:287)
      Signed-off-by: default avatarMaarten Lankhorst <maarten.lankhorst@canonical.com>
      Reported-by: zkabelac's avatarZdenek Kabelac <zdenek.kabelac@gmail.com>
      Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=36108Reviewed-by: Chris Wilson's avatarChris Wilson <chris@chris-wilson.co.uk>
      Signed-off-by: Keith Packard's avatarKeith Packard <keithp@keithp.com>
      deb08658
  4. 21 Mar, 2012 1 commit
    • Keith Packard's avatar
      Introduce a consistent coding style · 9838b703
      Keith Packard authored
      This is strictly the application of the script 'x-indent-all.sh'
      from util/modular. Compared to the patch that Daniel posted in
      January, I've added a few indent flags:
      
      	-bap
      	-psl
      	-T PrivatePtr
      	-T pmWait
      	-T _XFUNCPROTOBEGIN
      	-T _XFUNCPROTOEND
      	-T _X_EXPORT
      
      The typedefs were needed to make the output of sdksyms.sh match the
      previous output, otherwise, the code is formatted badly enough that
      sdksyms.sh generates incorrect output.
      
      The generated code was compared with the previous version and found to
      be essentially identical -- "assert" line numbers and BUILD_TIME were
      the only differences found.
      
      The comparison was done with this script:
      
      dir1=$1
      dir2=$2
      
      for dir in $dir1 $dir2; do
      	(cd $dir && find . -name '*.o' | while read file; do
      		dir=`dirname $file`
      		base=`basename $file .o`
      		dump=$dir/$base.dump
      		objdump -d $file > $dump
      	done)
      done
      
      find $dir1 -name '*.dump' | while read dump; do
      	otherdump=`echo $dump | sed "s;$dir1;$dir2;"`
      	diff -u $dump $otherdump
      done
      Signed-off-by: Keith Packard's avatarKeith Packard <keithp@keithp.com>
      Acked-by: Daniel Stone's avatarDaniel Stone <daniel@fooishbar.org>
      Acked-by: Alan Coopersmith's avatarAlan Coopersmith <alan.coopersmith@oracle.com>
      9838b703
  5. 23 Nov, 2011 1 commit
  6. 21 Sep, 2011 1 commit
  7. 27 Dec, 2010 1 commit
  8. 07 Dec, 2010 1 commit
  9. 18 Sep, 2010 1 commit
    • Jamey Sharp's avatar
      Xserver need not be compatible with old versions of xserver. · e4d4d6dd
      Jamey Sharp authored
      Delete time-traveling multiple personality disorder from the server.
      
      Gaetan notes:
      
          There were a couple of drivers containing an unknown version of the
          modes/parser code. This was done in server 1.2 time frame because it
          was released without mode code. It was barely or not maintained
          afterwards. There are currently no video drivers with a copy of the
          modes code.
      
      Most of these ifdefs were introduced in commit
      a8d760f5, where Aaron wrote,
      
          This change uses XORG_VERSION_CURRENT < 7.0 to mean "server newer
          than 1.2" since XORG_VERSION current went backwards at some point.
      
      Alan explains that:
      
          In Xorg 1.3, when we first released an Xorg server release decoupled
          from the katamari release schedule.  (1.0 through 1.2 were released
          as part of X11R7.0 through 7.2, while 1.3 came out between X11R7.2 &
          7.3.)
      
      Commit by Jamey Sharp and Josh Triplett.
      Signed-off-by: Jamey Sharp's avatarJamey Sharp <jamey@minilop.net>
      Signed-off-by: Josh Triplett's avatarJosh Triplett <josh@joshtriplett.org>
      Reviewed-by: Aaron Plattner's avatarAaron Plattner <aplattner@nvidia.com>
      e4d4d6dd
  10. 12 May, 2010 1 commit
  11. 29 Oct, 2009 2 commits
  12. 17 Jul, 2009 2 commits
  13. 14 Jul, 2009 1 commit
  14. 13 Feb, 2009 1 commit
  15. 03 Dec, 2008 1 commit
    • Paulo Cesar Pereira de Andrade's avatar
      Rework symbol visibility for easier maintenance · 49f77fff
      Paulo Cesar Pereira de Andrade authored
        Save in a few special cases, _X_EXPORT should not be used in C source
      files. Instead, it should be used in headers, and the proper C source
      include that header. Some special cases are symbols that need to be
      shared between modules, but not expected to be used by external drivers,
      and symbols that are accessible via LoaderSymbol/dlopen.
      
        This patch also adds conditionally some new sdk header files, depending
      on extensions enabled. These files were added to match pattern for
      other extensions/modules, that is, have the headers "deciding" symbol
      visibility in the sdk. These headers are:
      o Xext/panoramiXsrv.h, Xext/panoramiX.h
      o fbpict.h (unconditionally)
      o vidmodeproc.h
      o mioverlay.h (unconditionally, used only by xaa)
      o xfixes.h (unconditionally, symbols required by dri2)
      
        LoaderSymbol and similar functions now don't have different prototypes,
      in loaderProcs.h and xf86Module.h, so that both headers can be included,
      without the need of defining IN_LOADER.
      
        xf86NewInputDevice() device prototype readded to xf86Xinput.h, but
      not exported (and with a comment about it).
      49f77fff
  16. 30 Nov, 2008 1 commit
    • Paulo Cesar Pereira de Andrade's avatar
      Export symbols defined in the sdk. · d6cbd451
      Paulo Cesar Pereira de Andrade authored
        This is the biggest "visibility" patch. Instead of doing a "export"
      symbol on demand, export everything in the sdk, so that if some module
      fails due to an unresolved symbol, it is because it is using a symbol
      not in the sdk.
      
        Most exported symbols shouldn't really be made visible, neither
      advertised in the sdk, as they are only used by a single shared object.
      
        Symbols in the sdk (or referenced in sdk macros), but not defined
      anywhere include:
      XkbBuildCoreState()
      XkbInitialMap
      XkbXIUnsupported
      XkbCheckActionVMods()
      XkbSendCompatNotify()
      XkbDDXFakePointerButton()
      XkbDDXApplyConfig()
      _XkbStrCaseCmp()
      _XkbErrMessages[]
      _XkbErrCode
      _XkbErrLocation
      _XkbErrData
      XkbAccessXDetailText()
      XkbNKNDetailMaskText()
      XkbLookupGroupAndLevel()
      XkbInitAtoms()
      XkbGetOrderedDrawables()
      XkbFreeOrderedDrawables()
      XkbConvertXkbComponents()
      XkbWriteXKBSemantics()
      XkbWriteXKBLayout()
      XkbWriteXKBKeymap()
      XkbWriteXKBFile()
      XkbWriteCFile()
      XkbWriteXKMFile()
      XkbWriteToServer()
      XkbMergeFile()
      XkmFindTOCEntry()
      XkmReadFileSection()
      XkmReadFileSectionName()
      InitExtInput()
      xf86CheckButton()
      xf86SwitchCoreDevice()
      RamDacSetGamma()
      RamDacRestoreDACValues()
      xf86Bpp
      xf86ConfigPix24
      xf86MouseCflags[]
      xf86SupportedMouseTypes[]
      xf86NumMouseTypes
      xf86ChangeBusIndex()
      xf86EntityEnter()
      xf86EntityLeave()
      xf86WrapperInit()
      xf86RingBell()
      xf86findOptionBoolean()
      xf86debugListOptions()
      LoadSubModuleLocal()
      LoaderSymbolLocal()
      getInt10Rec()
      xf86CurrentScreen
      xf86ReallocatePciResources()
      xf86NewSerialNumber()
      xf86RandRSetInitialMode()
      fbCompositeSolidMask_nx1xn
      fbCompositeSolidMask_nx8888x0565C
      fbCompositeSolidMask_nx8888x8888C
      fbCompositeSolidMask_nx8x0565
      fbCompositeSolidMask_nx8x0888
      fbCompositeSolidMask_nx8x8888
      fbCompositeSrc_0565x0565
      fbCompositeSrc_8888x0565
      fbCompositeSrc_8888x0888
      fbCompositeSrc_8888x8888
      fbCompositeSrcAdd_1000x1000
      fbCompositeSrcAdd_8000x8000
      fbCompositeSrcAdd_8888x8888
      fbGeneration
      fbIn
      fbOver
      fbOver24
      fbOverlayGeneration
      fbRasterizeEdges
      fbRestoreAreas
      fbSaveAreas
      composeFunctions
      VBEBuildVbeModeList()
      VBECalcVbeModeIndex()
      TIramdac3030CalculateMNPForClock()
      shadowBufPtr
      shadowFindBuf()
      miRRGetScreenInfo()
      RRSetScreenConfig()
      RRModePruneUnused()
      PixmanImageFromPicture()
      extern int miPointerGetMotionEvents()
      miClipPicture()
      miRasterizeTriangle()
      fbPush1toN()
      fbInitializeBackingStore()
      ddxBeforeReset()
      SetupSprite()
      InitSprite()
      DGADeliverEvent()
      
        SPECIAL CASES
      o defined as _X_INTERNAL
      	xf86NewInputDevice()
      o defined as static
      	fbGCPrivateKey
      	fbOverlayScreenPrivateKey
      	fbScreenPrivateKey
      	fbWinPrivateKey
      o defined in libXfont.so, but declared in xorg/dixfont.h
      	GetGlyphs()
      	QueryGlyphExtents()
      	QueryTextExtents()
      	ParseGlyphCachingMode()
      	InitGlyphCaching()
      	SetGlyphCachingMode()
      d6cbd451
  17. 25 Nov, 2008 1 commit
    • Alan Coopersmith's avatar
      Fix const-mismatch warnings for DisplayModePtr's · d5f9a131
      Alan Coopersmith authored
      Includes fixes for:
      "xf86Config.c", line 2434: warning: argument #1 is incompatible with prototype:
      	prototype: pointer to struct _DisplayModeRec: "xf86.h", line 351
      	argument : pointer to const struct _DisplayModeRec
      
      "xf86EdidModes.c", line 312: warning: argument #1 is incompatible with prototype:
      	prototype: pointer to struct _DisplayModeRec: "../../../hw/xfree86/common/xf86.h", line 351
      	argument : pointer to const struct _DisplayModeRec
      
      "xf86EdidModes.c", line 438: warning: assignment type mismatch:
      	pointer to struct _DisplayModeRec "=" pointer to const struct _DisplayModeRec
      
      "xf86Modes.c", line 701: warning: assignment type mismatch:
      	pointer to struct _DisplayModeRec "=" pointer to const struct _DisplayModeRec
      d5f9a131
  18. 21 Jul, 2008 1 commit
    • Adam Jackson's avatar
      EDID: Various reduced blanking fixes. · 8c8c4fdf
      Adam Jackson authored
      - Use a single common function to compute reducedness.
      - Call it from both the old-school and new-school mode validation paths.
      - Define monitor reduced-blanking support in accord with EDID 1.4.
      - Attempt to filter RB DMT modes away from the "standard" EDID pool if
        the monitor doesn't claim RB support.
      8c8c4fdf
  19. 04 Jul, 2008 1 commit
  20. 19 May, 2008 1 commit
    • Adam Jackson's avatar
      Fix reduced-blanking mode filtering in RANDR 1.2. · 0178b6a4
      Adam Jackson authored
      If the monitor isn't reduced-blanking (either through EDID logic, or
      config file setting), then remove RB modes from the default pool.  Any
      RB modes from the driver and config file pools will stick around though;
      you asked for them, you got them.
      0178b6a4
  21. 07 Mar, 2008 1 commit
    • Adam Jackson's avatar
      Size xf86DefaultModes explicitly. · 3bf7ff70
      Adam Jackson authored
      i.e., don't check for the end of the list by ->name == NULL, since that
      won't work now.  Fix the consumers of xf86DefaultModes to use the new
      explicit size as well.
      3bf7ff70
  22. 06 Mar, 2008 1 commit
  23. 01 Mar, 2008 1 commit
  24. 29 Feb, 2008 1 commit
    • Adam Jackson's avatar
      Allow xf86DuplicateMode() to work correctly on read-only modes. · fd41f46a
      Adam Jackson authored
      Before this it was meaningless to try to mark DisplayModeRec tables
      const, since the mode name would be emitted as a pointer to an
      anonymous string constant, and therefore would have to be fixed up by
      ld.so and so couldn't live in .rodata.  With this change the standard
      mode lists can live in .rodata, and modes duplicated from them will
      have their names filled in on the fly.
      fd41f46a
  25. 13 Dec, 2007 3 commits
  26. 02 Nov, 2007 1 commit
  27. 11 Oct, 2007 1 commit
  28. 22 Aug, 2007 1 commit
  29. 29 Jun, 2007 1 commit
  30. 17 Feb, 2007 2 commits
    • Keith Packard's avatar
      Ensure drivers can use new modes header files. · 096965ec
      Keith Packard authored
      New modes header files required a few minor changes to be used by external
      drivers, the most notable of which is the publication of the config file
      parser header files.
      096965ec
    • Keith Packard's avatar
      Enable startup-time rotation; change rotation pixmap creation API. · e4507825
      Keith Packard authored
      Add monitor "Rotate" option taking one of "normal", "left", "inverted" or
      "right". However, because initial mode selection is made before the screen
      is completely initialized, we cannot create the shadow pixmap object at this
      point. Pend the shadow pixmap creation until the block handler.
      
      Note that this code is not completely functional yet.
      e4507825
  31. 16 Feb, 2007 2 commits