Commit a57d985e authored by Linus Torvalds's avatar Linus Torvalds

Merge tag 'please-pull-ia64-for-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux

Pull ia64 update from Tony Luck:
 "Usual mish-mash of ia64 fixes for next merge window"

* tag 'please-pull-ia64-for-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux:
  [IA64] xen: Fix return value check in xencomm_vtop()
  [IA64] Must enable interrupts in do_notify_resume_user before calling tracehook_notify_resume()
  [IA64] kexec: Move the dereference below the NULL test
  [IA64] Fix a node distance bug
parents cdeb9b01 39c9a4ab
...@@ -59,7 +59,7 @@ extern struct node_cpuid_s node_cpuid[NR_CPUS]; ...@@ -59,7 +59,7 @@ extern struct node_cpuid_s node_cpuid[NR_CPUS];
*/ */
extern u8 numa_slit[MAX_NUMNODES * MAX_NUMNODES]; extern u8 numa_slit[MAX_NUMNODES * MAX_NUMNODES];
#define node_distance(from,to) (numa_slit[(from) * num_online_nodes() + (to)]) #define node_distance(from,to) (numa_slit[(from) * MAX_NUMNODES + (to)])
extern int paddr_to_nid(unsigned long paddr); extern int paddr_to_nid(unsigned long paddr);
......
...@@ -85,12 +85,13 @@ static void ia64_machine_kexec(struct unw_frame_info *info, void *arg) ...@@ -85,12 +85,13 @@ static void ia64_machine_kexec(struct unw_frame_info *info, void *arg)
struct kimage *image = arg; struct kimage *image = arg;
relocate_new_kernel_t rnk; relocate_new_kernel_t rnk;
void *pal_addr = efi_get_pal_addr(); void *pal_addr = efi_get_pal_addr();
unsigned long code_addr = (unsigned long)page_address(image->control_code_page); unsigned long code_addr;
int ii; int ii;
u64 fp, gp; u64 fp, gp;
ia64_fptr_t *init_handler = (ia64_fptr_t *)ia64_os_init_on_kdump; ia64_fptr_t *init_handler = (ia64_fptr_t *)ia64_os_init_on_kdump;
BUG_ON(!image); BUG_ON(!image);
code_addr = (unsigned long)page_address(image->control_code_page);
if (image->type == KEXEC_TYPE_CRASH) { if (image->type == KEXEC_TYPE_CRASH) {
crash_save_this_cpu(); crash_save_this_cpu();
current->thread.ksp = (__u64)info->sw - 16; current->thread.ksp = (__u64)info->sw - 16;
......
...@@ -197,8 +197,8 @@ do_notify_resume_user(sigset_t *unused, struct sigscratch *scr, long in_syscall) ...@@ -197,8 +197,8 @@ do_notify_resume_user(sigset_t *unused, struct sigscratch *scr, long in_syscall)
ia64_do_signal(scr, in_syscall); ia64_do_signal(scr, in_syscall);
} }
if (test_thread_flag(TIF_NOTIFY_RESUME)) { if (test_and_clear_thread_flag(TIF_NOTIFY_RESUME)) {
clear_thread_flag(TIF_NOTIFY_RESUME); local_irq_enable(); /* force interrupt enable */
tracehook_notify_resume(&scr->pt); tracehook_notify_resume(&scr->pt);
} }
......
...@@ -17,6 +17,7 @@ ...@@ -17,6 +17,7 @@
*/ */
#include <linux/mm.h> #include <linux/mm.h>
#include <linux/err.h>
static unsigned long kernel_virtual_offset; static unsigned long kernel_virtual_offset;
static int is_xencomm_initialized; static int is_xencomm_initialized;
...@@ -98,7 +99,7 @@ xencomm_vtop(unsigned long vaddr) ...@@ -98,7 +99,7 @@ xencomm_vtop(unsigned long vaddr)
/* We assume the page is modified. */ /* We assume the page is modified. */
page = follow_page(vma, vaddr, FOLL_WRITE | FOLL_TOUCH); page = follow_page(vma, vaddr, FOLL_WRITE | FOLL_TOUCH);
if (!page) if (IS_ERR_OR_NULL(page))
return ~0UL; return ~0UL;
return (page_to_pfn(page) << PAGE_SHIFT) | (vaddr & ~PAGE_MASK); return (page_to_pfn(page) << PAGE_SHIFT) | (vaddr & ~PAGE_MASK);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment