Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1377902 > unrolled thread
| Started by | Michael Ellerman <mpe@ellerman.id.au> |
|---|---|
| First post | 2016-04-13 15:00 +0200 |
| Last post | 2016-04-15 12:10 +0200 |
| Articles | 20 on this page of 25 — 6 participants |
Back to article view | Back to linux.kernel
[PATCH 0/5] Live patching for powerpc Michael Ellerman <mpe@ellerman.id.au> - 2016-04-13 15:00 +0200
[PATCH 3/5] powerpc/livepatch: Add livepatch header Michael Ellerman <mpe@ellerman.id.au> - 2016-04-13 15:00 +0200
Re: [PATCH 3/5] powerpc/livepatch: Add livepatch header Miroslav Benes <mbenes@suse.cz> - 2016-04-14 14:20 +0200
Re: [PATCH 3/5] powerpc/livepatch: Add livepatch header Miroslav Benes <mbenes@suse.cz> - 2016-04-14 14:30 +0200
Re: [PATCH 3/5] powerpc/livepatch: Add livepatch header Michael Ellerman <mpe@ellerman.id.au> - 2016-04-14 15:20 +0200
[PATCH 1/5] ftrace: Make ftrace_location_range() global Michael Ellerman <mpe@ellerman.id.au> - 2016-04-13 15:00 +0200
[PATCH 4/5] powerpc/livepatch: Add livepatch stack to struct thread_info Michael Ellerman <mpe@ellerman.id.au> - 2016-04-13 15:00 +0200
Re: [PATCH 0/5] Live patching for powerpc Miroslav Benes <mbenes@suse.cz> - 2016-04-13 15:10 +0200
Re: [PATCH 0/5] Live patching for powerpc Jiri Kosina <jikos@kernel.org> - 2016-04-13 15:30 +0200
Re: [PATCH 0/5] Live patching for powerpc Michael Ellerman <mpe@ellerman.id.au> - 2016-04-14 09:00 +0200
Re: [PATCH 0/5] Live patching for powerpc Torsten Duwe <duwe@lst.de> - 2016-04-14 15:00 +0200
Re: [PATCH 0/5] Live patching for powerpc Michael Ellerman <mpe@ellerman.id.au> - 2016-04-14 15:10 +0200
Re: [PATCH 0/5] Live patching for powerpc Torsten Duwe <duwe@lst.de> - 2016-04-14 17:30 +0200
Re: [PATCH 0/5] Live patching for powerpc Josh Poimboeuf <jpoimboe@redhat.com> - 2016-04-14 18:50 +0200
Re: [PATCH 0/5] Live patching for powerpc Michael Ellerman <mpe@ellerman.id.au> - 2016-04-15 13:30 +0200
Re: [PATCH 0/5] Live patching for powerpc Josh Poimboeuf <jpoimboe@redhat.com> - 2016-04-15 15:00 +0200
Re: [PATCH 0/5] Live patching for powerpc Michael Ellerman <mpe@ellerman.id.au> - 2016-04-15 15:30 +0200
Re: [PATCH 0/5] Live patching for powerpc Jiri Kosina <jikos@kernel.org> - 2016-04-14 16:40 +0200
Re: [PATCH 0/5] Live patching for powerpc Michael Ellerman <mpe@ellerman.id.au> - 2016-04-15 14:30 +0200
Re: [PATCH 0/5] Live patching for powerpc Jiri Kosina <jikos@kernel.org> - 2016-04-15 17:10 +0200
Re: Live patching for powerpc Jessica Yu <jeyu@redhat.com> - 2016-04-13 20:30 +0200
Re: Live patching for powerpc Miroslav Benes <mbenes@suse.cz> - 2016-04-14 15:30 +0200
Re: Live patching for powerpc Jessica Yu <jeyu@redhat.com> - 2016-04-14 21:30 +0200
Re: Live patching for powerpc Miroslav Benes <mbenes@suse.cz> - 2016-04-15 10:30 +0200
Re: Live patching for powerpc Michael Ellerman <mpe@ellerman.id.au> - 2016-04-15 12:10 +0200
Page 1 of 2 [1] 2 Next page →
| From | Michael Ellerman <mpe@ellerman.id.au> |
|---|---|
| Date | 2016-04-13 15:00 +0200 |
| Subject | [PATCH 0/5] Live patching for powerpc |
| Message-ID | <rnsyJ-1lV-3@gated-at.bofh.it> |
This series adds live patching support for powerpc (ppc64le only ATM). It's unchanged since the version I posted on March 24, with the exception that I've dropped the first patch, which was a testing-only patch. If there's no further comments I'll put this in a topic branch in the next day or two and Jiri & I will both merge that into next. cheers Michael Ellerman (5): ftrace: Make ftrace_location_range() global livepatch: Allow architectures to specify an alternate ftrace location powerpc/livepatch: Add livepatch header powerpc/livepatch: Add livepatch stack to struct thread_info powerpc/livepatch: Add live patching support on ppc64le arch/powerpc/Kconfig | 3 ++ arch/powerpc/include/asm/livepatch.h | 62 ++++++++++++++++++++++ arch/powerpc/include/asm/thread_info.h | 4 +- arch/powerpc/kernel/asm-offsets.c | 4 ++ arch/powerpc/kernel/entry_64.S | 97 ++++++++++++++++++++++++++++++++++ arch/powerpc/kernel/irq.c | 3 ++ arch/powerpc/kernel/process.c | 6 ++- arch/powerpc/kernel/setup_64.c | 17 +++--- include/linux/ftrace.h | 1 + kernel/livepatch/core.c | 34 ++++++++++-- kernel/trace/ftrace.c | 14 ++++- 11 files changed, 232 insertions(+), 13 deletions(-) create mode 100644 arch/powerpc/include/asm/livepatch.h -- 2.5.0
[toc] | [next] | [standalone]
| From | Michael Ellerman <mpe@ellerman.id.au> |
|---|---|
| Date | 2016-04-13 15:00 +0200 |
| Subject | [PATCH 3/5] powerpc/livepatch: Add livepatch header |
| Message-ID | <rnsyK-1lV-17@gated-at.bofh.it> |
| In reply to | #1377902 |
Add the powerpc specific livepatch definitions. In particular we provide
a non-default implementation of klp_get_ftrace_location().
This is required because the location of the mcount call is not constant
when using -mprofile-kernel (which we always do for live patching).
Signed-off-by: Torsten Duwe <duwe@suse.de>
Signed-off-by: Balbir Singh <bsingharora@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
---
arch/powerpc/include/asm/livepatch.h | 54 ++++++++++++++++++++++++++++++++++++
1 file changed, 54 insertions(+)
create mode 100644 arch/powerpc/include/asm/livepatch.h
diff --git a/arch/powerpc/include/asm/livepatch.h b/arch/powerpc/include/asm/livepatch.h
new file mode 100644
index 000000000000..ad36e8e34fa1
--- /dev/null
+++ b/arch/powerpc/include/asm/livepatch.h
@@ -0,0 +1,54 @@
+/*
+ * livepatch.h - powerpc-specific Kernel Live Patching Core
+ *
+ * Copyright (C) 2015-2016, SUSE, IBM Corp.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, see <http://www.gnu.org/licenses/>.
+ */
+#ifndef _ASM_POWERPC_LIVEPATCH_H
+#define _ASM_POWERPC_LIVEPATCH_H
+
+#include <linux/module.h>
+#include <linux/ftrace.h>
+
+#ifdef CONFIG_LIVEPATCH
+static inline int klp_check_compiler_support(void)
+{
+ return 0;
+}
+
+static inline int klp_write_module_reloc(struct module *mod, unsigned long
+ type, unsigned long loc, unsigned long value)
+{
+ /* This requires infrastructure changes; we need the loadinfos. */
+ return -ENOSYS;
+}
+
+static inline void klp_arch_set_pc(struct pt_regs *regs, unsigned long ip)
+{
+ regs->nip = ip;
+}
+
+#define klp_get_ftrace_location klp_get_ftrace_location
+static inline unsigned long klp_get_ftrace_location(unsigned long faddr)
+{
+ /*
+ * Live patch works only with -mprofile-kernel on PPC. In this case,
+ * the ftrace location is always within the first 16 bytes.
+ */
+ return ftrace_location_range(faddr, faddr + 16);
+}
+#endif /* CONFIG_LIVEPATCH */
+
+#endif /* _ASM_POWERPC_LIVEPATCH_H */
--
2.5.0
[toc] | [prev] | [next] | [standalone]
| From | Miroslav Benes <mbenes@suse.cz> |
|---|---|
| Date | 2016-04-14 14:20 +0200 |
| Subject | Re: [PATCH 3/5] powerpc/livepatch: Add livepatch header |
| Message-ID | <rnOpB-1sB-25@gated-at.bofh.it> |
| In reply to | #1377903 |
On Wed, 13 Apr 2016, Michael Ellerman wrote:
> Add the powerpc specific livepatch definitions. In particular we provide
> a non-default implementation of klp_get_ftrace_location().
>
> This is required because the location of the mcount call is not constant
> when using -mprofile-kernel (which we always do for live patching).
>
> Signed-off-by: Torsten Duwe <duwe@suse.de>
> Signed-off-by: Balbir Singh <bsingharora@gmail.com>
> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
> ---
> arch/powerpc/include/asm/livepatch.h | 54 ++++++++++++++++++++++++++++++++++++
> 1 file changed, 54 insertions(+)
> create mode 100644 arch/powerpc/include/asm/livepatch.h
>
> diff --git a/arch/powerpc/include/asm/livepatch.h b/arch/powerpc/include/asm/livepatch.h
> new file mode 100644
> index 000000000000..ad36e8e34fa1
> --- /dev/null
> +++ b/arch/powerpc/include/asm/livepatch.h
> @@ -0,0 +1,54 @@
> +/*
> + * livepatch.h - powerpc-specific Kernel Live Patching Core
> + *
> + * Copyright (C) 2015-2016, SUSE, IBM Corp.
> + *
> + * This program is free software; you can redistribute it and/or
> + * modify it under the terms of the GNU General Public License
> + * as published by the Free Software Foundation; either version 2
> + * of the License, or (at your option) any later version.
> + *
> + * This program is distributed in the hope that it will be useful,
> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
> + * GNU General Public License for more details.
> + *
> + * You should have received a copy of the GNU General Public License
> + * along with this program; if not, see <http://www.gnu.org/licenses/>.
> + */
> +#ifndef _ASM_POWERPC_LIVEPATCH_H
> +#define _ASM_POWERPC_LIVEPATCH_H
> +
> +#include <linux/module.h>
> +#include <linux/ftrace.h>
> +
> +#ifdef CONFIG_LIVEPATCH
We don't use these guards in our header files since 335e073faacc ("klp:
remove CONFIG_LIVEPATCH dependency from klp headers").
> +static inline int klp_check_compiler_support(void)
> +{
> + return 0;
> +}
> +
> +static inline int klp_write_module_reloc(struct module *mod, unsigned long
> + type, unsigned long loc, unsigned long value)
> +{
> + /* This requires infrastructure changes; we need the loadinfos. */
> + return -ENOSYS;
> +}
And this is not needed anymore as Jessica pointed out.
> +static inline void klp_arch_set_pc(struct pt_regs *regs, unsigned long ip)
> +{
> + regs->nip = ip;
> +}
> +
> +#define klp_get_ftrace_location klp_get_ftrace_location
> +static inline unsigned long klp_get_ftrace_location(unsigned long faddr)
> +{
> + /*
> + * Live patch works only with -mprofile-kernel on PPC. In this case,
> + * the ftrace location is always within the first 16 bytes.
> + */
> + return ftrace_location_range(faddr, faddr + 16);
> +}
> +#endif /* CONFIG_LIVEPATCH */
> +
> +#endif /* _ASM_POWERPC_LIVEPATCH_H */
> --
> 2.5.0
>
[toc] | [prev] | [next] | [standalone]
| From | Miroslav Benes <mbenes@suse.cz> |
|---|---|
| Date | 2016-04-14 14:30 +0200 |
| Subject | Re: [PATCH 3/5] powerpc/livepatch: Add livepatch header |
| Message-ID | <rnOzh-1x1-15@gated-at.bofh.it> |
| In reply to | #1378757 |
On Thu, 14 Apr 2016, Miroslav Benes wrote:
> On Wed, 13 Apr 2016, Michael Ellerman wrote:
>
> > Add the powerpc specific livepatch definitions. In particular we provide
> > a non-default implementation of klp_get_ftrace_location().
> >
> > This is required because the location of the mcount call is not constant
> > when using -mprofile-kernel (which we always do for live patching).
> >
> > Signed-off-by: Torsten Duwe <duwe@suse.de>
> > Signed-off-by: Balbir Singh <bsingharora@gmail.com>
> > Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
> > ---
> > arch/powerpc/include/asm/livepatch.h | 54 ++++++++++++++++++++++++++++++++++++
> > 1 file changed, 54 insertions(+)
> > create mode 100644 arch/powerpc/include/asm/livepatch.h
> >
> > diff --git a/arch/powerpc/include/asm/livepatch.h b/arch/powerpc/include/asm/livepatch.h
> > new file mode 100644
> > index 000000000000..ad36e8e34fa1
> > --- /dev/null
> > +++ b/arch/powerpc/include/asm/livepatch.h
> > @@ -0,0 +1,54 @@
> > +/*
> > + * livepatch.h - powerpc-specific Kernel Live Patching Core
> > + *
> > + * Copyright (C) 2015-2016, SUSE, IBM Corp.
> > + *
> > + * This program is free software; you can redistribute it and/or
> > + * modify it under the terms of the GNU General Public License
> > + * as published by the Free Software Foundation; either version 2
> > + * of the License, or (at your option) any later version.
> > + *
> > + * This program is distributed in the hope that it will be useful,
> > + * but WITHOUT ANY WARRANTY; without even the implied warranty of
> > + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
> > + * GNU General Public License for more details.
> > + *
> > + * You should have received a copy of the GNU General Public License
> > + * along with this program; if not, see <http://www.gnu.org/licenses/>.
> > + */
> > +#ifndef _ASM_POWERPC_LIVEPATCH_H
> > +#define _ASM_POWERPC_LIVEPATCH_H
> > +
> > +#include <linux/module.h>
> > +#include <linux/ftrace.h>
> > +
> > +#ifdef CONFIG_LIVEPATCH
>
> We don't use these guards in our header files since 335e073faacc ("klp:
> remove CONFIG_LIVEPATCH dependency from klp headers").
...but you're gonna need it in the next patch...
[toc] | [prev] | [next] | [standalone]
| From | Michael Ellerman <mpe@ellerman.id.au> |
|---|---|
| Date | 2016-04-14 15:20 +0200 |
| Subject | Re: [PATCH 3/5] powerpc/livepatch: Add livepatch header |
| Message-ID | <rnPlF-2aV-15@gated-at.bofh.it> |
| In reply to | #1378778 |
On Thu, 2016-04-14 at 14:23 +0200, Miroslav Benes wrote:
> On Thu, 14 Apr 2016, Miroslav Benes wrote:
> > On Wed, 13 Apr 2016, Michael Ellerman wrote:
> > > diff --git a/arch/powerpc/include/asm/livepatch.h b/arch/powerpc/include/asm/livepatch.h
> > > new file mode 100644
> > > index 000000000000..ad36e8e34fa1
> > > --- /dev/null
> > > +++ b/arch/powerpc/include/asm/livepatch.h
> > > @@ -0,0 +1,54 @@
...
> > > +#ifndef _ASM_POWERPC_LIVEPATCH_H
> > > +#define _ASM_POWERPC_LIVEPATCH_H
> > > +
> > > +#include <linux/module.h>
> > > +#include <linux/ftrace.h>
> > > +
> > > +#ifdef CONFIG_LIVEPATCH
> >
> > We don't use these guards in our header files since 335e073faacc ("klp:
> > remove CONFIG_LIVEPATCH dependency from klp headers").
>
> ...but you're gonna need it in the next patch...
Yeah I know I said at one point those #ifdefs were unneeded, but then it turns
out we did want it on powerpc for other reasons.
cheers
[toc] | [prev] | [next] | [standalone]
| From | Michael Ellerman <mpe@ellerman.id.au> |
|---|---|
| Date | 2016-04-13 15:00 +0200 |
| Subject | [PATCH 1/5] ftrace: Make ftrace_location_range() global |
| Message-ID | <rnsyL-1lV-43@gated-at.bofh.it> |
| In reply to | #1377902 |
In order to support live patching on powerpc we would like to call
ftrace_location_range(), so make it global.
Signed-off-by: Torsten Duwe <duwe@suse.de>
Signed-off-by: Balbir Singh <bsingharora@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
---
include/linux/ftrace.h | 1 +
kernel/trace/ftrace.c | 14 +++++++++++++-
2 files changed, 14 insertions(+), 1 deletion(-)
diff --git a/include/linux/ftrace.h b/include/linux/ftrace.h
index dea12a6e413b..66a36a815f0a 100644
--- a/include/linux/ftrace.h
+++ b/include/linux/ftrace.h
@@ -455,6 +455,7 @@ int ftrace_update_record(struct dyn_ftrace *rec, int enable);
int ftrace_test_record(struct dyn_ftrace *rec, int enable);
void ftrace_run_stop_machine(int command);
unsigned long ftrace_location(unsigned long ip);
+unsigned long ftrace_location_range(unsigned long start, unsigned long end);
unsigned long ftrace_get_addr_new(struct dyn_ftrace *rec);
unsigned long ftrace_get_addr_curr(struct dyn_ftrace *rec);
diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
index b1870fbd2b67..7e8d792da963 100644
--- a/kernel/trace/ftrace.c
+++ b/kernel/trace/ftrace.c
@@ -1530,7 +1530,19 @@ static int ftrace_cmp_recs(const void *a, const void *b)
return 0;
}
-static unsigned long ftrace_location_range(unsigned long start, unsigned long end)
+/**
+ * ftrace_location_range - return the first address of a traced location
+ * if it touches the given ip range
+ * @start: start of range to search.
+ * @end: end of range to search (inclusive). @end points to the last byte
+ * to check.
+ *
+ * Returns rec->ip if the related ftrace location is a least partly within
+ * the given address range. That is, the first address of the instruction
+ * that is either a NOP or call to the function tracer. It checks the ftrace
+ * internal tables to determine if the address belongs or not.
+ */
+unsigned long ftrace_location_range(unsigned long start, unsigned long end)
{
struct ftrace_page *pg;
struct dyn_ftrace *rec;
--
2.5.0
[toc] | [prev] | [next] | [standalone]
| From | Michael Ellerman <mpe@ellerman.id.au> |
|---|---|
| Date | 2016-04-13 15:00 +0200 |
| Subject | [PATCH 4/5] powerpc/livepatch: Add livepatch stack to struct thread_info |
| Message-ID | <rnsyL-1lV-45@gated-at.bofh.it> |
| In reply to | #1377902 |
In order to support live patching we need to maintain an alternate
stack of TOC & LR values. We use the base of the stack for this, and
store the "live patch stack pointer" in struct thread_info.
Unlike the other fields of thread_info, we can not statically initialise
that value, so it must be done at run time.
This patch just adds the code to support that, it is not enabled until
the next patch which actually adds live patch support.
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Acked-by: Balbir Singh <bsingharora@gmail.com>
---
arch/powerpc/include/asm/livepatch.h | 8 ++++++++
arch/powerpc/include/asm/thread_info.h | 4 +++-
arch/powerpc/kernel/irq.c | 3 +++
arch/powerpc/kernel/process.c | 6 +++++-
arch/powerpc/kernel/setup_64.c | 17 ++++++++++-------
5 files changed, 29 insertions(+), 9 deletions(-)
diff --git a/arch/powerpc/include/asm/livepatch.h b/arch/powerpc/include/asm/livepatch.h
index ad36e8e34fa1..a402f7f94896 100644
--- a/arch/powerpc/include/asm/livepatch.h
+++ b/arch/powerpc/include/asm/livepatch.h
@@ -49,6 +49,14 @@ static inline unsigned long klp_get_ftrace_location(unsigned long faddr)
*/
return ftrace_location_range(faddr, faddr + 16);
}
+
+static inline void klp_init_thread_info(struct thread_info *ti)
+{
+ /* + 1 to account for STACK_END_MAGIC */
+ ti->livepatch_sp = (unsigned long *)(ti + 1) + 1;
+}
+#else
+static void klp_init_thread_info(struct thread_info *ti) { }
#endif /* CONFIG_LIVEPATCH */
#endif /* _ASM_POWERPC_LIVEPATCH_H */
diff --git a/arch/powerpc/include/asm/thread_info.h b/arch/powerpc/include/asm/thread_info.h
index 7efee4a3240b..8febc3f66d53 100644
--- a/arch/powerpc/include/asm/thread_info.h
+++ b/arch/powerpc/include/asm/thread_info.h
@@ -43,7 +43,9 @@ struct thread_info {
int preempt_count; /* 0 => preemptable,
<0 => BUG */
unsigned long local_flags; /* private flags for thread */
-
+#ifdef CONFIG_LIVEPATCH
+ unsigned long *livepatch_sp;
+#endif
/* low level flags - has atomic operations done on it */
unsigned long flags ____cacheline_aligned_in_smp;
};
diff --git a/arch/powerpc/kernel/irq.c b/arch/powerpc/kernel/irq.c
index 290559df1e8b..3cb46a3b1de7 100644
--- a/arch/powerpc/kernel/irq.c
+++ b/arch/powerpc/kernel/irq.c
@@ -66,6 +66,7 @@
#include <asm/udbg.h>
#include <asm/smp.h>
#include <asm/debug.h>
+#include <asm/livepatch.h>
#ifdef CONFIG_PPC64
#include <asm/paca.h>
@@ -607,10 +608,12 @@ void irq_ctx_init(void)
memset((void *)softirq_ctx[i], 0, THREAD_SIZE);
tp = softirq_ctx[i];
tp->cpu = i;
+ klp_init_thread_info(tp);
memset((void *)hardirq_ctx[i], 0, THREAD_SIZE);
tp = hardirq_ctx[i];
tp->cpu = i;
+ klp_init_thread_info(tp);
}
}
diff --git a/arch/powerpc/kernel/process.c b/arch/powerpc/kernel/process.c
index b8500b4ac7fe..2a9280b945e0 100644
--- a/arch/powerpc/kernel/process.c
+++ b/arch/powerpc/kernel/process.c
@@ -55,6 +55,8 @@
#include <asm/firmware.h>
#endif
#include <asm/code-patching.h>
+#include <asm/livepatch.h>
+
#include <linux/kprobes.h>
#include <linux/kdebug.h>
@@ -1400,13 +1402,15 @@ int copy_thread(unsigned long clone_flags, unsigned long usp,
extern void ret_from_kernel_thread(void);
void (*f)(void);
unsigned long sp = (unsigned long)task_stack_page(p) + THREAD_SIZE;
+ struct thread_info *ti = task_thread_info(p);
+
+ klp_init_thread_info(ti);
/* Copy registers */
sp -= sizeof(struct pt_regs);
childregs = (struct pt_regs *) sp;
if (unlikely(p->flags & PF_KTHREAD)) {
/* kernel thread */
- struct thread_info *ti = (void *)task_stack_page(p);
memset(childregs, 0, sizeof(struct pt_regs));
childregs->gpr[1] = sp + sizeof(struct pt_regs);
/* function */
diff --git a/arch/powerpc/kernel/setup_64.c b/arch/powerpc/kernel/setup_64.c
index f98be8383a39..96d4a2b23d0f 100644
--- a/arch/powerpc/kernel/setup_64.c
+++ b/arch/powerpc/kernel/setup_64.c
@@ -69,6 +69,7 @@
#include <asm/kvm_ppc.h>
#include <asm/hugetlb.h>
#include <asm/epapr_hcalls.h>
+#include <asm/livepatch.h>
#ifdef DEBUG
#define DBG(fmt...) udbg_printf(fmt)
@@ -667,16 +668,16 @@ static void __init emergency_stack_init(void)
limit = min(safe_stack_limit(), ppc64_rma_size);
for_each_possible_cpu(i) {
- unsigned long sp;
- sp = memblock_alloc_base(THREAD_SIZE, THREAD_SIZE, limit);
- sp += THREAD_SIZE;
- paca[i].emergency_sp = __va(sp);
+ struct thread_info *ti;
+ ti = __va(memblock_alloc_base(THREAD_SIZE, THREAD_SIZE, limit));
+ klp_init_thread_info(ti);
+ paca[i].emergency_sp = (void *)ti + THREAD_SIZE;
#ifdef CONFIG_PPC_BOOK3S_64
/* emergency stack for machine check exception handling. */
- sp = memblock_alloc_base(THREAD_SIZE, THREAD_SIZE, limit);
- sp += THREAD_SIZE;
- paca[i].mc_emergency_sp = __va(sp);
+ ti = __va(memblock_alloc_base(THREAD_SIZE, THREAD_SIZE, limit));
+ klp_init_thread_info(ti);
+ paca[i].mc_emergency_sp = (void *)ti + THREAD_SIZE;
#endif
}
}
@@ -700,6 +701,8 @@ void __init setup_arch(char **cmdline_p)
if (ppc_md.panic)
setup_panic();
+ klp_init_thread_info(&init_thread_info);
+
init_mm.start_code = (unsigned long)_stext;
init_mm.end_code = (unsigned long) _etext;
init_mm.end_data = (unsigned long) _edata;
--
2.5.0
[toc] | [prev] | [next] | [standalone]
| From | Miroslav Benes <mbenes@suse.cz> |
|---|---|
| Date | 2016-04-13 15:10 +0200 |
| Message-ID | <rnsIq-1Gg-3@gated-at.bofh.it> |
| In reply to | #1377902 |
On Wed, 13 Apr 2016, Michael Ellerman wrote: > This series adds live patching support for powerpc (ppc64le only ATM). > > It's unchanged since the version I posted on March 24, with the exception that > I've dropped the first patch, which was a testing-only patch. > > If there's no further comments I'll put this in a topic branch in the next day > or two and Jiri & I will both merge that into next. Hi, I'll definitely give it a proper look today or tomorrow, but there is one thing that needs to be solved. The patch set from Jessica reworking relocations for live patching is now merged in our for-next branch. This means that we need to find out if there is something in struct mod_arch_specific for powerpc which needs to be preserved and do it. Regards, Miroslav
[toc] | [prev] | [next] | [standalone]
| From | Jiri Kosina <jikos@kernel.org> |
|---|---|
| Date | 2016-04-13 15:30 +0200 |
| Message-ID | <rnt1N-1O6-25@gated-at.bofh.it> |
| In reply to | #1377913 |
On Wed, 13 Apr 2016, Miroslav Benes wrote: > > This series adds live patching support for powerpc (ppc64le only ATM). > > > > It's unchanged since the version I posted on March 24, with the exception that > > I've dropped the first patch, which was a testing-only patch. > > > > If there's no further comments I'll put this in a topic branch in the next day > > or two and Jiri & I will both merge that into next. > > Hi, > > I'll definitely give it a proper look today or tomorrow, but there is one > thing that needs to be solved. The patch set from Jessica reworking > relocations for live patching is now merged in our for-next branch. This > means that we need to find out if there is something in struct > mod_arch_specific for powerpc which needs to be preserved and do it. Michael, if the plan is still the original one, i.e. you push it to your branch, and I merge it to livepatching (and resolve any dependencies on the relocations code during the merge) and push it to Linus from livepatching.git, then there shouldn't be anything do to on your side. Alternatively, you can rebase on top of livepatching.git#for-next, and I'll take it directly. Thanks, -- Jiri Kosina SUSE Labs
[toc] | [prev] | [next] | [standalone]
| From | Michael Ellerman <mpe@ellerman.id.au> |
|---|---|
| Date | 2016-04-14 09:00 +0200 |
| Message-ID | <rnJpU-61B-13@gated-at.bofh.it> |
| In reply to | #1377934 |
On Wed, 2016-04-13 at 15:22 +0200, Jiri Kosina wrote: > On Wed, 13 Apr 2016, Miroslav Benes wrote: > > > This series adds live patching support for powerpc (ppc64le only ATM). > > > > > > It's unchanged since the version I posted on March 24, with the exception that > > > I've dropped the first patch, which was a testing-only patch. > > > > > > If there's no further comments I'll put this in a topic branch in the next day > > > or two and Jiri & I will both merge that into next. > > > > Hi, > > > > I'll definitely give it a proper look today or tomorrow, but there is one > > thing that needs to be solved. The patch set from Jessica reworking > > relocations for live patching is now merged in our for-next branch. This > > means that we need to find out if there is something in struct > > mod_arch_specific for powerpc which needs to be preserved and do it. > > Michael, if the plan is still the original one, i.e. you push it to your > branch, and I merge it to livepatching (and resolve any dependencies on > the relocations code during the merge) and push it to Linus from > livepatching.git, then there shouldn't be anything do to on your side. That is my plan yeah. Topic branch here: https://git.kernel.org/cgit/linux/kernel/git/powerpc/linux.git/log/?h=topic/livepatch I will merge that before Monday (my time) if I don't hear any objections. cheers
[toc] | [prev] | [next] | [standalone]
| From | Torsten Duwe <duwe@lst.de> |
|---|---|
| Date | 2016-04-14 15:00 +0200 |
| Message-ID | <rnP2j-1K8-19@gated-at.bofh.it> |
| In reply to | #1378532 |
On Thu, Apr 14, 2016 at 04:49:50PM +1000, Michael Ellerman wrote: > On Wed, 2016-04-13 at 15:22 +0200, Jiri Kosina wrote: > > On Wed, 13 Apr 2016, Miroslav Benes wrote: > > > > This series adds live patching support for powerpc (ppc64le only ATM). > > > > > > > > It's unchanged since the version I posted on March 24, with the exception that > > > > I've dropped the first patch, which was a testing-only patch. Confirmed. And it still works on top of 4.6-rc3, even with the additional testing. > > > > If there's no further comments I'll put this in a topic branch in the next day > > > > or two and Jiri & I will both merge that into next. "Go" from my side. FTR: then I still have a few ppc64 hunks floating around to support certain consistency models... Torsten
[toc] | [prev] | [next] | [standalone]
| From | Michael Ellerman <mpe@ellerman.id.au> |
|---|---|
| Date | 2016-04-14 15:10 +0200 |
| Message-ID | <rnPbY-275-11@gated-at.bofh.it> |
| In reply to | #1378813 |
On Thu, 2016-04-14 at 14:57 +0200, Torsten Duwe wrote: > On Thu, Apr 14, 2016 at 04:49:50PM +1000, Michael Ellerman wrote: > > On Wed, 2016-04-13 at 15:22 +0200, Jiri Kosina wrote: > > > On Wed, 13 Apr 2016, Miroslav Benes wrote: > > > > > This series adds live patching support for powerpc (ppc64le only ATM). > > > > > > > > > > It's unchanged since the version I posted on March 24, with the exception that > > > > > I've dropped the first patch, which was a testing-only patch. > > Confirmed. And it still works on top of 4.6-rc3, even with the additional testing. Thanks. Yeah I tested on top of rc3 as well as back on the topic branch (4.5-rc). > > > > > If there's no further comments I'll put this in a topic branch in the next day > > > > > or two and Jiri & I will both merge that into next. > > "Go" from my side. Throttle up! > FTR: then I still have a few ppc64 hunks floating around to support certain consistency > models... OK. I'm not quite sure what you mean but post them and we'll see I guess :) cheers
[toc] | [prev] | [next] | [standalone]
| From | Torsten Duwe <duwe@lst.de> |
|---|---|
| Date | 2016-04-14 17:30 +0200 |
| Message-ID | <rnRnt-3WP-37@gated-at.bofh.it> |
| In reply to | #1378818 |
On Thu, Apr 14, 2016 at 11:08:02PM +1000, Michael Ellerman wrote: > On Thu, 2016-04-14 at 14:57 +0200, Torsten Duwe wrote: > > > FTR: then I still have a few ppc64 hunks floating around to support certain consistency > > models... > > OK. I'm not quite sure what you mean but post them and we'll see I guess :) It's *roughly* the ppc64 equivalent of Josh Poimboeuf's Mar 25 | [RFC PATCH v1.9 14/14] livepatch: update task universe when exiting kernel which only considers x86. It's forward ported from an earlier code base; there's some glue missing, but here it is, for reference. Signed-off-by: Torsten Duwe <duwe@suse.de> diff --git a/arch/powerpc/include/asm/thread_info.h b/arch/powerpc/include/asm/thread_info.h index b034ecd..3e749f4 100644 --- a/arch/powerpc/include/asm/thread_info.h +++ b/arch/powerpc/include/asm/thread_info.h @@ -92,6 +92,7 @@ static inline struct thread_info *current_thread_info(void) TIF_NEED_RESCHED */ #define TIF_32BIT 4 /* 32 bit binary */ #define TIF_RESTORE_TM 5 /* need to restore TM FP/VEC/VSX */ +#define TIF_KLP_NEED_UPDATE 6 /* kGraft patching in progress */ #define TIF_SYSCALL_AUDIT 7 /* syscall auditing active */ #define TIF_SINGLESTEP 8 /* singlestepping active */ #define TIF_NOHZ 9 /* in adaptive nohz mode */ @@ -115,8 +116,10 @@ static inline struct thread_info *current_thread_info(void) #define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) #define _TIF_32BIT (1<<TIF_32BIT) #define _TIF_RESTORE_TM (1<<TIF_RESTORE_TM) +#define _TIF_KLP_NEED_UPDATE (1<<TIF_KLP_NEED_UPDATE) #define _TIF_SYSCALL_AUDIT (1<<TIF_SYSCALL_AUDIT) #define _TIF_SINGLESTEP (1<<TIF_SINGLESTEP) +#define _TIF_NOHZ (1<<TIF_NOHZ) #define _TIF_SECCOMP (1<<TIF_SECCOMP) #define _TIF_RESTOREALL (1<<TIF_RESTOREALL) #define _TIF_NOERROR (1<<TIF_NOERROR) @@ -124,7 +127,7 @@ static inline struct thread_info *current_thread_info(void) #define _TIF_UPROBE (1<<TIF_UPROBE) #define _TIF_SYSCALL_TRACEPOINT (1<<TIF_SYSCALL_TRACEPOINT) #define _TIF_EMULATE_STACK_STORE (1<<TIF_EMULATE_STACK_STORE) -#define _TIF_NOHZ (1<<TIF_NOHZ) + #define _TIF_SYSCALL_DOTRACE (_TIF_SYSCALL_TRACE | _TIF_SYSCALL_AUDIT | \ _TIF_SECCOMP | _TIF_SYSCALL_TRACEPOINT | \ _TIF_NOHZ) @@ -132,7 +135,8 @@ static inline struct thread_info *current_thread_info(void) #define _TIF_USER_WORK_MASK (_TIF_SIGPENDING | _TIF_NEED_RESCHED | \ _TIF_NOTIFY_RESUME | _TIF_UPROBE | \ _TIF_RESTORE_TM) -#define _TIF_PERSYSCALL_MASK (_TIF_RESTOREALL|_TIF_NOERROR) + +#define _TIF_PERSYSCALL_MASK (_TIF_RESTOREALL|_TIF_NOERROR|_TIF_KLP_NEED_UPDATE) /* Bits in local_flags */ /* Don't move TLF_NAPPING without adjusting the code in entry_32.S */ diff --git a/arch/powerpc/kernel/entry_64.S b/arch/powerpc/kernel/entry_64.S index 5bbd1bc..17f8a18 100644 --- a/arch/powerpc/kernel/entry_64.S +++ b/arch/powerpc/kernel/entry_64.S @@ -151,8 +151,8 @@ END_FW_FTR_SECTION_IFSET(FW_FEATURE_SPLPAR) CURRENT_THREAD_INFO(r11, r1) ld r10,TI_FLAGS(r11) - andi. r11,r10,_TIF_SYSCALL_DOTRACE - bne syscall_dotrace /* does not return */ + andi. r10,r10,(_TIF_SYSCALL_DOTRACE|_TIF_KLP_NEED_UPDATE) + bne- syscall_precall /* does not return */ cmpldi 0,r0,NR_syscalls bge- syscall_enosys @@ -245,6 +245,17 @@ syscall_error: neg r3,r3 std r5,_CCR(r1) b .Lsyscall_error_cont + +syscall_precall: + andi. r10,r10,(_TIF_KLP_NEED_UPDATE) + beq+ syscall_dotrace + + addi r11,r11,TI_FLAGS +1: ldarx r12,0,r11 + andc r12,r12,r10 + stdcx. r12,0,r11 + bne- 1b + subi r11,r11,TI_FLAGS /* Traced system call support */ syscall_dotrace:
[toc] | [prev] | [next] | [standalone]
| From | Josh Poimboeuf <jpoimboe@redhat.com> |
|---|---|
| Date | 2016-04-14 18:50 +0200 |
| Message-ID | <rnSCS-4Y2-27@gated-at.bofh.it> |
| In reply to | #1379028 |
On Thu, Apr 14, 2016 at 05:20:29PM +0200, Torsten Duwe wrote: > On Thu, Apr 14, 2016 at 11:08:02PM +1000, Michael Ellerman wrote: > > On Thu, 2016-04-14 at 14:57 +0200, Torsten Duwe wrote: > > > > > FTR: then I still have a few ppc64 hunks floating around to support certain consistency > > > models... > > > > OK. I'm not quite sure what you mean but post them and we'll see I guess :) > > It's *roughly* the ppc64 equivalent of Josh Poimboeuf's Mar 25 > | [RFC PATCH v1.9 14/14] livepatch: update task universe when exiting kernel > which only considers x86. > > It's forward ported from an earlier code base; there's some glue missing, > but here it is, for reference. > > Signed-off-by: Torsten Duwe <duwe@suse.de> Hi Torsten, Thanks for sharing. This is quite fortuitous as Miroslav just today mentioned to me that we would need something like this. If you don't mind, I may pull this patch or some variant of it into v2 of the consistency model. > > > diff --git a/arch/powerpc/include/asm/thread_info.h b/arch/powerpc/include/asm/thread_info.h > index b034ecd..3e749f4 100644 > --- a/arch/powerpc/include/asm/thread_info.h > +++ b/arch/powerpc/include/asm/thread_info.h > @@ -92,6 +92,7 @@ static inline struct thread_info *current_thread_info(void) > TIF_NEED_RESCHED */ > #define TIF_32BIT 4 /* 32 bit binary */ > #define TIF_RESTORE_TM 5 /* need to restore TM FP/VEC/VSX */ > +#define TIF_KLP_NEED_UPDATE 6 /* kGraft patching in progress */ > #define TIF_SYSCALL_AUDIT 7 /* syscall auditing active */ > #define TIF_SINGLESTEP 8 /* singlestepping active */ > #define TIF_NOHZ 9 /* in adaptive nohz mode */ > @@ -115,8 +116,10 @@ static inline struct thread_info *current_thread_info(void) > #define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) > #define _TIF_32BIT (1<<TIF_32BIT) > #define _TIF_RESTORE_TM (1<<TIF_RESTORE_TM) > +#define _TIF_KLP_NEED_UPDATE (1<<TIF_KLP_NEED_UPDATE) > #define _TIF_SYSCALL_AUDIT (1<<TIF_SYSCALL_AUDIT) > #define _TIF_SINGLESTEP (1<<TIF_SINGLESTEP) > +#define _TIF_NOHZ (1<<TIF_NOHZ) > #define _TIF_SECCOMP (1<<TIF_SECCOMP) > #define _TIF_RESTOREALL (1<<TIF_RESTOREALL) > #define _TIF_NOERROR (1<<TIF_NOERROR) > @@ -124,7 +127,7 @@ static inline struct thread_info *current_thread_info(void) > #define _TIF_UPROBE (1<<TIF_UPROBE) > #define _TIF_SYSCALL_TRACEPOINT (1<<TIF_SYSCALL_TRACEPOINT) > #define _TIF_EMULATE_STACK_STORE (1<<TIF_EMULATE_STACK_STORE) > -#define _TIF_NOHZ (1<<TIF_NOHZ) > + > #define _TIF_SYSCALL_DOTRACE (_TIF_SYSCALL_TRACE | _TIF_SYSCALL_AUDIT | \ > _TIF_SECCOMP | _TIF_SYSCALL_TRACEPOINT | \ > _TIF_NOHZ) > @@ -132,7 +135,8 @@ static inline struct thread_info *current_thread_info(void) > #define _TIF_USER_WORK_MASK (_TIF_SIGPENDING | _TIF_NEED_RESCHED | \ > _TIF_NOTIFY_RESUME | _TIF_UPROBE | \ > _TIF_RESTORE_TM) > -#define _TIF_PERSYSCALL_MASK (_TIF_RESTOREALL|_TIF_NOERROR) > + > +#define _TIF_PERSYSCALL_MASK (_TIF_RESTOREALL|_TIF_NOERROR|_TIF_KLP_NEED_UPDATE) > > /* Bits in local_flags */ > /* Don't move TLF_NAPPING without adjusting the code in entry_32.S */ > diff --git a/arch/powerpc/kernel/entry_64.S b/arch/powerpc/kernel/entry_64.S > index 5bbd1bc..17f8a18 100644 > --- a/arch/powerpc/kernel/entry_64.S > +++ b/arch/powerpc/kernel/entry_64.S > @@ -151,8 +151,8 @@ END_FW_FTR_SECTION_IFSET(FW_FEATURE_SPLPAR) > > CURRENT_THREAD_INFO(r11, r1) > ld r10,TI_FLAGS(r11) > - andi. r11,r10,_TIF_SYSCALL_DOTRACE > - bne syscall_dotrace /* does not return */ > + andi. r10,r10,(_TIF_SYSCALL_DOTRACE|_TIF_KLP_NEED_UPDATE) > + bne- syscall_precall /* does not return */ > cmpldi 0,r0,NR_syscalls > bge- syscall_enosys > > @@ -245,6 +245,17 @@ syscall_error: > neg r3,r3 > std r5,_CCR(r1) > b .Lsyscall_error_cont > + > +syscall_precall: > + andi. r10,r10,(_TIF_KLP_NEED_UPDATE) > + beq+ syscall_dotrace > + > + addi r11,r11,TI_FLAGS > +1: ldarx r12,0,r11 > + andc r12,r12,r10 > + stdcx. r12,0,r11 > + bne- 1b > + subi r11,r11,TI_FLAGS > > /* Traced system call support */ > syscall_dotrace: -- Josh
[toc] | [prev] | [next] | [standalone]
| From | Michael Ellerman <mpe@ellerman.id.au> |
|---|---|
| Date | 2016-04-15 13:30 +0200 |
| Message-ID | <roa6J-2aO-3@gated-at.bofh.it> |
| In reply to | #1379094 |
On Thu, 2016-04-14 at 11:41 -0500, Josh Poimboeuf wrote: > On Thu, Apr 14, 2016 at 05:20:29PM +0200, Torsten Duwe wrote: > > On Thu, Apr 14, 2016 at 11:08:02PM +1000, Michael Ellerman wrote: > > > On Thu, 2016-04-14 at 14:57 +0200, Torsten Duwe wrote: > > > > FTR: then I still have a few ppc64 hunks floating around to support certain consistency > > > > models... > > > > > > OK. I'm not quite sure what you mean but post them and we'll see I guess :) > > > > It's *roughly* the ppc64 equivalent of Josh Poimboeuf's Mar 25 > > > [RFC PATCH v1.9 14/14] livepatch: update task universe when exiting kernel > > which only considers x86. > > > > It's forward ported from an earlier code base; there's some glue missing, > > but here it is, for reference. > > > > Signed-off-by: Torsten Duwe <duwe@suse.de> > > Hi Torsten, > > Thanks for sharing. This is quite fortuitous as Miroslav just today > mentioned to me that we would need something like this. If you don't > mind, I may pull this patch or some variant of it into v2 of the > consistency model. Well please wait for me to review & ack it before you pull it into anything permanent. At a quick glance it seems OK but I'd probably do it a little differently. I'll try and have a closer look next week. cheers
[toc] | [prev] | [next] | [standalone]
| From | Josh Poimboeuf <jpoimboe@redhat.com> |
|---|---|
| Date | 2016-04-15 15:00 +0200 |
| Message-ID | <robvP-3a8-9@gated-at.bofh.it> |
| In reply to | #1379758 |
On Fri, Apr 15, 2016 at 09:22:49PM +1000, Michael Ellerman wrote: > On Thu, 2016-04-14 at 11:41 -0500, Josh Poimboeuf wrote: > > On Thu, Apr 14, 2016 at 05:20:29PM +0200, Torsten Duwe wrote: > > > On Thu, Apr 14, 2016 at 11:08:02PM +1000, Michael Ellerman wrote: > > > > On Thu, 2016-04-14 at 14:57 +0200, Torsten Duwe wrote: > > > > > FTR: then I still have a few ppc64 hunks floating around to support certain consistency > > > > > models... > > > > > > > > OK. I'm not quite sure what you mean but post them and we'll see I guess :) > > > > > > It's *roughly* the ppc64 equivalent of Josh Poimboeuf's Mar 25 > > > > > [RFC PATCH v1.9 14/14] livepatch: update task universe when exiting kernel > > > which only considers x86. > > > > > > It's forward ported from an earlier code base; there's some glue missing, > > > but here it is, for reference. > > > > > > Signed-off-by: Torsten Duwe <duwe@suse.de> > > > > Hi Torsten, > > > > Thanks for sharing. This is quite fortuitous as Miroslav just today > > mentioned to me that we would need something like this. If you don't > > mind, I may pull this patch or some variant of it into v2 of the > > consistency model. > > Well please wait for me to review & ack it before you pull it into anything > permanent. > > At a quick glance it seems OK but I'd probably do it a little differently. I'll > try and have a closer look next week. Sure, no problem. The consistency model patches are still in development so they won't be merged anytime soon. And we wouldn't merge any powerpc code without maintainer acks anyway. I'm just glad you guys are looking at it so I don't have to butcher it ;-) -- Josh
[toc] | [prev] | [next] | [standalone]
| From | Michael Ellerman <mpe@ellerman.id.au> |
|---|---|
| Date | 2016-04-15 15:30 +0200 |
| Message-ID | <robYR-3E4-7@gated-at.bofh.it> |
| In reply to | #1379797 |
On Fri, 2016-04-15 at 07:59 -0500, Josh Poimboeuf wrote: > On Fri, Apr 15, 2016 at 09:22:49PM +1000, Michael Ellerman wrote: > > On Thu, 2016-04-14 at 11:41 -0500, Josh Poimboeuf wrote: > > > On Thu, Apr 14, 2016 at 05:20:29PM +0200, Torsten Duwe wrote: > > > > On Thu, Apr 14, 2016 at 11:08:02PM +1000, Michael Ellerman wrote: > > > > > On Thu, 2016-04-14 at 14:57 +0200, Torsten Duwe wrote: > > > > > > FTR: then I still have a few ppc64 hunks floating around to support certain consistency > > > > > > models... > > > > > > > > > > OK. I'm not quite sure what you mean but post them and we'll see I guess :) > > > > > > > > It's *roughly* the ppc64 equivalent of Josh Poimboeuf's Mar 25 > > > > > [RFC PATCH v1.9 14/14] livepatch: update task universe when exiting kernel > > > > which only considers x86. > > > > > > > > It's forward ported from an earlier code base; there's some glue missing, > > > > but here it is, for reference. > > > > > > > > Signed-off-by: Torsten Duwe <duwe@suse.de> > > > > > > Hi Torsten, > > > > > > Thanks for sharing. This is quite fortuitous as Miroslav just today > > > mentioned to me that we would need something like this. If you don't > > > mind, I may pull this patch or some variant of it into v2 of the > > > consistency model. > > > > Well please wait for me to review & ack it before you pull it into anything > > permanent. > > > > At a quick glance it seems OK but I'd probably do it a little differently. I'll > > try and have a closer look next week. > > Sure, no problem. The consistency model patches are still in > development so they won't be merged anytime soon. And we wouldn't merge > any powerpc code without maintainer acks anyway. I'm just glad you guys > are looking at it so I don't have to butcher it ;-) I'm paid to butcher it ;) cheers
[toc] | [prev] | [next] | [standalone]
| From | Jiri Kosina <jikos@kernel.org> |
|---|---|
| Date | 2016-04-14 16:40 +0200 |
| Message-ID | <rnQB5-33W-41@gated-at.bofh.it> |
| In reply to | #1378813 |
On Thu, 14 Apr 2016, Torsten Duwe wrote: > > > > > It's unchanged since the version I posted on March 24, with the exception that > > > > > I've dropped the first patch, which was a testing-only patch. > > Confirmed. And it still works on top of 4.6-rc3, even with the > additional testing. Thanks a lot for testing. The imporant part here is testing on top of livepatching.git#for-4.7/arch-independent-klp-relocations as well. I am pretty sure there will be adjustments needed for the merge, as we'll have to figure out which parts of ELF can't be thrown away and need to be preserved in order for the relocation entry to be successfully constructed. Michael, I think this is an additional reason why the whole final pile will have to go through livepatching.git, as the merge with what we have in for-4.7/arch-independent-klp-relocations might not be completely trivial. -- Jiri Kosina SUSE Labs
[toc] | [prev] | [next] | [standalone]
| From | Michael Ellerman <mpe@ellerman.id.au> |
|---|---|
| Date | 2016-04-15 14:30 +0200 |
| Message-ID | <rob2O-2XS-13@gated-at.bofh.it> |
| In reply to | #1378947 |
On Thu, 2016-04-14 at 16:34 +0200, Jiri Kosina wrote: > On Thu, 14 Apr 2016, Torsten Duwe wrote: > > > > > > It's unchanged since the version I posted on March 24, with the exception that > > > > > > I've dropped the first patch, which was a testing-only patch. > > > > Confirmed. And it still works on top of 4.6-rc3, even with the > > additional testing. > > Thanks a lot for testing. > > The imporant part here is testing on top of > livepatching.git#for-4.7/arch-independent-klp-relocations as well. > > I am pretty sure there will be adjustments needed for the merge, as we'll > have to figure out which parts of ELF can't be thrown away and need to be > preserved in order for the relocation entry to be successfully > constructed. > > Michael, I think this is an additional reason why the whole final pile > will have to go through livepatching.git, as the merge with what we have > in for-4.7/arch-independent-klp-relocations might not be completely > trivial. Well it will go through both :) I'll merge it into powerpc#next, and you can merge it into livepatching and do what ever else is needed as part of, or after, that merge. cheers
[toc] | [prev] | [next] | [standalone]
| From | Jiri Kosina <jikos@kernel.org> |
|---|---|
| Date | 2016-04-15 17:10 +0200 |
| Message-ID | <rodxD-4ZA-13@gated-at.bofh.it> |
| In reply to | #1378532 |
On Thu, 14 Apr 2016, Michael Ellerman wrote: > Topic branch here: > > https://git.kernel.org/cgit/linux/kernel/git/powerpc/linux.git/log/?h=topic/livepatch > > I will merge that before Monday (my time) if I don't hear any objections. I've now pulled this into livepatching.git#for-4.7/livepatching-ppc64 and merged that branch into for-next as well. That branch already contains all the relocation changes queued for 4.7, so as much testing of the merged result as possible on ppc64 would be appreciated. Thanks everybody, -- Jiri Kosina SUSE Labs
[toc] | [prev] | [next] | [standalone]
Page 1 of 2 [1] 2 Next page →
Back to top | Article view | linux.kernel
csiph-web