Merge final patch-bomb from Andrew Morton:
"Various leftovers, mainly Christoph's pci_dma_supported() removals"
* emailed patches from Andrew Morton <akpm@linux-foundation.org>:
pci: remove pci_dma_supported
usbnet: remove ifdefed out call to dma_supported
kaweth: remove ifdefed out call to dma_supported
sfc: don't call dma_supported
nouveau: don't call pci_dma_supported
netup_unidvb: use pci_set_dma_mask insted of pci_dma_supported
cx23885: use pci_set_dma_mask insted of pci_dma_supported
cx25821: use pci_set_dma_mask insted of pci_dma_supported
cx88: use pci_set_dma_mask insted of pci_dma_supported
saa7134: use pci_set_dma_mask insted of pci_dma_supported
saa7164: use pci_set_dma_mask insted of pci_dma_supported
tw68-core: use pci_set_dma_mask insted of pci_dma_supported
pcnet32: use pci_set_dma_mask insted of pci_dma_supported
lib/string.c: add ULL suffix to the constant definition
hugetlb: trivial comment fix
selftests/mlock2: add ULL suffix to 64-bit constants
selftests/mlock2: add missing #define _GNU_SOURCE
Pull drm fixes from Dave Airlie:
"Two build fixes, one for VC4, one for nouveau where the ARM only code
is doing something a bit strange. While people are discussing that,
just workaround it and fix the build for now. The code in question
will never get used on anything non-ARM anyways.
Also one fix for AST that SuSE had been hiding in their kernel, that
allows all fbdev apps to work on that driver"
* 'drm-fixes' of git://people.freedesktop.org/~airlied/linux:
drm/nouveau: fix build failures on all non ARM.
drm/ast: Initialized data needed to map fbdev memory
drm/vc4: Add dependency on HAVE_DMA_ATTRS, and select DRM_GEM_CMA_HELPER
gk20a is an ARM only GPU, so we can just do the correct thing on
ARM but fail on other architectures. The other option was to use
SWIOTLB as the define, which means phys_to_page exists, but
this seems clearer.
Signed-off-by: Dave Airlie <airlied@redhat.com>
Due to a missing initialization there was no way to map fbdev memory.
Thus for example using the Xserver with the fbdev driver failed.
This fix adds initialization for fix.smem_start and fix.smem_len
in the fb_info structure, which fixes this problem.
Requested-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: stable@vger.kernel.org
Signed-off-by: Egbert Eich <eich@suse.de>
[pulled from SuSE tree by me - airlied]
Signed-off-by: Dave Airlie <airlied@redhat.com>
Just try to set a 64-bit DMA mask first and retry with the smaller dma_mask
if dma_set_mask failed.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Cc: David Airlie <airlied@linux.ie>
Cc: Ben Skeggs <bskeggs@redhat.com>
Cc: Alexandre Courbot <acourbot@nvidia.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: Thierry Reding <treding@nvidia.com>
Cc: Dave Airlie <airlied@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Pull drm updates from Dave Airlie:
"I Was Almost Tempted To Capitalise Every Word, but then I decided I
couldn't read it myself!
I've also got one pull request for the sti driver outstanding. It
relied on a commit in Greg's tree and I didn't find out in time, that
commit is in your tree now so I might send that along once this is
merged.
I also had the accidental misfortune to have access to a Skylake on my
desk for a few days, and I've had to encourage Intel to try harder,
which seems to be happening now.
Here is the main drm-next pull request for 4.4.
Highlights:
New driver:
vc4 driver for the Rasberry Pi VPU.
(From Eric Anholt at Broadcom.)
Core:
Atomic fbdev support
Atomic helpers for runtime pm
dp/aux i2c STATUS_UPDATE handling
struct_mutex usage cleanups.
Generic of probing support.
Documentation:
Kerneldoc for VGA switcheroo code.
Rename to gpu instead of drm to reflect scope.
i915:
Skylake GuC firmware fixes
HPD A support
VBT backlight fallbacks
Fastboot by default for some systems
FBC work
BXT/SKL workarounds
Skylake deeper sleep state fixes
amdgpu:
Enable GPU scheduler by default
New atombios opcodes
GPUVM debugging options
Stoney support.
Fencing cleanups.
radeon:
More efficient CS checking
nouveau:
gk20a instance memory handling improvements.
Improved PGOB detection and GK107 support
Kepler GDDR5 PLL statbility improvement
G8x/GT2xx reclock improvements
new userspace API compatiblity fixes.
virtio-gpu:
Add 3D support - qemu 2.5 has it merged for it's gtk backend.
msm:
Initial msm88896 (snapdragon 8200)
exynos:
HDMI cleanups
Enable mixer driver byt default
Add DECON-TV support
vmwgfx:
Move to using memremap + fixes.
rcar-du:
Add support for R8A7793/4 DU
armada:
Remove support for non-component mode
Improved plane handling
Power savings while in DPMS off.
tda998x:
Remove unused slave encoder support
Use more HDMI helpers
Fix EDID read handling
dwhdmi:
Interlace video mode support for ipu-v3/dw_hdmi
Hotplug state fixes
Audio driver integration
imx:
More color formats support.
tegra:
Minor fixes/improvements"
[ Merge fixup: remove unused variable 'dev' that had all uses removed in
commit 4e270f0880: "drm/gem: Drop struct_mutex requirement from
drm_gem_mmap_obj" ]
* 'drm-next' of git://people.freedesktop.org/~airlied/linux: (764 commits)
drm/vmwgfx: Relax irq locking somewhat
drm/vmwgfx: Properly flush cursor updates and page-flips
drm/i915/skl: disable display side power well support for now
drm/i915: Extend DSL readout fix to BDW and SKL.
drm/i915: Do graphics device reset under forcewake
drm/i915: Skip fence installation for objects with rotated views (v4)
vga_switcheroo: Drop client power state VGA_SWITCHEROO_INIT
drm/amdgpu: group together common fence implementation
drm/amdgpu: remove AMDGPU_FENCE_OWNER_MOVE
drm/amdgpu: remove now unused fence functions
drm/amdgpu: fix fence fallback check
drm/amdgpu: fix stoping the scheduler timeout
drm/amdgpu: cleanup on error in amdgpu_cs_ioctl()
drm/i915: Fix locking around GuC firmware load
drm/amdgpu: update Fiji's Golden setting
drm/amdgpu: update Fiji's rev id
drm/amdgpu: extract common code in vi_common_early_init
drm/amd/scheduler: don't oops on failure to load
drm/amdgpu: don't oops on failure to load (v2)
drm/amdgpu: don't VT switch on suspend
...
Switch everything to the new and more capable implementation of abs().
Mainly to give the new abs() a bit of a workout.
Cc: Michal Nazarewicz <mina86@mina86.com>
Cc: John Stultz <john.stultz@linaro.org>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Steven Rostedt <rostedt@goodmis.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Merge second patch-bomb from Andrew Morton:
- most of the rest of MM
- procfs
- lib/ updates
- printk updates
- bitops infrastructure tweaks
- checkpatch updates
- nilfs2 update
- signals
- various other misc bits: coredump, seqfile, kexec, pidns, zlib, ipc,
dma-debug, dma-mapping, ...
* emailed patches from Andrew Morton <akpm@linux-foundation.org>: (102 commits)
ipc,msg: drop dst nil validation in copy_msg
include/linux/zutil.h: fix usage example of zlib_adler32()
panic: release stale console lock to always get the logbuf printed out
dma-debug: check nents in dma_sync_sg*
dma-mapping: tidy up dma_parms default handling
pidns: fix set/getpriority and ioprio_set/get in PRIO_USER mode
kexec: use file name as the output message prefix
fs, seqfile: always allow oom killer
seq_file: reuse string_escape_str()
fs/seq_file: use seq_* helpers in seq_hex_dump()
coredump: change zap_threads() and zap_process() to use for_each_thread()
coredump: ensure all coredumping tasks have SIGNAL_GROUP_COREDUMP
signal: remove jffs2_garbage_collect_thread()->allow_signal(SIGCONT)
signal: introduce kernel_signal_stop() to fix jffs2_garbage_collect_thread()
signal: turn dequeue_signal_lock() into kernel_dequeue_signal()
signals: kill block_all_signals() and unblock_all_signals()
nilfs2: fix gcc uninitialized-variable warnings in powerpc build
nilfs2: fix gcc unused-but-set-variable warnings
MAINTAINERS: nilfs2: add header file for tracing
nilfs2: add tracepoints for analyzing reading and writing metadata files
...
Here's a handful of i915 fixes for drm-next/v4.4. Imre's commit alone
should address the remaining warnings galore you experienced on
Skylake. Almost all of the rest are also fixes against user or QA
reported bugs, with references.
* tag 'drm-intel-next-fixes-2015-11-06' of git://anongit.freedesktop.org/drm-intel:
drm/i915/skl: disable display side power well support for now
drm/i915: Extend DSL readout fix to BDW and SKL.
drm/i915: Do graphics device reset under forcewake
drm/i915: Skip fence installation for objects with rotated views (v4)
drm/i915: add quirk to enable backlight on Dell Chromebook 11 (2015)
drm/i915/skl: Prevent unclaimed register writes on skylake.
drm/i915: disable CPU PWM also on LPT/SPT backlight disable
drm/i915: Fix maxfifo watermark calc on vlv cursor planes
drm/i915: add hotplug activation period to hotplug update mask
One is fix for a regression in 4.3, One irq locking rework.
* 'vmwgfx-next' of git://people.freedesktop.org/~thomash/linux:
drm/vmwgfx: Relax irq locking somewhat
drm/vmwgfx: Properly flush cursor updates and page-flips
It is hardly possible to enumerate all problems with block_all_signals()
and unblock_all_signals(). Just for example,
1. block_all_signals(SIGSTOP/etc) simply can't help if the caller is
multithreaded. Another thread can dequeue the signal and force the
group stop.
2. Even is the caller is single-threaded, it will "stop" anyway. It
will not sleep, but it will spin in kernel space until SIGCONT or
SIGKILL.
And a lot more. In short, this interface doesn't work at all, at least
the last 10+ years.
Daniel said:
Yeah the only times I played around with the DRM_LOCK stuff was when
old drivers accidentally deadlocked - my impression is that the entire
DRM_LOCK thing was never really tested properly ;-) Hence I'm all for
purging where this leaks out of the drm subsystem.
Signed-off-by: Oleg Nesterov <oleg@redhat.com>
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Acked-by: Dave Airlie <airlied@redhat.com>
Cc: Richard Weinberger <richard@nod.at>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
There are many places which use mapping_gfp_mask to restrict a more
generic gfp mask which would be used for allocations which are not
directly related to the page cache but they are performed in the same
context.
Let's introduce a helper function which makes the restriction explicit and
easier to track. This patch doesn't introduce any functional changes.
[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: Michal Hocko <mhocko@suse.com>
Suggested-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
__GFP_WAIT was used to signal that the caller was in atomic context and
could not sleep. Now it is possible to distinguish between true atomic
context and callers that are not willing to sleep. The latter should
clear __GFP_DIRECT_RECLAIM so kswapd will still wake. As clearing
__GFP_WAIT behaves differently, there is a risk that people will clear the
wrong flags. This patch renames __GFP_WAIT to __GFP_RECLAIM to clearly
indicate what it does -- setting it allows all reclaim activity, clearing
them prevents it.
[akpm@linux-foundation.org: fix build]
[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: Mel Gorman <mgorman@techsingularity.net>
Acked-by: Michal Hocko <mhocko@suse.com>
Acked-by: Vlastimil Babka <vbabka@suse.cz>
Acked-by: Johannes Weiner <hannes@cmpxchg.org>
Cc: Christoph Lameter <cl@linux.com>
Acked-by: David Rientjes <rientjes@google.com>
Cc: Vitaly Wool <vitalywool@gmail.com>
Cc: Rik van Riel <riel@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
__GFP_WAIT has been used to identify atomic context in callers that hold
spinlocks or are in interrupts. They are expected to be high priority and
have access one of two watermarks lower than "min" which can be referred
to as the "atomic reserve". __GFP_HIGH users get access to the first
lower watermark and can be called the "high priority reserve".
Over time, callers had a requirement to not block when fallback options
were available. Some have abused __GFP_WAIT leading to a situation where
an optimisitic allocation with a fallback option can access atomic
reserves.
This patch uses __GFP_ATOMIC to identify callers that are truely atomic,
cannot sleep and have no alternative. High priority users continue to use
__GFP_HIGH. __GFP_DIRECT_RECLAIM identifies callers that can sleep and
are willing to enter direct reclaim. __GFP_KSWAPD_RECLAIM to identify
callers that want to wake kswapd for background reclaim. __GFP_WAIT is
redefined as a caller that is willing to enter direct reclaim and wake
kswapd for background reclaim.
This patch then converts a number of sites
o __GFP_ATOMIC is used by callers that are high priority and have memory
pools for those requests. GFP_ATOMIC uses this flag.
o Callers that have a limited mempool to guarantee forward progress clear
__GFP_DIRECT_RECLAIM but keep __GFP_KSWAPD_RECLAIM. bio allocations fall
into this category where kswapd will still be woken but atomic reserves
are not used as there is a one-entry mempool to guarantee progress.
o Callers that are checking if they are non-blocking should use the
helper gfpflags_allow_blocking() where possible. This is because
checking for __GFP_WAIT as was done historically now can trigger false
positives. Some exceptions like dm-crypt.c exist where the code intent
is clearer if __GFP_DIRECT_RECLAIM is used instead of the helper due to
flag manipulations.
o Callers that built their own GFP flags instead of starting with GFP_KERNEL
and friends now also need to specify __GFP_KSWAPD_RECLAIM.
The first key hazard to watch out for is callers that removed __GFP_WAIT
and was depending on access to atomic reserves for inconspicuous reasons.
In some cases it may be appropriate for them to use __GFP_HIGH.
The second key hazard is callers that assembled their own combination of
GFP flags instead of starting with something like GFP_KERNEL. They may
now wish to specify __GFP_KSWAPD_RECLAIM. It's almost certainly harmless
if it's missed in most cases as other activity will wake kswapd.
Signed-off-by: Mel Gorman <mgorman@techsingularity.net>
Acked-by: Vlastimil Babka <vbabka@suse.cz>
Acked-by: Michal Hocko <mhocko@suse.com>
Acked-by: Johannes Weiner <hannes@cmpxchg.org>
Cc: Christoph Lameter <cl@linux.com>
Cc: David Rientjes <rientjes@google.com>
Cc: Vitaly Wool <vitalywool@gmail.com>
Cc: Rik van Riel <riel@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Here is the first batch of updates for sound system on 4.4-rc1.
Again at this time, the update looks fairly calm; no big changes in
either ALSA core or ASoC infrastructures, rather all small cleanups,
in addition to the new stuff as usual.
The biggest changes are about Firewire sound devices. It gained lots
of new device support, and MIDI functionality. Also there are updates
for a few still working-in-progress stuff (topology API and ASoC
skylake), too. But overall, this update should give no big surprise.
Some highlight is below:
Core:
- A few more Kconfig items for tinification; it's marked as EXPERT,
so normal user should't be bothered :)
- Refactoring with a new PCM hw_constraint helper
- Removal of unused transfer_ack_{begin,end} PCM callbacks
Firewire:
- Restructuring of code subtree, lots of refactoring
- Support AMDTP variants
- New driver for Digidesign 002/003 family
- Adds support for TASCAM FireOne to ALSA OXFW driver
- Add MIDI support to TASCAM and Digi00x devices
HD-Audio:
- Automated modalias generation for codec drivers, finally
- Improvement on heuristics for setting mixer name
- A few fixes for longstanding bugs on Creative CA0132 cards
- Addition of audio rate callback with i915 communication
- Fix suspend issue on recent Dell XPS
- Intel Lewisburg controller support
ASoC:
- Updates to the topology userspace interface
- Big updates to the Renesas support (rcar)
- More updates for supporting Intel Sky Lake systems
- New drivers for Asahi Kasei Microdevices AK4613, Allwinnner A10,
Cirrus Logic WM8998, Dialog DA7219, Nuvoton NAU8825, Rockchip
S/PDIF, and Atmel class D amplifier
USB-Audio:
- A fix for newer Roland MIDI devices
- Quirks and workarounds for Zoom R16/24 device
Misc:
- A few fixes for some old Cirrus CS46xx PCI sound boards
- Yet another fixes for some old ESS Maestro3 PCI sound boards
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iQIcBAABCAAGBQJWPNI9AAoJEGwxgFQ9KSmkOGIP+wUX4eIWwV4BK3mTjdPgvB+i
M7niITY+baN6WqoX8Impe6CyvdOed/pQyHqkT8NFthhmYrgVU9iJBykgF1+BOPt3
ZtYb0qi2mOPbTL0mwFv6oDu8Nvh6hBdCz6ZepQQdjyG4QBdLs7Cea3o3ncJEgsqI
H9LHcCjwSIi4wAcIFVCiD2rJnI/sqhyH2jm9ay8TWDPkBnUBC0Pz1aE+DIbb5x5G
m53rVTjE2dU5MQJrG+rQyH5ngR51Qs6XLYLSnkMXBrZPSP5UQxM282pG19ILumFK
b5uOKWC2DyeWkmDTglAQXaSSbI+3Sj+W+oo05z51Pz2b8YEvehl2XjJpeB0Nlez/
q+i/c8LnUYV8MPlJdldC1jZO8MVRYEX5fEWm1Hwie+q1YozFkhxIfwKCdXnazpYE
ga9E5t/Utg0Rclb2vlYuHv3A4RmY1CW7VazP6PwZjhrahPMxN6zU8aTe+OzBJxkT
i8Ka+R7mMCVyAfauNuBcQtJ+cY+6JbOXsT/5BWTGW0qsa9V17uUOXriAYyNBLwFL
zcBa8OXHtYoiPbWIgE5rJUmRqTXJaOlNYyuot+AT2K7bOW9KMXmEROaSXyVNoqR8
AVZHVmByViI8TuQ98L7vakvyHSKoi4x1Aq/ODrS4Ya4+5T60PmVTyCxT7UUE0FNo
V39cwMFp8TCMifTeRP/+
=l9SO
-----END PGP SIGNATURE-----
Merge tag 'sound-4.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound
Pull sound updates from Takashi Iwai:
"Here is the first batch of updates for sound system on 4.4-rc1.
Again at this time, the update looks fairly calm; no big changes in
either ALSA core or ASoC infrastructures, rather all small cleanups,
in addition to the new stuff as usual.
The biggest changes are about Firewire sound devices. It gained lots
of new device support, and MIDI functionality. Also there are updates
for a few still working-in-progress stuff (topology API and ASoC
skylake), too. But overall, this update should give no big surprise.
Some highlights are below:
Core:
- A few more Kconfig items for tinification; it's marked as EXPERT,
so normal user should't be bothered :)
- Refactoring with a new PCM hw_constraint helper
- Removal of unused transfer_ack_{begin,end} PCM callbacks
Firewire:
- Restructuring of code subtree, lots of refactoring
- Support AMDTP variants
- New driver for Digidesign 002/003 family
- Adds support for TASCAM FireOne to ALSA OXFW driver
- Add MIDI support to TASCAM and Digi00x devices
HD-Audio:
- Automated modalias generation for codec drivers, finally
- Improvement on heuristics for setting mixer name
- A few fixes for longstanding bugs on Creative CA0132 cards
- Addition of audio rate callback with i915 communication
- Fix suspend issue on recent Dell XPS
- Intel Lewisburg controller support
ASoC:
- Updates to the topology userspace interface
- Big updates to the Renesas support (rcar)
- More updates for supporting Intel Sky Lake systems
- New drivers for Asahi Kasei Microdevices AK4613, Allwinnner A10,
Cirrus Logic WM8998, Dialog DA7219, Nuvoton NAU8825, Rockchip
S/PDIF, and Atmel class D amplifier
USB-Audio:
- A fix for newer Roland MIDI devices
- Quirks and workarounds for Zoom R16/24 device
Misc:
- A few fixes for some old Cirrus CS46xx PCI sound boards
- Yet another fixes for some old ESS Maestro3 PCI sound boards"
* tag 'sound-4.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: (330 commits)
ALSA: hda - Add Intel Lewisburg device IDs Audio
ALSA: hda - Apply pin fixup for HP ProBook 6550b
ALSA: hda - Fix lost 4k BDL boundary workaround
ALSA: maestro3: Fix Allegro mute until master volume/mute is touched
ALSA: maestro3: Enable docking support for Dell Latitude C810
ALSA: firewire-digi00x: add another rawmidi character device for MIDI control ports
ALSA: firewire-digi00x: add MIDI operations for MIDI control port
ALSA: firewire-digi00x: rename identifiers of MIDI operation for physical ports
ALSA: cs46xx: Fix suspend for all channels
ALSA: cs46xx: Fix Duplicate front for CS4294 and CS4298 codecs
ALSA: DocBook: Add soc-ops.c and soc-compress.c
ALSA: hda - Add / fix kernel doc comments
ALSA: Constify ratden/ratnum constraints
ALSA: hda - Disable 64bit address for Creative HDA controllers
ALSA: hda/realtek - Dell XPS one ALC3260 speaker no sound after resume back
ALSA: hda/ca0132 - Convert leftover pr_info() and pr_err()
ASoC: fsl: Use #ifdef instead of #if for CONFIG_PM_SLEEP
ASoC: rt5645: Sort the order for register bit defines
ASoC: dwc: add check for master/slave format
ASoC: rt5645: Add the HWEQ for the speaker output
...
Relax locking with the goal of reducing the number of locking cycles and
time spent with irqs disabled.
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Reviewed-by: Sinclair Yeh <syeh@vmware.com>
With the introduction of the new command buffer mechanism,
proper care wasn't taken to flush cursor image updates and
event-less screen-target page-flips.
Fix this by introducing explicit flush points.
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
The display power well support on this platform is in a somewhat broken
state atm, so disable it by default.
This in effect will get rid of incorrect assert WARNs about the CSR/DMC
firmware not being loaded during power well toggling. It also removes a
problem during driver loading where a register is accessed while its
backing power well is down, resulting in another WARN. Until we come up
with the root cause of the second problem and the proper fix for both
issues, keep all display side power wells on.
Also clarify a bit the option description.
Reported-by: Dave Airlie <airlied@redhat.com>
Reference: http://mid.gmane.org/CAPM=9tyjBQjSBTKa49cRr6SYkpNW7Pq-fUFznZZ8Y1snvvk7mA@mail.gmail.com
Signed-off-by: Imre Deak <imre.deak@intel.com>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1446757451-2777-1-git-send-email-imre.deak@intel.com
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
We have a timed release of a forcewake when using
I915_READ/WRITE macros. wait_for() macro will go to quite
long sleep if the first read doesn't satisfy the condition for
successful exit. With these two interacting, it is possible that
we lose the forcewake during the wait_for() and the subsequent read
will reaquire forcewake.
Further experiments with skl shows that when we lose forcewake,
we lose the reset request we submitted. So reset request register
is not power context saved.
Grab forcewakes for all engines before starting the reset/request
dance so that all requests stay valid for the duration of reset
requisition across all the engines.
v2: Add comment on power well sleeps. Wrap the reset handling
under forcewake instead of just reset requests (Chris)
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=92774
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Tested-by: Tomi Sarvela <tomix.p.sarvela@intel.com> (v1, v2)
Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1446721898-1450-1-git-send-email-mika.kuoppala@intel.com
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
While pinning a fb object to the display plane, only install a fence
if the object is using a normal view. This corresponds with the
behavior found in i915_gem_object_do_pin() where the fencability
criteria is determined only for objects with normal views.
v2:
Look at the object's map_and_fenceable flag to determine whether to
install a fence or not (Chris).
v3:
Pin and unpin a fence only if the current view type is normal.
v4:
Extend the "view type is normal" check for pin_fence as well.
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Ville Syrjala <ville.syrjala@linux.intel.com>
Signed-off-by: Vivek Kasireddy <vivek.kasireddy@intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1446170078-20792-1-git-send-email-vivek.kasireddy@intel.com
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
hda_intel.c:azx_probe() defers initialization of an audio controller
on the discrete GPU if the GPU is powered off. The power state of the
GPU is determined by calling vga_switcheroo_get_client_state().
vga_switcheroo_get_client_state() returns VGA_SWITCHEROO_INIT if
vga_switcheroo is not enabled, i.e. if no second GPU or no handler
has registered.
This can go wrong in the following scenario:
- Driver for the integrated GPU is not loaded.
- Driver for the discrete GPU registers with vga_switcheroo, uses driver
power control to power down the GPU, handler cuts power to the GPU.
- Driver for the audio controller gets loaded after the GPU was powered
down, calls vga_switcheroo_get_client_state() which returns
VGA_SWITCHEROO_INIT instead of VGA_SWITCHEROO_OFF.
- Consequence: azx_probe() tries to initialize the audio controller even
though the GPU is powered down.
The power state VGA_SWITCHEROO_INIT was introduced by c8e9cf7bb2
("vga_switcheroo: Add a helper function to get the client state").
It is not apparent what its benefit might be. The idea seems to
be to initialize the audio controller even if the power state is
VGA_SWITCHEROO_OFF (were vga_switcheroo enabled), but as shown
above this can fail.
Drop VGA_SWITCHEROO_INIT to solve this.
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Lukas Wunner <lukas@wunner.de>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Just two small cleanup patches to fix coccinelle warnings.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iQIcBAABCAAGBQJWM6yPAAoJEN0jrNd/PrOhyBUQALPErCqaBBlS6nv+inM/dIqH
UrhdBQcLF0BFPQmTEix82inkuqYEqB3u2TSDU6MH1IcJfJsOvSjj3/IOpx6uw1+P
AygHPGluMQzunjC48zPWwfYzbrz5zqLK+Apq6afyEowxpnLUcO4yT14u/s2SVdkg
qcNRU2pja/SsXJpz+JYBtCqyGPyuNU+AUBCqc3xFd2RuRQ99P5lZL0rdFTFihCoK
If8MT3VehSE9QKYTkWuWe2c3y3CeucOmreGT+HITj+BE7rbULu73vyd4zdfhb5n6
ObOER1L8YyyM9YfmWUm1swrcEUlG+mSq+ISm76mCwOVvftK0UKQV090WEgpNCRbH
I9D1+pn1vjEK2FXyErOH0AifNAILdoDj3boXLLtyITnjc4K4gKuMeDUpHwUarg/a
Ys51eHrO2mS4EWRxe8QwuP7hj2XFP6sFg3uwWNWMb2WYNoOGfPtxBfobhqU6jBMt
NkNWqSBv/dOvj/5Bddz+3dH6Ea7LDw1oZ3GbBX8K1x1EQTvEPwTjseL3PSAbRbMO
wmRQq/cknkQ9mSP0FEupUw73wc81C6C0iyxJXVtXfJUDkUfMPFJLo3L1Sjqsl4Ey
DVqRpGFUt6hspw8f+DzeittVrXsq65XRKDTg3VlnEQVq/tBPErzXPwVNLhi9fLkY
WQzb+vHIEic4zYY8yIjB
=Q9bM
-----END PGP SIGNATURE-----
Merge tag 'drm/panel/for-4.4-rc1' of git://anongit.freedesktop.org/tegra/linux into drm-next
drm/panel: Changes for v4.4-rc1
Just two small cleanup patches to fix coccinelle warnings.
* tag 'drm/panel/for-4.4-rc1' of git://anongit.freedesktop.org/tegra/linux:
drm/bridge: ptn3460: Fix coccinelle warnings
drm/bridge: ps8622: Fix coccinelle warnings
Just a couple of minor fixes and cleanups for this cycle.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iQIcBAABCAAGBQJWM6wLAAoJEN0jrNd/PrOh/HwP/23WEi/j4lBC8NMIOuxg9Eg5
xfEN7hD3VLS3a/wzqCsM5UK9d8hSftCSKrYggKFL1NWsb3XIIyDHTc40dHl3MFMA
r8WVk01XJhdpmSxhc0To1/a0HaKWfKlti2tZNTTYRa2w3pWMLSL/TVKmtAnebv9Z
s15ISWzyjsV6hIMwl3AdvawLDy+u/j3kvwXw/XnSJYRvjDvsFQb0msIu7lGEIWfO
/kabMKJAWUt/cdllWUbPbQdDZv2cY4m3MnSv3NLjOeyHqoZbnHvnx1zNMCYs/3+f
tAzIgpPaMRVNA2vvXINqs7GA3oqks9JmqPysBfUoXD3uiewCzSHXV5fC39kwdhSh
BntCBtL8PTbmVbX7dsgFEFHRx99Lvs37Jrk+4TTzO50L8nTtkXg8UsA/dpL/Ww5B
jlNe/ZAXCOvlEpnmLjmH7Y2N+kbaV7yQmYv/7YKDb1hkQ3mEnv2kwbM9WdN9emyG
pHdXWNGeb72Q8+fBAF1h47M40Zeebkfa6issx8uesTJj1smBwIqxIr3r8f3yShKt
YbMre/K5C+X3xbX9uV79A2k9QqCgWhGkdxSmpGfivOZSzfVNZ3e81fgIeF7f3bbs
uMLs2dpo46XSAOa+fl7GEKIt72824TiQSve+HpqqUv+qt2F5QcBldlwbqv0eJdF+
VmfERYXWM8sgLSLru7L7
=c0/4
-----END PGP SIGNATURE-----
Merge tag 'drm/tegra/for-4.4-rc1' of git://anongit.freedesktop.org/tegra/linux into drm-next
drm/tegra: Changes for v4.4-rc1
Just a couple of minor fixes and cleanups for this cycle.
* tag 'drm/tegra/for-4.4-rc1' of git://anongit.freedesktop.org/tegra/linux:
drm/tegra: dc: Request/free syncpoint at init/exit
drm/tegra: fb: Remove gratuituous blank line
gpu: host1x: Fix MLOCK's debug info
- Some correctness fixes found by coccinelle
- Add drivers/gpu/ipu-v3 directory to MAINTAINERS
- Add support for more color formats
- Fix a regression, making displays larger than FullHD work again
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
iQIcBAABAgAGBQJWM5loAAoJEFDCiBxwnmDrLwkQAOd2iOsgGemyffmh8shGwGq4
pVgw/2Z9FzdlLXe21R9B8rYOsvq/QR74m49blNGSwlNO6c2L3+65BBkyc2VQoI6t
c3GX0w2mnjqfHOZYiBT1Ca84FT1DBXjOprhljVbCBBZOr0xK4jRY3YBtlk30r8Yv
RlithxYNWjoCBidf4w7FyCKM7tIN7bNXXGtyysAMzNuXU7Mq3dfhF8/qYucYFmYP
XHOxFFX/q4EYchcQBCQi56kxEgEHtaFc+pwzM7mCwN5OVETcVeHw0EoTm56AjQrL
zHwBXvP4ryKpuNFCUqsMdy9KZw+4inHycAjfEKwD2s72llycx+W+Kbg/00Ve8rWn
6/Iv4Q0SuSSuRn4fWfioWSdQqHBZig3Y0AWCQ8BVCdTL2K2KIyxcT45vamo/zQhw
uxRVxQzEUle4ZJJ4DOt5h4ZHF70eQNM9TDGYYSKUqtfQcbZ6pr6mz36J9PgyQuh7
lTOfC5OZstTmS1iK+dqb5zbxhC76ff+v1lS8oTyJPK207f0hwt5OXTki9i7TueUH
DXbPmrotajFWoNOkgFPcBBQaI6P5+29lzFqXE2z43Qk6UoYmR4T+UbpD2nNKaj+I
qsIvgn4Zkg2RkxXehVQxRqynxx7XzfXVBXmtpbDfm50PoWsQMQa7fUiqWTyAp493
zQybk9I0eNexJNFIzyie
=EqNE
-----END PGP SIGNATURE-----
Merge tag 'imx-drm-next-2015-10-30' of git://git.pengutronix.de/git/pza/linux into drm-next
imx-drm fixes and color format updates
- Some correctness fixes found by coccinelle
- Add drivers/gpu/ipu-v3 directory to MAINTAINERS
- Add support for more color formats
- Fix a regression, making displays larger than FullHD work again
* tag 'imx-drm-next-2015-10-30' of git://git.pengutronix.de/git/pza/linux:
drm/imx: hdmi: fix HDMI setup to allow modes larger than FullHD
gpu: ipu-v3: fix div_ratio type
gpu: ipu-v3: csi: add support for 8 bpp grayscale sensors.
drm/imx: enable ARGB4444 16-bit color format
gpu: ipu-v3: add support for ARGB4444 16-bit color format
drm/imx: ipuv3-plane: enable support for RGBX8888 and RGBA8888 pixel formats
gpu: ipu-v3: add support for RGBX8888 and RGBA8888 pixel formats
drm/imx: enable 15-bit RGB with 1-bit alpha formats
gpu: ipu-v3: add support for 15-bit RGB with 1-bit alpha formats
MAINTAINERS: Add IPUv3 core driver to the i.MX DRM driver section
gpu: ipu-v3: ipu-csi: bool test doesn't need a comparison to false
- Updated register headers for GFX 8.1 for Stoney
- Add some new CZ revisions
- minor pageflip optimizations
- Fencing clean up
- Warning fix
- More fence cleanup
- oops fix
- Fiji fixes
* 'drm-next-4.4' of git://people.freedesktop.org/~agd5f/linux: (29 commits)
drm/amdgpu: group together common fence implementation
drm/amdgpu: remove AMDGPU_FENCE_OWNER_MOVE
drm/amdgpu: remove now unused fence functions
drm/amdgpu: fix fence fallback check
drm/amdgpu: fix stoping the scheduler timeout
drm/amdgpu: cleanup on error in amdgpu_cs_ioctl()
drm/amdgpu: update Fiji's Golden setting
drm/amdgpu: update Fiji's rev id
drm/amdgpu: extract common code in vi_common_early_init
drm/amd/scheduler: don't oops on failure to load
drm/amdgpu: don't oops on failure to load (v2)
drm/amdgpu: don't VT switch on suspend
drm/amdgpu: Make amdgpu_mn functions inline
drm/amdgpu: remove amdgpu_fence_ref/unref
drm/amdgpu: use common fence for sync
drm/amdgpu: use the new fence_is_later
drm/amdgpu: use common fences for VMID management v2
drm/amdgpu: move ring_from_fence to common code
drm/amdgpu: switch to common fence_wait_any_timeout v2
drm/amdgpu: remove unneeded fence functions
...
And also add some missing function documentation. No functional change.
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Chunming Zhou <david1.zhou@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Moves are exclusive operations anyway, just use the undefined owner for those.
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Chunming Zhou <david1.zhou@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Chunming Zhou <david1.zhou@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Interrupts are notorious unreliable, enable the fallback at
a couple of more places.
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Chunming Zhou <david1.zhou@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
cancel_delayed_work_sync is forbidden in interrupt context.
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Chunming Zhou <david1.zhou@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
We recently changed the locking in this function and now there is a
missing unlock on error. Also there are some other resources that we
should probably release as well...
Fixes: f48b2659f5 ('drm/amdgpu: fix the broken vm->mutex V2')
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
In two places amdgpu tries to tear down something it hasn't
initalised when failing. This is what happens when you
enable experimental support on topaz which then fails in
ring init.
This patch allows it to fail cleanly.
agd: Split out from from the original patch since the
scheduler is a driver independent.
Reviewed-by: Chunming Zhou <david1.zhou@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
In two places amdgpu tries to tear down something it hasn't
initalised when failing. This is what happens when you
enable experimental support on topaz which then fails in
ring init.
This patch allows it to fail cleanly.
v2 (agd): split out scheduler change into a separate patch
Reviewed-by: Chunming Zhou <david1.zhou@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
- Vast improvements to gk20a instmem handling.
- Improved PGOB detection + GK107 support.
- Compatibility between old/new interfaces added, final missing piece to
finally enabling userspace to start using them.
- Kepler GDDR5 PLL stability improvements
- Support for non-GPIO (PWM) voltage controllers
- G8x/GT2xx memory clock improvements
- Misc other fixes
* 'linux-4.4' of git://anongit.freedesktop.org/git/nouveau/linux-2.6: (45 commits)
drm/nouveau: bump patchlevel to indicate availability of abi16/nvif interop
drm/nouveau/abi16: implement limited interoperability with usif/nvif
drm/nouveau/abi16: introduce locked variant of nouveau_abi16_get()
drm/nouveau/abi16: remove unused argument from nouveau_abi16_get()
drm/nouveau/pci: enable c800 magic for Medion Erazer X7827
drm/nouveau/pci: enable c800 magic for Lenovo Y510P
drm/nouveau/pll/gk104: fix PLL instability due to bad configuration with gddr5
drm/nouveau/clk/g84: Enable reclocking for GDDR3 G94-G200
drm/nouveau/bus/hwsq: Implement VBLANK waiting heuristic
drm/nouveau/fb/ramnv50: Script changes for G94 and up
drm/nouveau/fb/ramnv50: Deal with cards without timing entries
drm/nouveau/fb/ramnv50: Voltage GPIOs
drm/nouveau/fb/ramgt215: Restructure r111100 calculation for DDR2
drm/nouveau/fb/ramgt215: Change FBVDD/Q when BIOS asks for it
drm/nouveau/fb/ramgt215: Transform GPIO ramfuc method from FBVREF-specific to generic
drm/nouveau/bios/rammap: Identify DLLoff for >= GF100
drm/nouveau/pci: Handle 5-bit and 8-bit tag field
drm/nouveau/disp,pm: constify nvkm_object_func structures
drm/nouveau/gr: add FERMI_COMPUTE_B class to GF110+
drm/nouveau/gr: document mp error 0x10
...
This pull request includes comprehensive cleanups to HDMI part and
several fixups. In addition, this pull request includes also a defconfig
patch which enables mixer driver as default. For this, I got already
Acked-by from Krzysztof Kozlowski who is a Exynos SoC maintainer.
* 'exynos-drm-next' of git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos: (34 commits)
drm/exynos/gem: remove DMA-mapping hacks used for constructing page array
ARM: exynos_defconfig: enable Exynos DRM Mixer driver
drm/exynos: simplify Kconfig component names
drm/exynos: re-arrange Kconfig entries
drm/exynos: abstract out common dependency
drm/exynos: separate Mixer and HDMI drivers
drm/exynos/mixer: replace direct cross-driver call with drm mode validation
drm/exynos: add atomic_check callback to exynos_crtc
drm/exynos/decon5433: add support for DECON-TV
drm/exynos/decon5433: remove duplicated initialization
drm/exynos/decon5433: merge different flag fields
drm/exynos/decon5433: add function to set particular register bits
drm/exynos/decon5433: fix timing registers writes
drm/exynos/decon5433: add PCLK clock
drm/exynos: cleanup name of gem object for exynos_drm
drm/exynos: fix to detach device of iommu
drm/exynos: add cursor plane support
drm/exynos: add global macro for the default primary plane
drm/exynos: fix spelling errors
drm: exynos: mixer: fix using usleep() in atomic context
...
USIF already takes the client mutex, but will need access to ABI16 data
in order to provide some limited interoperability.
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
This patch uses an approach closer to the nvidia driver to configure
both PLLs for high gddr5 memory clocks (usually above 2400MHz)
Previously nouveau used the one PLL as it was used for the lower clocks
and just adjusted the second PLL to get as close as possible to the
requested clock. This means for my card, that I got a 4050 MHz clock
although 4008 MHz was requested.
Now the driver iterates over a list of PLL configuration also used by
the nvidia driver and then adjust the second PLL to get near the
requested clock. Also it hold to some restriction I found while
analyzing the PLL configurations
This won't fix all gddr5 high clock issues itself, but it should be
fine on hybrid gpu systems as found on many laptops these days. Also
switching while normal desktop usage should be a lot more stable than
before.
v2: move the pll code into ramgk104
Signed-off-by: Karol Herbst <nouveau@karolherbst.de>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>