1. 04 8月, 2010 1 次提交
  2. 21 5月, 2010 1 次提交
  3. 18 5月, 2010 1 次提交
  4. 20 4月, 2010 2 次提交
  5. 08 4月, 2010 1 次提交
  6. 06 4月, 2010 1 次提交
  7. 30 3月, 2010 1 次提交
    • T
      include cleanup: Update gfp.h and slab.h includes to prepare for breaking... · 5a0e3ad6
      Tejun Heo 提交于
      include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h
      
      percpu.h is included by sched.h and module.h and thus ends up being
      included when building most .c files.  percpu.h includes slab.h which
      in turn includes gfp.h making everything defined by the two files
      universally available and complicating inclusion dependencies.
      
      percpu.h -> slab.h dependency is about to be removed.  Prepare for
      this change by updating users of gfp and slab facilities include those
      headers directly instead of assuming availability.  As this conversion
      needs to touch large number of source files, the following script is
      used as the basis of conversion.
      
        http://userweb.kernel.org/~tj/misc/slabh-sweep.py
      
      The script does the followings.
      
      * Scan files for gfp and slab usages and update includes such that
        only the necessary includes are there.  ie. if only gfp is used,
        gfp.h, if slab is used, slab.h.
      
      * When the script inserts a new include, it looks at the include
        blocks and try to put the new include such that its order conforms
        to its surrounding.  It's put in the include block which contains
        core kernel includes, in the same order that the rest are ordered -
        alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
        doesn't seem to be any matching order.
      
      * If the script can't find a place to put a new include (mostly
        because the file doesn't have fitting include block), it prints out
        an error message indicating which .h file needs to be added to the
        file.
      
      The conversion was done in the following steps.
      
      1. The initial automatic conversion of all .c files updated slightly
         over 4000 files, deleting around 700 includes and adding ~480 gfp.h
         and ~3000 slab.h inclusions.  The script emitted errors for ~400
         files.
      
      2. Each error was manually checked.  Some didn't need the inclusion,
         some needed manual addition while adding it to implementation .h or
         embedding .c file was more appropriate for others.  This step added
         inclusions to around 150 files.
      
      3. The script was run again and the output was compared to the edits
         from #2 to make sure no file was left behind.
      
      4. Several build tests were done and a couple of problems were fixed.
         e.g. lib/decompress_*.c used malloc/free() wrappers around slab
         APIs requiring slab.h to be added manually.
      
      5. The script was run on all .h files but without automatically
         editing them as sprinkling gfp.h and slab.h inclusions around .h
         files could easily lead to inclusion dependency hell.  Most gfp.h
         inclusion directives were ignored as stuff from gfp.h was usually
         wildly available and often used in preprocessor macros.  Each
         slab.h inclusion directive was examined and added manually as
         necessary.
      
      6. percpu.h was updated not to include slab.h.
      
      7. Build test were done on the following configurations and failures
         were fixed.  CONFIG_GCOV_KERNEL was turned off for all tests (as my
         distributed build env didn't work with gcov compiles) and a few
         more options had to be turned off depending on archs to make things
         build (like ipr on powerpc/64 which failed due to missing writeq).
      
         * x86 and x86_64 UP and SMP allmodconfig and a custom test config.
         * powerpc and powerpc64 SMP allmodconfig
         * sparc and sparc64 SMP allmodconfig
         * ia64 SMP allmodconfig
         * s390 SMP allmodconfig
         * alpha SMP allmodconfig
         * um on x86_64 SMP allmodconfig
      
      8. percpu.h modifications were reverted so that it could be applied as
         a separate patch and serve as bisection point.
      
      Given the fact that I had only a couple of failures from tests on step
      6, I'm fairly confident about the coverage of this conversion patch.
      If there is a breakage, it's likely to be something in one of the arch
      headers which should be easily discoverable easily on most builds of
      the specific arch.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Guess-its-ok-by: NChristoph Lameter <cl@linux-foundation.org>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
      5a0e3ad6
  8. 18 2月, 2010 1 次提交
    • J
      drm/radeon/kms: simplify memory controller setup V2 · d594e46a
      Jerome Glisse 提交于
      Get rid of _location and use _start/_end also simplify the
      computation of vram_start|end & gtt_start|end. For R1XX-R2XX
      we place VRAM at the same address of PCI aperture, those GPU
      shouldn't have much memory and seems to behave better when
      setup that way. For R3XX and newer we place VRAM at 0. For
      R6XX-R7XX AGP we place VRAM before or after AGP aperture this
      might limit to limit the VRAM size but it's very unlikely.
      For IGP we don't change the VRAM placement.
      
      Tested on (compiz,quake3,suspend/resume):
      PCI/PCIE:RV280,R420,RV515,RV570,RV610,RV710
      AGP:RV100,RV280,R420,RV350,RV620(RPB*),RV730
      IGP:RS480(RPB*),RS690,RS780(RPB*),RS880
      
      RPB: resume previously broken
      
      V2 correct commit message to reflect more accurately the bug
      and move VRAM placement to 0 for most of the GPU to avoid
      limiting VRAM.
      Signed-off-by: NJerome Glisse <jglisse@redhat.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      d594e46a
  9. 13 1月, 2010 1 次提交
  10. 23 12月, 2009 1 次提交
  11. 16 12月, 2009 1 次提交
  12. 10 12月, 2009 2 次提交
  13. 04 12月, 2009 1 次提交
  14. 02 12月, 2009 1 次提交
    • J
      drm/radeon/kms: Rework radeon object handling · 4c788679
      Jerome Glisse 提交于
      The locking & protection of radeon object was somewhat messy.
      This patch completely rework it to now use ttm reserve as a
      protection for the radeon object structure member. It also
      shrink down the various radeon object structure by removing
      field which were redondant with the ttm information. Last it
      converts few simple functions to inline which should with
      performances.
      
      airlied: rebase on top of r600 and other changes.
      Signed-off-by: NJerome Glisse <jglisse@redhat.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      4c788679
  15. 04 11月, 2009 1 次提交
    • D
      drm/radeon/kms: fix coherency issues on AGP cards. · df67bed9
      Dave Airlie 提交于
      When we are evicting from VRAM->RAM we allocate the ttm object,
      but we don't set the caching policy on it before blitting into it.
      This means on AGP we end up blitting into cached pages, and
      the CPU later flushes out on top of them. This was mostly seen as
      font corruption.
      
      The other question is why we don't evict VRAM->GTT in a lot of cases,
      this would save us some cache transitions since a lot of objects
      that are evicted from VRAM will probably end up being pulled back in
      a few operations later, and evicting them to system memory involves
      2 unnecessary cache transitions.
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      df67bed9
  16. 29 9月, 2009 1 次提交
    • M
      drm: fix radeon DRM warnings when !CONFIG_DEBUG_FS · f4e45d02
      Mikael Pettersson 提交于
      Compiling the radeon DRM driver with !CONFIG_DEBUG_FS
      throws the following warnings:
      
      drivers/gpu/drm/radeon/radeon_ttm.c: In function 'radeon_ttm_debugfs_init':
      drivers/gpu/drm/radeon/radeon_ttm.c:714: warning: unused variable 'i'
      drivers/gpu/drm/radeon/radeon_ttm.c: At top level:
      drivers/gpu/drm/radeon/radeon_ttm.c:692: warning: 'radeon_mem_types_list' defined but not used
      drivers/gpu/drm/radeon/radeon_ttm.c:693: warning: 'radeon_mem_types_names' defined but not used
      
      Fix: move these variables inside the #if defined(CONFIG_DEBUG_FS)
      block in radeon_ttm_debugsfs_init(), which is the only place using them.
      Signed-off-by: NMikael Pettersson <mikpe@it.uu.se>
      Signed-off-by: NDave Airlie <airlied@linux.ie>
      f4e45d02
  17. 28 9月, 2009 1 次提交
  18. 08 9月, 2009 1 次提交
    • J
      drm/radeon/kms: add r600 KMS support · 3ce0a23d
      Jerome Glisse 提交于
      This adds the r600 KMS + CS support to the Linux kernel.
      
      The r600 TTM support is quite basic and still needs more
      work esp around using interrupts, but the polled fencing
      should work okay for now.
      
      Also currently TTM is using memcpy to do VRAM moves,
      the code is here to use a 3D blit to do this, but
      isn't fully debugged yet.
      
      Authors:
      Alex Deucher <alexdeucher@gmail.com>
      Dave Airlie <airlied@redhat.com>
      Jerome Glisse <jglisse@redhat.com>
      Signed-off-by: NJerome Glisse <jglisse@redhat.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      3ce0a23d
  19. 02 9月, 2009 1 次提交
  20. 20 8月, 2009 1 次提交
  21. 19 8月, 2009 1 次提交
  22. 29 7月, 2009 3 次提交
    • D
      drm/radeon/kms: vram sizing on certain r100 chips needs workaround. · 7a50f01a
      Dave Airlie 提交于
      If an rn50/r100/m6/m7 GPU has < 64MB RAM, i.e. 8/16/32, the
      aperture used to calculate the MC_FB_LOCATION needs to be worked
      out from the CONFIG_APER_SIZE register, and not the actual vram size.
      
      TTM VRAM size was also being initialised wrong, use actual vram size
      to initialise it.
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      7a50f01a
    • M
      drm/radeon: Fall back to evicting BOs with memcpy if necessary. · 1ab2e105
      Michel Dänzer 提交于
      Otherwise if there's no GTT space we would fail the eviction, leading to
      cascaded failure.
      Signed-off-by: NMichel Dänzer <daenzer@vmware.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      1ab2e105
    • D
      drm/radeon/kms: add initial colortiling support. · e024e110
      Dave Airlie 提交于
      This adds new set/get tiling interfaces where the pitch
      and macro/micro tiling enables can be set. Along with
      a flag to decide if this object should have a surface when mapped.
      
      The only thing we need to allocate with a mapped surface should be
      the frontbuffer. Note rotate scanout shouldn't require one, and
      back/depth shouldn't either, though mesa needs some fixes.
      
      It fixes the TTM interfaces along Thomas's suggestions, and I've tested
      the surface stealing code with two X servers and not seen any lockdep issues.
      
      I've stopped tiling the fbcon frontbuffer, as I don't see there being
      any advantage other than testing, I've left the testing commands in there,
      just flip the fb_tiled to true in radeon_fb.c
      
      Open: Can we integrate endian swapping in with this?
      
      Future features:
      texture tiling - need to relocate texture registers TXOFFSET* with tiling info.
      
      This also merges Michel's cleanup surfaces regs at init time patch
      even though it makes sense on its own, this patch really relies on it.
      
      Some PowerMac firmwares set up a tiling surface at the beginning of VRAM
      which messes us up otherwise.
      that patch is:
      Signed-off-by: NMichel Dänzer <daenzer@vmware.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      e024e110
  23. 15 7月, 2009 1 次提交
  24. 19 6月, 2009 1 次提交
  25. 15 6月, 2009 1 次提交
    • J
      drm/radeon: introduce kernel modesetting for radeon hardware · 771fe6b9
      Jerome Glisse 提交于
      Add kernel modesetting support to radeon driver, use the ttm memory
      manager to manage memory and DRM/GEM to provide userspace API.
      In order to avoid backward compatibility issue and to allow clean
      design and code the radeon kernel modesetting use different code path
      than old radeon/drm driver.
      
      When kernel modesetting is enabled the IOCTL of radeon/drm
      driver are considered as invalid and an error message is printed
      in the log and they return failure.
      
      KMS enabled userspace will use new API to talk with the radeon/drm
      driver. The new API provide functions to create/destroy/share/mmap
      buffer object which are then managed by the kernel memory manager
      (here TTM). In order to submit command to the GPU the userspace
      provide a buffer holding the command stream, along this buffer
      userspace have to provide a list of buffer object used by the
      command stream. The kernel radeon driver will then place buffer
      in GPU accessible memory and will update command stream to reflect
      the position of the different buffers.
      
      The kernel will also perform security check on command stream
      provided by the user, we want to catch and forbid any illegal use
      of the GPU such as DMA into random system memory or into memory
      not owned by the process supplying the command stream. This part
      of the code is still incomplete and this why we propose that patch
      as a staging driver addition, future security might forbid current
      experimental userspace to run.
      
      This code support the following hardware : R1XX,R2XX,R3XX,R4XX,R5XX
      (radeon up to X1950). Works is underway to provide support for R6XX,
      R7XX and newer hardware (radeon from HD2XXX to HD4XXX).
      
      Authors:
          Jerome Glisse <jglisse@redhat.com>
          Dave Airlie <airlied@redhat.com>
          Alex Deucher <alexdeucher@gmail.com>
      Signed-off-by: NJerome Glisse <jglisse@redhat.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      Signed-off-by: NAlex Deucher <alexdeucher@gmail.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      771fe6b9