From: Siddh Raman Pant <code@siddh.me>
To: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
Maxime Ripard <mripard@kernel.org>,
Thomas Zimmermann <tzimmermann@suse.de>,
David Airlie <airlied@gmail.com>, Daniel Vetter <daniel@ffwll.ch>,
Andrzej Hajda <andrzej.hajda@intel.com>,
Neil Armstrong <neil.armstrong@linaro.org>,
Robert Foss <rfoss@kernel.org>,
Laurent Pinchart <Laurent.pinchart@ideasonboard.com>,
Jonas Karlman <jonas@kwiboo.se>,
Jernej Skrabec <jernej.skrabec@gmail.com>,
Jani Nikula <jani.nikula@linux.intel.com>,
Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org,
Suraj Upadhyay <usuraj35@gmail.com>
Subject: [PATCH v10 9/9] drm: Remove superfluous print statements in DRM core
Date: Wed, 7 Jun 2023 00:00:10 +0530 [thread overview]
Message-ID: <35def11d3722b361bc394c3d297adea922db5fd9.1686075579.git.code@siddh.me> (raw)
In-Reply-To: <cover.1686075579.git.code@siddh.me>
There are a couple of superfluous print statements using the drm_*
macros, which do stuff like printing newlines, print OOM messages
(OOM while allocating memory is already supposed to be noisy), and
printing strings like "Initialised" with no extra info whatsoever.
Thus, remove a couple of these superfluous strings.
Suggested-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Siddh Raman Pant <code@siddh.me>
---
drivers/gpu/drm/drm_client_modeset.c | 3 ---
drivers/gpu/drm/drm_context.c | 1 -
drivers/gpu/drm/drm_crtc_helper.c | 2 --
drivers/gpu/drm/drm_drv.c | 7 -------
drivers/gpu/drm/drm_file.c | 2 --
drivers/gpu/drm/drm_gem.c | 1 -
drivers/gpu/drm/drm_hashtab.c | 1 -
drivers/gpu/drm/drm_legacy_misc.c | 1 -
drivers/gpu/drm/drm_mipi_dbi.c | 2 --
drivers/gpu/drm/drm_pci.c | 6 ------
drivers/gpu/drm/drm_scatter.c | 2 --
11 files changed, 28 deletions(-)
diff --git a/drivers/gpu/drm/drm_client_modeset.c b/drivers/gpu/drm/drm_client_modeset.c
index 4e08ae688b83..e241f9aa5a16 100644
--- a/drivers/gpu/drm/drm_client_modeset.c
+++ b/drivers/gpu/drm/drm_client_modeset.c
@@ -793,8 +793,6 @@ int drm_client_modeset_probe(struct drm_client_dev *client, unsigned int width,
int i, ret = 0;
bool *enabled;
- drm_dbg_kms(dev, "\n");
-
if (!width)
width = dev->mode_config.max_width;
if (!height)
@@ -824,7 +822,6 @@ int drm_client_modeset_probe(struct drm_client_dev *client, unsigned int width,
offsets = kcalloc(connector_count, sizeof(*offsets), GFP_KERNEL);
enabled = kcalloc(connector_count, sizeof(bool), GFP_KERNEL);
if (!crtcs || !modes || !enabled || !offsets) {
- drm_err(client->dev, "Memory allocation failed\n");
ret = -ENOMEM;
goto out;
}
diff --git a/drivers/gpu/drm/drm_context.c b/drivers/gpu/drm/drm_context.c
index 8b7b925aee97..c8373294cce0 100644
--- a/drivers/gpu/drm/drm_context.c
+++ b/drivers/gpu/drm/drm_context.c
@@ -382,7 +382,6 @@ int drm_legacy_addctx(struct drm_device *dev, void *data,
ctx_entry = kmalloc(sizeof(*ctx_entry), GFP_KERNEL);
if (!ctx_entry) {
- drm_dbg_core(dev, "out of memory\n");
return -ENOMEM;
}
diff --git a/drivers/gpu/drm/drm_crtc_helper.c b/drivers/gpu/drm/drm_crtc_helper.c
index 59e7b86eab93..fcf539439880 100644
--- a/drivers/gpu/drm/drm_crtc_helper.c
+++ b/drivers/gpu/drm/drm_crtc_helper.c
@@ -567,8 +567,6 @@ int drm_crtc_helper_set_config(struct drm_mode_set *set,
int ret;
int i;
- drm_dbg_kms(NULL, "\n");
-
BUG_ON(!set);
BUG_ON(!set->crtc);
BUG_ON(!set->crtc->helper_private);
diff --git a/drivers/gpu/drm/drm_drv.c b/drivers/gpu/drm/drm_drv.c
index 7adf10cc6e67..86b0df358184 100644
--- a/drivers/gpu/drm/drm_drv.c
+++ b/drivers/gpu/drm/drm_drv.c
@@ -166,8 +166,6 @@ static int drm_minor_register(struct drm_device *dev, unsigned int type)
unsigned long flags;
int ret;
- drm_dbg_core(dev, "\n");
-
minor = *drm_minor_get_slot(dev, type);
if (!minor)
return 0;
@@ -422,8 +420,6 @@ void drm_minor_release(struct drm_minor *minor)
*/
void drm_put_dev(struct drm_device *dev)
{
- drm_dbg_core(NULL, "\n");
-
if (!dev) {
drm_err(NULL, "cleanup called no dev\n");
return;
@@ -1030,8 +1026,6 @@ static int drm_stub_open(struct inode *inode, struct file *filp)
struct drm_minor *minor;
int err;
- drm_dbg_core(NULL, "\n");
-
minor = drm_minor_acquire(iminor(inode));
if (IS_ERR(minor))
return PTR_ERR(minor);
@@ -1099,7 +1093,6 @@ static int __init drm_core_init(void)
drm_core_init_complete = true;
- drm_dbg_core(NULL, "Initialized\n");
return 0;
error:
diff --git a/drivers/gpu/drm/drm_file.c b/drivers/gpu/drm/drm_file.c
index 883d83bc0e3d..24c78f7ec101 100644
--- a/drivers/gpu/drm/drm_file.c
+++ b/drivers/gpu/drm/drm_file.c
@@ -454,8 +454,6 @@ EXPORT_SYMBOL(drm_open);
void drm_lastclose(struct drm_device * dev)
{
- drm_dbg_core(dev, "\n");
-
if (dev->driver->lastclose)
dev->driver->lastclose(dev);
drm_dbg_core(dev, "driver lastclose completed\n");
diff --git a/drivers/gpu/drm/drm_gem.c b/drivers/gpu/drm/drm_gem.c
index 3d88f0483fdf..43326cb4b4f6 100644
--- a/drivers/gpu/drm/drm_gem.c
+++ b/drivers/gpu/drm/drm_gem.c
@@ -101,7 +101,6 @@ drm_gem_init(struct drm_device *dev)
vma_offset_manager = drmm_kzalloc(dev, sizeof(*vma_offset_manager),
GFP_KERNEL);
if (!vma_offset_manager) {
- drm_err(dev, "out of memory\n");
return -ENOMEM;
}
diff --git a/drivers/gpu/drm/drm_hashtab.c b/drivers/gpu/drm/drm_hashtab.c
index 357f20d73b43..acc40d3ebb2a 100644
--- a/drivers/gpu/drm/drm_hashtab.c
+++ b/drivers/gpu/drm/drm_hashtab.c
@@ -53,7 +53,6 @@ int drm_ht_create(struct drm_open_hash *ht, unsigned int order)
else
ht->table = vzalloc(array_size(size, sizeof(*ht->table)));
if (!ht->table) {
- drm_err(NULL, "Out of memory for hash table\n");
return -ENOMEM;
}
return 0;
diff --git a/drivers/gpu/drm/drm_legacy_misc.c b/drivers/gpu/drm/drm_legacy_misc.c
index ad0eef292cb0..69a51f5150e3 100644
--- a/drivers/gpu/drm/drm_legacy_misc.c
+++ b/drivers/gpu/drm/drm_legacy_misc.c
@@ -70,7 +70,6 @@ int drm_legacy_setup(struct drm_device * dev)
return ret;
- drm_dbg_core(dev, "\n");
return 0;
}
diff --git a/drivers/gpu/drm/drm_mipi_dbi.c b/drivers/gpu/drm/drm_mipi_dbi.c
index 793fdd7da1d0..286cfafd022e 100644
--- a/drivers/gpu/drm/drm_mipi_dbi.c
+++ b/drivers/gpu/drm/drm_mipi_dbi.c
@@ -409,8 +409,6 @@ void mipi_dbi_pipe_disable(struct drm_simple_display_pipe *pipe)
{
struct mipi_dbi_dev *dbidev = drm_to_mipi_dbi_dev(pipe->crtc.dev);
- drm_dbg_kms(&dbidev->drm, "\n");
-
if (dbidev->backlight)
backlight_disable(dbidev->backlight);
else
diff --git a/drivers/gpu/drm/drm_pci.c b/drivers/gpu/drm/drm_pci.c
index 485ec407a115..5cdfcd38174e 100644
--- a/drivers/gpu/drm/drm_pci.c
+++ b/drivers/gpu/drm/drm_pci.c
@@ -155,8 +155,6 @@ static int drm_legacy_get_pci_dev(struct pci_dev *pdev,
if (IS_ERR(dev))
return PTR_ERR(dev);
- drm_dbg_core(dev, "\n");
-
ret = pci_enable_device(pdev);
if (ret)
goto err_free;
@@ -203,8 +201,6 @@ int drm_legacy_pci_init(const struct drm_driver *driver,
const struct pci_device_id *pid;
int i;
- drm_dbg_core(NULL, "\n");
-
if (WARN_ON(!(driver->driver_features & DRIVER_LEGACY)))
return -EINVAL;
@@ -247,8 +243,6 @@ void drm_legacy_pci_exit(const struct drm_driver *driver,
{
struct drm_device *dev, *tmp;
- drm_dbg_core(NULL, "\n");
-
if (!(driver->driver_features & DRIVER_LEGACY)) {
WARN_ON(1);
} else {
diff --git a/drivers/gpu/drm/drm_scatter.c b/drivers/gpu/drm/drm_scatter.c
index 08b3eb586484..59f755bf6ce9 100644
--- a/drivers/gpu/drm/drm_scatter.c
+++ b/drivers/gpu/drm/drm_scatter.c
@@ -82,8 +82,6 @@ int drm_legacy_sg_alloc(struct drm_device *dev, void *data,
struct drm_sg_mem *entry;
unsigned long pages, i, j;
- drm_dbg_core(dev, "\n");
-
if (!drm_core_check_feature(dev, DRIVER_LEGACY))
return -EOPNOTSUPP;
--
2.39.2
next prev parent reply other threads:[~2023-06-07 8:46 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-06 18:30 [PATCH v10 0/9] drm: Remove usage of deprecated DRM_* macros in DRM core Siddh Raman Pant
2023-06-06 18:30 ` [PATCH v10 1/9] Revert "drm: mipi-dsi: Convert logging to drm_* functions." Siddh Raman Pant
2023-06-06 18:30 ` [PATCH v10 2/9] drm/print: Fix and add support for NULL as first argument in drm_* macros Siddh Raman Pant
2023-06-06 18:30 ` [PATCH v10 3/9] drm: Remove usage of deprecated DRM_INFO in DRM core Siddh Raman Pant
2023-06-06 18:30 ` [PATCH v10 4/9] drm: Remove usage of deprecated DRM_NOTE " Siddh Raman Pant
2023-06-06 18:30 ` [PATCH v10 5/9] drm: Remove usage of deprecated DRM_ERROR " Siddh Raman Pant
2023-06-06 18:30 ` [PATCH v10 6/9] drm: Remove usage of deprecated DRM_DEBUG " Siddh Raman Pant
2023-06-06 18:30 ` [PATCH v10 7/9] drm: Remove usage of deprecated DRM_DEBUG_DRIVER " Siddh Raman Pant
2023-06-06 18:30 ` [PATCH v10 8/9] drm: Remove usage of deprecated DRM_DEBUG_KMS " Siddh Raman Pant
2023-06-06 18:30 ` Siddh Raman Pant [this message]
2023-06-09 13:12 ` [PATCH v10 9/9] drm: Remove superfluous print statements " Siddh Raman Pant
2023-07-10 4:51 ` [PATCH v10 0/9] drm: Remove usage of deprecated DRM_* macros " Siddh Raman Pant
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=35def11d3722b361bc394c3d297adea922db5fd9.1686075579.git.code@siddh.me \
--to=code@siddh.me \
--cc=Laurent.pinchart@ideasonboard.com \
--cc=airlied@gmail.com \
--cc=andrzej.hajda@intel.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=jani.nikula@linux.intel.com \
--cc=jernej.skrabec@gmail.com \
--cc=jonas@kwiboo.se \
--cc=linux-kernel@vger.kernel.org \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mripard@kernel.org \
--cc=neil.armstrong@linaro.org \
--cc=rfoss@kernel.org \
--cc=tzimmermann@suse.de \
--cc=usuraj35@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).