amd-gfx.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU
@ 2020-11-06 21:49 Lee Jones
  2020-11-06 21:49 ` [PATCH 06/19] drm/radeon/atom: Move prototype into shared location Lee Jones
                   ` (13 more replies)
  0 siblings, 14 replies; 44+ messages in thread
From: Lee Jones @ 2020-11-06 21:49 UTC (permalink / raw)
  To: lee.jones
  Cc: David Airlie, dri-devel, Eric Anholt, Huang Rui, Rob Clark,
	Gareth Hughes, Sumit Semwal, amd-gfx, Rob Clark, Tomi Valkeinen,
	Keith Whitwell, Andy Gross, Harry Wentland, linux-media,
	Daniel Vetter, Leo Li, linaro-mm-sig, by, Jeff Hartmann,
	linux-kernel, Faith, Philipp Zabel, Alex Deucher,
	Christian Koenig

This set is part of a larger effort attempting to clean-up W=1
kernel builds, which are currently overwhelmingly riddled with
niggly little warnings.

There are 5000 warnings to work through.  It will take a couple more
sets.  Although, ("drm/amd/display/dc/basics/fixpt31_32: Move
variables to where they're used") does take care of 2000 of them!

Lee Jones (19):
  drm/ttm/ttm_range_manager: Demote non-conformant kernel-doc header
  drm/r128/ati_pcigart: Source file headers are not good candidates for
    kernel-doc
  drm/selftests/test-drm_dp_mst_helper: Move
    'sideband_msg_req_encode_decode' onto the heap
  drm/mga/mga_dma: Demote kernel-doc abusers to standard comment blocks
  drm/mga/mga_state: Remove unused variable 'buf_priv'
  drm/radeon/atom: Move prototype into shared location
  drm/radeon/radeon_kms: Include header containing our own prototypes
  drm/omapdrm/omap_gem: Fix misnamed and missing parameter descriptions
  drm/omapdrm/omap_dmm_tiler: Demote abusive use of kernel-doc format
  drm/radeon/radeon: Move prototype into shared header
  drm/radeon/radeon_drv: Source file headers are not good candidates for
    kernel-doc
  drm/amd/display/dc/basics/fixpt31_32: Move variables to where they're
    used
  drm/radeon/radeon_drv: Move prototypes to a shared headerfile
  drm/amd/amdgpu/amdgpu_device: Provide documentation for 'reg_addr'
    params
  drm/radeon: Move prototypes to shared header
  drm/amd/amdgpu/amdgpu_kms: Remove 'struct drm_amdgpu_info_device
    dev_info' from the stack
  drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
  drm/radeon/atombios_crtc: Remove description of non-existent function
    param 'encoder'
  drm/v3d/v3d_drv: Remove unused static variable 'v3d_v3d_pm_ops'

 drivers/gpu/drm/amd/amdgpu/amdgpu_device.c    |   2 +
 drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c       | 104 +++++++++---------
 .../drm/amd/display/dc/basics/fixpt31_32.c    |   5 +
 .../gpu/drm/amd/display/include/fixed31_32.h  |   6 -
 drivers/gpu/drm/mga/mga_dma.c                 |  10 +-
 drivers/gpu/drm/mga/mga_state.c               |   2 -
 drivers/gpu/drm/omapdrm/omap_dmm_tiler.c      |   6 +-
 drivers/gpu/drm/omapdrm/omap_gem.c            |   3 +-
 drivers/gpu/drm/r128/ati_pcigart.c            |   2 +-
 drivers/gpu/drm/radeon/atom.h                 |   6 +
 drivers/gpu/drm/radeon/atombios_crtc.c        |   1 -
 drivers/gpu/drm/radeon/atombios_encoders.c    |   4 -
 drivers/gpu/drm/radeon/radeon.h               |   6 +
 drivers/gpu/drm/radeon/radeon_device.c        |   1 +
 drivers/gpu/drm/radeon/radeon_device.h        |  32 ++++++
 drivers/gpu/drm/radeon/radeon_display.c       |   4 -
 drivers/gpu/drm/radeon/radeon_drv.c           |  11 +-
 drivers/gpu/drm/radeon/radeon_drv.h           |   7 ++
 drivers/gpu/drm/radeon/radeon_kms.c           |   3 +-
 .../drm/selftests/test-drm_dp_mst_helper.c    |  11 +-
 drivers/gpu/drm/ttm/ttm_range_manager.c       |   2 +-
 drivers/gpu/drm/v3d/v3d_drv.c                 |  36 ------
 22 files changed, 138 insertions(+), 126 deletions(-)
 create mode 100644 drivers/gpu/drm/radeon/radeon_device.h

Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: amd-gfx@lists.freedesktop.org
Cc: Andy Gross <andy.gross@ti.com>
Cc: by <jhartmann@precisioninsight.com>
Cc: Christian Koenig <christian.koenig@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: David Airlie <airlied@linux.ie>
Cc: dri-devel@lists.freedesktop.org
Cc: Eric Anholt <eric@anholt.net>
Cc: Faith <faith@valinux.com>
Cc: Gareth Hughes <gareth@valinux.com>
Cc: Harry Wentland <harry.wentland@amd.com>
Cc: Huang Rui <ray.huang@amd.com>
Cc: Jeff Hartmann <jhartmann@valinux.com>
Cc: Keith Whitwell <keith@tungstengraphics.com>
Cc: Leo Li <sunpeng.li@amd.com>
Cc: linaro-mm-sig@lists.linaro.org
Cc: linux-media@vger.kernel.org
Cc: Philipp Zabel <p.zabel@pengutronix.de>
Cc: Rob Clark <rob.clark@linaro.org>
Cc: Rob Clark <rob@ti.com>
Cc: Sumit Semwal <sumit.semwal@linaro.org>
Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
-- 
2.25.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* [PATCH 06/19] drm/radeon/atom: Move prototype into shared location
  2020-11-06 21:49 [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Lee Jones
@ 2020-11-06 21:49 ` Lee Jones
  2020-11-10 21:54   ` Alex Deucher
  2020-11-06 21:49 ` [PATCH 07/19] drm/radeon/radeon_kms: Include header containing our own prototypes Lee Jones
                   ` (12 subsequent siblings)
  13 siblings, 1 reply; 44+ messages in thread
From: Lee Jones @ 2020-11-06 21:49 UTC (permalink / raw)
  To: lee.jones
  Cc: David Airlie, linux-kernel, amd-gfx, dri-devel, Daniel Vetter,
	Alex Deucher, Christian König

Both source files include atom.h, which seems like a reasonable
location to place an atom based function into.

Fixes the following W=1 kernel build warning(s):

 drivers/gpu/drm/radeon/radeon_atombios.c:1791:6: warning: no previous prototype for ‘radeon_atom_get_tv_timings’ [-Wmissing-prototypes]
 1791 | bool radeon_atom_get_tv_timings(struct radeon_device *rdev, int index,
 | ^~~~~~~~~~~~~~~~~~~~~~~~~~

Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: David Airlie <airlied@linux.ie>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: amd-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/gpu/drm/radeon/atom.h              | 6 ++++++
 drivers/gpu/drm/radeon/atombios_encoders.c | 4 ----
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/radeon/atom.h b/drivers/gpu/drm/radeon/atom.h
index 1bf06c91cd959..cb93b83114dbe 100644
--- a/drivers/gpu/drm/radeon/atom.h
+++ b/drivers/gpu/drm/radeon/atom.h
@@ -154,6 +154,12 @@ bool atom_parse_data_header(struct atom_context *ctx, int index, uint16_t *size,
 bool atom_parse_cmd_header(struct atom_context *ctx, int index,
 			   uint8_t *frev, uint8_t *crev);
 int atom_allocate_fb_scratch(struct atom_context *ctx);
+
+struct drm_display_mode;
+struct radeon_device;
+bool radeon_atom_get_tv_timings(struct radeon_device *rdev, int index,
+				struct drm_display_mode *mode);
+
 #include "atom-types.h"
 #include "atombios.h"
 #include "ObjectID.h"
diff --git a/drivers/gpu/drm/radeon/atombios_encoders.c b/drivers/gpu/drm/radeon/atombios_encoders.c
index cc5ee1b3af84f..85f903caf12e1 100644
--- a/drivers/gpu/drm/radeon/atombios_encoders.c
+++ b/drivers/gpu/drm/radeon/atombios_encoders.c
@@ -296,10 +296,6 @@ static void radeon_atom_backlight_exit(struct radeon_encoder *encoder)
 
 #endif
 
-/* evil but including atombios.h is much worse */
-bool radeon_atom_get_tv_timings(struct radeon_device *rdev, int index,
-				struct drm_display_mode *mode);
-
 static bool radeon_atom_mode_fixup(struct drm_encoder *encoder,
 				   const struct drm_display_mode *mode,
 				   struct drm_display_mode *adjusted_mode)
-- 
2.25.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 44+ messages in thread

* [PATCH 07/19] drm/radeon/radeon_kms: Include header containing our own prototypes
  2020-11-06 21:49 [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Lee Jones
  2020-11-06 21:49 ` [PATCH 06/19] drm/radeon/atom: Move prototype into shared location Lee Jones
@ 2020-11-06 21:49 ` Lee Jones
  2020-11-10 21:55   ` Alex Deucher
  2020-11-06 21:49 ` [PATCH 10/19] drm/radeon/radeon: Move prototype into shared header Lee Jones
                   ` (11 subsequent siblings)
  13 siblings, 1 reply; 44+ messages in thread
From: Lee Jones @ 2020-11-06 21:49 UTC (permalink / raw)
  To: lee.jones
  Cc: David Airlie, linux-kernel, amd-gfx, dri-devel, Daniel Vetter,
	Alex Deucher, Christian König

Fixes the following W=1 kernel build warning(s):

 drivers/gpu/drm/radeon/radeon_kms.c:61:6: warning: no previous prototype for ‘radeon_driver_unload_kms’ [-Wmissing-prototypes]
 drivers/gpu/drm/radeon/radeon_kms.c:104:5: warning: no previous prototype for ‘radeon_driver_load_kms’ [-Wmissing-prototypes]
 drivers/gpu/drm/radeon/radeon_kms.c:618:6: warning: no previous prototype for ‘radeon_driver_lastclose_kms’ [-Wmissing-prototypes]
 drivers/gpu/drm/radeon/radeon_kms.c:633:5: warning: no previous prototype for ‘radeon_driver_open_kms’ [-Wmissing-prototypes]
 drivers/gpu/drm/radeon/radeon_kms.c:704:6: warning: no previous prototype for ‘radeon_driver_postclose_kms’ [-Wmissing-prototypes]
 drivers/gpu/drm/radeon/radeon_kms.c:755:5: warning: no previous prototype for ‘radeon_get_vblank_counter_kms’ [-Wmissing-prototypes]
 drivers/gpu/drm/radeon/radeon_kms.c:825:5: warning: no previous prototype for ‘radeon_enable_vblank_kms’ [-Wmissing-prototypes]
 drivers/gpu/drm/radeon/radeon_kms.c:852:6: warning: no previous prototype for ‘radeon_disable_vblank_kms’ [-Wmissing-prototypes]

Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: David Airlie <airlied@linux.ie>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: amd-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/gpu/drm/radeon/radeon_kms.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/gpu/drm/radeon/radeon_kms.c b/drivers/gpu/drm/radeon/radeon_kms.c
index 99ee60f8b604d..0d8fbabffcead 100644
--- a/drivers/gpu/drm/radeon/radeon_kms.c
+++ b/drivers/gpu/drm/radeon/radeon_kms.c
@@ -40,6 +40,7 @@
 
 #include "radeon.h"
 #include "radeon_asic.h"
+#include "radeon_drv.h"
 
 #if defined(CONFIG_VGA_SWITCHEROO)
 bool radeon_has_atpx(void);
-- 
2.25.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 44+ messages in thread

* [PATCH 10/19] drm/radeon/radeon: Move prototype into shared header
  2020-11-06 21:49 [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Lee Jones
  2020-11-06 21:49 ` [PATCH 06/19] drm/radeon/atom: Move prototype into shared location Lee Jones
  2020-11-06 21:49 ` [PATCH 07/19] drm/radeon/radeon_kms: Include header containing our own prototypes Lee Jones
@ 2020-11-06 21:49 ` Lee Jones
  2020-11-07 14:26   ` Sam Ravnborg
  2020-11-06 21:49 ` [PATCH 11/19] drm/radeon/radeon_drv: Source file headers are not good candidates for kernel-doc Lee Jones
                   ` (10 subsequent siblings)
  13 siblings, 1 reply; 44+ messages in thread
From: Lee Jones @ 2020-11-06 21:49 UTC (permalink / raw)
  To: lee.jones
  Cc: David Airlie, linux-kernel, amd-gfx, Christian König,
	linaro-mm-sig, dri-devel, Daniel Vetter, Alex Deucher,
	Sumit Semwal, linux-media

Unfortunately, a suitable one didn't already exist.

Fixes the following W=1 kernel build warning(s):

 drivers/gpu/drm/radeon/radeon_device.c:637:6: warning: no previous prototype for ‘radeon_device_is_virtual’ [-Wmissing-prototypes]
 637 | bool radeon_device_is_virtual(void)
 | ^~~~~~~~~~~~~~~~~~~~~~~~

Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: David Airlie <airlied@linux.ie>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: Sumit Semwal <sumit.semwal@linaro.org>
Cc: amd-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Cc: linux-media@vger.kernel.org
Cc: linaro-mm-sig@lists.linaro.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/gpu/drm/radeon/radeon_device.c |  1 +
 drivers/gpu/drm/radeon/radeon_device.h | 32 ++++++++++++++++++++++++++
 drivers/gpu/drm/radeon/radeon_drv.c    |  3 +--
 3 files changed, 34 insertions(+), 2 deletions(-)
 create mode 100644 drivers/gpu/drm/radeon/radeon_device.h

diff --git a/drivers/gpu/drm/radeon/radeon_device.c b/drivers/gpu/drm/radeon/radeon_device.c
index 7f384ffe848a7..ad572f965190b 100644
--- a/drivers/gpu/drm/radeon/radeon_device.c
+++ b/drivers/gpu/drm/radeon/radeon_device.c
@@ -42,6 +42,7 @@
 #include <drm/drm_probe_helper.h>
 #include <drm/radeon_drm.h>
 
+#include "radeon_device.h"
 #include "radeon_reg.h"
 #include "radeon.h"
 #include "atom.h"
diff --git a/drivers/gpu/drm/radeon/radeon_device.h b/drivers/gpu/drm/radeon/radeon_device.h
new file mode 100644
index 0000000000000..c8e6dd2005224
--- /dev/null
+++ b/drivers/gpu/drm/radeon/radeon_device.h
@@ -0,0 +1,32 @@
+/* radeon_drv.h -- Private header for radeon device -*- linux-c -*-
+ *
+ * Copyright 1999 Precision Insight, Inc., Cedar Park, Texas.
+ * Copyright 2000 VA Linux Systems, Inc., Fremont, California.
+ * All rights reserved.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the "Software"),
+ * to deal in the Software without restriction, including without limitation
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense,
+ * and/or sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice (including the next
+ * paragraph) shall be included in all copies or substantial portions of the
+ * Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
+ * PRECISION INSIGHT AND/OR ITS SUPPLIERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
+ * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
+ * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+ * DEALINGS IN THE SOFTWARE.
+ */
+
+#ifndef __RADEON_DEV_H__
+#define __RADEON_DEV_H__
+
+bool radeon_device_is_virtual(void);
+
+#endif				/* __RADEON_DEV_H__ */
diff --git a/drivers/gpu/drm/radeon/radeon_drv.c b/drivers/gpu/drm/radeon/radeon_drv.c
index f5f1cb700d873..560267cc25892 100644
--- a/drivers/gpu/drm/radeon/radeon_drv.c
+++ b/drivers/gpu/drm/radeon/radeon_drv.c
@@ -51,6 +51,7 @@
 #include <drm/radeon_drm.h>
 
 #include "radeon_drv.h"
+#include "radeon_device.h"
 
 /*
  * KMS wrapper.
@@ -300,8 +301,6 @@ MODULE_DEVICE_TABLE(pci, pciidlist);
 
 static struct drm_driver kms_driver;
 
-bool radeon_device_is_virtual(void);
-
 static int radeon_pci_probe(struct pci_dev *pdev,
 			    const struct pci_device_id *ent)
 {
-- 
2.25.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 44+ messages in thread

* [PATCH 11/19] drm/radeon/radeon_drv: Source file headers are not good candidates for kernel-doc
  2020-11-06 21:49 [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Lee Jones
                   ` (2 preceding siblings ...)
  2020-11-06 21:49 ` [PATCH 10/19] drm/radeon/radeon: Move prototype into shared header Lee Jones
@ 2020-11-06 21:49 ` Lee Jones
  2020-11-10 21:56   ` Alex Deucher
  2020-11-06 21:49 ` [PATCH 12/19] drm/amd/display/dc/basics/fixpt31_32: Move variables to where they're used Lee Jones
                   ` (9 subsequent siblings)
  13 siblings, 1 reply; 44+ messages in thread
From: Lee Jones @ 2020-11-06 21:49 UTC (permalink / raw)
  To: lee.jones
  Cc: David Airlie, linux-kernel, amd-gfx, dri-devel, Daniel Vetter,
	Alex Deucher, Gareth Hughes, Christian König

Fixes the following W=1 kernel build warning(s):

 drivers/gpu/drm/radeon/radeon_drv.c:2: warning: Cannot understand  * file radeon_drv.c

Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: David Airlie <airlied@linux.ie>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: Gareth Hughes <gareth@valinux.com>
Cc: amd-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/gpu/drm/radeon/radeon_drv.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/radeon/radeon_drv.c b/drivers/gpu/drm/radeon/radeon_drv.c
index 560267cc25892..bb7b33e535f81 100644
--- a/drivers/gpu/drm/radeon/radeon_drv.c
+++ b/drivers/gpu/drm/radeon/radeon_drv.c
@@ -1,4 +1,4 @@
-/**
+/*
  * \file radeon_drv.c
  * ATI Radeon driver
  *
-- 
2.25.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 44+ messages in thread

* [PATCH 12/19] drm/amd/display/dc/basics/fixpt31_32: Move variables to where they're used
  2020-11-06 21:49 [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Lee Jones
                   ` (3 preceding siblings ...)
  2020-11-06 21:49 ` [PATCH 11/19] drm/radeon/radeon_drv: Source file headers are not good candidates for kernel-doc Lee Jones
@ 2020-11-06 21:49 ` Lee Jones
  2020-11-09 19:58   ` Alex Deucher
  2020-11-06 21:49 ` [PATCH 13/19] drm/radeon/radeon_drv: Move prototypes to a shared headerfile Lee Jones
                   ` (8 subsequent siblings)
  13 siblings, 1 reply; 44+ messages in thread
From: Lee Jones @ 2020-11-06 21:49 UTC (permalink / raw)
  To: lee.jones
  Cc: Leo Li, linux-kernel, amd-gfx, David Airlie, dri-devel,
	Daniel Vetter, Alex Deucher, Harry Wentland,
	Christian König

Also rid some unused ones.

This patch solves 2000 warnings!

Fixes the following W=1 kernel build warning(s):

 In file included from drivers/gpu/drm/amd/amdgpu/../display/dc/dc_types.h:33,
 from drivers/gpu/drm/amd/amdgpu/../display/dc/dm_services_types.h:30,
 from drivers/gpu/drm/amd/amdgpu/../display/dc/dm_services.h:35,
 from drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/amdgpu_dm_helpers.c:35:
 At top level:
 drivers/gpu/drm/amd/amdgpu/../display/include/fixed31_32.h:76:32: warning: ‘dc_fixpt_ln2_div_2’ defined but not used [-Wunused-const-variable=]
 76 | static const struct fixed31_32 dc_fixpt_ln2_div_2 = { 1488522236LL };
 | ^~~~~~~~~~~~~~~~~~
 drivers/gpu/drm/amd/amdgpu/../display/include/fixed31_32.h:75:32: warning: ‘dc_fixpt_ln2’ defined but not used [-Wunused-const-variable=]
 75 | static const struct fixed31_32 dc_fixpt_ln2 = { 2977044471LL };
 | ^~~~~~~~~~~~
 drivers/gpu/drm/amd/amdgpu/../display/include/fixed31_32.h:74:32: warning: ‘dc_fixpt_e’ defined but not used [-Wunused-const-variable=]
 74 | static const struct fixed31_32 dc_fixpt_e = { 11674931555LL };
 | ^~~~~~~~~~
 drivers/gpu/drm/amd/amdgpu/../display/include/fixed31_32.h:73:32: warning: ‘dc_fixpt_two_pi’ defined but not used [-Wunused-const-variable=]
 73 | static const struct fixed31_32 dc_fixpt_two_pi = { 26986075409LL };
 | ^~~~~~~~~~~~~~~
 drivers/gpu/drm/amd/amdgpu/../display/include/fixed31_32.h:72:32: warning: ‘dc_fixpt_pi’ defined but not used [-Wunused-const-variable=]
 72 | static const struct fixed31_32 dc_fixpt_pi = { 13493037705LL };
 | ^~~~~~~~~~~

Cc: Harry Wentland <harry.wentland@amd.com>
Cc: Leo Li <sunpeng.li@amd.com>
Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: David Airlie <airlied@linux.ie>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: amd-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/gpu/drm/amd/display/dc/basics/fixpt31_32.c | 5 +++++
 drivers/gpu/drm/amd/display/include/fixed31_32.h   | 6 ------
 2 files changed, 5 insertions(+), 6 deletions(-)

diff --git a/drivers/gpu/drm/amd/display/dc/basics/fixpt31_32.c b/drivers/gpu/drm/amd/display/dc/basics/fixpt31_32.c
index 1e9a2d3520684..59f37563704ad 100644
--- a/drivers/gpu/drm/amd/display/dc/basics/fixpt31_32.c
+++ b/drivers/gpu/drm/amd/display/dc/basics/fixpt31_32.c
@@ -26,6 +26,11 @@
 #include "dm_services.h"
 #include "include/fixed31_32.h"
 
+static const struct fixed31_32 dc_fixpt_pi = { 13493037705LL };
+static const struct fixed31_32 dc_fixpt_two_pi = { 26986075409LL };
+static const struct fixed31_32 dc_fixpt_ln2 = { 2977044471LL };
+static const struct fixed31_32 dc_fixpt_ln2_div_2 = { 1488522236LL };
+
 static inline unsigned long long abs_i64(
 	long long arg)
 {
diff --git a/drivers/gpu/drm/amd/display/include/fixed31_32.h b/drivers/gpu/drm/amd/display/include/fixed31_32.h
index 16df2a485dd0d..22053d7ea6ced 100644
--- a/drivers/gpu/drm/amd/display/include/fixed31_32.h
+++ b/drivers/gpu/drm/amd/display/include/fixed31_32.h
@@ -69,12 +69,6 @@ static const struct fixed31_32 dc_fixpt_epsilon = { 1LL };
 static const struct fixed31_32 dc_fixpt_half = { 0x80000000LL };
 static const struct fixed31_32 dc_fixpt_one = { 0x100000000LL };
 
-static const struct fixed31_32 dc_fixpt_pi = { 13493037705LL };
-static const struct fixed31_32 dc_fixpt_two_pi = { 26986075409LL };
-static const struct fixed31_32 dc_fixpt_e = { 11674931555LL };
-static const struct fixed31_32 dc_fixpt_ln2 = { 2977044471LL };
-static const struct fixed31_32 dc_fixpt_ln2_div_2 = { 1488522236LL };
-
 /*
  * @brief
  * Initialization routines
-- 
2.25.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 44+ messages in thread

* [PATCH 13/19] drm/radeon/radeon_drv: Move prototypes to a shared headerfile
  2020-11-06 21:49 [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Lee Jones
                   ` (4 preceding siblings ...)
  2020-11-06 21:49 ` [PATCH 12/19] drm/amd/display/dc/basics/fixpt31_32: Move variables to where they're used Lee Jones
@ 2020-11-06 21:49 ` Lee Jones
  2020-11-10 21:58   ` Alex Deucher
  2020-11-06 21:49 ` [PATCH 14/19] drm/amd/amdgpu/amdgpu_device: Provide documentation for 'reg_addr' params Lee Jones
                   ` (7 subsequent siblings)
  13 siblings, 1 reply; 44+ messages in thread
From: Lee Jones @ 2020-11-06 21:49 UTC (permalink / raw)
  To: lee.jones
  Cc: David Airlie, linux-kernel, amd-gfx, dri-devel, Daniel Vetter,
	Alex Deucher, Gareth Hughes, Christian König

Fixes the following W=1 kernel build warning(s):

 62 | void radeon_driver_unload_kms(struct drm_device *dev)
 | ^~~~~~~~~~~~~~~~~~~~~~~~
 drivers/gpu/drm/radeon/radeon_kms.c:105:5: warning: no previous prototype for ‘radeon_driver_load_kms’ [-Wmissing-prototypes]
 105 | int radeon_driver_load_kms(struct drm_device *dev, unsigned long flags)
 | ^~~~~~~~~~~~~~~~~~~~~~
 drivers/gpu/drm/radeon/radeon_kms.c:619:6: warning: no previous prototype for ‘radeon_driver_lastclose_kms’ [-Wmissing-prototypes]
 619 | void radeon_driver_lastclose_kms(struct drm_device *dev)
 | ^~~~~~~~~~~~~~~~~~~~~~~~~~~
 drivers/gpu/drm/radeon/radeon_kms.c:634:5: warning: no previous prototype for ‘radeon_driver_open_kms’ [-Wmissing-prototypes]
 634 | int radeon_driver_open_kms(struct drm_device *dev, struct drm_file *file_priv)
 | ^~~~~~~~~~~~~~~~~~~~~~
 drivers/gpu/drm/radeon/radeon_kms.c:705:6: warning: no previous prototype for ‘radeon_driver_postclose_kms’ [-Wmissing-prototypes]
 705 | void radeon_driver_postclose_kms(struct drm_device *dev,
 | ^~~~~~~~~~~~~~~~~~~~~~~~~~~

Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: David Airlie <airlied@linux.ie>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: Gareth Hughes <gareth@valinux.com>
Cc: amd-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/gpu/drm/radeon/radeon_drv.c | 6 ------
 drivers/gpu/drm/radeon/radeon_drv.h | 7 +++++++
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/drivers/gpu/drm/radeon/radeon_drv.c b/drivers/gpu/drm/radeon/radeon_drv.c
index bb7b33e535f81..e0d664e9e2feb 100644
--- a/drivers/gpu/drm/radeon/radeon_drv.c
+++ b/drivers/gpu/drm/radeon/radeon_drv.c
@@ -112,12 +112,6 @@
 #define KMS_DRIVER_MAJOR	2
 #define KMS_DRIVER_MINOR	50
 #define KMS_DRIVER_PATCHLEVEL	0
-int radeon_driver_load_kms(struct drm_device *dev, unsigned long flags);
-void radeon_driver_unload_kms(struct drm_device *dev);
-void radeon_driver_lastclose_kms(struct drm_device *dev);
-int radeon_driver_open_kms(struct drm_device *dev, struct drm_file *file_priv);
-void radeon_driver_postclose_kms(struct drm_device *dev,
-				 struct drm_file *file_priv);
 int radeon_suspend_kms(struct drm_device *dev, bool suspend,
 		       bool fbcon, bool freeze);
 int radeon_resume_kms(struct drm_device *dev, bool resume, bool fbcon);
diff --git a/drivers/gpu/drm/radeon/radeon_drv.h b/drivers/gpu/drm/radeon/radeon_drv.h
index 173deb4634146..ac7970919c4d3 100644
--- a/drivers/gpu/drm/radeon/radeon_drv.h
+++ b/drivers/gpu/drm/radeon/radeon_drv.h
@@ -118,4 +118,11 @@
 long radeon_drm_ioctl(struct file *filp,
 		      unsigned int cmd, unsigned long arg);
 
+int radeon_driver_load_kms(struct drm_device *dev, unsigned long flags);
+void radeon_driver_unload_kms(struct drm_device *dev);
+void radeon_driver_lastclose_kms(struct drm_device *dev);
+int radeon_driver_open_kms(struct drm_device *dev, struct drm_file *file_priv);
+void radeon_driver_postclose_kms(struct drm_device *dev,
+				 struct drm_file *file_priv);
+
 #endif				/* __RADEON_DRV_H__ */
-- 
2.25.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 44+ messages in thread

* [PATCH 14/19] drm/amd/amdgpu/amdgpu_device: Provide documentation for 'reg_addr' params
  2020-11-06 21:49 [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Lee Jones
                   ` (5 preceding siblings ...)
  2020-11-06 21:49 ` [PATCH 13/19] drm/radeon/radeon_drv: Move prototypes to a shared headerfile Lee Jones
@ 2020-11-06 21:49 ` Lee Jones
  2020-11-09 19:54   ` Alex Deucher
  2020-11-06 21:49 ` [PATCH 15/19] drm/radeon: Move prototypes to shared header Lee Jones
                   ` (6 subsequent siblings)
  13 siblings, 1 reply; 44+ messages in thread
From: Lee Jones @ 2020-11-06 21:49 UTC (permalink / raw)
  To: lee.jones
  Cc: David Airlie, linux-kernel, amd-gfx, Christian König,
	linaro-mm-sig, dri-devel, Daniel Vetter, Alex Deucher,
	Sumit Semwal, linux-media

Fixes the following W=1 kernel build warning(s):

 drivers/gpu/drm/amd/amdgpu/amdgpu_device.c:594: warning: Function parameter or member 'reg_addr' not described in 'amdgpu_device_indirect_rreg'
 drivers/gpu/drm/amd/amdgpu/amdgpu_device.c:624: warning: Function parameter or member 'reg_addr' not described in 'amdgpu_device_indirect_rreg64'

Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: David Airlie <airlied@linux.ie>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: Sumit Semwal <sumit.semwal@linaro.org>
Cc: amd-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Cc: linux-media@vger.kernel.org
Cc: linaro-mm-sig@lists.linaro.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
index 300fcade4a2b1..63374d12e00fe 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
@@ -585,6 +585,7 @@ void amdgpu_mm_wdoorbell64(struct amdgpu_device *adev, u32 index, u64 v)
  * @adev: amdgpu_device pointer
  * @pcie_index: mmio register offset
  * @pcie_data: mmio register offset
+ * @reg_addr: indirect register address to read from
  *
  * Returns the value of indirect register @reg_addr
  */
@@ -615,6 +616,7 @@ u32 amdgpu_device_indirect_rreg(struct amdgpu_device *adev,
  * @adev: amdgpu_device pointer
  * @pcie_index: mmio register offset
  * @pcie_data: mmio register offset
+ * @reg_addr: indirect register address to read from
  *
  * Returns the value of indirect register @reg_addr
  */
-- 
2.25.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 44+ messages in thread

* [PATCH 15/19] drm/radeon: Move prototypes to shared header
  2020-11-06 21:49 [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Lee Jones
                   ` (6 preceding siblings ...)
  2020-11-06 21:49 ` [PATCH 14/19] drm/amd/amdgpu/amdgpu_device: Provide documentation for 'reg_addr' params Lee Jones
@ 2020-11-06 21:49 ` Lee Jones
  2020-11-10 21:59   ` Alex Deucher
  2020-11-06 21:49 ` [PATCH 16/19] drm/amd/amdgpu/amdgpu_kms: Remove 'struct drm_amdgpu_info_device dev_info' from the stack Lee Jones
                   ` (5 subsequent siblings)
  13 siblings, 1 reply; 44+ messages in thread
From: Lee Jones @ 2020-11-06 21:49 UTC (permalink / raw)
  To: lee.jones
  Cc: David Airlie, linux-kernel, amd-gfx, Christian König,
	linaro-mm-sig, dri-devel, Daniel Vetter, Alex Deucher,
	Sumit Semwal, linux-media

Fixes the following W=1 kernel build warning(s):

 drivers/gpu/drm/radeon/radeon_kms.c:756:5: warning: no previous prototype for ‘radeon_get_vblank_counter_kms’ [-Wmissing-prototypes]
 756 | u32 radeon_get_vblank_counter_kms(struct drm_crtc *crtc)
 | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 drivers/gpu/drm/radeon/radeon_kms.c:826:5: warning: no previous prototype for ‘radeon_enable_vblank_kms’ [-Wmissing-prototypes]
 826 | int radeon_enable_vblank_kms(struct drm_crtc *crtc)
 | ^~~~~~~~~~~~~~~~~~~~~~~~
 drivers/gpu/drm/radeon/radeon_kms.c:853:6: warning: no previous prototype for ‘radeon_disable_vblank_kms’ [-Wmissing-prototypes]
 853 | void radeon_disable_vblank_kms(struct drm_crtc *crtc)
 | ^~~~~~~~~~~~~~~~~~~~~~~~~

Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: David Airlie <airlied@linux.ie>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: Sumit Semwal <sumit.semwal@linaro.org>
Cc: amd-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Cc: linux-media@vger.kernel.org
Cc: linaro-mm-sig@lists.linaro.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/gpu/drm/radeon/radeon.h         | 6 ++++++
 drivers/gpu/drm/radeon/radeon_display.c | 4 ----
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/radeon/radeon.h b/drivers/gpu/drm/radeon/radeon.h
index e1132d86d2507..961a31b8805c2 100644
--- a/drivers/gpu/drm/radeon/radeon.h
+++ b/drivers/gpu/drm/radeon/radeon.h
@@ -2832,6 +2832,12 @@ extern void radeon_program_register_sequence(struct radeon_device *rdev,
 					     const u32 array_size);
 struct radeon_device *radeon_get_rdev(struct ttm_bo_device *bdev);
 
+/* KMS */
+
+u32 radeon_get_vblank_counter_kms(struct drm_crtc *crtc);
+int radeon_enable_vblank_kms(struct drm_crtc *crtc);
+void radeon_disable_vblank_kms(struct drm_crtc *crtc);
+
 /*
  * vm
  */
diff --git a/drivers/gpu/drm/radeon/radeon_display.c b/drivers/gpu/drm/radeon/radeon_display.c
index b79686cf8bdbd..bd60f16fd0d78 100644
--- a/drivers/gpu/drm/radeon/radeon_display.c
+++ b/drivers/gpu/drm/radeon/radeon_display.c
@@ -45,10 +45,6 @@
 #include "atom.h"
 #include "radeon.h"
 
-u32 radeon_get_vblank_counter_kms(struct drm_crtc *crtc);
-int radeon_enable_vblank_kms(struct drm_crtc *crtc);
-void radeon_disable_vblank_kms(struct drm_crtc *crtc);
-
 static void avivo_crtc_load_lut(struct drm_crtc *crtc)
 {
 	struct radeon_crtc *radeon_crtc = to_radeon_crtc(crtc);
-- 
2.25.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 44+ messages in thread

* [PATCH 16/19] drm/amd/amdgpu/amdgpu_kms: Remove 'struct drm_amdgpu_info_device dev_info' from the stack
  2020-11-06 21:49 [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Lee Jones
                   ` (7 preceding siblings ...)
  2020-11-06 21:49 ` [PATCH 15/19] drm/radeon: Move prototypes to shared header Lee Jones
@ 2020-11-06 21:49 ` Lee Jones
  2020-11-09 20:05   ` Alex Deucher
  2020-11-06 21:49 ` [PATCH 17/19] drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param Lee Jones
                   ` (4 subsequent siblings)
  13 siblings, 1 reply; 44+ messages in thread
From: Lee Jones @ 2020-11-06 21:49 UTC (permalink / raw)
  To: lee.jones
  Cc: David Airlie, linux-kernel, amd-gfx, dri-devel, Daniel Vetter,
	Alex Deucher, Christian König

Place it on the heap instead.

Fixes the following W=1 kernel build warning(s):

 drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c: In function ‘amdgpu_info_ioctl’:
 drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c:979:1: warning: the frame size of 1128 bytes is larger than 1024 bytes [-Wframe-larger-than=]

Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: David Airlie <airlied@linux.ie>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: amd-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 104 +++++++++++++-----------
 1 file changed, 55 insertions(+), 49 deletions(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
index 918d4e9c6461a..ef6fa5007d135 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
@@ -721,38 +721,42 @@ static int amdgpu_info_ioctl(struct drm_device *dev, void *data, struct drm_file
 		return n ? -EFAULT : 0;
 	}
 	case AMDGPU_INFO_DEV_INFO: {
-		struct drm_amdgpu_info_device dev_info;
+		struct drm_amdgpu_info_device *dev_info;
 		uint64_t vm_size;
+		int ret;
+
+		dev_info = kzalloc(sizeof(*dev_info), GFP_KERNEL);
+		if (!dev_info)
+			return -ENOMEM;
 
-		memset(&dev_info, 0, sizeof(dev_info));
-		dev_info.device_id = dev->pdev->device;
-		dev_info.chip_rev = adev->rev_id;
-		dev_info.external_rev = adev->external_rev_id;
-		dev_info.pci_rev = dev->pdev->revision;
-		dev_info.family = adev->family;
-		dev_info.num_shader_engines = adev->gfx.config.max_shader_engines;
-		dev_info.num_shader_arrays_per_engine = adev->gfx.config.max_sh_per_se;
+		dev_info->device_id = dev->pdev->device;
+		dev_info->chip_rev = adev->rev_id;
+		dev_info->external_rev = adev->external_rev_id;
+		dev_info->pci_rev = dev->pdev->revision;
+		dev_info->family = adev->family;
+		dev_info->num_shader_engines = adev->gfx.config.max_shader_engines;
+		dev_info->num_shader_arrays_per_engine = adev->gfx.config.max_sh_per_se;
 		/* return all clocks in KHz */
-		dev_info.gpu_counter_freq = amdgpu_asic_get_xclk(adev) * 10;
+		dev_info->gpu_counter_freq = amdgpu_asic_get_xclk(adev) * 10;
 		if (adev->pm.dpm_enabled) {
-			dev_info.max_engine_clock = amdgpu_dpm_get_sclk(adev, false) * 10;
-			dev_info.max_memory_clock = amdgpu_dpm_get_mclk(adev, false) * 10;
+			dev_info->max_engine_clock = amdgpu_dpm_get_sclk(adev, false) * 10;
+			dev_info->max_memory_clock = amdgpu_dpm_get_mclk(adev, false) * 10;
 		} else {
-			dev_info.max_engine_clock = adev->clock.default_sclk * 10;
-			dev_info.max_memory_clock = adev->clock.default_mclk * 10;
+			dev_info->max_engine_clock = adev->clock.default_sclk * 10;
+			dev_info->max_memory_clock = adev->clock.default_mclk * 10;
 		}
-		dev_info.enabled_rb_pipes_mask = adev->gfx.config.backend_enable_mask;
-		dev_info.num_rb_pipes = adev->gfx.config.max_backends_per_se *
+		dev_info->enabled_rb_pipes_mask = adev->gfx.config.backend_enable_mask;
+		dev_info->num_rb_pipes = adev->gfx.config.max_backends_per_se *
 			adev->gfx.config.max_shader_engines;
-		dev_info.num_hw_gfx_contexts = adev->gfx.config.max_hw_contexts;
-		dev_info._pad = 0;
-		dev_info.ids_flags = 0;
+		dev_info->num_hw_gfx_contexts = adev->gfx.config.max_hw_contexts;
+		dev_info->_pad = 0;
+		dev_info->ids_flags = 0;
 		if (adev->flags & AMD_IS_APU)
-			dev_info.ids_flags |= AMDGPU_IDS_FLAGS_FUSION;
+			dev_info->ids_flags |= AMDGPU_IDS_FLAGS_FUSION;
 		if (amdgpu_mcbp || amdgpu_sriov_vf(adev))
-			dev_info.ids_flags |= AMDGPU_IDS_FLAGS_PREEMPTION;
+			dev_info->ids_flags |= AMDGPU_IDS_FLAGS_PREEMPTION;
 		if (amdgpu_is_tmz(adev))
-			dev_info.ids_flags |= AMDGPU_IDS_FLAGS_TMZ;
+			dev_info->ids_flags |= AMDGPU_IDS_FLAGS_TMZ;
 
 		vm_size = adev->vm_manager.max_pfn * AMDGPU_GPU_PAGE_SIZE;
 		vm_size -= AMDGPU_VA_RESERVED_SIZE;
@@ -762,45 +766,47 @@ static int amdgpu_info_ioctl(struct drm_device *dev, void *data, struct drm_file
 		    adev->vce.fw_version < AMDGPU_VCE_FW_53_45)
 			vm_size = min(vm_size, 1ULL << 40);
 
-		dev_info.virtual_address_offset = AMDGPU_VA_RESERVED_SIZE;
-		dev_info.virtual_address_max =
+		dev_info->virtual_address_offset = AMDGPU_VA_RESERVED_SIZE;
+		dev_info->virtual_address_max =
 			min(vm_size, AMDGPU_GMC_HOLE_START);
 
 		if (vm_size > AMDGPU_GMC_HOLE_START) {
-			dev_info.high_va_offset = AMDGPU_GMC_HOLE_END;
-			dev_info.high_va_max = AMDGPU_GMC_HOLE_END | vm_size;
+			dev_info->high_va_offset = AMDGPU_GMC_HOLE_END;
+			dev_info->high_va_max = AMDGPU_GMC_HOLE_END | vm_size;
 		}
-		dev_info.virtual_address_alignment = max((int)PAGE_SIZE, AMDGPU_GPU_PAGE_SIZE);
-		dev_info.pte_fragment_size = (1 << adev->vm_manager.fragment_size) * AMDGPU_GPU_PAGE_SIZE;
-		dev_info.gart_page_size = AMDGPU_GPU_PAGE_SIZE;
-		dev_info.cu_active_number = adev->gfx.cu_info.number;
-		dev_info.cu_ao_mask = adev->gfx.cu_info.ao_cu_mask;
-		dev_info.ce_ram_size = adev->gfx.ce_ram_size;
-		memcpy(&dev_info.cu_ao_bitmap[0], &adev->gfx.cu_info.ao_cu_bitmap[0],
+		dev_info->virtual_address_alignment = max((int)PAGE_SIZE, AMDGPU_GPU_PAGE_SIZE);
+		dev_info->pte_fragment_size = (1 << adev->vm_manager.fragment_size) * AMDGPU_GPU_PAGE_SIZE;
+		dev_info->gart_page_size = AMDGPU_GPU_PAGE_SIZE;
+		dev_info->cu_active_number = adev->gfx.cu_info.number;
+		dev_info->cu_ao_mask = adev->gfx.cu_info.ao_cu_mask;
+		dev_info->ce_ram_size = adev->gfx.ce_ram_size;
+		memcpy(&dev_info->cu_ao_bitmap[0], &adev->gfx.cu_info.ao_cu_bitmap[0],
 		       sizeof(adev->gfx.cu_info.ao_cu_bitmap));
-		memcpy(&dev_info.cu_bitmap[0], &adev->gfx.cu_info.bitmap[0],
+		memcpy(&dev_info->cu_bitmap[0], &adev->gfx.cu_info.bitmap[0],
 		       sizeof(adev->gfx.cu_info.bitmap));
-		dev_info.vram_type = adev->gmc.vram_type;
-		dev_info.vram_bit_width = adev->gmc.vram_width;
-		dev_info.vce_harvest_config = adev->vce.harvest_config;
-		dev_info.gc_double_offchip_lds_buf =
+		dev_info->vram_type = adev->gmc.vram_type;
+		dev_info->vram_bit_width = adev->gmc.vram_width;
+		dev_info->vce_harvest_config = adev->vce.harvest_config;
+		dev_info->gc_double_offchip_lds_buf =
 			adev->gfx.config.double_offchip_lds_buf;
-		dev_info.wave_front_size = adev->gfx.cu_info.wave_front_size;
-		dev_info.num_shader_visible_vgprs = adev->gfx.config.max_gprs;
-		dev_info.num_cu_per_sh = adev->gfx.config.max_cu_per_sh;
-		dev_info.num_tcc_blocks = adev->gfx.config.max_texture_channel_caches;
-		dev_info.gs_vgt_table_depth = adev->gfx.config.gs_vgt_table_depth;
-		dev_info.gs_prim_buffer_depth = adev->gfx.config.gs_prim_buffer_depth;
-		dev_info.max_gs_waves_per_vgt = adev->gfx.config.max_gs_threads;
+		dev_info->wave_front_size = adev->gfx.cu_info.wave_front_size;
+		dev_info->num_shader_visible_vgprs = adev->gfx.config.max_gprs;
+		dev_info->num_cu_per_sh = adev->gfx.config.max_cu_per_sh;
+		dev_info->num_tcc_blocks = adev->gfx.config.max_texture_channel_caches;
+		dev_info->gs_vgt_table_depth = adev->gfx.config.gs_vgt_table_depth;
+		dev_info->gs_prim_buffer_depth = adev->gfx.config.gs_prim_buffer_depth;
+		dev_info->max_gs_waves_per_vgt = adev->gfx.config.max_gs_threads;
 
 		if (adev->family >= AMDGPU_FAMILY_NV)
-			dev_info.pa_sc_tile_steering_override =
+			dev_info->pa_sc_tile_steering_override =
 				adev->gfx.config.pa_sc_tile_steering_override;
 
-		dev_info.tcc_disabled_mask = adev->gfx.config.tcc_disabled_mask;
+		dev_info->tcc_disabled_mask = adev->gfx.config.tcc_disabled_mask;
 
-		return copy_to_user(out, &dev_info,
-				    min((size_t)size, sizeof(dev_info))) ? -EFAULT : 0;
+		ret = copy_to_user(out, dev_info,
+				   min((size_t)size, sizeof(*dev_info))) ? -EFAULT : 0;
+		kfree(dev_info);
+		return ret;
 	}
 	case AMDGPU_INFO_VCE_CLOCK_TABLE: {
 		unsigned i;
-- 
2.25.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 44+ messages in thread

* [PATCH 17/19] drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
  2020-11-06 21:49 [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Lee Jones
                   ` (8 preceding siblings ...)
  2020-11-06 21:49 ` [PATCH 16/19] drm/amd/amdgpu/amdgpu_kms: Remove 'struct drm_amdgpu_info_device dev_info' from the stack Lee Jones
@ 2020-11-06 21:49 ` Lee Jones
  2020-11-07 14:29   ` Sam Ravnborg
  2020-11-09 19:50   ` Alex Deucher
  2020-11-06 21:49 ` [PATCH 18/19] drm/radeon/atombios_crtc: Remove description of non-existent function param 'encoder' Lee Jones
                   ` (3 subsequent siblings)
  13 siblings, 2 replies; 44+ messages in thread
From: Lee Jones @ 2020-11-06 21:49 UTC (permalink / raw)
  To: lee.jones
  Cc: David Airlie, linux-kernel, amd-gfx, dri-devel, Daniel Vetter,
	Alex Deucher, Christian König

Fixes the following W=1 kernel build warning(s):

 drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Function parameter or member 'dev' not described in 'radeon_info_ioctl'
 drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Excess function parameter 'rdev' description in 'radeon_info_ioctl'

Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: David Airlie <airlied@linux.ie>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: amd-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/gpu/drm/radeon/radeon_kms.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/radeon/radeon_kms.c b/drivers/gpu/drm/radeon/radeon_kms.c
index 0d8fbabffcead..21c206795c364 100644
--- a/drivers/gpu/drm/radeon/radeon_kms.c
+++ b/drivers/gpu/drm/radeon/radeon_kms.c
@@ -213,7 +213,7 @@ static void radeon_set_filp_rights(struct drm_device *dev,
 /**
  * radeon_info_ioctl - answer a device specific request.
  *
- * @rdev: radeon device pointer
+ * @dev: radeon device pointer
  * @data: request object
  * @filp: drm filp
  *
-- 
2.25.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 44+ messages in thread

* [PATCH 18/19] drm/radeon/atombios_crtc: Remove description of non-existent function param 'encoder'
  2020-11-06 21:49 [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Lee Jones
                   ` (9 preceding siblings ...)
  2020-11-06 21:49 ` [PATCH 17/19] drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param Lee Jones
@ 2020-11-06 21:49 ` Lee Jones
  2020-11-10 22:01   ` Alex Deucher
  2020-11-06 22:26 ` [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Sam Ravnborg
                   ` (2 subsequent siblings)
  13 siblings, 1 reply; 44+ messages in thread
From: Lee Jones @ 2020-11-06 21:49 UTC (permalink / raw)
  To: lee.jones
  Cc: David Airlie, linux-kernel, amd-gfx, dri-devel, Daniel Vetter,
	Alex Deucher, Christian König

Fixes the following W=1 kernel build warning(s):

 drivers/gpu/drm/radeon/atombios_crtc.c:1796: warning: Excess function parameter 'encoder' description in 'radeon_get_shared_nondp_ppll'

Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: David Airlie <airlied@linux.ie>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: amd-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/gpu/drm/radeon/atombios_crtc.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/gpu/drm/radeon/atombios_crtc.c b/drivers/gpu/drm/radeon/atombios_crtc.c
index 91811757104c0..1979ed3d65472 100644
--- a/drivers/gpu/drm/radeon/atombios_crtc.c
+++ b/drivers/gpu/drm/radeon/atombios_crtc.c
@@ -1787,7 +1787,6 @@ static int radeon_get_shared_dp_ppll(struct drm_crtc *crtc)
  * radeon_get_shared_nondp_ppll - return the PPLL used by another non-DP crtc
  *
  * @crtc: drm crtc
- * @encoder: drm encoder
  *
  * Returns the PPLL (Pixel PLL) used by another non-DP crtc/encoder which can
  * be shared (i.e., same clock).
-- 
2.25.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 44+ messages in thread

* Re: [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU
  2020-11-06 21:49 [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Lee Jones
                   ` (10 preceding siblings ...)
  2020-11-06 21:49 ` [PATCH 18/19] drm/radeon/atombios_crtc: Remove description of non-existent function param 'encoder' Lee Jones
@ 2020-11-06 22:26 ` Sam Ravnborg
  2020-11-07 12:18 ` Christian König
  2020-11-13  7:19 ` Lee Jones
  13 siblings, 0 replies; 44+ messages in thread
From: Sam Ravnborg @ 2020-11-06 22:26 UTC (permalink / raw)
  To: Lee Jones
  Cc: Faith, Alex Deucher, Andy Gross, David Airlie, Tomi Valkeinen,
	linux-kernel, amd-gfx, Rob Clark, linaro-mm-sig, Leo Li,
	Huang Rui, dri-devel, Keith Whitwell, Jeff Hartmann, Rob Clark,
	Gareth Hughes, Christian Koenig, by, linux-media

Hi Lee and DRM folks.

On Fri, Nov 06, 2020 at 09:49:30PM +0000, Lee Jones wrote:
> This set is part of a larger effort attempting to clean-up W=1
> kernel builds, which are currently overwhelmingly riddled with
> niggly little warnings.
> 
> There are 5000 warnings to work through.  It will take a couple more
> sets.  Although, ("drm/amd/display/dc/basics/fixpt31_32: Move
> variables to where they're used") does take care of 2000 of them!
> 
> Lee Jones (19):
>   drm/ttm/ttm_range_manager: Demote non-conformant kernel-doc header
>   drm/r128/ati_pcigart: Source file headers are not good candidates for
>     kernel-doc
Applied

>   drm/selftests/test-drm_dp_mst_helper: Move
>     'sideband_msg_req_encode_decode' onto the heap
>   drm/mga/mga_dma: Demote kernel-doc abusers to standard comment blocks
>   drm/mga/mga_state: Remove unused variable 'buf_priv'
Applied x2

>   drm/radeon/atom: Move prototype into shared location
>   drm/radeon/radeon_kms: Include header containing our own prototypes
>   drm/omapdrm/omap_gem: Fix misnamed and missing parameter descriptions
>   drm/omapdrm/omap_dmm_tiler: Demote abusive use of kernel-doc format
>   drm/radeon/radeon: Move prototype into shared header
>   drm/radeon/radeon_drv: Source file headers are not good candidates for
>     kernel-doc
>   drm/amd/display/dc/basics/fixpt31_32: Move variables to where they're
>     used
>   drm/radeon/radeon_drv: Move prototypes to a shared headerfile
>   drm/amd/amdgpu/amdgpu_device: Provide documentation for 'reg_addr'
>     params
>   drm/radeon: Move prototypes to shared header
>   drm/amd/amdgpu/amdgpu_kms: Remove 'struct drm_amdgpu_info_device
>     dev_info' from the stack
>   drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
>   drm/radeon/atombios_crtc: Remove description of non-existent function
>     param 'encoder'
>   drm/v3d/v3d_drv: Remove unused static variable 'v3d_v3d_pm_ops'

I have applied the three patches that has no obvious maintainer as indicated
above. I assume the respective maintaines to pick radeon, omapdrm, ttm,
amd, v3d and selftest patches.

	Sam
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU
  2020-11-06 21:49 [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Lee Jones
                   ` (11 preceding siblings ...)
  2020-11-06 22:26 ` [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Sam Ravnborg
@ 2020-11-07 12:18 ` Christian König
  2020-11-07 15:07   ` Lee Jones
  2020-11-07 17:34   ` Sam Ravnborg
  2020-11-13  7:19 ` Lee Jones
  13 siblings, 2 replies; 44+ messages in thread
From: Christian König @ 2020-11-07 12:18 UTC (permalink / raw)
  To: Lee Jones
  Cc: David Airlie, dri-devel, Eric Anholt, Huang Rui, Rob Clark,
	Gareth Hughes, Sumit Semwal, amd-gfx, Rob Clark, Tomi Valkeinen,
	Keith Whitwell, Andy Gross, Harry Wentland, linux-media,
	Daniel Vetter, Leo Li, linaro-mm-sig, by, Jeff Hartmann,
	linux-kernel, Faith, Philipp Zabel, Alex Deucher

Well that's quite a patch set.

First of all can you separate this a bit more by driver? I'm assuming we 
maintainers are supposed to pick that up and apply it.

radeon and amdgpu can stick together since that is mostly Alex and me, 
but I'm not sure if we want to do some of the suggested changes to radeon.

Going to pick up the single TTM change for upstreaming.

Thanks,
Christian.

Am 06.11.20 um 22:49 schrieb Lee Jones:
> This set is part of a larger effort attempting to clean-up W=1
> kernel builds, which are currently overwhelmingly riddled with
> niggly little warnings.
>
> There are 5000 warnings to work through.  It will take a couple more
> sets.  Although, ("drm/amd/display/dc/basics/fixpt31_32: Move
> variables to where they're used") does take care of 2000 of them!
>
> Lee Jones (19):
>    drm/ttm/ttm_range_manager: Demote non-conformant kernel-doc header
>    drm/r128/ati_pcigart: Source file headers are not good candidates for
>      kernel-doc
>    drm/selftests/test-drm_dp_mst_helper: Move
>      'sideband_msg_req_encode_decode' onto the heap
>    drm/mga/mga_dma: Demote kernel-doc abusers to standard comment blocks
>    drm/mga/mga_state: Remove unused variable 'buf_priv'
>    drm/radeon/atom: Move prototype into shared location
>    drm/radeon/radeon_kms: Include header containing our own prototypes
>    drm/omapdrm/omap_gem: Fix misnamed and missing parameter descriptions
>    drm/omapdrm/omap_dmm_tiler: Demote abusive use of kernel-doc format
>    drm/radeon/radeon: Move prototype into shared header
>    drm/radeon/radeon_drv: Source file headers are not good candidates for
>      kernel-doc
>    drm/amd/display/dc/basics/fixpt31_32: Move variables to where they're
>      used
>    drm/radeon/radeon_drv: Move prototypes to a shared headerfile
>    drm/amd/amdgpu/amdgpu_device: Provide documentation for 'reg_addr'
>      params
>    drm/radeon: Move prototypes to shared header
>    drm/amd/amdgpu/amdgpu_kms: Remove 'struct drm_amdgpu_info_device
>      dev_info' from the stack
>    drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
>    drm/radeon/atombios_crtc: Remove description of non-existent function
>      param 'encoder'
>    drm/v3d/v3d_drv: Remove unused static variable 'v3d_v3d_pm_ops'
>
>   drivers/gpu/drm/amd/amdgpu/amdgpu_device.c    |   2 +
>   drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c       | 104 +++++++++---------
>   .../drm/amd/display/dc/basics/fixpt31_32.c    |   5 +
>   .../gpu/drm/amd/display/include/fixed31_32.h  |   6 -
>   drivers/gpu/drm/mga/mga_dma.c                 |  10 +-
>   drivers/gpu/drm/mga/mga_state.c               |   2 -
>   drivers/gpu/drm/omapdrm/omap_dmm_tiler.c      |   6 +-
>   drivers/gpu/drm/omapdrm/omap_gem.c            |   3 +-
>   drivers/gpu/drm/r128/ati_pcigart.c            |   2 +-
>   drivers/gpu/drm/radeon/atom.h                 |   6 +
>   drivers/gpu/drm/radeon/atombios_crtc.c        |   1 -
>   drivers/gpu/drm/radeon/atombios_encoders.c    |   4 -
>   drivers/gpu/drm/radeon/radeon.h               |   6 +
>   drivers/gpu/drm/radeon/radeon_device.c        |   1 +
>   drivers/gpu/drm/radeon/radeon_device.h        |  32 ++++++
>   drivers/gpu/drm/radeon/radeon_display.c       |   4 -
>   drivers/gpu/drm/radeon/radeon_drv.c           |  11 +-
>   drivers/gpu/drm/radeon/radeon_drv.h           |   7 ++
>   drivers/gpu/drm/radeon/radeon_kms.c           |   3 +-
>   .../drm/selftests/test-drm_dp_mst_helper.c    |  11 +-
>   drivers/gpu/drm/ttm/ttm_range_manager.c       |   2 +-
>   drivers/gpu/drm/v3d/v3d_drv.c                 |  36 ------
>   22 files changed, 138 insertions(+), 126 deletions(-)
>   create mode 100644 drivers/gpu/drm/radeon/radeon_device.h
>
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Cc: amd-gfx@lists.freedesktop.org
> Cc: Andy Gross <andy.gross@ti.com>
> Cc: by <jhartmann@precisioninsight.com>
> Cc: Christian Koenig <christian.koenig@amd.com>
> Cc: "Christian König" <christian.koenig@amd.com>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: David Airlie <airlied@linux.ie>
> Cc: dri-devel@lists.freedesktop.org
> Cc: Eric Anholt <eric@anholt.net>
> Cc: Faith <faith@valinux.com>
> Cc: Gareth Hughes <gareth@valinux.com>
> Cc: Harry Wentland <harry.wentland@amd.com>
> Cc: Huang Rui <ray.huang@amd.com>
> Cc: Jeff Hartmann <jhartmann@valinux.com>
> Cc: Keith Whitwell <keith@tungstengraphics.com>
> Cc: Leo Li <sunpeng.li@amd.com>
> Cc: linaro-mm-sig@lists.linaro.org
> Cc: linux-media@vger.kernel.org
> Cc: Philipp Zabel <p.zabel@pengutronix.de>
> Cc: Rob Clark <rob.clark@linaro.org>
> Cc: Rob Clark <rob@ti.com>
> Cc: Sumit Semwal <sumit.semwal@linaro.org>
> Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 10/19] drm/radeon/radeon: Move prototype into shared header
  2020-11-06 21:49 ` [PATCH 10/19] drm/radeon/radeon: Move prototype into shared header Lee Jones
@ 2020-11-07 14:26   ` Sam Ravnborg
  2020-11-07 15:14     ` Lee Jones
  2020-11-09 11:06     ` Lee Jones
  0 siblings, 2 replies; 44+ messages in thread
From: Sam Ravnborg @ 2020-11-07 14:26 UTC (permalink / raw)
  To: Lee Jones
  Cc: David Airlie, linux-kernel, dri-devel, linaro-mm-sig, amd-gfx,
	Alex Deucher, Christian König, linux-media

Hi Lee,

On Fri, Nov 06, 2020 at 09:49:40PM +0000, Lee Jones wrote:
> Unfortunately, a suitable one didn't already exist.
> 
> Fixes the following W=1 kernel build warning(s):
> 
>  drivers/gpu/drm/radeon/radeon_device.c:637:6: warning: no previous prototype for ‘radeon_device_is_virtual’ [-Wmissing-prototypes]
>  637 | bool radeon_device_is_virtual(void)
>  | ^~~~~~~~~~~~~~~~~~~~~~~~
> 
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Cc: "Christian König" <christian.koenig@amd.com>
> Cc: David Airlie <airlied@linux.ie>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: Sumit Semwal <sumit.semwal@linaro.org>
> Cc: amd-gfx@lists.freedesktop.org
> Cc: dri-devel@lists.freedesktop.org
> Cc: linux-media@vger.kernel.org
> Cc: linaro-mm-sig@lists.linaro.org
> Signed-off-by: Lee Jones <lee.jones@linaro.org>
> ---
>  drivers/gpu/drm/radeon/radeon_device.c |  1 +
>  drivers/gpu/drm/radeon/radeon_device.h | 32 ++++++++++++++++++++++++++
>  drivers/gpu/drm/radeon/radeon_drv.c    |  3 +--
>  3 files changed, 34 insertions(+), 2 deletions(-)
>  create mode 100644 drivers/gpu/drm/radeon/radeon_device.h

Other public functions in radeon_device.c have their prototype in
radeon.h - for example radeon_is_px()

Add radeon_device_is_virtual() there so we avoiid this new header.

	Sam
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 17/19] drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
  2020-11-06 21:49 ` [PATCH 17/19] drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param Lee Jones
@ 2020-11-07 14:29   ` Sam Ravnborg
  2020-11-07 15:13     ` Lee Jones
  2020-11-09 19:50   ` Alex Deucher
  1 sibling, 1 reply; 44+ messages in thread
From: Sam Ravnborg @ 2020-11-07 14:29 UTC (permalink / raw)
  To: Lee Jones
  Cc: David Airlie, linux-kernel, dri-devel, amd-gfx, Alex Deucher,
	Christian König

Hi Lee,

On Fri, Nov 06, 2020 at 09:49:47PM +0000, Lee Jones wrote:
> Fixes the following W=1 kernel build warning(s):
> 
>  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Function parameter or member 'dev' not described in 'radeon_info_ioctl'
>  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Excess function parameter 'rdev' description in 'radeon_info_ioctl'
> 
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Cc: "Christian König" <christian.koenig@amd.com>
> Cc: David Airlie <airlied@linux.ie>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: amd-gfx@lists.freedesktop.org
> Cc: dri-devel@lists.freedesktop.org
> Signed-off-by: Lee Jones <lee.jones@linaro.org>
> ---
>  drivers/gpu/drm/radeon/radeon_kms.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/radeon/radeon_kms.c b/drivers/gpu/drm/radeon/radeon_kms.c
> index 0d8fbabffcead..21c206795c364 100644
> --- a/drivers/gpu/drm/radeon/radeon_kms.c
> +++ b/drivers/gpu/drm/radeon/radeon_kms.c
> @@ -213,7 +213,7 @@ static void radeon_set_filp_rights(struct drm_device *dev,
>  /**
>   * radeon_info_ioctl - answer a device specific request.
>   *
> - * @rdev: radeon device pointer
> + * @dev: radeon device pointer
>   * @data: request object
>   * @filp: drm filp
>   *

Delete all the kernel-doc annotation as we do not pull this file into
the kernel-doc anyway.

Keep the /* Answer a device specific request */ part.

At least thats what I see as the best way to deal with it.

	Sam
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU
  2020-11-07 12:18 ` Christian König
@ 2020-11-07 15:07   ` Lee Jones
  2020-11-07 17:34   ` Sam Ravnborg
  1 sibling, 0 replies; 44+ messages in thread
From: Lee Jones @ 2020-11-07 15:07 UTC (permalink / raw)
  To: Christian König
  Cc: David Airlie, dri-devel, Eric Anholt, Huang Rui, Rob Clark,
	Gareth Hughes, Sumit Semwal, amd-gfx, Rob Clark, Tomi Valkeinen,
	Keith Whitwell, Andy Gross, Harry Wentland, linux-media,
	Daniel Vetter, Leo Li, linaro-mm-sig, by, Jeff Hartmann,
	linux-kernel, Faith, Philipp Zabel, Alex Deucher

On Sat, 07 Nov 2020, Christian König wrote:

> Well that's quite a patch set.
> 
> First of all can you separate this a bit more by driver? I'm assuming we
> maintainers are supposed to pick that up and apply it.

I'm not sure what would achieve?  It's not a pull-request.

Either way, patches should be applied individually.

> radeon and amdgpu can stick together since that is mostly Alex and me, but
> I'm not sure if we want to do some of the suggested changes to radeon.

That's fine.  Just review, providing your reasons as to why they are
not suitable and we'll work through the issues together, patch by
patch.

> Going to pick up the single TTM change for upstreaming.

Thanks.

> Am 06.11.20 um 22:49 schrieb Lee Jones:
> > This set is part of a larger effort attempting to clean-up W=1
> > kernel builds, which are currently overwhelmingly riddled with
> > niggly little warnings.
> > 
> > There are 5000 warnings to work through.  It will take a couple more
> > sets.  Although, ("drm/amd/display/dc/basics/fixpt31_32: Move
> > variables to where they're used") does take care of 2000 of them!
> > 
> > Lee Jones (19):
> >    drm/ttm/ttm_range_manager: Demote non-conformant kernel-doc header
> >    drm/r128/ati_pcigart: Source file headers are not good candidates for
> >      kernel-doc
> >    drm/selftests/test-drm_dp_mst_helper: Move
> >      'sideband_msg_req_encode_decode' onto the heap
> >    drm/mga/mga_dma: Demote kernel-doc abusers to standard comment blocks
> >    drm/mga/mga_state: Remove unused variable 'buf_priv'
> >    drm/radeon/atom: Move prototype into shared location
> >    drm/radeon/radeon_kms: Include header containing our own prototypes
> >    drm/omapdrm/omap_gem: Fix misnamed and missing parameter descriptions
> >    drm/omapdrm/omap_dmm_tiler: Demote abusive use of kernel-doc format
> >    drm/radeon/radeon: Move prototype into shared header
> >    drm/radeon/radeon_drv: Source file headers are not good candidates for
> >      kernel-doc
> >    drm/amd/display/dc/basics/fixpt31_32: Move variables to where they're
> >      used
> >    drm/radeon/radeon_drv: Move prototypes to a shared headerfile
> >    drm/amd/amdgpu/amdgpu_device: Provide documentation for 'reg_addr'
> >      params
> >    drm/radeon: Move prototypes to shared header
> >    drm/amd/amdgpu/amdgpu_kms: Remove 'struct drm_amdgpu_info_device
> >      dev_info' from the stack
> >    drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
> >    drm/radeon/atombios_crtc: Remove description of non-existent function
> >      param 'encoder'
> >    drm/v3d/v3d_drv: Remove unused static variable 'v3d_v3d_pm_ops'
> > 
> >   drivers/gpu/drm/amd/amdgpu/amdgpu_device.c    |   2 +
> >   drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c       | 104 +++++++++---------
> >   .../drm/amd/display/dc/basics/fixpt31_32.c    |   5 +
> >   .../gpu/drm/amd/display/include/fixed31_32.h  |   6 -
> >   drivers/gpu/drm/mga/mga_dma.c                 |  10 +-
> >   drivers/gpu/drm/mga/mga_state.c               |   2 -
> >   drivers/gpu/drm/omapdrm/omap_dmm_tiler.c      |   6 +-
> >   drivers/gpu/drm/omapdrm/omap_gem.c            |   3 +-
> >   drivers/gpu/drm/r128/ati_pcigart.c            |   2 +-
> >   drivers/gpu/drm/radeon/atom.h                 |   6 +
> >   drivers/gpu/drm/radeon/atombios_crtc.c        |   1 -
> >   drivers/gpu/drm/radeon/atombios_encoders.c    |   4 -
> >   drivers/gpu/drm/radeon/radeon.h               |   6 +
> >   drivers/gpu/drm/radeon/radeon_device.c        |   1 +
> >   drivers/gpu/drm/radeon/radeon_device.h        |  32 ++++++
> >   drivers/gpu/drm/radeon/radeon_display.c       |   4 -
> >   drivers/gpu/drm/radeon/radeon_drv.c           |  11 +-
> >   drivers/gpu/drm/radeon/radeon_drv.h           |   7 ++
> >   drivers/gpu/drm/radeon/radeon_kms.c           |   3 +-
> >   .../drm/selftests/test-drm_dp_mst_helper.c    |  11 +-
> >   drivers/gpu/drm/ttm/ttm_range_manager.c       |   2 +-
> >   drivers/gpu/drm/v3d/v3d_drv.c                 |  36 ------
> >   22 files changed, 138 insertions(+), 126 deletions(-)
> >   create mode 100644 drivers/gpu/drm/radeon/radeon_device.h
> > 
> > Cc: Alex Deucher <alexander.deucher@amd.com>
> > Cc: amd-gfx@lists.freedesktop.org
> > Cc: Andy Gross <andy.gross@ti.com>
> > Cc: by <jhartmann@precisioninsight.com>
> > Cc: Christian Koenig <christian.koenig@amd.com>
> > Cc: "Christian König" <christian.koenig@amd.com>
> > Cc: Daniel Vetter <daniel@ffwll.ch>
> > Cc: David Airlie <airlied@linux.ie>
> > Cc: dri-devel@lists.freedesktop.org
> > Cc: Eric Anholt <eric@anholt.net>
> > Cc: Faith <faith@valinux.com>
> > Cc: Gareth Hughes <gareth@valinux.com>
> > Cc: Harry Wentland <harry.wentland@amd.com>
> > Cc: Huang Rui <ray.huang@amd.com>
> > Cc: Jeff Hartmann <jhartmann@valinux.com>
> > Cc: Keith Whitwell <keith@tungstengraphics.com>
> > Cc: Leo Li <sunpeng.li@amd.com>
> > Cc: linaro-mm-sig@lists.linaro.org
> > Cc: linux-media@vger.kernel.org
> > Cc: Philipp Zabel <p.zabel@pengutronix.de>
> > Cc: Rob Clark <rob.clark@linaro.org>
> > Cc: Rob Clark <rob@ti.com>
> > Cc: Sumit Semwal <sumit.semwal@linaro.org>
> > Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
> 

-- 
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 17/19] drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
  2020-11-07 14:29   ` Sam Ravnborg
@ 2020-11-07 15:13     ` Lee Jones
  0 siblings, 0 replies; 44+ messages in thread
From: Lee Jones @ 2020-11-07 15:13 UTC (permalink / raw)
  To: Sam Ravnborg
  Cc: David Airlie, linux-kernel, dri-devel, amd-gfx, Alex Deucher,
	Christian König

On Sat, 07 Nov 2020, Sam Ravnborg wrote:

> Hi Lee,
> 
> On Fri, Nov 06, 2020 at 09:49:47PM +0000, Lee Jones wrote:
> > Fixes the following W=1 kernel build warning(s):
> > 
> >  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Function parameter or member 'dev' not described in 'radeon_info_ioctl'
> >  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Excess function parameter 'rdev' description in 'radeon_info_ioctl'
> > 
> > Cc: Alex Deucher <alexander.deucher@amd.com>
> > Cc: "Christian König" <christian.koenig@amd.com>
> > Cc: David Airlie <airlied@linux.ie>
> > Cc: Daniel Vetter <daniel@ffwll.ch>
> > Cc: amd-gfx@lists.freedesktop.org
> > Cc: dri-devel@lists.freedesktop.org
> > Signed-off-by: Lee Jones <lee.jones@linaro.org>
> > ---
> >  drivers/gpu/drm/radeon/radeon_kms.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/drivers/gpu/drm/radeon/radeon_kms.c b/drivers/gpu/drm/radeon/radeon_kms.c
> > index 0d8fbabffcead..21c206795c364 100644
> > --- a/drivers/gpu/drm/radeon/radeon_kms.c
> > +++ b/drivers/gpu/drm/radeon/radeon_kms.c
> > @@ -213,7 +213,7 @@ static void radeon_set_filp_rights(struct drm_device *dev,
> >  /**
> >   * radeon_info_ioctl - answer a device specific request.
> >   *
> > - * @rdev: radeon device pointer
> > + * @dev: radeon device pointer
> >   * @data: request object
> >   * @filp: drm filp
> >   *
> 
> Delete all the kernel-doc annotation as we do not pull this file into
> the kernel-doc anyway.
> 
> Keep the /* Answer a device specific request */ part.
> 
> At least thats what I see as the best way to deal with it.

Demoting all headers, even if they are conformant, it not the way to
go.  Some contributors/maintainers prefer to keep the kernel-doc
(pretty colours, automated checking [a la, this patch!] and the-like)
formatting, even if they are not directly referenced from
/Documentation.

For now, so long as the build is happy, I am happy.

If you wish to make the build unhappy about this, you should take up
the argument to encompass `scripts/find-unused-docs.sh` into it.

-- 
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 10/19] drm/radeon/radeon: Move prototype into shared header
  2020-11-07 14:26   ` Sam Ravnborg
@ 2020-11-07 15:14     ` Lee Jones
  2020-11-09 11:06     ` Lee Jones
  1 sibling, 0 replies; 44+ messages in thread
From: Lee Jones @ 2020-11-07 15:14 UTC (permalink / raw)
  To: Sam Ravnborg
  Cc: David Airlie, linux-kernel, dri-devel, linaro-mm-sig, amd-gfx,
	Alex Deucher, Christian König, linux-media

On Sat, 07 Nov 2020, Sam Ravnborg wrote:

> Hi Lee,
> 
> On Fri, Nov 06, 2020 at 09:49:40PM +0000, Lee Jones wrote:
> > Unfortunately, a suitable one didn't already exist.
> > 
> > Fixes the following W=1 kernel build warning(s):
> > 
> >  drivers/gpu/drm/radeon/radeon_device.c:637:6: warning: no previous prototype for ‘radeon_device_is_virtual’ [-Wmissing-prototypes]
> >  637 | bool radeon_device_is_virtual(void)
> >  | ^~~~~~~~~~~~~~~~~~~~~~~~
> > 
> > Cc: Alex Deucher <alexander.deucher@amd.com>
> > Cc: "Christian König" <christian.koenig@amd.com>
> > Cc: David Airlie <airlied@linux.ie>
> > Cc: Daniel Vetter <daniel@ffwll.ch>
> > Cc: Sumit Semwal <sumit.semwal@linaro.org>
> > Cc: amd-gfx@lists.freedesktop.org
> > Cc: dri-devel@lists.freedesktop.org
> > Cc: linux-media@vger.kernel.org
> > Cc: linaro-mm-sig@lists.linaro.org
> > Signed-off-by: Lee Jones <lee.jones@linaro.org>
> > ---
> >  drivers/gpu/drm/radeon/radeon_device.c |  1 +
> >  drivers/gpu/drm/radeon/radeon_device.h | 32 ++++++++++++++++++++++++++
> >  drivers/gpu/drm/radeon/radeon_drv.c    |  3 +--
> >  3 files changed, 34 insertions(+), 2 deletions(-)
> >  create mode 100644 drivers/gpu/drm/radeon/radeon_device.h
> 
> Other public functions in radeon_device.c have their prototype in
> radeon.h - for example radeon_is_px()
> 
> Add radeon_device_is_virtual() there so we avoiid this new header.

I'm happy to do that, if it's deemed better.

-- 
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU
  2020-11-07 12:18 ` Christian König
  2020-11-07 15:07   ` Lee Jones
@ 2020-11-07 17:34   ` Sam Ravnborg
  2020-11-07 18:41     ` Lee Jones
  1 sibling, 1 reply; 44+ messages in thread
From: Sam Ravnborg @ 2020-11-07 17:34 UTC (permalink / raw)
  To: Christian König
  Cc: Faith, Alex Deucher, Andy Gross, David Airlie, Tomi Valkeinen,
	linux-kernel, dri-devel, Rob Clark, linaro-mm-sig, Leo Li,
	Huang Rui, amd-gfx, Keith Whitwell, Jeff Hartmann, Rob Clark,
	Gareth Hughes, Lee Jones, by, linux-media

Hi Christian.

> I'm not sure if we want to do some of the suggested changes to radeon.

All patches for radeon looks good to me except "drm/radeon/radeon: Move
prototype into shared header".

Acked-by: Sam Ravnborg <sam@ravnborg.org>
from me to have them applied (except the shared header one).
I can reply to the individual patches if you like.

	Sam
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU
  2020-11-07 17:34   ` Sam Ravnborg
@ 2020-11-07 18:41     ` Lee Jones
  2020-11-07 19:29       ` Sam Ravnborg
  0 siblings, 1 reply; 44+ messages in thread
From: Lee Jones @ 2020-11-07 18:41 UTC (permalink / raw)
  To: Sam Ravnborg
  Cc: Faith, Alex Deucher, Andy Gross, David Airlie, Tomi Valkeinen,
	linux-kernel, dri-devel, Rob Clark, linaro-mm-sig, Leo Li,
	Huang Rui, amd-gfx, Keith Whitwell, Jeff Hartmann, Rob Clark,
	Gareth Hughes, Christian König, by, linux-media

On Sat, 07 Nov 2020, Sam Ravnborg wrote:

> Hi Christian.
> 
> > I'm not sure if we want to do some of the suggested changes to radeon.
> 
> All patches for radeon looks good to me except "drm/radeon/radeon: Move
> prototype into shared header".

Was that the one where the prototype needs moving to radeon.h?

> Acked-by: Sam Ravnborg <sam@ravnborg.org>
> from me to have them applied (except the shared header one).

Thanks Sam.

> I can reply to the individual patches if you like.

-- 
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU
  2020-11-07 18:41     ` Lee Jones
@ 2020-11-07 19:29       ` Sam Ravnborg
  0 siblings, 0 replies; 44+ messages in thread
From: Sam Ravnborg @ 2020-11-07 19:29 UTC (permalink / raw)
  To: Lee Jones
  Cc: Faith, Alex Deucher, Andy Gross, David Airlie, Tomi Valkeinen,
	linux-kernel, dri-devel, Rob Clark, linaro-mm-sig, Leo Li,
	Huang Rui, amd-gfx, Keith Whitwell, Jeff Hartmann, Rob Clark,
	Gareth Hughes, Christian König, by, linux-media

On Sat, Nov 07, 2020 at 06:41:38PM +0000, Lee Jones wrote:
> On Sat, 07 Nov 2020, Sam Ravnborg wrote:
> 
> > Hi Christian.
> > 
> > > I'm not sure if we want to do some of the suggested changes to radeon.
> > 
> > All patches for radeon looks good to me except "drm/radeon/radeon: Move
> > prototype into shared header".
> 
> Was that the one where the prototype needs moving to radeon.h?
Yes,

	Sam
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 10/19] drm/radeon/radeon: Move prototype into shared header
  2020-11-07 14:26   ` Sam Ravnborg
  2020-11-07 15:14     ` Lee Jones
@ 2020-11-09 11:06     ` Lee Jones
  2020-11-09 15:25       ` Sam Ravnborg
  1 sibling, 1 reply; 44+ messages in thread
From: Lee Jones @ 2020-11-09 11:06 UTC (permalink / raw)
  To: Sam Ravnborg
  Cc: David Airlie, linux-kernel, dri-devel, linaro-mm-sig, amd-gfx,
	Alex Deucher, Christian König, linux-media

On Sat, 07 Nov 2020, Sam Ravnborg wrote:

> Hi Lee,
> 
> On Fri, Nov 06, 2020 at 09:49:40PM +0000, Lee Jones wrote:
> > Unfortunately, a suitable one didn't already exist.
> > 
> > Fixes the following W=1 kernel build warning(s):
> > 
> >  drivers/gpu/drm/radeon/radeon_device.c:637:6: warning: no previous prototype for ‘radeon_device_is_virtual’ [-Wmissing-prototypes]
> >  637 | bool radeon_device_is_virtual(void)
> >  | ^~~~~~~~~~~~~~~~~~~~~~~~
> > 
> > Cc: Alex Deucher <alexander.deucher@amd.com>
> > Cc: "Christian König" <christian.koenig@amd.com>
> > Cc: David Airlie <airlied@linux.ie>
> > Cc: Daniel Vetter <daniel@ffwll.ch>
> > Cc: Sumit Semwal <sumit.semwal@linaro.org>
> > Cc: amd-gfx@lists.freedesktop.org
> > Cc: dri-devel@lists.freedesktop.org
> > Cc: linux-media@vger.kernel.org
> > Cc: linaro-mm-sig@lists.linaro.org
> > Signed-off-by: Lee Jones <lee.jones@linaro.org>
> > ---
> >  drivers/gpu/drm/radeon/radeon_device.c |  1 +
> >  drivers/gpu/drm/radeon/radeon_device.h | 32 ++++++++++++++++++++++++++
> >  drivers/gpu/drm/radeon/radeon_drv.c    |  3 +--
> >  3 files changed, 34 insertions(+), 2 deletions(-)
> >  create mode 100644 drivers/gpu/drm/radeon/radeon_device.h
> 
> Other public functions in radeon_device.c have their prototype in
> radeon.h - for example radeon_is_px()
> 
> Add radeon_device_is_virtual() there so we avoiid this new header.

Oh yes, I remember why this wasn't a suitable solution now:

The macro "radeon_init" in radeon.h clashes with the init function of
the same name in radeon_drv.c:

  In file included from drivers/gpu/drm/radeon/radeon_drv.c:53:
  drivers/gpu/drm/radeon/radeon_drv.c:620:31: error: expected identifier or ‘(’ before ‘void’
  620 | static int __init radeon_init(void)
  | ^~~~
  drivers/gpu/drm/radeon/radeon.h:2705:28: note: in definition of macro ‘radeon_init’
  2705 | #define radeon_init(rdev) (rdev)->asic->init((rdev))
  | ^~~~
  In file included from drivers/gpu/drm/radeon/radeon_drv.c:35:
  drivers/gpu/drm/radeon/radeon_drv.c: In function ‘__inittest’:
  drivers/gpu/drm/radeon/radeon_drv.c:653:13: error: ‘radeon_init’ undeclared (first use in this function); did you mean ‘radeon_exit’?
  653 | module_init(radeon_init);
  | ^~~~~~~~~~~
  include/linux/module.h:133:11: note: in definition of macro ‘module_init’
  133 | { return initfn; } | ^~~~~~
  drivers/gpu/drm/radeon/radeon_drv.c:653:13: note: each undeclared identifier is reported only once for each function it appears in
  653 | module_init(radeon_init);
  | ^~~~~~~~~~~
  include/linux/module.h:133:11: note: in definition of macro ‘module_init’
  133 | { return initfn; } | ^~~~~~
  In file included from include/linux/compiler_types.h:65,
  from <command-line>:
  drivers/gpu/drm/radeon/radeon_drv.c: At top level:
  drivers/gpu/drm/radeon/radeon_drv.c:653:13: error: ‘radeon_init’ undeclared here (not in a function); did you mean ‘radeon_exit’?
  653 | module_init(radeon_init);
  | ^~~~~~~~~~~
  include/linux/compiler_attributes.h:109:65: note: in definition of macro ‘__copy’
  109 | # define __copy(symbol) __attribute__((__copy__(symbol)))
  | ^~~~~~
  drivers/gpu/drm/radeon/radeon_drv.c:653:1: note: in expansion of macro ‘module_init’
  653 | module_init(radeon_init);
  | ^~~~~~~~~~~
  In file included from drivers/gpu/drm/radeon/radeon_drv.c:35:
  include/linux/module.h:134:6: error: ‘init_module’ aliased to undefined symbol ‘radeon_init’
  134 | int init_module(void) __copy(initfn) __attribute__((alias(#initfn)));
  | ^~~~~~~~~~~
  drivers/gpu/drm/radeon/radeon_drv.c:653:1: note: in expansion of macro ‘module_init’
  653 | module_init(radeon_init);
  | ^~~~~~~~~~~

How would you like me to move forward?

-- 
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 10/19] drm/radeon/radeon: Move prototype into shared header
  2020-11-09 11:06     ` Lee Jones
@ 2020-11-09 15:25       ` Sam Ravnborg
  2020-11-09 16:10         ` Lee Jones
  0 siblings, 1 reply; 44+ messages in thread
From: Sam Ravnborg @ 2020-11-09 15:25 UTC (permalink / raw)
  To: Lee Jones
  Cc: David Airlie, linux-kernel, dri-devel, linaro-mm-sig, amd-gfx,
	Alex Deucher, Christian König, linux-media

Hi Lee,
> > 
> > Other public functions in radeon_device.c have their prototype in
> > radeon.h - for example radeon_is_px()
> > 
> > Add radeon_device_is_virtual() there so we avoiid this new header.
> 
> Oh yes, I remember why this wasn't a suitable solution now:
> 
> The macro "radeon_init" in radeon.h clashes with the init function of
> the same name in radeon_drv.c:
> 
>   In file included from drivers/gpu/drm/radeon/radeon_drv.c:53:
>   drivers/gpu/drm/radeon/radeon_drv.c:620:31: error: expected identifier or ‘(’ before ‘void’
>   620 | static int __init radeon_init(void)
...
> 
> How would you like me to move forward?

Fix the thousand of warnings in other places :-)
I will take a look at radeon and post a new series based on your work
with all W=1 warnings fixed.

	Sam
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 10/19] drm/radeon/radeon: Move prototype into shared header
  2020-11-09 15:25       ` Sam Ravnborg
@ 2020-11-09 16:10         ` Lee Jones
  0 siblings, 0 replies; 44+ messages in thread
From: Lee Jones @ 2020-11-09 16:10 UTC (permalink / raw)
  To: Sam Ravnborg
  Cc: David Airlie, linux-kernel, dri-devel, linaro-mm-sig, amd-gfx,
	Alex Deucher, Christian König, linux-media

On Mon, 09 Nov 2020, Sam Ravnborg wrote:

> Hi Lee,
> > > 
> > > Other public functions in radeon_device.c have their prototype in
> > > radeon.h - for example radeon_is_px()
> > > 
> > > Add radeon_device_is_virtual() there so we avoiid this new header.
> > 
> > Oh yes, I remember why this wasn't a suitable solution now:
> > 
> > The macro "radeon_init" in radeon.h clashes with the init function of
> > the same name in radeon_drv.c:
> > 
> >   In file included from drivers/gpu/drm/radeon/radeon_drv.c:53:
> >   drivers/gpu/drm/radeon/radeon_drv.c:620:31: error: expected identifier or ‘(’ before ‘void’
> >   620 | static int __init radeon_init(void)
> ...
> > 
> > How would you like me to move forward?
> 
> Fix the thousand of warnings in other places :-)
> I will take a look at radeon and post a new series based on your work
> with all W=1 warnings fixed.

I'll drop this patch and carry on ploughing through the rest of them.

-- 
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 17/19] drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
  2020-11-06 21:49 ` [PATCH 17/19] drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param Lee Jones
  2020-11-07 14:29   ` Sam Ravnborg
@ 2020-11-09 19:50   ` Alex Deucher
  2020-11-09 19:55     ` Sam Ravnborg
  2020-11-09 19:59     ` Lee Jones
  1 sibling, 2 replies; 44+ messages in thread
From: Alex Deucher @ 2020-11-09 19:50 UTC (permalink / raw)
  To: Lee Jones
  Cc: David Airlie, LKML, Maling list - DRI developers, amd-gfx list,
	Alex Deucher, Christian König

On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
>
> Fixes the following W=1 kernel build warning(s):
>
>  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Function parameter or member 'dev' not described in 'radeon_info_ioctl'
>  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Excess function parameter 'rdev' description in 'radeon_info_ioctl'
>
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Cc: "Christian König" <christian.koenig@amd.com>
> Cc: David Airlie <airlied@linux.ie>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: amd-gfx@lists.freedesktop.org
> Cc: dri-devel@lists.freedesktop.org
> Signed-off-by: Lee Jones <lee.jones@linaro.org>
> ---
>  drivers/gpu/drm/radeon/radeon_kms.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/radeon/radeon_kms.c b/drivers/gpu/drm/radeon/radeon_kms.c
> index 0d8fbabffcead..21c206795c364 100644
> --- a/drivers/gpu/drm/radeon/radeon_kms.c
> +++ b/drivers/gpu/drm/radeon/radeon_kms.c
> @@ -213,7 +213,7 @@ static void radeon_set_filp_rights(struct drm_device *dev,
>  /**
>   * radeon_info_ioctl - answer a device specific request.
>   *
> - * @rdev: radeon device pointer
> + * @dev: radeon device pointer

This should be:
+ * @dev: drm device pointer

Alex

>   * @data: request object
>   * @filp: drm filp
>   *
> --
> 2.25.1
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 14/19] drm/amd/amdgpu/amdgpu_device: Provide documentation for 'reg_addr' params
  2020-11-06 21:49 ` [PATCH 14/19] drm/amd/amdgpu/amdgpu_device: Provide documentation for 'reg_addr' params Lee Jones
@ 2020-11-09 19:54   ` Alex Deucher
  0 siblings, 0 replies; 44+ messages in thread
From: Alex Deucher @ 2020-11-09 19:54 UTC (permalink / raw)
  To: Lee Jones
  Cc: David Airlie, LKML, Maling list - DRI developers,
	moderated list:DMA BUFFER SHARING FRAMEWORK, amd-gfx list,
	Alex Deucher, Christian König, linux-media

On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
>
> Fixes the following W=1 kernel build warning(s):
>
>  drivers/gpu/drm/amd/amdgpu/amdgpu_device.c:594: warning: Function parameter or member 'reg_addr' not described in 'amdgpu_device_indirect_rreg'
>  drivers/gpu/drm/amd/amdgpu/amdgpu_device.c:624: warning: Function parameter or member 'reg_addr' not described in 'amdgpu_device_indirect_rreg64'
>
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Cc: "Christian König" <christian.koenig@amd.com>
> Cc: David Airlie <airlied@linux.ie>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: Sumit Semwal <sumit.semwal@linaro.org>
> Cc: amd-gfx@lists.freedesktop.org
> Cc: dri-devel@lists.freedesktop.org
> Cc: linux-media@vger.kernel.org
> Cc: linaro-mm-sig@lists.linaro.org
> Signed-off-by: Lee Jones <lee.jones@linaro.org>

Applied.  Thanks!

Alex

> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
> index 300fcade4a2b1..63374d12e00fe 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
> @@ -585,6 +585,7 @@ void amdgpu_mm_wdoorbell64(struct amdgpu_device *adev, u32 index, u64 v)
>   * @adev: amdgpu_device pointer
>   * @pcie_index: mmio register offset
>   * @pcie_data: mmio register offset
> + * @reg_addr: indirect register address to read from
>   *
>   * Returns the value of indirect register @reg_addr
>   */
> @@ -615,6 +616,7 @@ u32 amdgpu_device_indirect_rreg(struct amdgpu_device *adev,
>   * @adev: amdgpu_device pointer
>   * @pcie_index: mmio register offset
>   * @pcie_data: mmio register offset
> + * @reg_addr: indirect register address to read from
>   *
>   * Returns the value of indirect register @reg_addr
>   */
> --
> 2.25.1
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 17/19] drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
  2020-11-09 19:50   ` Alex Deucher
@ 2020-11-09 19:55     ` Sam Ravnborg
  2020-11-09 20:06       ` Alex Deucher
  2020-11-09 20:10       ` Lee Jones
  2020-11-09 19:59     ` Lee Jones
  1 sibling, 2 replies; 44+ messages in thread
From: Sam Ravnborg @ 2020-11-09 19:55 UTC (permalink / raw)
  To: Alex Deucher
  Cc: David Airlie, LKML, amd-gfx list, Maling list - DRI developers,
	Alex Deucher, Lee Jones, Christian König

Hi Alex,
On Mon, Nov 09, 2020 at 02:50:35PM -0500, Alex Deucher wrote:
> On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
> >
> > Fixes the following W=1 kernel build warning(s):
> >
> >  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Function parameter or member 'dev' not described in 'radeon_info_ioctl'
> >  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Excess function parameter 'rdev' description in 'radeon_info_ioctl'
> >
> > Cc: Alex Deucher <alexander.deucher@amd.com>
> > Cc: "Christian König" <christian.koenig@amd.com>
> > Cc: David Airlie <airlied@linux.ie>
> > Cc: Daniel Vetter <daniel@ffwll.ch>
> > Cc: amd-gfx@lists.freedesktop.org
> > Cc: dri-devel@lists.freedesktop.org
> > Signed-off-by: Lee Jones <lee.jones@linaro.org>
> > ---
> >  drivers/gpu/drm/radeon/radeon_kms.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/gpu/drm/radeon/radeon_kms.c b/drivers/gpu/drm/radeon/radeon_kms.c
> > index 0d8fbabffcead..21c206795c364 100644
> > --- a/drivers/gpu/drm/radeon/radeon_kms.c
> > +++ b/drivers/gpu/drm/radeon/radeon_kms.c
> > @@ -213,7 +213,7 @@ static void radeon_set_filp_rights(struct drm_device *dev,
> >  /**
> >   * radeon_info_ioctl - answer a device specific request.
> >   *
> > - * @rdev: radeon device pointer
> > + * @dev: radeon device pointer
> 
> This should be:
> + * @dev: drm device pointer

good spot. I am continuing the work on radeon and will post a patchset
that contains only radeon fixes with Lee's patches and a few more by me.
I will fix the above.

	Sam
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 12/19] drm/amd/display/dc/basics/fixpt31_32: Move variables to where they're used
  2020-11-06 21:49 ` [PATCH 12/19] drm/amd/display/dc/basics/fixpt31_32: Move variables to where they're used Lee Jones
@ 2020-11-09 19:58   ` Alex Deucher
  0 siblings, 0 replies; 44+ messages in thread
From: Alex Deucher @ 2020-11-09 19:58 UTC (permalink / raw)
  To: Lee Jones
  Cc: Leo Li, LKML, Maling list - DRI developers, David Airlie,
	amd-gfx list, Alex Deucher, Christian König

On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
>
> Also rid some unused ones.
>
> This patch solves 2000 warnings!
>
> Fixes the following W=1 kernel build warning(s):
>
>  In file included from drivers/gpu/drm/amd/amdgpu/../display/dc/dc_types.h:33,
>  from drivers/gpu/drm/amd/amdgpu/../display/dc/dm_services_types.h:30,
>  from drivers/gpu/drm/amd/amdgpu/../display/dc/dm_services.h:35,
>  from drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/amdgpu_dm_helpers.c:35:
>  At top level:
>  drivers/gpu/drm/amd/amdgpu/../display/include/fixed31_32.h:76:32: warning: ‘dc_fixpt_ln2_div_2’ defined but not used [-Wunused-const-variable=]
>  76 | static const struct fixed31_32 dc_fixpt_ln2_div_2 = { 1488522236LL };
>  | ^~~~~~~~~~~~~~~~~~
>  drivers/gpu/drm/amd/amdgpu/../display/include/fixed31_32.h:75:32: warning: ‘dc_fixpt_ln2’ defined but not used [-Wunused-const-variable=]
>  75 | static const struct fixed31_32 dc_fixpt_ln2 = { 2977044471LL };
>  | ^~~~~~~~~~~~
>  drivers/gpu/drm/amd/amdgpu/../display/include/fixed31_32.h:74:32: warning: ‘dc_fixpt_e’ defined but not used [-Wunused-const-variable=]
>  74 | static const struct fixed31_32 dc_fixpt_e = { 11674931555LL };
>  | ^~~~~~~~~~
>  drivers/gpu/drm/amd/amdgpu/../display/include/fixed31_32.h:73:32: warning: ‘dc_fixpt_two_pi’ defined but not used [-Wunused-const-variable=]
>  73 | static const struct fixed31_32 dc_fixpt_two_pi = { 26986075409LL };
>  | ^~~~~~~~~~~~~~~
>  drivers/gpu/drm/amd/amdgpu/../display/include/fixed31_32.h:72:32: warning: ‘dc_fixpt_pi’ defined but not used [-Wunused-const-variable=]
>  72 | static const struct fixed31_32 dc_fixpt_pi = { 13493037705LL };
>  | ^~~~~~~~~~~
>
> Cc: Harry Wentland <harry.wentland@amd.com>
> Cc: Leo Li <sunpeng.li@amd.com>
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Cc: "Christian König" <christian.koenig@amd.com>
> Cc: David Airlie <airlied@linux.ie>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: amd-gfx@lists.freedesktop.org
> Cc: dri-devel@lists.freedesktop.org
> Signed-off-by: Lee Jones <lee.jones@linaro.org>

Applied.  Thanks!

Alex

> ---
>  drivers/gpu/drm/amd/display/dc/basics/fixpt31_32.c | 5 +++++
>  drivers/gpu/drm/amd/display/include/fixed31_32.h   | 6 ------
>  2 files changed, 5 insertions(+), 6 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/display/dc/basics/fixpt31_32.c b/drivers/gpu/drm/amd/display/dc/basics/fixpt31_32.c
> index 1e9a2d3520684..59f37563704ad 100644
> --- a/drivers/gpu/drm/amd/display/dc/basics/fixpt31_32.c
> +++ b/drivers/gpu/drm/amd/display/dc/basics/fixpt31_32.c
> @@ -26,6 +26,11 @@
>  #include "dm_services.h"
>  #include "include/fixed31_32.h"
>
> +static const struct fixed31_32 dc_fixpt_pi = { 13493037705LL };
> +static const struct fixed31_32 dc_fixpt_two_pi = { 26986075409LL };
> +static const struct fixed31_32 dc_fixpt_ln2 = { 2977044471LL };
> +static const struct fixed31_32 dc_fixpt_ln2_div_2 = { 1488522236LL };
> +
>  static inline unsigned long long abs_i64(
>         long long arg)
>  {
> diff --git a/drivers/gpu/drm/amd/display/include/fixed31_32.h b/drivers/gpu/drm/amd/display/include/fixed31_32.h
> index 16df2a485dd0d..22053d7ea6ced 100644
> --- a/drivers/gpu/drm/amd/display/include/fixed31_32.h
> +++ b/drivers/gpu/drm/amd/display/include/fixed31_32.h
> @@ -69,12 +69,6 @@ static const struct fixed31_32 dc_fixpt_epsilon = { 1LL };
>  static const struct fixed31_32 dc_fixpt_half = { 0x80000000LL };
>  static const struct fixed31_32 dc_fixpt_one = { 0x100000000LL };
>
> -static const struct fixed31_32 dc_fixpt_pi = { 13493037705LL };
> -static const struct fixed31_32 dc_fixpt_two_pi = { 26986075409LL };
> -static const struct fixed31_32 dc_fixpt_e = { 11674931555LL };
> -static const struct fixed31_32 dc_fixpt_ln2 = { 2977044471LL };
> -static const struct fixed31_32 dc_fixpt_ln2_div_2 = { 1488522236LL };
> -
>  /*
>   * @brief
>   * Initialization routines
> --
> 2.25.1
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 17/19] drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
  2020-11-09 19:50   ` Alex Deucher
  2020-11-09 19:55     ` Sam Ravnborg
@ 2020-11-09 19:59     ` Lee Jones
  1 sibling, 0 replies; 44+ messages in thread
From: Lee Jones @ 2020-11-09 19:59 UTC (permalink / raw)
  To: Alex Deucher
  Cc: David Airlie, LKML, Maling list - DRI developers, amd-gfx list,
	Alex Deucher, Christian König

On Mon, 09 Nov 2020, Alex Deucher wrote:

> On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
> >
> > Fixes the following W=1 kernel build warning(s):
> >
> >  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Function parameter or member 'dev' not described in 'radeon_info_ioctl'
> >  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Excess function parameter 'rdev' description in 'radeon_info_ioctl'
> >
> > Cc: Alex Deucher <alexander.deucher@amd.com>
> > Cc: "Christian König" <christian.koenig@amd.com>
> > Cc: David Airlie <airlied@linux.ie>
> > Cc: Daniel Vetter <daniel@ffwll.ch>
> > Cc: amd-gfx@lists.freedesktop.org
> > Cc: dri-devel@lists.freedesktop.org
> > Signed-off-by: Lee Jones <lee.jones@linaro.org>
> > ---
> >  drivers/gpu/drm/radeon/radeon_kms.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/gpu/drm/radeon/radeon_kms.c b/drivers/gpu/drm/radeon/radeon_kms.c
> > index 0d8fbabffcead..21c206795c364 100644
> > --- a/drivers/gpu/drm/radeon/radeon_kms.c
> > +++ b/drivers/gpu/drm/radeon/radeon_kms.c
> > @@ -213,7 +213,7 @@ static void radeon_set_filp_rights(struct drm_device *dev,
> >  /**
> >   * radeon_info_ioctl - answer a device specific request.
> >   *
> > - * @rdev: radeon device pointer
> > + * @dev: radeon device pointer
> 
> This should be:
> + * @dev: drm device pointer

Makes sense.  If you don't fancy fixing this up, I'll send out a
fix-up in a few days.

-- 
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 16/19] drm/amd/amdgpu/amdgpu_kms: Remove 'struct drm_amdgpu_info_device dev_info' from the stack
  2020-11-06 21:49 ` [PATCH 16/19] drm/amd/amdgpu/amdgpu_kms: Remove 'struct drm_amdgpu_info_device dev_info' from the stack Lee Jones
@ 2020-11-09 20:05   ` Alex Deucher
  0 siblings, 0 replies; 44+ messages in thread
From: Alex Deucher @ 2020-11-09 20:05 UTC (permalink / raw)
  To: Lee Jones
  Cc: David Airlie, LKML, Maling list - DRI developers, amd-gfx list,
	Alex Deucher, Christian König

On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
>
> Place it on the heap instead.
>
> Fixes the following W=1 kernel build warning(s):
>
>  drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c: In function ‘amdgpu_info_ioctl’:
>  drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c:979:1: warning: the frame size of 1128 bytes is larger than 1024 bytes [-Wframe-larger-than=]
>
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Cc: "Christian König" <christian.koenig@amd.com>
> Cc: David Airlie <airlied@linux.ie>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: amd-gfx@lists.freedesktop.org
> Cc: dri-devel@lists.freedesktop.org
> Signed-off-by: Lee Jones <lee.jones@linaro.org>

Applied.  Thanks!

Alex


> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 104 +++++++++++++-----------
>  1 file changed, 55 insertions(+), 49 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
> index 918d4e9c6461a..ef6fa5007d135 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
> @@ -721,38 +721,42 @@ static int amdgpu_info_ioctl(struct drm_device *dev, void *data, struct drm_file
>                 return n ? -EFAULT : 0;
>         }
>         case AMDGPU_INFO_DEV_INFO: {
> -               struct drm_amdgpu_info_device dev_info;
> +               struct drm_amdgpu_info_device *dev_info;
>                 uint64_t vm_size;
> +               int ret;
> +
> +               dev_info = kzalloc(sizeof(*dev_info), GFP_KERNEL);
> +               if (!dev_info)
> +                       return -ENOMEM;
>
> -               memset(&dev_info, 0, sizeof(dev_info));
> -               dev_info.device_id = dev->pdev->device;
> -               dev_info.chip_rev = adev->rev_id;
> -               dev_info.external_rev = adev->external_rev_id;
> -               dev_info.pci_rev = dev->pdev->revision;
> -               dev_info.family = adev->family;
> -               dev_info.num_shader_engines = adev->gfx.config.max_shader_engines;
> -               dev_info.num_shader_arrays_per_engine = adev->gfx.config.max_sh_per_se;
> +               dev_info->device_id = dev->pdev->device;
> +               dev_info->chip_rev = adev->rev_id;
> +               dev_info->external_rev = adev->external_rev_id;
> +               dev_info->pci_rev = dev->pdev->revision;
> +               dev_info->family = adev->family;
> +               dev_info->num_shader_engines = adev->gfx.config.max_shader_engines;
> +               dev_info->num_shader_arrays_per_engine = adev->gfx.config.max_sh_per_se;
>                 /* return all clocks in KHz */
> -               dev_info.gpu_counter_freq = amdgpu_asic_get_xclk(adev) * 10;
> +               dev_info->gpu_counter_freq = amdgpu_asic_get_xclk(adev) * 10;
>                 if (adev->pm.dpm_enabled) {
> -                       dev_info.max_engine_clock = amdgpu_dpm_get_sclk(adev, false) * 10;
> -                       dev_info.max_memory_clock = amdgpu_dpm_get_mclk(adev, false) * 10;
> +                       dev_info->max_engine_clock = amdgpu_dpm_get_sclk(adev, false) * 10;
> +                       dev_info->max_memory_clock = amdgpu_dpm_get_mclk(adev, false) * 10;
>                 } else {
> -                       dev_info.max_engine_clock = adev->clock.default_sclk * 10;
> -                       dev_info.max_memory_clock = adev->clock.default_mclk * 10;
> +                       dev_info->max_engine_clock = adev->clock.default_sclk * 10;
> +                       dev_info->max_memory_clock = adev->clock.default_mclk * 10;
>                 }
> -               dev_info.enabled_rb_pipes_mask = adev->gfx.config.backend_enable_mask;
> -               dev_info.num_rb_pipes = adev->gfx.config.max_backends_per_se *
> +               dev_info->enabled_rb_pipes_mask = adev->gfx.config.backend_enable_mask;
> +               dev_info->num_rb_pipes = adev->gfx.config.max_backends_per_se *
>                         adev->gfx.config.max_shader_engines;
> -               dev_info.num_hw_gfx_contexts = adev->gfx.config.max_hw_contexts;
> -               dev_info._pad = 0;
> -               dev_info.ids_flags = 0;
> +               dev_info->num_hw_gfx_contexts = adev->gfx.config.max_hw_contexts;
> +               dev_info->_pad = 0;
> +               dev_info->ids_flags = 0;
>                 if (adev->flags & AMD_IS_APU)
> -                       dev_info.ids_flags |= AMDGPU_IDS_FLAGS_FUSION;
> +                       dev_info->ids_flags |= AMDGPU_IDS_FLAGS_FUSION;
>                 if (amdgpu_mcbp || amdgpu_sriov_vf(adev))
> -                       dev_info.ids_flags |= AMDGPU_IDS_FLAGS_PREEMPTION;
> +                       dev_info->ids_flags |= AMDGPU_IDS_FLAGS_PREEMPTION;
>                 if (amdgpu_is_tmz(adev))
> -                       dev_info.ids_flags |= AMDGPU_IDS_FLAGS_TMZ;
> +                       dev_info->ids_flags |= AMDGPU_IDS_FLAGS_TMZ;
>
>                 vm_size = adev->vm_manager.max_pfn * AMDGPU_GPU_PAGE_SIZE;
>                 vm_size -= AMDGPU_VA_RESERVED_SIZE;
> @@ -762,45 +766,47 @@ static int amdgpu_info_ioctl(struct drm_device *dev, void *data, struct drm_file
>                     adev->vce.fw_version < AMDGPU_VCE_FW_53_45)
>                         vm_size = min(vm_size, 1ULL << 40);
>
> -               dev_info.virtual_address_offset = AMDGPU_VA_RESERVED_SIZE;
> -               dev_info.virtual_address_max =
> +               dev_info->virtual_address_offset = AMDGPU_VA_RESERVED_SIZE;
> +               dev_info->virtual_address_max =
>                         min(vm_size, AMDGPU_GMC_HOLE_START);
>
>                 if (vm_size > AMDGPU_GMC_HOLE_START) {
> -                       dev_info.high_va_offset = AMDGPU_GMC_HOLE_END;
> -                       dev_info.high_va_max = AMDGPU_GMC_HOLE_END | vm_size;
> +                       dev_info->high_va_offset = AMDGPU_GMC_HOLE_END;
> +                       dev_info->high_va_max = AMDGPU_GMC_HOLE_END | vm_size;
>                 }
> -               dev_info.virtual_address_alignment = max((int)PAGE_SIZE, AMDGPU_GPU_PAGE_SIZE);
> -               dev_info.pte_fragment_size = (1 << adev->vm_manager.fragment_size) * AMDGPU_GPU_PAGE_SIZE;
> -               dev_info.gart_page_size = AMDGPU_GPU_PAGE_SIZE;
> -               dev_info.cu_active_number = adev->gfx.cu_info.number;
> -               dev_info.cu_ao_mask = adev->gfx.cu_info.ao_cu_mask;
> -               dev_info.ce_ram_size = adev->gfx.ce_ram_size;
> -               memcpy(&dev_info.cu_ao_bitmap[0], &adev->gfx.cu_info.ao_cu_bitmap[0],
> +               dev_info->virtual_address_alignment = max((int)PAGE_SIZE, AMDGPU_GPU_PAGE_SIZE);
> +               dev_info->pte_fragment_size = (1 << adev->vm_manager.fragment_size) * AMDGPU_GPU_PAGE_SIZE;
> +               dev_info->gart_page_size = AMDGPU_GPU_PAGE_SIZE;
> +               dev_info->cu_active_number = adev->gfx.cu_info.number;
> +               dev_info->cu_ao_mask = adev->gfx.cu_info.ao_cu_mask;
> +               dev_info->ce_ram_size = adev->gfx.ce_ram_size;
> +               memcpy(&dev_info->cu_ao_bitmap[0], &adev->gfx.cu_info.ao_cu_bitmap[0],
>                        sizeof(adev->gfx.cu_info.ao_cu_bitmap));
> -               memcpy(&dev_info.cu_bitmap[0], &adev->gfx.cu_info.bitmap[0],
> +               memcpy(&dev_info->cu_bitmap[0], &adev->gfx.cu_info.bitmap[0],
>                        sizeof(adev->gfx.cu_info.bitmap));
> -               dev_info.vram_type = adev->gmc.vram_type;
> -               dev_info.vram_bit_width = adev->gmc.vram_width;
> -               dev_info.vce_harvest_config = adev->vce.harvest_config;
> -               dev_info.gc_double_offchip_lds_buf =
> +               dev_info->vram_type = adev->gmc.vram_type;
> +               dev_info->vram_bit_width = adev->gmc.vram_width;
> +               dev_info->vce_harvest_config = adev->vce.harvest_config;
> +               dev_info->gc_double_offchip_lds_buf =
>                         adev->gfx.config.double_offchip_lds_buf;
> -               dev_info.wave_front_size = adev->gfx.cu_info.wave_front_size;
> -               dev_info.num_shader_visible_vgprs = adev->gfx.config.max_gprs;
> -               dev_info.num_cu_per_sh = adev->gfx.config.max_cu_per_sh;
> -               dev_info.num_tcc_blocks = adev->gfx.config.max_texture_channel_caches;
> -               dev_info.gs_vgt_table_depth = adev->gfx.config.gs_vgt_table_depth;
> -               dev_info.gs_prim_buffer_depth = adev->gfx.config.gs_prim_buffer_depth;
> -               dev_info.max_gs_waves_per_vgt = adev->gfx.config.max_gs_threads;
> +               dev_info->wave_front_size = adev->gfx.cu_info.wave_front_size;
> +               dev_info->num_shader_visible_vgprs = adev->gfx.config.max_gprs;
> +               dev_info->num_cu_per_sh = adev->gfx.config.max_cu_per_sh;
> +               dev_info->num_tcc_blocks = adev->gfx.config.max_texture_channel_caches;
> +               dev_info->gs_vgt_table_depth = adev->gfx.config.gs_vgt_table_depth;
> +               dev_info->gs_prim_buffer_depth = adev->gfx.config.gs_prim_buffer_depth;
> +               dev_info->max_gs_waves_per_vgt = adev->gfx.config.max_gs_threads;
>
>                 if (adev->family >= AMDGPU_FAMILY_NV)
> -                       dev_info.pa_sc_tile_steering_override =
> +                       dev_info->pa_sc_tile_steering_override =
>                                 adev->gfx.config.pa_sc_tile_steering_override;
>
> -               dev_info.tcc_disabled_mask = adev->gfx.config.tcc_disabled_mask;
> +               dev_info->tcc_disabled_mask = adev->gfx.config.tcc_disabled_mask;
>
> -               return copy_to_user(out, &dev_info,
> -                                   min((size_t)size, sizeof(dev_info))) ? -EFAULT : 0;
> +               ret = copy_to_user(out, dev_info,
> +                                  min((size_t)size, sizeof(*dev_info))) ? -EFAULT : 0;
> +               kfree(dev_info);
> +               return ret;
>         }
>         case AMDGPU_INFO_VCE_CLOCK_TABLE: {
>                 unsigned i;
> --
> 2.25.1
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 17/19] drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
  2020-11-09 19:55     ` Sam Ravnborg
@ 2020-11-09 20:06       ` Alex Deucher
  2020-11-09 20:10       ` Lee Jones
  1 sibling, 0 replies; 44+ messages in thread
From: Alex Deucher @ 2020-11-09 20:06 UTC (permalink / raw)
  To: Sam Ravnborg
  Cc: David Airlie, LKML, amd-gfx list, Maling list - DRI developers,
	Alex Deucher, Lee Jones, Christian König

On Mon, Nov 9, 2020 at 2:56 PM Sam Ravnborg <sam@ravnborg.org> wrote:
>
> Hi Alex,
> On Mon, Nov 09, 2020 at 02:50:35PM -0500, Alex Deucher wrote:
> > On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
> > >
> > > Fixes the following W=1 kernel build warning(s):
> > >
> > >  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Function parameter or member 'dev' not described in 'radeon_info_ioctl'
> > >  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Excess function parameter 'rdev' description in 'radeon_info_ioctl'
> > >
> > > Cc: Alex Deucher <alexander.deucher@amd.com>
> > > Cc: "Christian König" <christian.koenig@amd.com>
> > > Cc: David Airlie <airlied@linux.ie>
> > > Cc: Daniel Vetter <daniel@ffwll.ch>
> > > Cc: amd-gfx@lists.freedesktop.org
> > > Cc: dri-devel@lists.freedesktop.org
> > > Signed-off-by: Lee Jones <lee.jones@linaro.org>
> > > ---
> > >  drivers/gpu/drm/radeon/radeon_kms.c | 2 +-
> > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/drivers/gpu/drm/radeon/radeon_kms.c b/drivers/gpu/drm/radeon/radeon_kms.c
> > > index 0d8fbabffcead..21c206795c364 100644
> > > --- a/drivers/gpu/drm/radeon/radeon_kms.c
> > > +++ b/drivers/gpu/drm/radeon/radeon_kms.c
> > > @@ -213,7 +213,7 @@ static void radeon_set_filp_rights(struct drm_device *dev,
> > >  /**
> > >   * radeon_info_ioctl - answer a device specific request.
> > >   *
> > > - * @rdev: radeon device pointer
> > > + * @dev: radeon device pointer
> >
> > This should be:
> > + * @dev: drm device pointer
>
> good spot. I am continuing the work on radeon and will post a patchset
> that contains only radeon fixes with Lee's patches and a few more by me.
> I will fix the above.

Awesome.  Thanks!

Alex
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 17/19] drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
  2020-11-09 19:55     ` Sam Ravnborg
  2020-11-09 20:06       ` Alex Deucher
@ 2020-11-09 20:10       ` Lee Jones
  2020-11-09 20:52         ` Sam Ravnborg
  1 sibling, 1 reply; 44+ messages in thread
From: Lee Jones @ 2020-11-09 20:10 UTC (permalink / raw)
  To: Sam Ravnborg
  Cc: David Airlie, LKML, amd-gfx list, Alex Deucher,
	Maling list - DRI developers, Alex Deucher, Christian König

On Mon, 09 Nov 2020, Sam Ravnborg wrote:

> Hi Alex,
> On Mon, Nov 09, 2020 at 02:50:35PM -0500, Alex Deucher wrote:
> > On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
> > >
> > > Fixes the following W=1 kernel build warning(s):
> > >
> > >  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Function parameter or member 'dev' not described in 'radeon_info_ioctl'
> > >  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Excess function parameter 'rdev' description in 'radeon_info_ioctl'
> > >
> > > Cc: Alex Deucher <alexander.deucher@amd.com>
> > > Cc: "Christian König" <christian.koenig@amd.com>
> > > Cc: David Airlie <airlied@linux.ie>
> > > Cc: Daniel Vetter <daniel@ffwll.ch>
> > > Cc: amd-gfx@lists.freedesktop.org
> > > Cc: dri-devel@lists.freedesktop.org
> > > Signed-off-by: Lee Jones <lee.jones@linaro.org>
> > > ---
> > >  drivers/gpu/drm/radeon/radeon_kms.c | 2 +-
> > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/drivers/gpu/drm/radeon/radeon_kms.c b/drivers/gpu/drm/radeon/radeon_kms.c
> > > index 0d8fbabffcead..21c206795c364 100644
> > > --- a/drivers/gpu/drm/radeon/radeon_kms.c
> > > +++ b/drivers/gpu/drm/radeon/radeon_kms.c
> > > @@ -213,7 +213,7 @@ static void radeon_set_filp_rights(struct drm_device *dev,
> > >  /**
> > >   * radeon_info_ioctl - answer a device specific request.
> > >   *
> > > - * @rdev: radeon device pointer
> > > + * @dev: radeon device pointer
> > 
> > This should be:
> > + * @dev: drm device pointer
> 
> good spot. I am continuing the work on radeon and will post a patchset
> that contains only radeon fixes with Lee's patches and a few more by me.
> I will fix the above.

What do you mean by "continuing on"?

How will you prevent your work from conflicting with my current effort?

-- 
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 17/19] drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
  2020-11-09 20:10       ` Lee Jones
@ 2020-11-09 20:52         ` Sam Ravnborg
  2020-11-09 21:15           ` Lee Jones
  0 siblings, 1 reply; 44+ messages in thread
From: Sam Ravnborg @ 2020-11-09 20:52 UTC (permalink / raw)
  To: Lee Jones
  Cc: David Airlie, LKML, amd-gfx list, Alex Deucher,
	Maling list - DRI developers, Alex Deucher, Christian König

On Mon, Nov 09, 2020 at 08:10:13PM +0000, Lee Jones wrote:
> On Mon, 09 Nov 2020, Sam Ravnborg wrote:
> 
> > Hi Alex,
> > On Mon, Nov 09, 2020 at 02:50:35PM -0500, Alex Deucher wrote:
> > > On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
> > > >
> > > > Fixes the following W=1 kernel build warning(s):
> > > >
> > > >  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Function parameter or member 'dev' not described in 'radeon_info_ioctl'
> > > >  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Excess function parameter 'rdev' description in 'radeon_info_ioctl'
> > > >
> > > > Cc: Alex Deucher <alexander.deucher@amd.com>
> > > > Cc: "Christian König" <christian.koenig@amd.com>
> > > > Cc: David Airlie <airlied@linux.ie>
> > > > Cc: Daniel Vetter <daniel@ffwll.ch>
> > > > Cc: amd-gfx@lists.freedesktop.org
> > > > Cc: dri-devel@lists.freedesktop.org
> > > > Signed-off-by: Lee Jones <lee.jones@linaro.org>
> > > > ---
> > > >  drivers/gpu/drm/radeon/radeon_kms.c | 2 +-
> > > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > > >
> > > > diff --git a/drivers/gpu/drm/radeon/radeon_kms.c b/drivers/gpu/drm/radeon/radeon_kms.c
> > > > index 0d8fbabffcead..21c206795c364 100644
> > > > --- a/drivers/gpu/drm/radeon/radeon_kms.c
> > > > +++ b/drivers/gpu/drm/radeon/radeon_kms.c
> > > > @@ -213,7 +213,7 @@ static void radeon_set_filp_rights(struct drm_device *dev,
> > > >  /**
> > > >   * radeon_info_ioctl - answer a device specific request.
> > > >   *
> > > > - * @rdev: radeon device pointer
> > > > + * @dev: radeon device pointer
> > > 
> > > This should be:
> > > + * @dev: drm device pointer
> > 
> > good spot. I am continuing the work on radeon and will post a patchset
> > that contains only radeon fixes with Lee's patches and a few more by me.
> > I will fix the above.
> 
> What do you mean by "continuing on"?
> 
> How will you prevent your work from conflicting with my current effort?

Quoting from previous mail in this thread:

  "
  > > How would you like me to move forward?
  >
  > Fix the thousand of warnings in other places :-)
  > I will take a look at radeon and post a new series based on your work
  > with all W=1 warnings fixed.

  I'll drop this patch and carry on ploughing through the rest of them.
"

Here I promised you to fix all warnings in the radeon driver.
And despite this being more work than anticipated a promise is a
promise. So therefore I started working on this.

If you want to do the rest of the radeon driver you are welcome and I
will gladly drop this again. Just let me know your preference.

	Sam
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 17/19] drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
  2020-11-09 20:52         ` Sam Ravnborg
@ 2020-11-09 21:15           ` Lee Jones
  0 siblings, 0 replies; 44+ messages in thread
From: Lee Jones @ 2020-11-09 21:15 UTC (permalink / raw)
  To: Sam Ravnborg
  Cc: David Airlie, LKML, amd-gfx list, Alex Deucher,
	Maling list - DRI developers, Alex Deucher, Christian König

On Mon, 09 Nov 2020, Sam Ravnborg wrote:

> On Mon, Nov 09, 2020 at 08:10:13PM +0000, Lee Jones wrote:
> > On Mon, 09 Nov 2020, Sam Ravnborg wrote:
> > 
> > > Hi Alex,
> > > On Mon, Nov 09, 2020 at 02:50:35PM -0500, Alex Deucher wrote:
> > > > On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
> > > > >
> > > > > Fixes the following W=1 kernel build warning(s):
> > > > >
> > > > >  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Function parameter or member 'dev' not described in 'radeon_info_ioctl'
> > > > >  drivers/gpu/drm/radeon/radeon_kms.c:226: warning: Excess function parameter 'rdev' description in 'radeon_info_ioctl'
> > > > >
> > > > > Cc: Alex Deucher <alexander.deucher@amd.com>
> > > > > Cc: "Christian König" <christian.koenig@amd.com>
> > > > > Cc: David Airlie <airlied@linux.ie>
> > > > > Cc: Daniel Vetter <daniel@ffwll.ch>
> > > > > Cc: amd-gfx@lists.freedesktop.org
> > > > > Cc: dri-devel@lists.freedesktop.org
> > > > > Signed-off-by: Lee Jones <lee.jones@linaro.org>
> > > > > ---
> > > > >  drivers/gpu/drm/radeon/radeon_kms.c | 2 +-
> > > > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > > > >
> > > > > diff --git a/drivers/gpu/drm/radeon/radeon_kms.c b/drivers/gpu/drm/radeon/radeon_kms.c
> > > > > index 0d8fbabffcead..21c206795c364 100644
> > > > > --- a/drivers/gpu/drm/radeon/radeon_kms.c
> > > > > +++ b/drivers/gpu/drm/radeon/radeon_kms.c
> > > > > @@ -213,7 +213,7 @@ static void radeon_set_filp_rights(struct drm_device *dev,
> > > > >  /**
> > > > >   * radeon_info_ioctl - answer a device specific request.
> > > > >   *
> > > > > - * @rdev: radeon device pointer
> > > > > + * @dev: radeon device pointer
> > > > 
> > > > This should be:
> > > > + * @dev: drm device pointer
> > > 
> > > good spot. I am continuing the work on radeon and will post a patchset
> > > that contains only radeon fixes with Lee's patches and a few more by me.
> > > I will fix the above.
> > 
> > What do you mean by "continuing on"?
> > 
> > How will you prevent your work from conflicting with my current effort?
> 
> Quoting from previous mail in this thread:
> 
>   "
>   > > How would you like me to move forward?
>   >
>   > Fix the thousand of warnings in other places :-)
>   > I will take a look at radeon and post a new series based on your work
>   > with all W=1 warnings fixed.
> 
>   I'll drop this patch and carry on ploughing through the rest of them.
> "
> 
> Here I promised you to fix all warnings in the radeon driver.
> And despite this being more work than anticipated a promise is a
> promise. So therefore I started working on this.
> 
> If you want to do the rest of the radeon driver you are welcome and I
> will gladly drop this again. Just let me know your preference.

That was the plan.  To continue on and solve as many warnings as I can
before I start bumping into more serious issues like the one mentioned
above.  If you'd like to solve the radeon_init() issue right away;
however, that would be super helpful.

-- 
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 06/19] drm/radeon/atom: Move prototype into shared location
  2020-11-06 21:49 ` [PATCH 06/19] drm/radeon/atom: Move prototype into shared location Lee Jones
@ 2020-11-10 21:54   ` Alex Deucher
  0 siblings, 0 replies; 44+ messages in thread
From: Alex Deucher @ 2020-11-10 21:54 UTC (permalink / raw)
  To: Lee Jones
  Cc: David Airlie, LKML, Maling list - DRI developers, amd-gfx list,
	Alex Deucher, Christian König

On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
>
> Both source files include atom.h, which seems like a reasonable
> location to place an atom based function into.
>
> Fixes the following W=1 kernel build warning(s):
>
>  drivers/gpu/drm/radeon/radeon_atombios.c:1791:6: warning: no previous prototype for ‘radeon_atom_get_tv_timings’ [-Wmissing-prototypes]
>  1791 | bool radeon_atom_get_tv_timings(struct radeon_device *rdev, int index,
>  | ^~~~~~~~~~~~~~~~~~~~~~~~~~
>
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Cc: "Christian König" <christian.koenig@amd.com>
> Cc: David Airlie <airlied@linux.ie>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: amd-gfx@lists.freedesktop.org
> Cc: dri-devel@lists.freedesktop.org
> Signed-off-by: Lee Jones <lee.jones@linaro.org>
> ---
>  drivers/gpu/drm/radeon/atom.h              | 6 ++++++
>  drivers/gpu/drm/radeon/atombios_encoders.c | 4 ----
>  2 files changed, 6 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/gpu/drm/radeon/atom.h b/drivers/gpu/drm/radeon/atom.h
> index 1bf06c91cd959..cb93b83114dbe 100644
> --- a/drivers/gpu/drm/radeon/atom.h
> +++ b/drivers/gpu/drm/radeon/atom.h
> @@ -154,6 +154,12 @@ bool atom_parse_data_header(struct atom_context *ctx, int index, uint16_t *size,
>  bool atom_parse_cmd_header(struct atom_context *ctx, int index,
>                            uint8_t *frev, uint8_t *crev);
>  int atom_allocate_fb_scratch(struct atom_context *ctx);
> +
> +struct drm_display_mode;
> +struct radeon_device;
> +bool radeon_atom_get_tv_timings(struct radeon_device *rdev, int index,
> +                               struct drm_display_mode *mode);
> +

I'd prefer to add radeon_atombios.h for all of the stuff exported from
radeon_atombios.c.  When you add the .h file, please take the
copyright license from the .c file which implements the functions.

Thanks,

Alex

>  #include "atom-types.h"
>  #include "atombios.h"
>  #include "ObjectID.h"
> diff --git a/drivers/gpu/drm/radeon/atombios_encoders.c b/drivers/gpu/drm/radeon/atombios_encoders.c
> index cc5ee1b3af84f..85f903caf12e1 100644
> --- a/drivers/gpu/drm/radeon/atombios_encoders.c
> +++ b/drivers/gpu/drm/radeon/atombios_encoders.c
> @@ -296,10 +296,6 @@ static void radeon_atom_backlight_exit(struct radeon_encoder *encoder)
>
>  #endif
>
> -/* evil but including atombios.h is much worse */
> -bool radeon_atom_get_tv_timings(struct radeon_device *rdev, int index,
> -                               struct drm_display_mode *mode);
> -
>  static bool radeon_atom_mode_fixup(struct drm_encoder *encoder,
>                                    const struct drm_display_mode *mode,
>                                    struct drm_display_mode *adjusted_mode)
> --
> 2.25.1
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 07/19] drm/radeon/radeon_kms: Include header containing our own prototypes
  2020-11-06 21:49 ` [PATCH 07/19] drm/radeon/radeon_kms: Include header containing our own prototypes Lee Jones
@ 2020-11-10 21:55   ` Alex Deucher
  0 siblings, 0 replies; 44+ messages in thread
From: Alex Deucher @ 2020-11-10 21:55 UTC (permalink / raw)
  To: Lee Jones
  Cc: David Airlie, LKML, Maling list - DRI developers, amd-gfx list,
	Alex Deucher, Christian König

On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
>
> Fixes the following W=1 kernel build warning(s):
>
>  drivers/gpu/drm/radeon/radeon_kms.c:61:6: warning: no previous prototype for ‘radeon_driver_unload_kms’ [-Wmissing-prototypes]
>  drivers/gpu/drm/radeon/radeon_kms.c:104:5: warning: no previous prototype for ‘radeon_driver_load_kms’ [-Wmissing-prototypes]
>  drivers/gpu/drm/radeon/radeon_kms.c:618:6: warning: no previous prototype for ‘radeon_driver_lastclose_kms’ [-Wmissing-prototypes]
>  drivers/gpu/drm/radeon/radeon_kms.c:633:5: warning: no previous prototype for ‘radeon_driver_open_kms’ [-Wmissing-prototypes]
>  drivers/gpu/drm/radeon/radeon_kms.c:704:6: warning: no previous prototype for ‘radeon_driver_postclose_kms’ [-Wmissing-prototypes]
>  drivers/gpu/drm/radeon/radeon_kms.c:755:5: warning: no previous prototype for ‘radeon_get_vblank_counter_kms’ [-Wmissing-prototypes]
>  drivers/gpu/drm/radeon/radeon_kms.c:825:5: warning: no previous prototype for ‘radeon_enable_vblank_kms’ [-Wmissing-prototypes]
>  drivers/gpu/drm/radeon/radeon_kms.c:852:6: warning: no previous prototype for ‘radeon_disable_vblank_kms’ [-Wmissing-prototypes]
>
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Cc: "Christian König" <christian.koenig@amd.com>
> Cc: David Airlie <airlied@linux.ie>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: amd-gfx@lists.freedesktop.org
> Cc: dri-devel@lists.freedesktop.org
> Signed-off-by: Lee Jones <lee.jones@linaro.org>

Applied.  Thanks!

Alex


> ---
>  drivers/gpu/drm/radeon/radeon_kms.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/drivers/gpu/drm/radeon/radeon_kms.c b/drivers/gpu/drm/radeon/radeon_kms.c
> index 99ee60f8b604d..0d8fbabffcead 100644
> --- a/drivers/gpu/drm/radeon/radeon_kms.c
> +++ b/drivers/gpu/drm/radeon/radeon_kms.c
> @@ -40,6 +40,7 @@
>
>  #include "radeon.h"
>  #include "radeon_asic.h"
> +#include "radeon_drv.h"
>
>  #if defined(CONFIG_VGA_SWITCHEROO)
>  bool radeon_has_atpx(void);
> --
> 2.25.1
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 11/19] drm/radeon/radeon_drv: Source file headers are not good candidates for kernel-doc
  2020-11-06 21:49 ` [PATCH 11/19] drm/radeon/radeon_drv: Source file headers are not good candidates for kernel-doc Lee Jones
@ 2020-11-10 21:56   ` Alex Deucher
  0 siblings, 0 replies; 44+ messages in thread
From: Alex Deucher @ 2020-11-10 21:56 UTC (permalink / raw)
  To: Lee Jones
  Cc: David Airlie, LKML, Maling list - DRI developers, amd-gfx list,
	Alex Deucher, Gareth Hughes, Christian König

On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
>
> Fixes the following W=1 kernel build warning(s):
>
>  drivers/gpu/drm/radeon/radeon_drv.c:2: warning: Cannot understand  * file radeon_drv.c
>
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Cc: "Christian König" <christian.koenig@amd.com>
> Cc: David Airlie <airlied@linux.ie>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: Gareth Hughes <gareth@valinux.com>
> Cc: amd-gfx@lists.freedesktop.org
> Cc: dri-devel@lists.freedesktop.org
> Signed-off-by: Lee Jones <lee.jones@linaro.org>

Applied.  Thanks!

Alex

> ---
>  drivers/gpu/drm/radeon/radeon_drv.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/radeon/radeon_drv.c b/drivers/gpu/drm/radeon/radeon_drv.c
> index 560267cc25892..bb7b33e535f81 100644
> --- a/drivers/gpu/drm/radeon/radeon_drv.c
> +++ b/drivers/gpu/drm/radeon/radeon_drv.c
> @@ -1,4 +1,4 @@
> -/**
> +/*
>   * \file radeon_drv.c
>   * ATI Radeon driver
>   *
> --
> 2.25.1
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 13/19] drm/radeon/radeon_drv: Move prototypes to a shared headerfile
  2020-11-06 21:49 ` [PATCH 13/19] drm/radeon/radeon_drv: Move prototypes to a shared headerfile Lee Jones
@ 2020-11-10 21:58   ` Alex Deucher
  0 siblings, 0 replies; 44+ messages in thread
From: Alex Deucher @ 2020-11-10 21:58 UTC (permalink / raw)
  To: Lee Jones
  Cc: David Airlie, LKML, Maling list - DRI developers, amd-gfx list,
	Alex Deucher, Gareth Hughes, Christian König

On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
>
> Fixes the following W=1 kernel build warning(s):
>
>  62 | void radeon_driver_unload_kms(struct drm_device *dev)
>  | ^~~~~~~~~~~~~~~~~~~~~~~~
>  drivers/gpu/drm/radeon/radeon_kms.c:105:5: warning: no previous prototype for ‘radeon_driver_load_kms’ [-Wmissing-prototypes]
>  105 | int radeon_driver_load_kms(struct drm_device *dev, unsigned long flags)
>  | ^~~~~~~~~~~~~~~~~~~~~~
>  drivers/gpu/drm/radeon/radeon_kms.c:619:6: warning: no previous prototype for ‘radeon_driver_lastclose_kms’ [-Wmissing-prototypes]
>  619 | void radeon_driver_lastclose_kms(struct drm_device *dev)
>  | ^~~~~~~~~~~~~~~~~~~~~~~~~~~
>  drivers/gpu/drm/radeon/radeon_kms.c:634:5: warning: no previous prototype for ‘radeon_driver_open_kms’ [-Wmissing-prototypes]
>  634 | int radeon_driver_open_kms(struct drm_device *dev, struct drm_file *file_priv)
>  | ^~~~~~~~~~~~~~~~~~~~~~
>  drivers/gpu/drm/radeon/radeon_kms.c:705:6: warning: no previous prototype for ‘radeon_driver_postclose_kms’ [-Wmissing-prototypes]
>  705 | void radeon_driver_postclose_kms(struct drm_device *dev,
>  | ^~~~~~~~~~~~~~~~~~~~~~~~~~~
>
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Cc: "Christian König" <christian.koenig@amd.com>
> Cc: David Airlie <airlied@linux.ie>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: Gareth Hughes <gareth@valinux.com>
> Cc: amd-gfx@lists.freedesktop.org
> Cc: dri-devel@lists.freedesktop.org
> Signed-off-by: Lee Jones <lee.jones@linaro.org>

Applied.  Thanks!

Alex

> ---
>  drivers/gpu/drm/radeon/radeon_drv.c | 6 ------
>  drivers/gpu/drm/radeon/radeon_drv.h | 7 +++++++
>  2 files changed, 7 insertions(+), 6 deletions(-)
>
> diff --git a/drivers/gpu/drm/radeon/radeon_drv.c b/drivers/gpu/drm/radeon/radeon_drv.c
> index bb7b33e535f81..e0d664e9e2feb 100644
> --- a/drivers/gpu/drm/radeon/radeon_drv.c
> +++ b/drivers/gpu/drm/radeon/radeon_drv.c
> @@ -112,12 +112,6 @@
>  #define KMS_DRIVER_MAJOR       2
>  #define KMS_DRIVER_MINOR       50
>  #define KMS_DRIVER_PATCHLEVEL  0
> -int radeon_driver_load_kms(struct drm_device *dev, unsigned long flags);
> -void radeon_driver_unload_kms(struct drm_device *dev);
> -void radeon_driver_lastclose_kms(struct drm_device *dev);
> -int radeon_driver_open_kms(struct drm_device *dev, struct drm_file *file_priv);
> -void radeon_driver_postclose_kms(struct drm_device *dev,
> -                                struct drm_file *file_priv);
>  int radeon_suspend_kms(struct drm_device *dev, bool suspend,
>                        bool fbcon, bool freeze);
>  int radeon_resume_kms(struct drm_device *dev, bool resume, bool fbcon);
> diff --git a/drivers/gpu/drm/radeon/radeon_drv.h b/drivers/gpu/drm/radeon/radeon_drv.h
> index 173deb4634146..ac7970919c4d3 100644
> --- a/drivers/gpu/drm/radeon/radeon_drv.h
> +++ b/drivers/gpu/drm/radeon/radeon_drv.h
> @@ -118,4 +118,11 @@
>  long radeon_drm_ioctl(struct file *filp,
>                       unsigned int cmd, unsigned long arg);
>
> +int radeon_driver_load_kms(struct drm_device *dev, unsigned long flags);
> +void radeon_driver_unload_kms(struct drm_device *dev);
> +void radeon_driver_lastclose_kms(struct drm_device *dev);
> +int radeon_driver_open_kms(struct drm_device *dev, struct drm_file *file_priv);
> +void radeon_driver_postclose_kms(struct drm_device *dev,
> +                                struct drm_file *file_priv);
> +
>  #endif                         /* __RADEON_DRV_H__ */
> --
> 2.25.1
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 15/19] drm/radeon: Move prototypes to shared header
  2020-11-06 21:49 ` [PATCH 15/19] drm/radeon: Move prototypes to shared header Lee Jones
@ 2020-11-10 21:59   ` Alex Deucher
  0 siblings, 0 replies; 44+ messages in thread
From: Alex Deucher @ 2020-11-10 21:59 UTC (permalink / raw)
  To: Lee Jones
  Cc: David Airlie, LKML, Maling list - DRI developers,
	moderated list:DMA BUFFER SHARING FRAMEWORK, amd-gfx list,
	Alex Deucher, Christian König, linux-media

On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
>
> Fixes the following W=1 kernel build warning(s):
>
>  drivers/gpu/drm/radeon/radeon_kms.c:756:5: warning: no previous prototype for ‘radeon_get_vblank_counter_kms’ [-Wmissing-prototypes]
>  756 | u32 radeon_get_vblank_counter_kms(struct drm_crtc *crtc)
>  | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>  drivers/gpu/drm/radeon/radeon_kms.c:826:5: warning: no previous prototype for ‘radeon_enable_vblank_kms’ [-Wmissing-prototypes]
>  826 | int radeon_enable_vblank_kms(struct drm_crtc *crtc)
>  | ^~~~~~~~~~~~~~~~~~~~~~~~
>  drivers/gpu/drm/radeon/radeon_kms.c:853:6: warning: no previous prototype for ‘radeon_disable_vblank_kms’ [-Wmissing-prototypes]
>  853 | void radeon_disable_vblank_kms(struct drm_crtc *crtc)
>  | ^~~~~~~~~~~~~~~~~~~~~~~~~
>
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Cc: "Christian König" <christian.koenig@amd.com>
> Cc: David Airlie <airlied@linux.ie>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: Sumit Semwal <sumit.semwal@linaro.org>
> Cc: amd-gfx@lists.freedesktop.org
> Cc: dri-devel@lists.freedesktop.org
> Cc: linux-media@vger.kernel.org
> Cc: linaro-mm-sig@lists.linaro.org
> Signed-off-by: Lee Jones <lee.jones@linaro.org>

Applied.  Thanks!

Alex


> ---
>  drivers/gpu/drm/radeon/radeon.h         | 6 ++++++
>  drivers/gpu/drm/radeon/radeon_display.c | 4 ----
>  2 files changed, 6 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/gpu/drm/radeon/radeon.h b/drivers/gpu/drm/radeon/radeon.h
> index e1132d86d2507..961a31b8805c2 100644
> --- a/drivers/gpu/drm/radeon/radeon.h
> +++ b/drivers/gpu/drm/radeon/radeon.h
> @@ -2832,6 +2832,12 @@ extern void radeon_program_register_sequence(struct radeon_device *rdev,
>                                              const u32 array_size);
>  struct radeon_device *radeon_get_rdev(struct ttm_bo_device *bdev);
>
> +/* KMS */
> +
> +u32 radeon_get_vblank_counter_kms(struct drm_crtc *crtc);
> +int radeon_enable_vblank_kms(struct drm_crtc *crtc);
> +void radeon_disable_vblank_kms(struct drm_crtc *crtc);
> +
>  /*
>   * vm
>   */
> diff --git a/drivers/gpu/drm/radeon/radeon_display.c b/drivers/gpu/drm/radeon/radeon_display.c
> index b79686cf8bdbd..bd60f16fd0d78 100644
> --- a/drivers/gpu/drm/radeon/radeon_display.c
> +++ b/drivers/gpu/drm/radeon/radeon_display.c
> @@ -45,10 +45,6 @@
>  #include "atom.h"
>  #include "radeon.h"
>
> -u32 radeon_get_vblank_counter_kms(struct drm_crtc *crtc);
> -int radeon_enable_vblank_kms(struct drm_crtc *crtc);
> -void radeon_disable_vblank_kms(struct drm_crtc *crtc);
> -
>  static void avivo_crtc_load_lut(struct drm_crtc *crtc)
>  {
>         struct radeon_crtc *radeon_crtc = to_radeon_crtc(crtc);
> --
> 2.25.1
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 18/19] drm/radeon/atombios_crtc: Remove description of non-existent function param 'encoder'
  2020-11-06 21:49 ` [PATCH 18/19] drm/radeon/atombios_crtc: Remove description of non-existent function param 'encoder' Lee Jones
@ 2020-11-10 22:01   ` Alex Deucher
  0 siblings, 0 replies; 44+ messages in thread
From: Alex Deucher @ 2020-11-10 22:01 UTC (permalink / raw)
  To: Lee Jones
  Cc: David Airlie, LKML, Maling list - DRI developers, amd-gfx list,
	Alex Deucher, Christian König

On Fri, Nov 6, 2020 at 4:50 PM Lee Jones <lee.jones@linaro.org> wrote:
>
> Fixes the following W=1 kernel build warning(s):
>
>  drivers/gpu/drm/radeon/atombios_crtc.c:1796: warning: Excess function parameter 'encoder' description in 'radeon_get_shared_nondp_ppll'
>
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Cc: "Christian König" <christian.koenig@amd.com>
> Cc: David Airlie <airlied@linux.ie>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: amd-gfx@lists.freedesktop.org
> Cc: dri-devel@lists.freedesktop.org
> Signed-off-by: Lee Jones <lee.jones@linaro.org>

Applied.  Thanks!

Alex

> ---
>  drivers/gpu/drm/radeon/atombios_crtc.c | 1 -
>  1 file changed, 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/radeon/atombios_crtc.c b/drivers/gpu/drm/radeon/atombios_crtc.c
> index 91811757104c0..1979ed3d65472 100644
> --- a/drivers/gpu/drm/radeon/atombios_crtc.c
> +++ b/drivers/gpu/drm/radeon/atombios_crtc.c
> @@ -1787,7 +1787,6 @@ static int radeon_get_shared_dp_ppll(struct drm_crtc *crtc)
>   * radeon_get_shared_nondp_ppll - return the PPLL used by another non-DP crtc
>   *
>   * @crtc: drm crtc
> - * @encoder: drm encoder
>   *
>   * Returns the PPLL (Pixel PLL) used by another non-DP crtc/encoder which can
>   * be shared (i.e., same clock).
> --
> 2.25.1
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU
  2020-11-06 21:49 [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Lee Jones
                   ` (12 preceding siblings ...)
  2020-11-07 12:18 ` Christian König
@ 2020-11-13  7:19 ` Lee Jones
  2020-11-13  7:28   ` Alex Deucher
  13 siblings, 1 reply; 44+ messages in thread
From: Lee Jones @ 2020-11-13  7:19 UTC (permalink / raw)
  To: linux-kernel, Alex Deucher, amd-gfx, Andy Gross, by,
	Christian Koenig, Daniel Vetter, David Airlie, dri-devel,
	Eric Anholt, Faith, Gareth Hughes, Harry Wentland, Huang Rui,
	Jeff Hartmann, Keith Whitwell, Leo Li, linaro-mm-sig,
	linux-media, Philipp Zabel, Rob Clark, Rob Clark, Sumit Semwal,
	Tomi Valkeinen

On Fri, 06 Nov 2020, Lee Jones wrote:

> This set is part of a larger effort attempting to clean-up W=1
> kernel builds, which are currently overwhelmingly riddled with
> niggly little warnings.
> 
> There are 5000 warnings to work through.  It will take a couple more
> sets.  Although, ("drm/amd/display/dc/basics/fixpt31_32: Move
> variables to where they're used") does take care of 2000 of them!
> 
> Lee Jones (19):
>   drm/ttm/ttm_range_manager: Demote non-conformant kernel-doc header
>   drm/r128/ati_pcigart: Source file headers are not good candidates for
>     kernel-doc
>   drm/selftests/test-drm_dp_mst_helper: Move
>     'sideband_msg_req_encode_decode' onto the heap
>   drm/mga/mga_dma: Demote kernel-doc abusers to standard comment blocks
>   drm/mga/mga_state: Remove unused variable 'buf_priv'
>   drm/radeon/atom: Move prototype into shared location
>   drm/radeon/radeon_kms: Include header containing our own prototypes
>   drm/omapdrm/omap_gem: Fix misnamed and missing parameter descriptions
>   drm/omapdrm/omap_dmm_tiler: Demote abusive use of kernel-doc format
>   drm/radeon/radeon: Move prototype into shared header
>   drm/radeon/radeon_drv: Source file headers are not good candidates for
>     kernel-doc
>   drm/amd/display/dc/basics/fixpt31_32: Move variables to where they're
>     used
>   drm/radeon/radeon_drv: Move prototypes to a shared headerfile
>   drm/amd/amdgpu/amdgpu_device: Provide documentation for 'reg_addr'
>     params
>   drm/radeon: Move prototypes to shared header
>   drm/amd/amdgpu/amdgpu_kms: Remove 'struct drm_amdgpu_info_device
>     dev_info' from the stack
>   drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
>   drm/radeon/atombios_crtc: Remove description of non-existent function
>     param 'encoder'
>   drm/v3d/v3d_drv: Remove unused static variable 'v3d_v3d_pm_ops'
> 
>  drivers/gpu/drm/amd/amdgpu/amdgpu_device.c    |   2 +
>  drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c       | 104 +++++++++---------
>  .../drm/amd/display/dc/basics/fixpt31_32.c    |   5 +
>  .../gpu/drm/amd/display/include/fixed31_32.h  |   6 -
>  drivers/gpu/drm/mga/mga_dma.c                 |  10 +-
>  drivers/gpu/drm/mga/mga_state.c               |   2 -
>  drivers/gpu/drm/omapdrm/omap_dmm_tiler.c      |   6 +-
>  drivers/gpu/drm/omapdrm/omap_gem.c            |   3 +-
>  drivers/gpu/drm/r128/ati_pcigart.c            |   2 +-
>  drivers/gpu/drm/radeon/atom.h                 |   6 +
>  drivers/gpu/drm/radeon/atombios_crtc.c        |   1 -
>  drivers/gpu/drm/radeon/atombios_encoders.c    |   4 -
>  drivers/gpu/drm/radeon/radeon.h               |   6 +
>  drivers/gpu/drm/radeon/radeon_device.c        |   1 +
>  drivers/gpu/drm/radeon/radeon_device.h        |  32 ++++++
>  drivers/gpu/drm/radeon/radeon_display.c       |   4 -
>  drivers/gpu/drm/radeon/radeon_drv.c           |  11 +-
>  drivers/gpu/drm/radeon/radeon_drv.h           |   7 ++
>  drivers/gpu/drm/radeon/radeon_kms.c           |   3 +-
>  .../drm/selftests/test-drm_dp_mst_helper.c    |  11 +-
>  drivers/gpu/drm/ttm/ttm_range_manager.c       |   2 +-
>  drivers/gpu/drm/v3d/v3d_drv.c                 |  36 ------
>  22 files changed, 138 insertions(+), 126 deletions(-)
>  create mode 100644 drivers/gpu/drm/radeon/radeon_device.h

Still no Radeon patches in today's -next.

I really wanted to have had this set rebased by now.

How long do they take to peculate through?

-- 
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU
  2020-11-13  7:19 ` Lee Jones
@ 2020-11-13  7:28   ` Alex Deucher
  2020-11-13  7:36     ` Lee Jones
  0 siblings, 1 reply; 44+ messages in thread
From: Alex Deucher @ 2020-11-13  7:28 UTC (permalink / raw)
  To: Lee Jones
  Cc: David Airlie, Maling list - DRI developers, Eric Anholt,
	Huang Rui, Rob Clark, Gareth Hughes, Sumit Semwal, amd-gfx list,
	Rob Clark, Tomi Valkeinen, Keith Whitwell, Andy Gross,
	Harry Wentland, linux-media, Daniel Vetter, Leo Li,
	moderated list:DMA BUFFER SHARING FRAMEWORK, by, Jeff Hartmann,
	LKML, Faith, Philipp Zabel, Alex Deucher, Christian Koenig

On Fri, Nov 13, 2020 at 2:19 AM Lee Jones <lee.jones@linaro.org> wrote:
>
> On Fri, 06 Nov 2020, Lee Jones wrote:
>
> > This set is part of a larger effort attempting to clean-up W=1
> > kernel builds, which are currently overwhelmingly riddled with
> > niggly little warnings.
> >
> > There are 5000 warnings to work through.  It will take a couple more
> > sets.  Although, ("drm/amd/display/dc/basics/fixpt31_32: Move
> > variables to where they're used") does take care of 2000 of them!
> >
> > Lee Jones (19):
> >   drm/ttm/ttm_range_manager: Demote non-conformant kernel-doc header
> >   drm/r128/ati_pcigart: Source file headers are not good candidates for
> >     kernel-doc
> >   drm/selftests/test-drm_dp_mst_helper: Move
> >     'sideband_msg_req_encode_decode' onto the heap
> >   drm/mga/mga_dma: Demote kernel-doc abusers to standard comment blocks
> >   drm/mga/mga_state: Remove unused variable 'buf_priv'
> >   drm/radeon/atom: Move prototype into shared location
> >   drm/radeon/radeon_kms: Include header containing our own prototypes
> >   drm/omapdrm/omap_gem: Fix misnamed and missing parameter descriptions
> >   drm/omapdrm/omap_dmm_tiler: Demote abusive use of kernel-doc format
> >   drm/radeon/radeon: Move prototype into shared header
> >   drm/radeon/radeon_drv: Source file headers are not good candidates for
> >     kernel-doc
> >   drm/amd/display/dc/basics/fixpt31_32: Move variables to where they're
> >     used
> >   drm/radeon/radeon_drv: Move prototypes to a shared headerfile
> >   drm/amd/amdgpu/amdgpu_device: Provide documentation for 'reg_addr'
> >     params
> >   drm/radeon: Move prototypes to shared header
> >   drm/amd/amdgpu/amdgpu_kms: Remove 'struct drm_amdgpu_info_device
> >     dev_info' from the stack
> >   drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
> >   drm/radeon/atombios_crtc: Remove description of non-existent function
> >     param 'encoder'
> >   drm/v3d/v3d_drv: Remove unused static variable 'v3d_v3d_pm_ops'
> >
> >  drivers/gpu/drm/amd/amdgpu/amdgpu_device.c    |   2 +
> >  drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c       | 104 +++++++++---------
> >  .../drm/amd/display/dc/basics/fixpt31_32.c    |   5 +
> >  .../gpu/drm/amd/display/include/fixed31_32.h  |   6 -
> >  drivers/gpu/drm/mga/mga_dma.c                 |  10 +-
> >  drivers/gpu/drm/mga/mga_state.c               |   2 -
> >  drivers/gpu/drm/omapdrm/omap_dmm_tiler.c      |   6 +-
> >  drivers/gpu/drm/omapdrm/omap_gem.c            |   3 +-
> >  drivers/gpu/drm/r128/ati_pcigart.c            |   2 +-
> >  drivers/gpu/drm/radeon/atom.h                 |   6 +
> >  drivers/gpu/drm/radeon/atombios_crtc.c        |   1 -
> >  drivers/gpu/drm/radeon/atombios_encoders.c    |   4 -
> >  drivers/gpu/drm/radeon/radeon.h               |   6 +
> >  drivers/gpu/drm/radeon/radeon_device.c        |   1 +
> >  drivers/gpu/drm/radeon/radeon_device.h        |  32 ++++++
> >  drivers/gpu/drm/radeon/radeon_display.c       |   4 -
> >  drivers/gpu/drm/radeon/radeon_drv.c           |  11 +-
> >  drivers/gpu/drm/radeon/radeon_drv.h           |   7 ++
> >  drivers/gpu/drm/radeon/radeon_kms.c           |   3 +-
> >  .../drm/selftests/test-drm_dp_mst_helper.c    |  11 +-
> >  drivers/gpu/drm/ttm/ttm_range_manager.c       |   2 +-
> >  drivers/gpu/drm/v3d/v3d_drv.c                 |  36 ------
> >  22 files changed, 138 insertions(+), 126 deletions(-)
> >  create mode 100644 drivers/gpu/drm/radeon/radeon_device.h
>
> Still no Radeon patches in today's -next.
>
> I really wanted to have had this set rebased by now.
>
> How long do they take to peculate through?

Usually a day or two, but I was swamped the last couple of days. I
pushed an updated -next branch today:
https://cgit.freedesktop.org/~agd5f/linux/log/?h=drm-next

Alex

>
> --
> Lee Jones [李琼斯]
> Senior Technical Lead - Developer Services
> Linaro.org │ Open source software for Arm SoCs
> Follow Linaro: Facebook | Twitter | Blog
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU
  2020-11-13  7:28   ` Alex Deucher
@ 2020-11-13  7:36     ` Lee Jones
  0 siblings, 0 replies; 44+ messages in thread
From: Lee Jones @ 2020-11-13  7:36 UTC (permalink / raw)
  To: Alex Deucher
  Cc: David Airlie, Maling list - DRI developers, Eric Anholt,
	Huang Rui, Rob Clark, Gareth Hughes, Sumit Semwal, amd-gfx list,
	Rob Clark, Tomi Valkeinen, Keith Whitwell, Andy Gross,
	Harry Wentland, linux-media, Daniel Vetter, Leo Li,
	moderated list:DMA BUFFER SHARING FRAMEWORK, by, Jeff Hartmann,
	LKML, Faith, Philipp Zabel, Alex Deucher, Christian Koenig

On Fri, 13 Nov 2020, Alex Deucher wrote:

> On Fri, Nov 13, 2020 at 2:19 AM Lee Jones <lee.jones@linaro.org> wrote:
> >
> > On Fri, 06 Nov 2020, Lee Jones wrote:
> >
> > > This set is part of a larger effort attempting to clean-up W=1
> > > kernel builds, which are currently overwhelmingly riddled with
> > > niggly little warnings.
> > >
> > > There are 5000 warnings to work through.  It will take a couple more
> > > sets.  Although, ("drm/amd/display/dc/basics/fixpt31_32: Move
> > > variables to where they're used") does take care of 2000 of them!
> > >
> > > Lee Jones (19):
> > >   drm/ttm/ttm_range_manager: Demote non-conformant kernel-doc header
> > >   drm/r128/ati_pcigart: Source file headers are not good candidates for
> > >     kernel-doc
> > >   drm/selftests/test-drm_dp_mst_helper: Move
> > >     'sideband_msg_req_encode_decode' onto the heap
> > >   drm/mga/mga_dma: Demote kernel-doc abusers to standard comment blocks
> > >   drm/mga/mga_state: Remove unused variable 'buf_priv'
> > >   drm/radeon/atom: Move prototype into shared location
> > >   drm/radeon/radeon_kms: Include header containing our own prototypes
> > >   drm/omapdrm/omap_gem: Fix misnamed and missing parameter descriptions
> > >   drm/omapdrm/omap_dmm_tiler: Demote abusive use of kernel-doc format
> > >   drm/radeon/radeon: Move prototype into shared header
> > >   drm/radeon/radeon_drv: Source file headers are not good candidates for
> > >     kernel-doc
> > >   drm/amd/display/dc/basics/fixpt31_32: Move variables to where they're
> > >     used
> > >   drm/radeon/radeon_drv: Move prototypes to a shared headerfile
> > >   drm/amd/amdgpu/amdgpu_device: Provide documentation for 'reg_addr'
> > >     params
> > >   drm/radeon: Move prototypes to shared header
> > >   drm/amd/amdgpu/amdgpu_kms: Remove 'struct drm_amdgpu_info_device
> > >     dev_info' from the stack
> > >   drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param
> > >   drm/radeon/atombios_crtc: Remove description of non-existent function
> > >     param 'encoder'
> > >   drm/v3d/v3d_drv: Remove unused static variable 'v3d_v3d_pm_ops'
> > >
> > >  drivers/gpu/drm/amd/amdgpu/amdgpu_device.c    |   2 +
> > >  drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c       | 104 +++++++++---------
> > >  .../drm/amd/display/dc/basics/fixpt31_32.c    |   5 +
> > >  .../gpu/drm/amd/display/include/fixed31_32.h  |   6 -
> > >  drivers/gpu/drm/mga/mga_dma.c                 |  10 +-
> > >  drivers/gpu/drm/mga/mga_state.c               |   2 -
> > >  drivers/gpu/drm/omapdrm/omap_dmm_tiler.c      |   6 +-
> > >  drivers/gpu/drm/omapdrm/omap_gem.c            |   3 +-
> > >  drivers/gpu/drm/r128/ati_pcigart.c            |   2 +-
> > >  drivers/gpu/drm/radeon/atom.h                 |   6 +
> > >  drivers/gpu/drm/radeon/atombios_crtc.c        |   1 -
> > >  drivers/gpu/drm/radeon/atombios_encoders.c    |   4 -
> > >  drivers/gpu/drm/radeon/radeon.h               |   6 +
> > >  drivers/gpu/drm/radeon/radeon_device.c        |   1 +
> > >  drivers/gpu/drm/radeon/radeon_device.h        |  32 ++++++
> > >  drivers/gpu/drm/radeon/radeon_display.c       |   4 -
> > >  drivers/gpu/drm/radeon/radeon_drv.c           |  11 +-
> > >  drivers/gpu/drm/radeon/radeon_drv.h           |   7 ++
> > >  drivers/gpu/drm/radeon/radeon_kms.c           |   3 +-
> > >  .../drm/selftests/test-drm_dp_mst_helper.c    |  11 +-
> > >  drivers/gpu/drm/ttm/ttm_range_manager.c       |   2 +-
> > >  drivers/gpu/drm/v3d/v3d_drv.c                 |  36 ------
> > >  22 files changed, 138 insertions(+), 126 deletions(-)
> > >  create mode 100644 drivers/gpu/drm/radeon/radeon_device.h
> >
> > Still no Radeon patches in today's -next.
> >
> > I really wanted to have had this set rebased by now.
> >
> > How long do they take to peculate through?
> 
> Usually a day or two, but I was swamped the last couple of days. I
> pushed an updated -next branch today:
> https://cgit.freedesktop.org/~agd5f/linux/log/?h=drm-next

Ah, wonderful.

I'll rebase all of the sets on Monday and see what we're left with.

-- 
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 44+ messages in thread

end of thread, other threads:[~2020-11-13 14:28 UTC | newest]

Thread overview: 44+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-06 21:49 [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Lee Jones
2020-11-06 21:49 ` [PATCH 06/19] drm/radeon/atom: Move prototype into shared location Lee Jones
2020-11-10 21:54   ` Alex Deucher
2020-11-06 21:49 ` [PATCH 07/19] drm/radeon/radeon_kms: Include header containing our own prototypes Lee Jones
2020-11-10 21:55   ` Alex Deucher
2020-11-06 21:49 ` [PATCH 10/19] drm/radeon/radeon: Move prototype into shared header Lee Jones
2020-11-07 14:26   ` Sam Ravnborg
2020-11-07 15:14     ` Lee Jones
2020-11-09 11:06     ` Lee Jones
2020-11-09 15:25       ` Sam Ravnborg
2020-11-09 16:10         ` Lee Jones
2020-11-06 21:49 ` [PATCH 11/19] drm/radeon/radeon_drv: Source file headers are not good candidates for kernel-doc Lee Jones
2020-11-10 21:56   ` Alex Deucher
2020-11-06 21:49 ` [PATCH 12/19] drm/amd/display/dc/basics/fixpt31_32: Move variables to where they're used Lee Jones
2020-11-09 19:58   ` Alex Deucher
2020-11-06 21:49 ` [PATCH 13/19] drm/radeon/radeon_drv: Move prototypes to a shared headerfile Lee Jones
2020-11-10 21:58   ` Alex Deucher
2020-11-06 21:49 ` [PATCH 14/19] drm/amd/amdgpu/amdgpu_device: Provide documentation for 'reg_addr' params Lee Jones
2020-11-09 19:54   ` Alex Deucher
2020-11-06 21:49 ` [PATCH 15/19] drm/radeon: Move prototypes to shared header Lee Jones
2020-11-10 21:59   ` Alex Deucher
2020-11-06 21:49 ` [PATCH 16/19] drm/amd/amdgpu/amdgpu_kms: Remove 'struct drm_amdgpu_info_device dev_info' from the stack Lee Jones
2020-11-09 20:05   ` Alex Deucher
2020-11-06 21:49 ` [PATCH 17/19] drm/radeon/radeon_kms: Fix misnaming of 'radeon_info_ioctl's dev param Lee Jones
2020-11-07 14:29   ` Sam Ravnborg
2020-11-07 15:13     ` Lee Jones
2020-11-09 19:50   ` Alex Deucher
2020-11-09 19:55     ` Sam Ravnborg
2020-11-09 20:06       ` Alex Deucher
2020-11-09 20:10       ` Lee Jones
2020-11-09 20:52         ` Sam Ravnborg
2020-11-09 21:15           ` Lee Jones
2020-11-09 19:59     ` Lee Jones
2020-11-06 21:49 ` [PATCH 18/19] drm/radeon/atombios_crtc: Remove description of non-existent function param 'encoder' Lee Jones
2020-11-10 22:01   ` Alex Deucher
2020-11-06 22:26 ` [PATCH 00/19] [Set 2] Rid W=1 warnings from GPU Sam Ravnborg
2020-11-07 12:18 ` Christian König
2020-11-07 15:07   ` Lee Jones
2020-11-07 17:34   ` Sam Ravnborg
2020-11-07 18:41     ` Lee Jones
2020-11-07 19:29       ` Sam Ravnborg
2020-11-13  7:19 ` Lee Jones
2020-11-13  7:28   ` Alex Deucher
2020-11-13  7:36     ` Lee Jones

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).