1. 07 Jun, 2010 1 commit
  2. 18 May, 2010 1 commit
    • Alex Deucher's avatar
      drm/radeon/kms/pm: rework power management · ce8f5370
      Alex Deucher authored
      - Separate dynpm and profile based power management methods.  You can select the pm method
        by echoing the selected method ("dynpm" or "profile") to power_method in sysfs.
      - Expose basic 4 profile in profile method
        "default" - default clocks
        "auto" - select between low and high based on ac/dc state
        "low" - DC, low power mode
        "high" - AC, performance mode
        The current base profile is "default", but it should switched to "auto" once we've tested
        on more systems.  Switching the state is a matter of echoing the requested profile to
        power_profile in sysfs.  The lowest power states are selected automatically when dpms turns
        the monitors off in all states but default.
      - Remove dynamic fence-based reclocking for the moment.  We can revisit this later once we
        have basic pm in.
      - Move pm init/fini to modesetting path.  pm is tightly coupled with display state.  Make sure
        display side is initialized before pm.
      - Add pm suspend/resume functions to make sure pm state is properly reinitialized on resume.
      - Remove dynpm module option.  It's now selectable via sysfs.
      Signed-off-by: default avatarAlex Deucher <alexdeucher@gmail.com>
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
  3. 17 May, 2010 1 commit
  4. 06 May, 2010 1 commit
  5. 18 Apr, 2010 1 commit
  6. 30 Mar, 2010 3 commits
  7. 28 Feb, 2010 2 commits
    • Dave Airlie's avatar
    • Dave Airlie's avatar
      vga_switcheroo: initial implementation (v15) · 6a9ee8af
      Dave Airlie authored
      Many new laptops now come with 2 gpus, one to be used for low power
      modes and one for gaming/on-ac applications. These GPUs are typically
      wired to the laptop panel and VGA ports via a multiplexer unit which
      is controlled via ACPI methods.
      4 combinations of systems typically exist - with 2 ACPI methods.
      Intel/ATI - Lenovo W500/T500 - use ATPX ACPI method
      ATI/ATI - some ASUS - use ATPX ACPI Method
      Intel/Nvidia - - use _DSM ACPI method
      Nvidia/Nvidia -  - use _DSM ACPI method.
      This patch adds support for the ATPX method and initial bits
      for the _DSM methods that need to written by someone with
      access to the hardware.
      Add a proper non-debugfs interface - need to get some proper
      testing first.
      v2: add power up/down support for both devices
      on W500 puts i915/radeon into D3 and cuts power to radeon.
      v3: redo probing methods, no DMI list, drm devices call to
      register with switcheroo, it tries to find an ATPX method on
      any device and once there is two devices + ATPX it inits the
      v4: ATPX msg handling using buffers - should work on more machines
      v5: rearchitect after more mjg59 discussion - move ATPX handling to
          radeon driver.
      v6: add file headers + initial nouveau bits (to be filled out).
      v7: merge delayed switcher code.
      v8: avoid suspend/resume of gpu that is off
      v9: rearchitect - mjg59 is always right. - move all ATPX code to
      radeon, should allow simpler DSM also proper ATRM handling
      v10: add ATRM support for radeon BIOS, add mutex to lock vgasr_priv
      v11: fix bug in resuming Intel for 2nd time.
      v12: start fixing up nvidia code blindly.
      v13: blindly guess at finishing nvidia code
      v14: remove radeon audio hacks - fix up intel resume more like upstream
      v15: clean up printks + remove unnecessary igd/dis pointers
      mount debugfs
      /sys/kernel/debug/vgaswitcheroo/switch - should exist if ATPX detected
       + 2 cards.
      DIS - immediate change to discrete
      IGD - immediate change to IGD
      DDIS - delayed change to discrete
      DIGD - delayed change to IGD
      ON - turn on not in use
      OFF - turn off not in use
      Tested on W500 (Intel/ATI) and T500 (Intel/ATI)
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
  8. 24 Feb, 2010 1 commit
  9. 08 Feb, 2010 1 commit
  10. 17 Dec, 2009 1 commit
    • Arnd Bergmann's avatar
      drm: convert drm_ioctl to unlocked_ioctl · ed8b6704
      Arnd Bergmann authored
      drm_ioctl is called with the Big Kernel Lock held,
      which shows up very high in statistics on vfs_ioctl.
      Moving the lock into the drm_ioctl function itself
      makes sure we blame the right subsystem and it gets
      us one step closer to eliminating the locked version
      of fops->ioctl.
      Since drm_ioctl does not require the lock itself,
      we only need to hold it while calling the specific
      handler. The 32 bit conversion handlers do not
      interact with any other code, so they don't need
      the BKL here either and can just call drm_ioctl.
      As a bonus, this cleans up all the other users
      of drm_ioctl which now no longer have to find
      the inode or call lock_kernel.
      [airlied: squashed the non-driver bits
      of the second patch in here, this provides
      the flag for drivers to use to select unlocked
      ioctls - but doesn't modify any drivers].
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Cc: David Airlie <airlied@linux.ie>
      Cc: dri-devel@lists.sourceforge.net
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
  11. 15 Dec, 2009 1 commit
  12. 10 Dec, 2009 1 commit
  13. 09 Dec, 2009 1 commit
  14. 24 Sep, 2009 1 commit
  15. 14 Sep, 2009 1 commit
  16. 07 Sep, 2009 2 commits
  17. 03 Aug, 2009 1 commit
  18. 29 Jul, 2009 1 commit
  19. 24 Jun, 2009 1 commit
  20. 18 Jun, 2009 1 commit
  21. 16 Jun, 2009 1 commit
  22. 14 Jun, 2009 1 commit
    • Jerome Glisse's avatar
      drm/radeon: introduce kernel modesetting for radeon hardware · 771fe6b9
      Jerome Glisse authored
      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).
          Jerome Glisse <jglisse@redhat.com>
          Dave Airlie <airlied@redhat.com>
          Alex Deucher <alexdeucher@gmail.com>
      Signed-off-by: default avatarJerome Glisse <jglisse@redhat.com>
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      Signed-off-by: default avatarAlex Deucher <alexdeucher@gmail.com>
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
  23. 12 Mar, 2009 3 commits
  24. 29 Dec, 2008 1 commit
  25. 17 Oct, 2008 1 commit
  26. 01 Aug, 2008 1 commit
  27. 13 Jul, 2008 1 commit
    • Dave Airlie's avatar
      drm: reorganise drm tree to be more future proof. · c0e09200
      Dave Airlie authored
      With the coming of kernel based modesetting and the memory manager stuff,
      the everything in one directory approach was getting very ugly and
      starting to be unmanageable.
      This restructures the drm along the lines of other kernel components.
      It creates a drivers/gpu/drm directory and moves the hw drivers into
      subdirectores. It moves the includes into an include/drm, and
      sets up the unifdef for the userspace headers we should be exporting.
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
  28. 06 May, 2008 1 commit
  29. 26 Apr, 2008 1 commit
    • Jesse Barnes's avatar
      drm/vbl rework: rework how the drm deals with vblank. · ac741ab7
      Jesse Barnes authored
      Other Authors: Michel Dänzer <michel@tungstengraphics.com>
      mga: Ian Romanick <idr@us.ibm.com>
      via: Thomas Hellstrom <thomas-at-tungstengraphics-dot-com>
      This re-works the DRM internals to provide a better interface for drivers
      to expose vblank on multiple crtcs.
      It also includes work done by Michel on making i915 triple buffering and pageflipping work properly.
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
  30. 10 Jul, 2007 1 commit
  31. 21 Sep, 2006 1 commit
  32. 30 Jun, 2006 1 commit
  33. 11 Nov, 2005 1 commit
  34. 10 Nov, 2005 1 commit
    • Dave Airlie's avatar
      drm: rename driver hooks more understandably · 22eae947
      Dave Airlie authored
      Rename the driver hooks in the DRM to something a little more understandable:
      preinit         ->      load
      postinit        ->      (removed)
      presetup        ->      firstopen
      postsetup       ->      (removed)
      open_helper     ->      open
      prerelease      ->      preclose
      free_filp_priv  ->      postclose
      pretakedown     ->      lastclose
      postcleanup     ->      unload
      release         ->      reclaim_buffers_locked
      version         ->      (removed)
      postinit and version were replaced with generic code in the Linux DRM (drivers
      now set their version numbers and description in the driver structure, like on
      BSD).  postsetup wasn't used at all.  Fixes the savage hooks for
      initializing and tearing down mappings at the right times.  Testing involved at
      least starting X, running glxgears, killing glxgears, exiting X, and repeating.
      Tested on:      FreeBSD (g200, g400, r200, r128)
                      Linux (r200, savage4)
      From: Eric Anholt <anholt@freebsd.org>
      Signed-off-by: default avatarDave Airlie <airlied@linux.ie>