Re: [PATCH v3 12/14] drm/rockchip: vop2: Add debugfs support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Sascha:

On 12/6/23 19:20, Sascha Hauer wrote:
On Wed, Dec 06, 2023 at 06:20:58PM +0800, Andy Yan wrote:
Hi Sascha:

+	unsigned int n = vop2->data->regs_dump_size;

'n' is used only once, it might be clearer just to use the value where
needed and drop the extra variable.

Okay, will do.

+	unsigned int i;
+
+	drm_modeset_lock_all(drm_dev);
+
+	if (vop2->enable_count) {
+		for (i = 0; i < n; i++) {
+			dump = &vop2->data->regs_dump[i];
+			vop2_regs_print(vop2, s, dump, false);
+		}
+	} else {
+		seq_printf(s, "VOP disabled:\n");

There's nothing following after the ':', right? Then this should be
"VOP: disabled\n" or without the colon at all.

the colon will be droped in next versin.


+	}
+	drm_modeset_unlock_all(drm_dev);

This code is repeated in vop2_active_regs_show() below. Maybe factor
this out to a common function?



Do you mean all the code between drm_modeset_lock_all and drm_modeset_unlock_all ?

Including drm_modeset_lock_all() and drm_modeset_unlock_all(), yes.


Okay, will try in v4.


Sascha




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux