lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 25 Oct 2023 14:18:06 +0300
From:   Michal Wilczynski <michal.wilczynski@...el.com>
To:     linux-acpi@...r.kernel.org, linux-kernel@...r.kernel.org
Cc:     rafael.j.wysocki@...el.com, andriy.shevchenko@...ux.intel.com,
        lenb@...nel.org, Michal Wilczynski <michal.wilczynski@...el.com>
Subject: [PATCH v1 6/6] ACPI: acpi_video: Fix holes in acpi_video_bus

As identified by 'pahole' utility there are holes in acpi_video_bus
struct. Rearrange elements to get rid of the holes. Put elements
biggest in size first, and one-byte elements later.

Signed-off-by: Michal Wilczynski <michal.wilczynski@...el.com>
---
 drivers/acpi/acpi_video.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/acpi/acpi_video.c b/drivers/acpi/acpi_video.c
index bfc7f51a527d..1e10d5b748b2 100644
--- a/drivers/acpi/acpi_video.c
+++ b/drivers/acpi/acpi_video.c
@@ -155,19 +155,19 @@ struct acpi_video_enumerated_device {
 
 struct acpi_video_bus {
 	struct acpi_device *device;
+	struct acpi_video_enumerated_device *attached_array;
+	struct list_head video_device_list;
+	struct mutex device_list_lock;	/* protects video_device_list */
+	struct list_head entry;
+	struct input_dev *input;
+	struct notifier_block pm_nb;
 	bool backlight_registered;
 	u8 dos_setting;
-	struct acpi_video_enumerated_device *attached_array;
 	u8 attached_count;
 	u8 child_count;
 	struct acpi_video_bus_cap cap;
 	struct acpi_video_bus_flags flags;
-	struct list_head video_device_list;
-	struct mutex device_list_lock;	/* protects video_device_list */
-	struct list_head entry;
-	struct input_dev *input;
 	char phys[32];	/* for input device */
-	struct notifier_block pm_nb;
 };
 
 struct acpi_video_device_flags {
-- 
2.41.0

Powered by blists - more mailing lists