The Linux Kernel Mailing List
 help / color / mirror / Atom feed
* [PATCH 0/4] ACPI: video: checkpatch cleanups
@ 2026-05-10  2:47 Jean-Ralph Aviles
  2026-05-10  2:47 ` [PATCH 1/4] ACPI: video: Do not initialise device_id_scheme Jean-Ralph Aviles
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Jean-Ralph Aviles @ 2026-05-10  2:47 UTC (permalink / raw)
  To: rafael, lenb; +Cc: linux-acpi, linux-kernel, jeanralph.aviles

Fix numerous checkpatch errors in acpi/acpi_video.c.

Note: First kernel submission. I'm not sure if a 4 patch series is
appropriate, but this is how I would approach it.

Jean-Ralph Aviles (4):
  ACPI: video: Do not initialise device_id_scheme
  ACPI: video: Fix block comment warnings
  ACPI: video: Fix quoted strings split across lines
  ACPI: video: Add blank line after declaration

 drivers/acpi/acpi_video.c | 20 +++++++-------------
 1 file changed, 7 insertions(+), 13 deletions(-)

-- 
2.51.2


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

* [PATCH 1/4] ACPI: video: Do not initialise device_id_scheme
  2026-05-10  2:47 [PATCH 0/4] ACPI: video: checkpatch cleanups Jean-Ralph Aviles
@ 2026-05-10  2:47 ` Jean-Ralph Aviles
  2026-05-10  2:47 ` [PATCH 2/4] ACPI: video: Fix block comment warnings Jean-Ralph Aviles
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: Jean-Ralph Aviles @ 2026-05-10  2:47 UTC (permalink / raw)
  To: rafael, lenb; +Cc: linux-acpi, linux-kernel, jeanralph.aviles

Reported by checkpatch:

ERROR: do not initialise statics to false
Signed-off-by: Jean-Ralph Aviles <jeanralph.aviles@gmail.com>
---
 drivers/acpi/acpi_video.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/acpi/acpi_video.c b/drivers/acpi/acpi_video.c
index 05793ddef787..e8880a2113cb 100644
--- a/drivers/acpi/acpi_video.c
+++ b/drivers/acpi/acpi_video.c
@@ -63,7 +63,7 @@ MODULE_PARM_DESC(hw_changes_brightness,
  * Whether the struct acpi_video_device_attrib::device_id_scheme bit should be
  * assumed even if not actually set.
  */
-static bool device_id_scheme = false;
+static bool device_id_scheme;
 module_param(device_id_scheme, bool, 0444);
 
 static int only_lcd;
-- 
2.51.2


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

* [PATCH 2/4] ACPI: video: Fix block comment warnings
  2026-05-10  2:47 [PATCH 0/4] ACPI: video: checkpatch cleanups Jean-Ralph Aviles
  2026-05-10  2:47 ` [PATCH 1/4] ACPI: video: Do not initialise device_id_scheme Jean-Ralph Aviles
@ 2026-05-10  2:47 ` Jean-Ralph Aviles
  2026-05-10  2:47 ` [PATCH 3/4] ACPI: video: Fix quoted strings split across lines Jean-Ralph Aviles
  2026-05-10  2:47 ` [PATCH 4/4] ACPI: video: Add blank line after declaration Jean-Ralph Aviles
  3 siblings, 0 replies; 5+ messages in thread
From: Jean-Ralph Aviles @ 2026-05-10  2:47 UTC (permalink / raw)
  To: rafael, lenb; +Cc: linux-acpi, linux-kernel, jeanralph.aviles

Reported by checkpatch:

WARNING: Block comments use a trailing */ on a separate line
Signed-off-by: Jean-Ralph Aviles <jeanralph.aviles@gmail.com>
---
 drivers/acpi/acpi_video.c | 9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)

diff --git a/drivers/acpi/acpi_video.c b/drivers/acpi/acpi_video.c
index e8880a2113cb..fc45f0ecf7cf 100644
--- a/drivers/acpi/acpi_video.c
+++ b/drivers/acpi/acpi_video.c
@@ -126,8 +126,7 @@ struct acpi_video_device_attrib {
 	u32 display_type:4;	/* Describe the specific type in use */
 	u32 vendor_specific:4;	/* Chipset Vendor Specific */
 	u32 bios_can_detect:1;	/* BIOS can detect the device */
-	u32 depend_on_vga:1;	/* Non-VGA output device whose power is related to
-				   the VGA device. */
+	u32 depend_on_vga:1;	/* Non-VGA output device whose power is related to the VGA device */
 	u32 pipe_id:3;		/* For VGA multiple-head devices. */
 	u32 reserved:10;	/* Must be 0 */
 
@@ -1536,13 +1535,11 @@ static void acpi_video_bus_notify(acpi_handle handle, u32 event, void *data)
 	input = video->input;
 
 	switch (event) {
-	case ACPI_VIDEO_NOTIFY_SWITCH:	/* User requested a switch,
-					 * most likely via hotkey. */
+	case ACPI_VIDEO_NOTIFY_SWITCH:	/* User requested a switch, most likely via hotkey. */
 		keycode = KEY_SWITCHVIDEOMODE;
 		break;
 
-	case ACPI_VIDEO_NOTIFY_PROBE:	/* User plugged in or removed a video
-					 * connector. */
+	case ACPI_VIDEO_NOTIFY_PROBE:	/* User plugged in or removed a video connector. */
 		acpi_video_device_enumerate(video);
 		acpi_video_device_rebind(video);
 		keycode = KEY_SWITCHVIDEOMODE;
-- 
2.51.2


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

* [PATCH 3/4] ACPI: video: Fix quoted strings split across lines
  2026-05-10  2:47 [PATCH 0/4] ACPI: video: checkpatch cleanups Jean-Ralph Aviles
  2026-05-10  2:47 ` [PATCH 1/4] ACPI: video: Do not initialise device_id_scheme Jean-Ralph Aviles
  2026-05-10  2:47 ` [PATCH 2/4] ACPI: video: Fix block comment warnings Jean-Ralph Aviles
@ 2026-05-10  2:47 ` Jean-Ralph Aviles
  2026-05-10  2:47 ` [PATCH 4/4] ACPI: video: Add blank line after declaration Jean-Ralph Aviles
  3 siblings, 0 replies; 5+ messages in thread
From: Jean-Ralph Aviles @ 2026-05-10  2:47 UTC (permalink / raw)
  To: rafael, lenb; +Cc: linux-acpi, linux-kernel, jeanralph.aviles

Reported by checkpatch:

WARNING: quoted string split across lines
Signed-off-by: Jean-Ralph Aviles <jeanralph.aviles@gmail.com>
---
 drivers/acpi/acpi_video.c | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/drivers/acpi/acpi_video.c b/drivers/acpi/acpi_video.c
index fc45f0ecf7cf..4fec8d817812 100644
--- a/drivers/acpi/acpi_video.c
+++ b/drivers/acpi/acpi_video.c
@@ -56,8 +56,7 @@ MODULE_PARM_DESC(report_key_events,
 static int hw_changes_brightness = -1;
 module_param(hw_changes_brightness, int, 0644);
 MODULE_PARM_DESC(hw_changes_brightness,
-	"Set this to 1 on buggy hw which changes the brightness itself when "
-	"a hotkey is pressed: -1: auto, 0: normal 1: hw-changes-brightness");
+	"Set this to 1 on buggy hw which changes the brightness itself when a hotkey is pressed: -1: auto, 0: normal 1: hw-changes-brightness");
 
 /*
  * Whether the struct acpi_video_device_attrib::device_id_scheme bit should be
@@ -1987,10 +1986,7 @@ static int acpi_video_bus_probe(struct auxiliary_device *aux_dev,
 
 	if (!allow_duplicates && acpi_video_bus_dev_is_duplicate(&aux_dev->dev)) {
 		pr_info(FW_BUG
-			"Duplicate ACPI video bus devices for the"
-			" same VGA controller, please try module "
-			"parameter \"video.allow_duplicates=1\""
-			"if the current driver doesn't work.\n");
+			"Duplicate ACPI video bus devices for the same VGA controller, please try module parameter \"video.allow_duplicates=1\" if the current driver doesn't work.\n");
 		return -ENODEV;
 	}
 
-- 
2.51.2


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

* [PATCH 4/4] ACPI: video: Add blank line after declaration
  2026-05-10  2:47 [PATCH 0/4] ACPI: video: checkpatch cleanups Jean-Ralph Aviles
                   ` (2 preceding siblings ...)
  2026-05-10  2:47 ` [PATCH 3/4] ACPI: video: Fix quoted strings split across lines Jean-Ralph Aviles
@ 2026-05-10  2:47 ` Jean-Ralph Aviles
  3 siblings, 0 replies; 5+ messages in thread
From: Jean-Ralph Aviles @ 2026-05-10  2:47 UTC (permalink / raw)
  To: rafael, lenb; +Cc: linux-acpi, linux-kernel, jeanralph.aviles

Reported by checkpatch:

WARNING: Missing a blank line after declarations
Signed-off-by: Jean-Ralph Aviles <jeanralph.aviles@gmail.com>
---
 drivers/acpi/acpi_video.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/acpi/acpi_video.c b/drivers/acpi/acpi_video.c
index 4fec8d817812..39a1c25fd840 100644
--- a/drivers/acpi/acpi_video.c
+++ b/drivers/acpi/acpi_video.c
@@ -1361,6 +1361,7 @@ acpi_video_get_next_level(struct acpi_video_device *device,
 			  u32 level_current, u32 event)
 {
 	int min, max, min_above, max_below, i, l, delta = 255;
+
 	max = max_below = 0;
 	min = min_above = 255;
 	/* Find closest level to level_current */
-- 
2.51.2


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

end of thread, other threads:[~2026-05-10  2:48 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-05-10  2:47 [PATCH 0/4] ACPI: video: checkpatch cleanups Jean-Ralph Aviles
2026-05-10  2:47 ` [PATCH 1/4] ACPI: video: Do not initialise device_id_scheme Jean-Ralph Aviles
2026-05-10  2:47 ` [PATCH 2/4] ACPI: video: Fix block comment warnings Jean-Ralph Aviles
2026-05-10  2:47 ` [PATCH 3/4] ACPI: video: Fix quoted strings split across lines Jean-Ralph Aviles
2026-05-10  2:47 ` [PATCH 4/4] ACPI: video: Add blank line after declaration Jean-Ralph Aviles

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox