Xtensa updates for v7.1
- use register_sys_off_handler(SYS_OFF_MODE_RESTART) instead of the deprecated register_restart_handler() - drop custom ucontext.h and reuse asm-generic ucontext.h -----BEGIN PGP SIGNATURE----- iQJHBAABCgAxFiEEK2eFS5jlMn3N6xfYUfnMkfg/oEQFAmnpMOUTHGpjbXZia2Jj QGdtYWlsLmNvbQAKCRBR+cyR+D+gRNzcD/4mlomyRBUrEFIopXLtm931NJa3txfo tt/u1/d5PZMtHHeS3sEZMdSMBcwsn5J/V2TlxjuKVvaQMxZRQavYwETxJoQXkhbj VTsNdSRAAFWTluIwM7V+4r9rYjGPhfu2Y4ePt0egOF5zpvdKQ8N5wNRETKoOjXIN dr3FYcYai5O2BS05T57zIB3OF9AxV0j0Bd767K0N4OSkT1O993qYZfYiKzgg4nhB ZvJWlXsSUbw/Ik8Pj30PagcaCcXpACXkpuJJM6O5K1boT0ptDT7PYQDTa7ZrBy6o TkTijlgrIWW6HFVcJRcGjXKn3UmRmoHulNTDnyRKNFrSWXs2k7aX/nGv1lGCk2oQ jfgqcQ5XCVZPhLcJ6Ec44okEHT13Ds3uGTj1H9u0bWePRzlg/n7DVBMW0bF6Emqi K/47Z5Domp5FUsOMY9lX5/vKj+cueR87erX25dPJv3Dxk42sZa96CObvswjZvpNk DcjgXuWgiqrQblYHV/vAHbjsrg5+AL0oDxCA2sAx0cEorCIYxFXM0IVwHwnX+G7H Vc9xEWJuayahJ5M9F5tXeMMm/uaPi53VPjPjKuRMLec2Jqup27OU+9EsuVDnaMCI +t8DXoKtesuk/IaPWVsbgApD+ry/aENNGcMC1h4iqG+paY12tcyFHFm8eLqq2qu7 RCRWK7td1Kx5+w== =phOc -----END PGP SIGNATURE----- Merge tag 'xtensa-20260422' of https://github.com/jcmvbkbc/linux-xtensa Pull Xtensa updates from Max Filippov: - use register_sys_off_handler(SYS_OFF_MODE_RESTART) instead of the deprecated register_restart_handler() - drop custom ucontext.h and reuse asm-generic ucontext.h * tag 'xtensa-20260422' of https://github.com/jcmvbkbc/linux-xtensa: xtensa: uapi: Reuse asm-generic ucontext.h xtensa: xtfpga: Use register_sys_off_handler(SYS_OFF_MODE_RESTART) xtensa: xt2000: Use register_sys_off_handler(SYS_OFF_MODE_RESTART) xtensa: ISS: Use register_sys_off_handler(SYS_OFF_MODE_RESTART)master
commit
5fb4fde3b2
|
|
@ -1,22 +0,0 @@
|
|||
/*
|
||||
* include/asm-xtensa/ucontext.h
|
||||
*
|
||||
* This file is subject to the terms and conditions of the GNU General Public
|
||||
* License. See the file "COPYING" in the main directory of this archive
|
||||
* for more details.
|
||||
*
|
||||
* Copyright (C) 2001 - 2005 Tensilica Inc.
|
||||
*/
|
||||
|
||||
#ifndef _XTENSA_UCONTEXT_H
|
||||
#define _XTENSA_UCONTEXT_H
|
||||
|
||||
struct ucontext {
|
||||
unsigned long uc_flags;
|
||||
struct ucontext *uc_link;
|
||||
stack_t uc_stack;
|
||||
struct sigcontext uc_mcontext;
|
||||
sigset_t uc_sigmask; /* mask last for extensibility */
|
||||
};
|
||||
|
||||
#endif /* _XTENSA_UCONTEXT_H */
|
||||
|
|
@ -1,2 +1,3 @@
|
|||
# SPDX-License-Identifier: GPL-2.0
|
||||
generated-y += unistd_32.h
|
||||
generic-y += ucontext.h
|
||||
|
|
|
|||
|
|
@ -32,8 +32,7 @@ static int iss_power_off(struct sys_off_data *unused)
|
|||
return NOTIFY_DONE;
|
||||
}
|
||||
|
||||
static int iss_restart(struct notifier_block *this,
|
||||
unsigned long event, void *ptr)
|
||||
static int iss_restart(struct sys_off_data *unused)
|
||||
{
|
||||
/* Flush and reset the mmu, simulate a processor reset, and
|
||||
* jump to the reset vector. */
|
||||
|
|
@ -42,10 +41,6 @@ static int iss_restart(struct notifier_block *this,
|
|||
return NOTIFY_DONE;
|
||||
}
|
||||
|
||||
static struct notifier_block iss_restart_block = {
|
||||
.notifier_call = iss_restart,
|
||||
};
|
||||
|
||||
static int
|
||||
iss_panic_event(struct notifier_block *this, unsigned long event, void *ptr)
|
||||
{
|
||||
|
|
@ -84,7 +79,9 @@ void __init platform_setup(char **p_cmdline)
|
|||
}
|
||||
|
||||
atomic_notifier_chain_register(&panic_notifier_list, &iss_panic_block);
|
||||
register_restart_handler(&iss_restart_block);
|
||||
register_sys_off_handler(SYS_OFF_MODE_RESTART,
|
||||
SYS_OFF_PRIO_PLATFORM,
|
||||
iss_restart, NULL);
|
||||
register_sys_off_handler(SYS_OFF_MODE_POWER_OFF,
|
||||
SYS_OFF_PRIO_PLATFORM,
|
||||
iss_power_off, NULL);
|
||||
|
|
|
|||
|
|
@ -50,8 +50,7 @@ static int xt2000_power_off(struct sys_off_data *unused)
|
|||
return NOTIFY_DONE;
|
||||
}
|
||||
|
||||
static int xt2000_restart(struct notifier_block *this,
|
||||
unsigned long event, void *ptr)
|
||||
static int xt2000_restart(struct sys_off_data *unused)
|
||||
{
|
||||
/* Flush and reset the mmu, simulate a processor reset, and
|
||||
* jump to the reset vector. */
|
||||
|
|
@ -60,10 +59,6 @@ static int xt2000_restart(struct notifier_block *this,
|
|||
return NOTIFY_DONE;
|
||||
}
|
||||
|
||||
static struct notifier_block xt2000_restart_block = {
|
||||
.notifier_call = xt2000_restart,
|
||||
};
|
||||
|
||||
void __init platform_setup(char** cmdline)
|
||||
{
|
||||
led_print (0, "LINUX ");
|
||||
|
|
@ -140,7 +135,9 @@ static int __init xt2000_setup_devinit(void)
|
|||
platform_device_register(&xt2000_serial8250_device);
|
||||
platform_device_register(&xt2000_sonic_device);
|
||||
mod_timer(&heartbeat_timer, jiffies + HZ / 2);
|
||||
register_restart_handler(&xt2000_restart_block);
|
||||
register_sys_off_handler(SYS_OFF_MODE_RESTART,
|
||||
SYS_OFF_PRIO_PLATFORM,
|
||||
xt2000_restart, NULL);
|
||||
register_sys_off_handler(SYS_OFF_MODE_POWER_OFF,
|
||||
SYS_OFF_PRIO_DEFAULT,
|
||||
xt2000_power_off, NULL);
|
||||
|
|
|
|||
|
|
@ -42,8 +42,7 @@ static int xtfpga_power_off(struct sys_off_data *unused)
|
|||
return NOTIFY_DONE;
|
||||
}
|
||||
|
||||
static int xtfpga_restart(struct notifier_block *this,
|
||||
unsigned long event, void *ptr)
|
||||
static int xtfpga_restart(struct sys_off_data *unused)
|
||||
{
|
||||
/* Try software reset first. */
|
||||
WRITE_ONCE(*(u32 *)XTFPGA_SWRST_VADDR, 0xdead);
|
||||
|
|
@ -56,10 +55,6 @@ static int xtfpga_restart(struct notifier_block *this,
|
|||
return NOTIFY_DONE;
|
||||
}
|
||||
|
||||
static struct notifier_block xtfpga_restart_block = {
|
||||
.notifier_call = xtfpga_restart,
|
||||
};
|
||||
|
||||
#ifdef CONFIG_XTENSA_CALIBRATE_CCOUNT
|
||||
|
||||
void __init platform_calibrate_ccount(void)
|
||||
|
|
@ -71,7 +66,9 @@ void __init platform_calibrate_ccount(void)
|
|||
|
||||
static void __init xtfpga_register_handlers(void)
|
||||
{
|
||||
register_restart_handler(&xtfpga_restart_block);
|
||||
register_sys_off_handler(SYS_OFF_MODE_RESTART,
|
||||
SYS_OFF_PRIO_PLATFORM,
|
||||
xtfpga_restart, NULL);
|
||||
register_sys_off_handler(SYS_OFF_MODE_POWER_OFF,
|
||||
SYS_OFF_PRIO_DEFAULT,
|
||||
xtfpga_power_off, NULL);
|
||||
|
|
|
|||
Loading…
Reference in New Issue