Markus Elfring
ecab76688a
drm/amdgpu: Use kmalloc_array() in amdgpu_debugfs_gca_config_read()
...
A multiplication for the size determination of a memory allocation
indicated that an array data structure should be processed.
Thus use the corresponding function "kmalloc_array".
This issue was detected by using the Coccinelle software.
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 14:38:27 -04:00
Tom St Denis
f2cdaf2066
drm/amd/amdgpu: Hook up read_sensor() to debugfs (v2)
...
(v2) Tidy'ed up read function.
Signed-off-by: Tom St Denis <tom.stdenis@amd.com >
Reviewed-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 14:38:26 -04:00
Tom St Denis
a6e3695221
drm/amd/powerplay: Add read_sensor() callback to hwmgr (v3)
...
Provides standardized interface to read various sensors.
The API is extensible (by adding to the end of the
amd_pp_sensors enumeration list.
Support has been added to Carrizo/smu7
(v2) Squashed the two sensor patches into one.
(v3) Updated to apply to smu7_hwmgr instead
Signed-off-by: Tom St Denis <tom.stdenis@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 14:38:26 -04:00
Huang Rui
167ac5733c
drm/amdgpu: implement raster configuration for gfx v8
...
This patch is to implement the raster configuration and harvested
configuration of gfx v8.
Signed-off-by: Huang Rui <ray.huang@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Acked-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 14:38:25 -04:00
Huang Rui
0b2138a455
drm/amdgpu: implement raster configuration for gfx v7
...
This patch is to implement the raster configuration and harvested
configuration of gfx v7.
Signed-off-by: Huang Rui <ray.huang@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Acked-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 14:38:25 -04:00
Huang Rui
865ab832ba
drm/amdgpu: implement raster configuration for gfx v6
...
This patch is to implement the raster configuration and harvested
configuration of gfx v6.
Signed-off-by: Huang Rui <ray.huang@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Acked-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 14:38:24 -04:00
Edward O'Callaghan
e88a614c40
drm/amdkfd: Pass 'struct queue_propertices' by reference
...
Allow init_queue() to take 'struct queue_properties' by reference.
Signed-off-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Reviewed-by: Oded Gabbay <oded.gabbay@gmail.com >
Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com >
2016-09-19 20:58:35 +03:00
Edward O'Callaghan
6f4d92a127
drm/amdkfd: Unify multiple calls to pr_debug() into one
...
Signed-off-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Reviewed-by: Oded Gabbay <oded.gabbay@gmail.com >
Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com >
2016-09-19 20:58:35 +03:00
Edward O'Callaghan
1d602430d3
drm/amdkfd: Fix possible infinite loop
...
When the loop predicating timeout parameter passed happens to
not be a multiple of 20 the unsigned integer will overflow and
the loop will become unbounded.
Signed-off-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Reviewed-by: Oded Gabbay <oded.gabbay@gmail.com >
Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com >
2016-09-19 20:58:35 +03:00
Edward O'Callaghan
ad16a469ff
drm/amdkfd: Reuse function to find a process through pasid
...
The kfd_lookup_process_by_pasid() is just for that purpose,
so use it instead of repeating the code.
v2: return on the condition (p == NULL) instead of BUG_ON(!p).
Signed-off-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Reviewed-by: Oded Gabbay <oded.gabbay@gmail.com >
Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com >
2016-09-19 20:58:35 +03:00
Edward O'Callaghan
78b13f7964
drm/amdkfd: Add some missing memset zero'ing in queue init func
...
Signed-off-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Reviewed-by: Oded Gabbay <oded.gabbay@gmail.com >
Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com >
2016-09-19 20:58:35 +03:00
Edward O'Callaghan
585f0e6c53
drm/amdkfd: Tidy up kfd_generate_gpu_id() uint64_t bitshift unpack
...
Dereference the one time and unpack the lower and upper 32bit
portions with the proper kernel helper macros.
Signed-off-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Reviewed-by: Oded Gabbay <oded.gabbay@gmail.com >
Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com >
2016-09-19 20:58:35 +03:00
Rex Zhu
e805ed83ba
drm/amd/powerplay: delete useless files.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:17 -04:00
Rex Zhu
ab4f06d3ad
drm/amd/powerplay: use smu7 hwmgr to manager iceland
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:17 -04:00
Rex Zhu
18aafc59b1
drm/amd/powerplay: implement fw related smu interface for iceland.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:16 -04:00
Rex Zhu
9c6d495696
drm/amd/powerplay: use smu7 common functions and data on icelannd.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:16 -04:00
Rex Zhu
5746f90c56
drm/amd/powerplay: use smu7 common functions and data on Fiji.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:15 -04:00
Rex Zhu
d01ec3fb8c
drm/amd/powerplay: use smu7 common functions and data on Polars10.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:15 -04:00
Rex Zhu
ac43f0800f
drm/amd/powerplay: use smu7 common functions and data on Tonga.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:14 -04:00
Rex Zhu
1ff55f4651
drm/amd/powerplay: implement smu7_smumgr for asics with smu ip version 7.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:14 -04:00
Rex Zhu
fb044ed90c
drm/amd/powerplay: use smu7_hwmgr to manager tonga.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:13 -04:00
Rex Zhu
1486022088
drm/amd/powerplay: implement fw image related smum interface for tonga.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:12 -04:00
Rex Zhu
b859c20703
drm/amd/powerplay: use smu7 hwmgr to manager fiji
...
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:12 -04:00
Rex Zhu
18edef19ea
drm/amd/powerplay: implement fw image related smu interface for Fiji.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:11 -04:00
Rex Zhu
4be051aeb3
drm/amd/powerplay: use smu7 hwmgr to manager polaris10/11
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:11 -04:00
Rex Zhu
34a564eaf5
drm/amd/powerplay: implement fw image related smum interface for Polaris.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:10 -04:00
Rex Zhu
599a7e9fe1
drm/amd/powerplay: implement smu7 hwmgr to manager asics with smu ip version 7.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Reviewed-by: Ken Wang <Qingqing.Wang@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:10 -04:00
Rex Zhu
ee1a51f882
drm/amd/powerplay: add common interface in smumgr to help to visit fw image.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:09 -04:00
Rex Zhu
6a99a964f6
drm/amd/powerplay: add parameter of the mclk switch latency time
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Ken Wang <Qingqing.Wang@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:09 -04:00
Rex Zhu
c07aefc268
drm/amd/powerplay: fix potential issue of array access violation
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:08 -04:00
Rex Zhu
9716ebc38d
drm/amd/powerplay: fix mclk not switching back after multi-head was disabled
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
Cc: stable@vger.kernel.org
2016-09-19 13:22:08 -04:00
Alex Deucher
f2aba352a9
Revert "drm/radeon: skip suspend/resume on DRM_SWITCH_POWER_DYNAMIC_OFF"
...
This is not necessary as pointed out by Lukas Wunner.
This reverts commit 5e0b1617fc
.
2016-09-19 13:22:07 -04:00
Alex Deucher
e313de7e89
Revert "drm/amdgpu: skip suspend/resume on DRM_SWITCH_POWER_DYNAMIC_OFF"
...
This is not necessary as pointed out by Lukas Wunner.
This reverts commit f46cf3735f
.
2016-09-19 13:22:06 -04:00
Alex Deucher
02124a03e6
drm/amdgpu/dce6: fix off by one in interrupt setup
...
Reviewed-by: Tom St Denis <tom.stdenis@amd.com >
Reported-by: Christian Inci <chris.pcguy.inci@gmail.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:21:54 -04:00
Jani Nikula
8e4f768c43
drm/i915/dsi: double check element parsing against size if present
...
Be a little paranoid in case the specs change or something.
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Link: http://patchwork.freedesktop.org/patch/msgid/27050d48d0ff3d58e79fcacc41ced4c071b01424.1474286487.git.jani.nikula@intel.com
2016-09-19 18:38:11 +03:00
Jani Nikula
4b4f497e13
drm/i915/bios: log about presence of DSI sequences we do not run
...
Leave behind some debugging clues in case some panels don't work
properly.
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Link: http://patchwork.freedesktop.org/patch/msgid/b36302b24676af511f4bbf702be21cc7e8f987c2.1474286487.git.jani.nikula@intel.com
2016-09-19 18:38:02 +03:00
Jani Nikula
416062d017
drm/i915/dsi: run backlight on/off sequences in panel enable/disable hooks
...
Based on the documentation alone, it's anyone's guess when exactly we
should be running these sequences. Add them where it feels logical. The
drm panel hooks don't currently offer us more granularity anyway.
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Link: http://patchwork.freedesktop.org/patch/msgid/267c4a2bde2076af18e9b8335c0bef2e26ea3112.1474286487.git.jani.nikula@intel.com
2016-09-19 18:37:54 +03:00
Jani Nikula
b1cb1bd291
drm/i915/dsi: update reset and power sequences in panel prepare/unprepare hooks
...
Based on the documentation alone, it's anyone's guess when exactly we
should be running these sequences. Add power on/off sequences where they
feel logical and update assert/deassert reset. The drm panel hooks don't
currently offer us more granularity anyway.
v2: update assert/deassert reset as well (Ville)
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Link: http://patchwork.freedesktop.org/patch/msgid/1543320494df953fa073e136248238eaa1eed059.1474286487.git.jani.nikula@intel.com
2016-09-19 18:37:45 +03:00
Jani Nikula
044aad65ee
drm/i915/dsi: add skip functions for spi and pmic elements
...
In sequence block v3 these are gracefully skipped anyway, but add the
functions so we can have some debug breadcrumbs.
v2: the pmic block is 15 bytes (Ville)
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Link: http://patchwork.freedesktop.org/patch/msgid/d102ef1f21e6ea9a17655ef31593e68343336a48.1474286487.git.jani.nikula@intel.com
2016-09-19 18:37:36 +03:00
Jani Nikula
0b9407c398
drm/i915/dsi: add debug logging to element execution
...
Just simple breadcrumbs for now. While at it, rename the i2c skip
function.
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Link: http://patchwork.freedesktop.org/patch/msgid/d11c40a99f5ef2419ede87a2ac1858e4c60768b8.1474286487.git.jani.nikula@intel.com
2016-09-19 18:37:23 +03:00
Jani Nikula
f7d3c970f4
drm/i915/dsi: don't debug log "missing" sequences
...
This is not interesting. They are not "missing", they are just not part
of the VBT sequences for the panel.
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Link: http://patchwork.freedesktop.org/patch/msgid/54909b29802398d23f1d26f6589671e69688f904.1474286487.git.jani.nikula@intel.com
2016-09-19 18:37:06 +03:00
Ville Syrjälä
699fbeeac4
drm/fb-helper: Fix sparse warnings
...
drm/drm_fb_helper.c:2306:12: warning: symbol 'drm_fb_helper_modinit' was not declared. Should it be static?
While at it, move the lefover static inline to the right place.
Cc: Daniel Vetter <daniel.vetter@ffwll.ch >
Cc: Sean Paul <seanpaul@chromium.org >
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Link: http://patchwork.freedesktop.org/patch/msgid/1474292035-15695-4-git-send-email-ville.syrjala@linux.intel.com
2016-09-19 16:45:15 +02:00
Ville Syrjälä
c30b440097
drm/blend: Fix sparse warnings
...
drm/drm_blend.c:207:5: warning: symbol 'drm_atomic_normalize_zpos' was not declared. Should it be static?
Cc: Marek Szyprowski <m.szyprowski@samsung.com >
Cc: Benjamin Gaignard <benjamin.gaignard@linaro.org >
Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com >
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Link: http://patchwork.freedesktop.org/patch/msgid/1474292035-15695-3-git-send-email-ville.syrjala@linux.intel.com
2016-09-19 16:44:45 +02:00
Ville Syrjälä
7135ac54ce
drm/atomic-helper: Fix sparse warnings
...
drm/drm_atomic_helper.c:1696:6: warning: symbol 'plane_crtc_active' was not declared. Should it be static?
Cc: Daniel Vetter <daniel.vetter@ffwll.ch >
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Link: http://patchwork.freedesktop.org/patch/msgid/1474292035-15695-2-git-send-email-ville.syrjala@linux.intel.com
2016-09-19 16:44:36 +02:00
Jani Nikula
96106c9729
drm: fix implicit declaration build error on ia64
...
drivers/gpu/drm/drm_dp_helper.c: In function 'drm_dp_downstream_debug':
>> drivers/gpu/drm/drm_dp_helper.c:551:2: error: implicit declaration of
>> function 'seq_printf' [-Werror=implicit-function-declaration]
seq_printf(m, "\tDP branch device present: %s\n",
^
>> drivers/gpu/drm/drm_dp_helper.c:559:3: error: implicit declaration of
>> function 'seq_puts' [-Werror=implicit-function-declaration]
seq_puts(m, "\t\tType: DisplayPort\n");
^
Reported-by: kbuild test robot <fengguang.wu@intel.com >
References: https://lists.freedesktop.org/archives/intel-gfx/2016-September/106638.html
Fixes: 80209e5f2c
("drm: Add DP branch device info on debugfs")
Cc: Mika Kahola <mika.kahola@intel.com >
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Link: http://patchwork.freedesktop.org/patch/msgid/1474020396-14875-1-git-send-email-jani.nikula@intel.com
2016-09-19 16:41:40 +02:00
Daniel Vetter
199e4e967a
drm: Extract drm_bridge.h
...
We don't want to burry the bridge structures kerneldoc in drm_crtc.h.
Cc: Archit Taneja <archit.taneja@gmail.com >
Reviewed-by: Archit Taneja <architt@codeaurora.org >
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com >
Link: http://patchwork.freedesktop.org/patch/msgid/20160831160913.12991-3-daniel.vetter@ffwll.ch
2016-09-19 15:04:15 +02:00
David Herrmann
2cc107dc5b
drm: cleanup drm_core_{init,exit}()
...
Various cleanups to the DRM core initialization and exit handlers:
- Register chrdev last: Once register_chrdev() returns, open() will
succeed on the given chrdevs. This is usually not an issue, as no
chardevs are registered, yet. However, nodes can be created by
user-space via mknod(2), even though such major/minor combinations are
unknown to the kernel. Avoid calling into drm_stub_open() in those
cases.
Again, drm_stub_open() would just bail out as the inode is unknown,
but it's really non-obvious if you hack on drm_stub_open().
- Unify error-paths into just one label. All the error-path helpers can
be called even though the constructors were not called yet, or failed.
Hence, just call all cleanups unconditionally.
- Call into drm_global_release(). This is a no-op, but provides
debugging helpers in case there're GLOBALS left on module unload. This
function was unused until now.
- Use DRM_ERROR() instead of printk(), and also print the error-code on
failure (even if it is static!).
- Don't throw away error-codes of register_chrdev()!
- Don't hardcode -1 as errno. This is just plain wrong.
- Order exit-handlers in the exact reverse order of initialization
(except if the order actually matters for syncing-reasons, which is
not the case here, though).
v2:
- Call drm_core_exit() directly from the init-error-handler. Requires to
drop __exit annotation, though.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com >
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Link: http://patchwork.freedesktop.org/patch/msgid/20160901124837.680-7-dh.herrmann@gmail.com
2016-09-19 13:57:39 +02:00
David Herrmann
82d5e73f6b
drm: drop obsolete drm_core.h
...
The drm_core.h header contains a set of constants meant to be used
throughout DRM. However, as it turns out, they're each used just once and
don't bring any benefit. They're also grossly mis-named and lack
name-spacing. This patch inlines them, or moves them into drm_internal.h
as appropriate:
- CORE_AUTHOR and CORE_DESC are inlined into corresponding MODULE_*()
macros. It's just confusing having to follow 2 pointers when trying to
find the definition of these fields. Grep'ping for MODULE_AUTHOR()
should reveal the full information, if there's no strong reason not to.
- CORE_NAME, CORE_DATE, CORE_MAJOR, CORE_MINOR, and CORE_PATCHLEVEL are
inlined into the sysfs 'version' attribute. They're stripped
everywhere else (which is just some printk() statements). CORE_NAME
just doesn't make *any* sense, as we hard-code it in many places,
anyway. The other constants are outdated and just serve
binary-compatibility purposes. Hence, inline them in 'version' sysfs
attribute (we might even try dropping it..).
- DRM_IF_MAJOR and DRM_IF_MINOR are moved into drm_internal.h as they're
only used by the global ioctl handlers. Furthermore, versioning
interfaces breaks backports and as such is deprecated, anyway. We just
keep them for historic reasons. I doubt anyone will ever modify them
again.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com >
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Link: http://patchwork.freedesktop.org/patch/msgid/20160901124837.680-6-dh.herrmann@gmail.com
2016-09-19 13:57:38 +02:00
David Herrmann
d9a1f0b4eb
drm: use drm_file to tag vm-bos
...
Rather than using "struct file*", use "struct drm_file*" as tag VM tag for
BOs. This will pave the way for "struct drm_file*" without any "struct
file*" back-pointer.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com >
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Link: http://patchwork.freedesktop.org/patch/msgid/20160901124837.680-3-dh.herrmann@gmail.com
2016-09-19 11:22:08 +02:00
David Herrmann
75ae95a75d
drm: remove redundant drm_file->uid
...
Each DRM file-context caches the EUID of the process that opened the file.
It is used exclusively for debugging purposes in /proc/dri/ and friends.
Note, however, that we can already fetch the EUID from
priv->pid->task->creds. The pointer-chasing will not hurt us, since it is
only about debugging, anyway.
Since we already are in an rcu-read-side, we can use __task_cred() rather
than task_cred_xxx().
Signed-off-by: David Herrmann <dh.herrmann@gmail.com >
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Link: http://patchwork.freedesktop.org/patch/msgid/20160901124837.680-2-dh.herrmann@gmail.com
2016-09-19 11:21:42 +02:00