Skip to content

Commit

Permalink
parisc/power: Fix power soft-off when running on qemu
Browse files Browse the repository at this point in the history
Firmware returns the physical address of the power switch,
so need to use gsc_writel() instead of direct memory access.

Fixes: d0c2194 ("parisc/power: Add power soft-off when running on qemu")
Signed-off-by: Helge Deller <deller@gmx.de>
Cc: stable@vger.kernel.org # v6.0+
  • Loading branch information
Helge Deller committed Nov 18, 2023
1 parent 721d28f commit 6ad6e15
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/parisc/power.c
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ static struct notifier_block parisc_panic_block = {
static int qemu_power_off(struct sys_off_data *data)
{
/* this turns the system off via SeaBIOS */
*(int *)data->cb_data = 0;
gsc_writel(0, (unsigned long) data->cb_data);
pdc_soft_power_button(1);
return NOTIFY_DONE;
}
Expand Down

0 comments on commit 6ad6e15

Please sign in to comment.