2008-02-08 19:19:31 +07:00
|
|
|
/* MN10300 In-kernel exception handling
|
|
|
|
*
|
|
|
|
* Copyright (C) 2007 Matsushita Electric Industrial Co., Ltd.
|
|
|
|
* Copyright (C) 2007 Red Hat, Inc. All Rights Reserved.
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU General Public Licence
|
|
|
|
* as published by the Free Software Foundation; either version
|
|
|
|
* 2 of the Licence, or (at your option) any later version.
|
|
|
|
*/
|
2016-07-24 01:01:45 +07:00
|
|
|
#include <linux/extable.h>
|
2008-02-08 19:19:31 +07:00
|
|
|
#include <linux/spinlock.h>
|
2016-12-25 02:46:01 +07:00
|
|
|
#include <linux/uaccess.h>
|
2008-02-08 19:19:31 +07:00
|
|
|
|
|
|
|
int fixup_exception(struct pt_regs *regs)
|
|
|
|
{
|
|
|
|
const struct exception_table_entry *fixup;
|
|
|
|
|
|
|
|
fixup = search_exception_tables(regs->pc);
|
|
|
|
if (fixup) {
|
|
|
|
regs->pc = fixup->fixup;
|
|
|
|
return 1;
|
|
|
|
}
|
|
|
|
|
|
|
|
return 0;
|
|
|
|
}
|