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]
Message-ID: <20250616175019.3471583-5-superm1@kernel.org>
Date: Mon, 16 Jun 2025 12:50:18 -0500
From: Mario Limonciello <superm1@...nel.org>
To: "Rafael J . Wysocki" <rafael@...nel.org>,
	Alex Deucher <alexander.deucher@....com>,
	Bjorn Helgaas <bhelgaas@...gle.com>
Cc: amd-gfx@...ts.freedesktop.org (open list:RADEON and AMDGPU DRM DRIVERS),
	linux-pm@...r.kernel.org (open list:HIBERNATION (aka Software Suspend, aka swsusp)),
	linux-pci@...r.kernel.org (open list:PCI SUBSYSTEM),
	linux-kernel@...r.kernel.org (open list),
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Danilo Krummrich <dakr@...nel.org>,
	"James E . J . Bottomley" <James.Bottomley@...senPartnership.com>,
	"Martin K . Petersen" <martin.petersen@...cle.com>,
	dri-devel@...ts.freedesktop.org (open list:DRM DRIVERS),
	linux-scsi@...r.kernel.org (open list:SCSI SUBSYSTEM),
	linux-usb@...r.kernel.org (open list:USB SUBSYSTEM),
	Mario Limonciello <mario.limonciello@....com>
Subject: [PATCH v4 4/5] scsi: Add PM_EVENT_POWEROFF into suspend callbacks

From: Mario Limonciello <mario.limonciello@....com>

When the ACPI core uses hibernation callbacks for shutdown drivers
will receive PM_EVENT_POWEROFF and should handle it the same as
PM_EVENT_HIBERNATE would have been used.

Signed-off-by: Mario Limonciello <mario.limonciello@....com>
---
v3:
 * New patch
 * https://lore.kernel.org/linux-pm/20250609024619.407257-1-superm1@kernel.org/T/#me6db0fb946e3d604a8f3d455128844ed802c82bb
---
 drivers/scsi/mesh.c | 1 +
 drivers/scsi/stex.c | 1 +
 2 files changed, 2 insertions(+)

diff --git a/drivers/scsi/mesh.c b/drivers/scsi/mesh.c
index 1c15cac41d805..768b85eecc8fd 100644
--- a/drivers/scsi/mesh.c
+++ b/drivers/scsi/mesh.c
@@ -1762,6 +1762,7 @@ static int mesh_suspend(struct macio_dev *mdev, pm_message_t mesg)
 	case PM_EVENT_SUSPEND:
 	case PM_EVENT_HIBERNATE:
 	case PM_EVENT_FREEZE:
+	case PM_EVENT_POWEROFF:
 		break;
 	default:
 		return 0;
diff --git a/drivers/scsi/stex.c b/drivers/scsi/stex.c
index 63ed7f9aaa937..ee9372e1f7f07 100644
--- a/drivers/scsi/stex.c
+++ b/drivers/scsi/stex.c
@@ -1965,6 +1965,7 @@ static int stex_choice_sleep_mic(struct st_hba *hba, pm_message_t state)
 	case PM_EVENT_SUSPEND:
 		return ST_S3;
 	case PM_EVENT_HIBERNATE:
+	case PM_EVENT_POWEROFF:
 		hba->msi_lock = 0;
 		return ST_S4;
 	default:
-- 
2.43.0


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ