1. 06 9月, 2012 4 次提交
    • D
      drm/i915/hdmi: convert to encoder->disable/enable · 5ab432ef
      Daniel Vetter 提交于
      I've picked hdmi as the first encoder to convert because it's rather
      simple:
      - no cloning possible
      - no differences between prepare/commit and dpms off/on switching.
      
      A few changes are required to do so:
      - Split up the dpms code into an enable/disable function and wire it
        up with the intel encoder.
      - Noop out the existing encoder prepare/commit functions used by the
        crtc helper - our crtc enable/disable code now calls back into the
        encoder enable/disable code at the right spot.
      - Create new helper functions to handle dpms changes.
      - Add intel_encoder->connectors_active to better track dpms state. Atm
        this is unused, but it will be useful to correctly disable the
        entire display pipe for cloned configurations. Also note that for
        now this is only useful in the dpms code - thanks to the crtc
        helper's dpms confusion across a modeset operation we can't (yet)
        rely on this having a sensible value in all circumstances.
      - Rip out the encoder helper dpms callback, if this is still getting
        called somewhere we have a bug. The slight issue with that is that
        the crtc helper abuses dpms off to disable unused functions. Hence
        we also need to implement a default encoder disable function to do
        just that with the new encoder->disable callback.
      - Note that we drop the cpt modeset verification in the commit
        callback, too. The right place to do this would be in the crtc's
        enable function, _after_ all the encoders are set up. But because
        not all encoders are converted yet, we can't do that. Hence disable
        this check temporarily as a minor concession to bisectability.
      
      v2: Squash the dpms mode to only the supported values -
      connector->dpms is for internal tracking only, we can hence avoid
      needless state-changes a bit whithout causing harm.
      
      v3: Apply bikeshed to disable|enable_ddi, suggested by Paulo Zanoni.
      Reviewed-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-Off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      5ab432ef
    • D
      drm/i915: add direct encoder disable/enable infrastructure · ef9c3aee
      Daniel Vetter 提交于
      Just prep work, not yet put to some use.
      
      Note that because we're still using the crtc helper to switch modes
      (and their complicated way to do partial modesets), we need to call
      the encoder's disable function unconditionally.
      
      But once this is cleaned up we shouldn't call the encoder's disable
      function unconditionally any more, because then we know that we'll
      only call it if the encoder is actually enabled. Also note that we
      then need to be careful about which crtc we're filtering the encoder
      list on: We want to filter on the crtc of the _current_ mode, not the
      one we're about to set up.
      
      For the enabling side we need to do the same trick. And again, we
      should be able to simplify this quite a bit when things have settled
      into place.
      
      Also note that this simply does not take cloning into account, so dpms
      needs to be handled specially for the few outputs where we even bother
      with it.
      Reviewed-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-Off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      ef9c3aee
    • D
      drm/i915: rip out crtc prepare/commit indirection · eae307a5
      Daniel Vetter 提交于
      Just impendance matching with the the crtc helper stuff.
      
      ... and somehow the design of this all ended up in this commit here,
      too ;-)
      
      The big plan is that this new set of crtc display_funcs take full
      responsibility of modeset operations for the entire display output
      pipeline (by calling down into object-specific callbacks and
      functions). The platform-specific callbacks simply know best what the
      proper order is.
      
      This has the drawback that we can't do minimal change-overs any more
      if a modeset just disables one encoder in a cloned configuration
      (because we will only expose a disable/enable action that takes
      down/sets up the entire crtc including all encoders). Imo that's the
      only sane way to do it though:
      - The use-case for this is pretty minimal, even when presenting (at
        least sane people) should use a dual-screen output so that you can
        see your notes on your panel. Clone mode is imo BS.
      - With all the clone mode constrains, shared resources, and special
        ordering requirements (which differ even on the same platform
        sometimes for different outputs) there's no way we'd get this right
        for all cases. Especially since this is a under-used feature.
      - And to top it off: On haswell even dp link re-training requires us
        to take down the entire display pipe - otherwise the chip dies.
      
      So the only sane way is to do a full modeset on every crtc where the
      output config changes in any way.
      
      To support global modeset (i.e. set the configuration for all crtcs at
      once) we'd then add one more function to allocate global and shared
      objects in the best ways (e.g. fdi links, pch plls, ...). The crtc
      functions would then simply use the pre-allocated stuff (and shouldn't
      be able to fail, ever). We could even do all the object pinning in
      there (and maybe try to defragment the global gtt if we fail)!
      Reviewed-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-Off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      eae307a5
    • D
      drm/i915: add crtc->enable/disable vfuncs insted of dpms · 76e5a89c
      Daniel Vetter 提交于
      Because that's what we're essentially calling. This is the first step
      in untangling the crtc_helper induced dpms handling mess we have - at
      the crtc level we only have 2 states and the magic is just in
      selecting which one (and atm there isn't even much magic, but on
      recent platforms where not even the crt output has more than 2 states
      we could do better).
      Reviewed-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-Off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      76e5a89c
  2. 17 8月, 2012 29 次提交
  3. 16 8月, 2012 1 次提交
  4. 15 8月, 2012 3 次提交
    • D
      Merge branch 'drm-nouveau-fixes' of git://git.freedesktop.org/git/nouveau/linux-2.6 into drm-fixes · 2e26c73a
      Dave Airlie 提交于
      * 'drm-nouveau-fixes' of git://git.freedesktop.org/git/nouveau/linux-2.6:
        drm/nv86/fifo: suspend fix
        drm/nouveau: disable copy engine on NVAF
        nouveau: fixup scanout enable in nvc0_pm
        drm/nouveau/aux: mask off higher bits of auxch index in i2c table entry
        drm/nvd0/disp: mask off high 16 bit of negative cursor x-coordinate
        drm/nve0/fifo: add support for the flip completion swmthd
      2e26c73a
    • D
      Merge branch 'drm-intel-fixes' of git://people.freedesktop.org/~danvet/drm-intel into drm-fixes · a389b6a1
      Dave Airlie 提交于
      Daniel Vetter writes:
      
      "A few important fixers:
      - fix various lvds backlight issues, regressed in 3.6 (Takashi Iwai)
      - make the retina mbp work (ignore bogus edp bpc value in vbt)
      - fix a gmbus regression introduced in (iirc) 3.4 (Jani Nikula)
      - fix an edp panel power sequence regression, fixes the new macbook air
      - apply the tlb invalidate w/a
      
      Otherwise we still have another gmbus regression (patches are awaiting
      tested-bys) and there's something odd going with some rare systems not
      entering rc6 often enough (and hence blowing through too much power).  It
      seems to be a timing-related issue and can be mitigated by frobbing the
      magic tuning parameters. We're still working on that one. Also, we still
      have some fallout from the hw context support, but you can only hit that
      with mesa master."
      
      * 'drm-intel-fixes' of git://people.freedesktop.org/~danvet/drm-intel:
        drm/i915: Apply post-sync write for pipe control invalidates
        drm/i915: reorder edp disabling to fix ivb MacBook Air
        drm/i915: ensure i2c adapter is all set before adding it
        drm/i915: ignore eDP bpc settings from vbt
        drm/i915: Fix blank panel at reopening lid
      a389b6a1
    • D
      sparc64: Be less verbose during vmemmap population. · 2856cc2e
      David S. Miller 提交于
      On a 2-node machine with 256GB of ram we get 512 lines of
      console output, which is just too much.
      
      This mimicks Yinghai Lu's x86 commit c2b91e2e
      (x86_64/mm: check and print vmemmap allocation continuous) except that
      we aren't ever going to get contiguous block pointers in between calls
      so just print when the virtual address or node changes.
      
      This decreases the output by an order of 16.
      
      Also demote this to KERN_DEBUG.
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      2856cc2e
  5. 14 8月, 2012 3 次提交
    • C
      drm/i915: Apply post-sync write for pipe control invalidates · 7d54a904
      Chris Wilson 提交于
      When invalidating the TLBs it is documentated as requiring a post-sync
      write. Failure to do so seems to result in a GPU hang.
      
      Exposure to this hang on IVB seems to be a result of removing the extra
      stalls required for SNB pipecontrol workarounds:
      
      commit 6c6cf5aa
      Author: Chris Wilson <chris@chris-wilson.co.uk>
      Date:   Fri Jul 20 18:02:28 2012 +0100
      
          drm/i915: Only apply the SNB pipe control w/a to gen6
      
      Note: Manually switch the pipe_control cmd to 4 dwords to avoid a
      (silent) functional conflict with -next. This way will get a loud (but
      conflict with next (since the scratch_addr has been deleted there).
      
      Reported-and-tested-by: yex.tian@intel.com
      Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=53322Acked-by: NBen Widawsky <ben@bwidawsk.net>
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      [danvet: added note about merge conflict with -next.]
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      7d54a904
    • D
      drm/i915: reorder edp disabling to fix ivb MacBook Air · 35a38556
      Daniel Vetter 提交于
      eDP is tons of fun. It turns out that at least the new MacBook Air 5,1
      model absolutely doesn't like the new force vdd dance we've introduced
      in
      
      commit 6cb49835
      Author: Daniel Vetter <daniel.vetter@ffwll.ch>
      Date:   Sun May 20 17:14:50 2012 +0200
      
          drm/i915: enable vdd when switching off the eDP panel
      
      But that patch also tried to fix some neat edp sequence issue with the
      force_vdd timings. Closer inspection reveals that we've raised
      force_vdd only to do the aux channel communication dp_sink_dpms. If we
      move the edp_panel_off below that, we don't need any force_vdd for the
      disable sequence, which makes the Air happy.
      
      Unfortunately the reporter of the original bug that the above commit
      fixed is travelling, so we can't test whether this regresses things.
      But my theory is that since we don't check for any power-off ->
      force_vdd-on delays in edp_panel_vdd_on, this was the actual
      root-cause of this failure. With that force_vdd dance completely
      eliminated, I'm hopeful the original bug stays fixed, too.
      
      For reference the old bug, which hopefully doesn't get broken by this:
      
      https://bugzilla.kernel.org/show_bug.cgi?id=43163
      
      In any case, regression fixers win over plain bugfixes, so this needs
      to go in asap.
      
      v2: The crucial pieces seems to be to clear the force_vdd flag
      uncoditionally, too, in edp_panel_off. Looks like this is left behind
      by the firmware somehow.
      
      v3: The Apple firmware seems to switch off the panel on it's own, hence
      we still need to keep force_vdd on, but properly clear it when switching
      the panel off.
      
      Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=45671Tested-by: NRoberto Romer <sildurin@gmail.com>
      Tested-by: NDaniel Wagner <wagi@monom.org>
      Tested-by: NKeith Packard <keithp@keithp.com>
      Cc: stable@vger.kernel.org
      Cc: Keith Packard <keithp@keithp.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      35a38556
    • L
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux · ddf343f6
      Linus Torvalds 提交于
      Pull s390 patches from Martin Schwidefsky:
       "Included are bug fixes and a patch to enable system call filtering
        with BPF."
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux:
        s390/compat: fix mmap compat system calls
        s390/compat: fix compat wrappers for process_vm system calls
        s390: do not clobber personality flags in sys_32_personality()
        s390/seccomp: add support for system call filtering using BPF
        s390/sclp_sdias: Add missing break and "fall through"
        s390/mm: remove MAX_PHYSADDR_BITS define
      ddf343f6