linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] arm64: audit: Fix build for audit changes
@ 2014-07-17 11:26 Mark Brown
  2014-07-17 11:59 ` Catalin Marinas
                   ` (3 more replies)
  0 siblings, 4 replies; 16+ messages in thread
From: Mark Brown @ 2014-07-17 11:26 UTC (permalink / raw)
  To: linux-arm-kernel

From: Mark Brown <broonie@linaro.org>

Commit 3efe33f5d2 (audit: x86: drop arch from __audit_syscall_entry()
interface) removed the arch parameter from __audit_syscall_entry() and
updated the only current user in mainline but this breaks the ARMv8 audit
code that has been added in -next. Fix this by making the equivalent
update to ARMv8.

Signed-off-by: Mark Brown <broonie@linaro.org>
---
 arch/arm64/kernel/ptrace.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm64/kernel/ptrace.c b/arch/arm64/kernel/ptrace.c
index 70526cfda056..310842e3d477 100644
--- a/arch/arm64/kernel/ptrace.c
+++ b/arch/arm64/kernel/ptrace.c
@@ -1115,8 +1115,8 @@ asmlinkage int syscall_trace_enter(struct pt_regs *regs)
 	if (test_thread_flag(TIF_SYSCALL_TRACEPOINT))
 		trace_sys_enter(regs, regs->syscallno);
 
-	audit_syscall_entry(syscall_get_arch(), regs->syscallno,
-		regs->orig_x0, regs->regs[1], regs->regs[2], regs->regs[3]);
+	audit_syscall_entry(regs->syscallno, regs->orig_x0, regs->regs[1],
+			    regs->regs[2], regs->regs[3]);
 
 	return regs->syscallno;
 }
-- 
2.0.1

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH] arm64: audit: Fix build for audit changes
  2014-07-17 11:26 [PATCH] arm64: audit: Fix build for audit changes Mark Brown
@ 2014-07-17 11:59 ` Catalin Marinas
  2014-07-17 14:50   ` Mark Brown
  2014-07-17 16:26 ` Richard Guy Briggs
                   ` (2 subsequent siblings)
  3 siblings, 1 reply; 16+ messages in thread
From: Catalin Marinas @ 2014-07-17 11:59 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Jul 17, 2014 at 12:26:42PM +0100, Mark Brown wrote:
> From: Mark Brown <broonie@linaro.org>
> 
> Commit 3efe33f5d2 (audit: x86: drop arch from __audit_syscall_entry()
> interface) removed the arch parameter from __audit_syscall_entry() and
> updated the only current user in mainline but this breaks the ARMv8 audit
> code that has been added in -next. Fix this by making the equivalent
> update to ARMv8.
> 
> Signed-off-by: Mark Brown <broonie@linaro.org>
> ---
>  arch/arm64/kernel/ptrace.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/arch/arm64/kernel/ptrace.c b/arch/arm64/kernel/ptrace.c
> index 70526cfda056..310842e3d477 100644
> --- a/arch/arm64/kernel/ptrace.c
> +++ b/arch/arm64/kernel/ptrace.c
> @@ -1115,8 +1115,8 @@ asmlinkage int syscall_trace_enter(struct pt_regs *regs)
>  	if (test_thread_flag(TIF_SYSCALL_TRACEPOINT))
>  		trace_sys_enter(regs, regs->syscallno);
>  
> -	audit_syscall_entry(syscall_get_arch(), regs->syscallno,
> -		regs->orig_x0, regs->regs[1], regs->regs[2], regs->regs[3]);
> +	audit_syscall_entry(regs->syscallno, regs->orig_x0, regs->regs[1],
> +			    regs->regs[2], regs->regs[3]);
>  
>  	return regs->syscallno;
>  }

Thanks. This will have to be applied after 3.17-rc1 since commit
3efe33f5d2 does not seem to be in mainline yet (nor the arm64 audit
patches).

-- 
Catalin

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH] arm64: audit: Fix build for audit changes
  2014-07-17 11:59 ` Catalin Marinas
@ 2014-07-17 14:50   ` Mark Brown
  2014-07-17 14:58     ` Catalin Marinas
  0 siblings, 1 reply; 16+ messages in thread
From: Mark Brown @ 2014-07-17 14:50 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Jul 17, 2014 at 12:59:38PM +0100, Catalin Marinas wrote:
> On Thu, Jul 17, 2014 at 12:26:42PM +0100, Mark Brown wrote:

> > Commit 3efe33f5d2 (audit: x86: drop arch from __audit_syscall_entry()
> > interface) removed the arch parameter from __audit_syscall_entry() and

> Thanks. This will have to be applied after 3.17-rc1 since commit
> 3efe33f5d2 does not seem to be in mainline yet (nor the arm64 audit
> patches).

That's not great and is kind of missing the point of -next - the core
idea is to find these inter-tree dependencies, ensure things work when
they're merged together and avoid things like massive bisection breaks.
Leaving things also causes problems for anyone trying to do integration
testing on -next.

What would be better would be if we could get the two trees synced up,
in this case something like picking the audit change up in the ARMv8
tree (or vice versa) seems like it'd be quick and easy since it looks
like neither tree uses topic branches.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20140717/eb7fde8e/attachment-0001.sig>

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH] arm64: audit: Fix build for audit changes
  2014-07-17 14:50   ` Mark Brown
@ 2014-07-17 14:58     ` Catalin Marinas
  2014-07-17 15:01       ` Mark Brown
  0 siblings, 1 reply; 16+ messages in thread
From: Catalin Marinas @ 2014-07-17 14:58 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Jul 17, 2014 at 03:50:02PM +0100, Mark Brown wrote:
> On Thu, Jul 17, 2014 at 12:59:38PM +0100, Catalin Marinas wrote:
> > On Thu, Jul 17, 2014 at 12:26:42PM +0100, Mark Brown wrote:
> 
> > > Commit 3efe33f5d2 (audit: x86: drop arch from __audit_syscall_entry()
> > > interface) removed the arch parameter from __audit_syscall_entry() and
> 
> > Thanks. This will have to be applied after 3.17-rc1 since commit
> > 3efe33f5d2 does not seem to be in mainline yet (nor the arm64 audit
> > patches).
> 
> That's not great and is kind of missing the point of -next - the core
> idea is to find these inter-tree dependencies, ensure things work when
> they're merged together and avoid things like massive bisection breaks.
> Leaving things also causes problems for anyone trying to do integration
> testing on -next.
> 
> What would be better would be if we could get the two trees synced up,
> in this case something like picking the audit change up in the ARMv8
> tree (or vice versa) seems like it'd be quick and easy since it looks
> like neither tree uses topic branches.

It's not ideal indeed but applying this patch on my tree would break it.
So we need a common base where the audit API is changed, guaranteed not
to be rebased so that I can merge it in the arm64 for-next/core branch.

Do you know which tree commit 3efe33f5d2 is in? I assume some tip
branch?

-- 
Catalin

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH] arm64: audit: Fix build for audit changes
  2014-07-17 14:58     ` Catalin Marinas
@ 2014-07-17 15:01       ` Mark Brown
  0 siblings, 0 replies; 16+ messages in thread
From: Mark Brown @ 2014-07-17 15:01 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Jul 17, 2014 at 03:58:38PM +0100, Catalin Marinas wrote:
> On Thu, Jul 17, 2014 at 03:50:02PM +0100, Mark Brown wrote:

> > What would be better would be if we could get the two trees synced up,
> > in this case something like picking the audit change up in the ARMv8
> > tree (or vice versa) seems like it'd be quick and easy since it looks
> > like neither tree uses topic branches.

> It's not ideal indeed but applying this patch on my tree would break it.
> So we need a common base where the audit API is changed, guaranteed not
> to be rebased so that I can merge it in the arm64 for-next/core branch.

> Do you know which tree commit 3efe33f5d2 is in? I assume some tip
> branch?

It's the head commit in Eric's audit tree.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20140717/97456dab/attachment-0001.sig>

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH] arm64: audit: Fix build for audit changes
  2014-07-17 11:26 [PATCH] arm64: audit: Fix build for audit changes Mark Brown
  2014-07-17 11:59 ` Catalin Marinas
@ 2014-07-17 16:26 ` Richard Guy Briggs
  2014-07-24 19:12 ` Mark Brown
  2014-08-11  9:09 ` Will Deacon
  3 siblings, 0 replies; 16+ messages in thread
From: Richard Guy Briggs @ 2014-07-17 16:26 UTC (permalink / raw)
  To: linux-arm-kernel

On 14/07/17, Mark Brown wrote:
> From: Mark Brown <broonie@linaro.org>
> 
> Commit 3efe33f5d2 (audit: x86: drop arch from __audit_syscall_entry()
> interface) removed the arch parameter from __audit_syscall_entry() and
> updated the only current user in mainline but this breaks the ARMv8 audit
> code that has been added in -next. Fix this by making the equivalent
> update to ARMv8.
> 
> Signed-off-by: Mark Brown <broonie@linaro.org>

Signed-off-by: Richard Guy Briggs <rgb@redhat.com>

I'm not sure the best way to propagate this patch, but it will be
necessary.

> ---
>  arch/arm64/kernel/ptrace.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/arch/arm64/kernel/ptrace.c b/arch/arm64/kernel/ptrace.c
> index 70526cfda056..310842e3d477 100644
> --- a/arch/arm64/kernel/ptrace.c
> +++ b/arch/arm64/kernel/ptrace.c
> @@ -1115,8 +1115,8 @@ asmlinkage int syscall_trace_enter(struct pt_regs *regs)
>  	if (test_thread_flag(TIF_SYSCALL_TRACEPOINT))
>  		trace_sys_enter(regs, regs->syscallno);
>  
> -	audit_syscall_entry(syscall_get_arch(), regs->syscallno,
> -		regs->orig_x0, regs->regs[1], regs->regs[2], regs->regs[3]);
> +	audit_syscall_entry(regs->syscallno, regs->orig_x0, regs->regs[1],
> +			    regs->regs[2], regs->regs[3]);
>  
>  	return regs->syscallno;
>  }
> -- 
> 2.0.1
> 

- RGB

--
Richard Guy Briggs <rbriggs@redhat.com>
Senior Software Engineer, Kernel Security, AMER ENG Base Operating Systems, Red Hat
Remote, Ottawa, Canada
Voice: +1.647.777.2635, Internal: (81) 32635, Alt: +1.613.693.0684x3545

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH] arm64: audit: Fix build for audit changes
  2014-07-17 11:26 [PATCH] arm64: audit: Fix build for audit changes Mark Brown
  2014-07-17 11:59 ` Catalin Marinas
  2014-07-17 16:26 ` Richard Guy Briggs
@ 2014-07-24 19:12 ` Mark Brown
  2014-07-25  9:21   ` Catalin Marinas
  2014-08-11  9:09 ` Will Deacon
  3 siblings, 1 reply; 16+ messages in thread
From: Mark Brown @ 2014-07-24 19:12 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Jul 17, 2014 at 12:26:42PM +0100, Mark Brown wrote:
> From: Mark Brown <broonie@linaro.org>
> 
> Commit 3efe33f5d2 (audit: x86: drop arch from __audit_syscall_entry()
> interface) removed the arch parameter from __audit_syscall_entry() and
> updated the only current user in mainline but this breaks the ARMv8 audit
> code that has been added in -next. Fix this by making the equivalent
> update to ARMv8.

This is still broken -next.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20140724/e5e74e46/attachment.sig>

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH] arm64: audit: Fix build for audit changes
  2014-07-24 19:12 ` Mark Brown
@ 2014-07-25  9:21   ` Catalin Marinas
  2014-07-25 11:04     ` Mark Brown
  0 siblings, 1 reply; 16+ messages in thread
From: Catalin Marinas @ 2014-07-25  9:21 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Jul 24, 2014 at 08:12:37PM +0100, Mark Brown wrote:
> On Thu, Jul 17, 2014 at 12:26:42PM +0100, Mark Brown wrote:
> > From: Mark Brown <broonie@linaro.org>
> > 
> > Commit 3efe33f5d2 (audit: x86: drop arch from __audit_syscall_entry()
> > interface) removed the arch parameter from __audit_syscall_entry() and
> > updated the only current user in mainline but this breaks the ARMv8 audit
> > code that has been added in -next. Fix this by making the equivalent
> > update to ARMv8.
> 
> This is still broken -next.

It should now be temporarily fixed for the defconfig
(CONFIG_AUTIDSYSCALL disabled). I'm reluctant to merge the audit tree in
the arm64 tree as (a) I haven't seen a confirmation that this branch is
stable and will go upstream as is and (b) there are x86 changes without
Acks from the x86 maintainers (whether needed or not, I can't say).

So my temporary patch is some #ifndef's around the offending code. It
will be reverted and your patch applied once the audit tree meets the
arm64 tree.

-- 
Catalin

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH] arm64: audit: Fix build for audit changes
  2014-07-25  9:21   ` Catalin Marinas
@ 2014-07-25 11:04     ` Mark Brown
  0 siblings, 0 replies; 16+ messages in thread
From: Mark Brown @ 2014-07-25 11:04 UTC (permalink / raw)
  To: linux-arm-kernel

On Fri, Jul 25, 2014 at 10:21:09AM +0100, Catalin Marinas wrote:
> On Thu, Jul 24, 2014 at 08:12:37PM +0100, Mark Brown wrote:

> > This is still broken -next.

> It should now be temporarily fixed for the defconfig
> (CONFIG_AUTIDSYSCALL disabled). I'm reluctant to merge the audit tree in
> the arm64 tree as (a) I haven't seen a confirmation that this branch is
> stable and will go upstream as is and (b) there are x86 changes without
> Acks from the x86 maintainers (whether needed or not, I can't say).

I'd not expect it to be essential, it's just a function prototype
change.

> So my temporary patch is some #ifndef's around the offending code. It
> will be reverted and your patch applied once the audit tree meets the
> arm64 tree.

That's good thanks, though it's still going to mean we have massive
bisection breaks and anyone with an existing config will run into
trouble - I'm going to be adding all*config builds to my daily tests
soon too which will still trigger the issue).  

I suspect the easiest thing would be to cherry pick the commit over (it
can always be reverted later on if there's an issue) if a shared branch
can't be arranged.  It's a real shame Eric hasn't replied here...
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20140725/7967cc6d/attachment.sig>

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH] arm64: audit: Fix build for audit changes
  2014-07-17 11:26 [PATCH] arm64: audit: Fix build for audit changes Mark Brown
                   ` (2 preceding siblings ...)
  2014-07-24 19:12 ` Mark Brown
@ 2014-08-11  9:09 ` Will Deacon
  2014-08-11 13:22   ` Eric Paris
  3 siblings, 1 reply; 16+ messages in thread
From: Will Deacon @ 2014-08-11  9:09 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Jul 17, 2014 at 12:26:42PM +0100, Mark Brown wrote:
> From: Mark Brown <broonie@linaro.org>
> 
> Commit 3efe33f5d2 (audit: x86: drop arch from __audit_syscall_entry()
> interface) removed the arch parameter from __audit_syscall_entry() and
> updated the only current user in mainline but this breaks the ARMv8 audit
> code that has been added in -next. Fix this by making the equivalent
> update to ARMv8.
> 
> Signed-off-by: Mark Brown <broonie@linaro.org>
> ---
>  arch/arm64/kernel/ptrace.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/arch/arm64/kernel/ptrace.c b/arch/arm64/kernel/ptrace.c
> index 70526cfda056..310842e3d477 100644
> --- a/arch/arm64/kernel/ptrace.c
> +++ b/arch/arm64/kernel/ptrace.c
> @@ -1115,8 +1115,8 @@ asmlinkage int syscall_trace_enter(struct pt_regs *regs)
>  	if (test_thread_flag(TIF_SYSCALL_TRACEPOINT))
>  		trace_sys_enter(regs, regs->syscallno);
>  
> -	audit_syscall_entry(syscall_get_arch(), regs->syscallno,
> -		regs->orig_x0, regs->regs[1], regs->regs[2], regs->regs[3]);
> +	audit_syscall_entry(regs->syscallno, regs->orig_x0, regs->regs[1],
> +			    regs->regs[2], regs->regs[3]);

Eric, Richard: when is 3efe33f5d2 ("audit: x86: drop arch from
__audit_syscall_entry() interface") going to hit mainline? I've been holding
off this fix until the offending commit is merged, but if that's not going
to happen for 3.17, then we probably need to do something else to fix -next.

Will

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH] arm64: audit: Fix build for audit changes
  2014-08-11  9:09 ` Will Deacon
@ 2014-08-11 13:22   ` Eric Paris
  2014-08-11 13:33     ` Will Deacon
  0 siblings, 1 reply; 16+ messages in thread
From: Eric Paris @ 2014-08-11 13:22 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, 2014-08-11 at 10:09 +0100, Will Deacon wrote:
> On Thu, Jul 17, 2014 at 12:26:42PM +0100, Mark Brown wrote:
> > From: Mark Brown <broonie@linaro.org>
> > 
> > Commit 3efe33f5d2 (audit: x86: drop arch from __audit_syscall_entry()
> > interface) removed the arch parameter from __audit_syscall_entry() and
> > updated the only current user in mainline but this breaks the ARMv8 audit
> > code that has been added in -next. Fix this by making the equivalent
> > update to ARMv8.
> > 
> > Signed-off-by: Mark Brown <broonie@linaro.org>
> > ---
> >  arch/arm64/kernel/ptrace.c | 4 ++--
> >  1 file changed, 2 insertions(+), 2 deletions(-)
> > 
> > diff --git a/arch/arm64/kernel/ptrace.c b/arch/arm64/kernel/ptrace.c
> > index 70526cfda056..310842e3d477 100644
> > --- a/arch/arm64/kernel/ptrace.c
> > +++ b/arch/arm64/kernel/ptrace.c
> > @@ -1115,8 +1115,8 @@ asmlinkage int syscall_trace_enter(struct pt_regs *regs)
> >  	if (test_thread_flag(TIF_SYSCALL_TRACEPOINT))
> >  		trace_sys_enter(regs, regs->syscallno);
> >  
> > -	audit_syscall_entry(syscall_get_arch(), regs->syscallno,
> > -		regs->orig_x0, regs->regs[1], regs->regs[2], regs->regs[3]);
> > +	audit_syscall_entry(regs->syscallno, regs->orig_x0, regs->regs[1],
> > +			    regs->regs[2], regs->regs[3]);
> 
> Eric, Richard: when is 3efe33f5d2 ("audit: x86: drop arch from
> __audit_syscall_entry() interface") going to hit mainline? I've been holding
> off this fix until the offending commit is merged, but if that's not going
> to happen for 3.17, then we probably need to do something else to fix -next.

I think I'm being lazy this window and not oging to send a pull.  So
I'll pick up this fix as soon as rc1 cuts in my tree.

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH] arm64: audit: Fix build for audit changes
  2014-08-11 13:22   ` Eric Paris
@ 2014-08-11 13:33     ` Will Deacon
  2014-08-11 15:15       ` Catalin Marinas
  0 siblings, 1 reply; 16+ messages in thread
From: Will Deacon @ 2014-08-11 13:33 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, Aug 11, 2014 at 02:22:24PM +0100, Eric Paris wrote:
> On Mon, 2014-08-11 at 10:09 +0100, Will Deacon wrote:
> > On Thu, Jul 17, 2014 at 12:26:42PM +0100, Mark Brown wrote:
> > > From: Mark Brown <broonie@linaro.org>
> > > 
> > > Commit 3efe33f5d2 (audit: x86: drop arch from __audit_syscall_entry()
> > > interface) removed the arch parameter from __audit_syscall_entry() and
> > > updated the only current user in mainline but this breaks the ARMv8 audit
> > > code that has been added in -next. Fix this by making the equivalent
> > > update to ARMv8.
> > > 
> > > Signed-off-by: Mark Brown <broonie@linaro.org>
> > > ---
> > >  arch/arm64/kernel/ptrace.c | 4 ++--
> > >  1 file changed, 2 insertions(+), 2 deletions(-)
> > > 
> > > diff --git a/arch/arm64/kernel/ptrace.c b/arch/arm64/kernel/ptrace.c
> > > index 70526cfda056..310842e3d477 100644
> > > --- a/arch/arm64/kernel/ptrace.c
> > > +++ b/arch/arm64/kernel/ptrace.c
> > > @@ -1115,8 +1115,8 @@ asmlinkage int syscall_trace_enter(struct pt_regs *regs)
> > >  	if (test_thread_flag(TIF_SYSCALL_TRACEPOINT))
> > >  		trace_sys_enter(regs, regs->syscallno);
> > >  
> > > -	audit_syscall_entry(syscall_get_arch(), regs->syscallno,
> > > -		regs->orig_x0, regs->regs[1], regs->regs[2], regs->regs[3]);
> > > +	audit_syscall_entry(regs->syscallno, regs->orig_x0, regs->regs[1],
> > > +			    regs->regs[2], regs->regs[3]);
> > 
> > Eric, Richard: when is 3efe33f5d2 ("audit: x86: drop arch from
> > __audit_syscall_entry() interface") going to hit mainline? I've been holding
> > off this fix until the offending commit is merged, but if that's not going
> > to happen for 3.17, then we probably need to do something else to fix -next.
> 
> I think I'm being lazy this window and not oging to send a pull.  So
> I'll pick up this fix as soon as rc1 cuts in my tree.

Oh, alright then. If you're not going to send the code for mainline, you
could also just drop it from -next ;)

Anyway, if you do fix it, please let me know so that I can remove our #ifdef
CONFIG_AUDITSYSCALL guards (which only exist to stop build breakage in -next
with defconfig).

Will

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH] arm64: audit: Fix build for audit changes
  2014-08-11 13:33     ` Will Deacon
@ 2014-08-11 15:15       ` Catalin Marinas
  2014-08-11 15:47         ` Will Deacon
  0 siblings, 1 reply; 16+ messages in thread
From: Catalin Marinas @ 2014-08-11 15:15 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, Aug 11, 2014 at 02:33:38PM +0100, Will Deacon wrote:
> On Mon, Aug 11, 2014 at 02:22:24PM +0100, Eric Paris wrote:
> > On Mon, 2014-08-11 at 10:09 +0100, Will Deacon wrote:
> > > On Thu, Jul 17, 2014 at 12:26:42PM +0100, Mark Brown wrote:
> > > > From: Mark Brown <broonie@linaro.org>
> > > > 
> > > > Commit 3efe33f5d2 (audit: x86: drop arch from __audit_syscall_entry()
> > > > interface) removed the arch parameter from __audit_syscall_entry() and
> > > > updated the only current user in mainline but this breaks the ARMv8 audit
> > > > code that has been added in -next. Fix this by making the equivalent
> > > > update to ARMv8.
> > > > 
> > > > Signed-off-by: Mark Brown <broonie@linaro.org>
> > > > ---
> > > >  arch/arm64/kernel/ptrace.c | 4 ++--
> > > >  1 file changed, 2 insertions(+), 2 deletions(-)
> > > > 
> > > > diff --git a/arch/arm64/kernel/ptrace.c b/arch/arm64/kernel/ptrace.c
> > > > index 70526cfda056..310842e3d477 100644
> > > > --- a/arch/arm64/kernel/ptrace.c
> > > > +++ b/arch/arm64/kernel/ptrace.c
> > > > @@ -1115,8 +1115,8 @@ asmlinkage int syscall_trace_enter(struct pt_regs *regs)
> > > >  	if (test_thread_flag(TIF_SYSCALL_TRACEPOINT))
> > > >  		trace_sys_enter(regs, regs->syscallno);
> > > >  
> > > > -	audit_syscall_entry(syscall_get_arch(), regs->syscallno,
> > > > -		regs->orig_x0, regs->regs[1], regs->regs[2], regs->regs[3]);
> > > > +	audit_syscall_entry(regs->syscallno, regs->orig_x0, regs->regs[1],
> > > > +			    regs->regs[2], regs->regs[3]);
> > > 
> > > Eric, Richard: when is 3efe33f5d2 ("audit: x86: drop arch from
> > > __audit_syscall_entry() interface") going to hit mainline? I've been holding
> > > off this fix until the offending commit is merged, but if that's not going
> > > to happen for 3.17, then we probably need to do something else to fix -next.
> > 
> > I think I'm being lazy this window and not oging to send a pull.  So
> > I'll pick up this fix as soon as rc1 cuts in my tree.
> 
> Oh, alright then. If you're not going to send the code for mainline, you
> could also just drop it from -next ;)
> 
> Anyway, if you do fix it, please let me know so that I can remove our #ifdef
> CONFIG_AUDITSYSCALL guards (which only exist to stop build breakage in -next
> with defconfig).

Actually, Eric could carry the arm64 change from Mark into -next as well
and we can drop the arm64 #ifdef before the API change hits mainline.

-- 
Catalin

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH] arm64: audit: Fix build for audit changes
  2014-08-11 15:15       ` Catalin Marinas
@ 2014-08-11 15:47         ` Will Deacon
  0 siblings, 0 replies; 16+ messages in thread
From: Will Deacon @ 2014-08-11 15:47 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, Aug 11, 2014 at 04:15:02PM +0100, Catalin Marinas wrote:
> On Mon, Aug 11, 2014 at 02:33:38PM +0100, Will Deacon wrote:
> > On Mon, Aug 11, 2014 at 02:22:24PM +0100, Eric Paris wrote:
> > > On Mon, 2014-08-11 at 10:09 +0100, Will Deacon wrote:
> > > > On Thu, Jul 17, 2014 at 12:26:42PM +0100, Mark Brown wrote:
> > > > > From: Mark Brown <broonie@linaro.org>
> > > > > 
> > > > > Commit 3efe33f5d2 (audit: x86: drop arch from __audit_syscall_entry()
> > > > > interface) removed the arch parameter from __audit_syscall_entry() and
> > > > > updated the only current user in mainline but this breaks the ARMv8 audit
> > > > > code that has been added in -next. Fix this by making the equivalent
> > > > > update to ARMv8.
> > > > > 
> > > > > Signed-off-by: Mark Brown <broonie@linaro.org>
> > > > > ---
> > > > >  arch/arm64/kernel/ptrace.c | 4 ++--
> > > > >  1 file changed, 2 insertions(+), 2 deletions(-)
> > > > > 
> > > > > diff --git a/arch/arm64/kernel/ptrace.c b/arch/arm64/kernel/ptrace.c
> > > > > index 70526cfda056..310842e3d477 100644
> > > > > --- a/arch/arm64/kernel/ptrace.c
> > > > > +++ b/arch/arm64/kernel/ptrace.c
> > > > > @@ -1115,8 +1115,8 @@ asmlinkage int syscall_trace_enter(struct pt_regs *regs)
> > > > >  	if (test_thread_flag(TIF_SYSCALL_TRACEPOINT))
> > > > >  		trace_sys_enter(regs, regs->syscallno);
> > > > >  
> > > > > -	audit_syscall_entry(syscall_get_arch(), regs->syscallno,
> > > > > -		regs->orig_x0, regs->regs[1], regs->regs[2], regs->regs[3]);
> > > > > +	audit_syscall_entry(regs->syscallno, regs->orig_x0, regs->regs[1],
> > > > > +			    regs->regs[2], regs->regs[3]);
> > > > 
> > > > Eric, Richard: when is 3efe33f5d2 ("audit: x86: drop arch from
> > > > __audit_syscall_entry() interface") going to hit mainline? I've been holding
> > > > off this fix until the offending commit is merged, but if that's not going
> > > > to happen for 3.17, then we probably need to do something else to fix -next.
> > > 
> > > I think I'm being lazy this window and not oging to send a pull.  So
> > > I'll pick up this fix as soon as rc1 cuts in my tree.
> > 
> > Oh, alright then. If you're not going to send the code for mainline, you
> > could also just drop it from -next ;)
> > 
> > Anyway, if you do fix it, please let me know so that I can remove our #ifdef
> > CONFIG_AUDITSYSCALL guards (which only exist to stop build breakage in -next
> > with defconfig).
> 
> Actually, Eric could carry the arm64 change from Mark into -next as well
> and we can drop the arm64 #ifdef before the API change hits mainline.

Indeed -- I think that's what we'd agreed, right?

Will

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH] arm64: audit: Fix build for audit changes
  2014-08-17 14:26 Mark Brown
@ 2014-08-18 16:40 ` Catalin Marinas
  0 siblings, 0 replies; 16+ messages in thread
From: Catalin Marinas @ 2014-08-18 16:40 UTC (permalink / raw)
  To: linux-arm-kernel

On Sun, Aug 17, 2014 at 03:26:37PM +0100, Mark Brown wrote:
> From: Mark Brown <broonie@linaro.org>
> 
> Commit 3efe33f5d2 (audit: x86: drop arch from __audit_syscall_entry()
> interface) removed the arch parameter from __audit_syscall_entry() and
> updated the only current user in mainline but this breaks the ARMv8 audit
> code that has been added in -next. Fix this by making the equivalent
> update to ARMv8.
> 
> Signed-off-by: Mark Brown <broonie@linaro.org>

Acked-by: Catalin Marinas <catalin.marinas@arm.com>

BTW, we plan to revert the temporary hack to avoid this error with
defconfig. So the above patch should go into next on top of the other
patches from Eric changing the function prototype.

Thanks,

Catalin

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH] arm64: audit: Fix build for audit changes
@ 2014-08-17 14:26 Mark Brown
  2014-08-18 16:40 ` Catalin Marinas
  0 siblings, 1 reply; 16+ messages in thread
From: Mark Brown @ 2014-08-17 14:26 UTC (permalink / raw)
  To: linux-arm-kernel

From: Mark Brown <broonie@linaro.org>

Commit 3efe33f5d2 (audit: x86: drop arch from __audit_syscall_entry()
interface) removed the arch parameter from __audit_syscall_entry() and
updated the only current user in mainline but this breaks the ARMv8 audit
code that has been added in -next. Fix this by making the equivalent
update to ARMv8.

Signed-off-by: Mark Brown <broonie@linaro.org>
---

Now -rc1 is out this should be applied to the audit tree (or squashed
into the commit above) - the arm64 audit support is in mainline now and
-next is failing to build arm64 due to this.

 arch/arm64/kernel/ptrace.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm64/kernel/ptrace.c b/arch/arm64/kernel/ptrace.c
index 0310811..159251f 100644
--- a/arch/arm64/kernel/ptrace.c
+++ b/arch/arm64/kernel/ptrace.c
@@ -1116,8 +1116,8 @@ asmlinkage int syscall_trace_enter(struct pt_regs *regs)
 		trace_sys_enter(regs, regs->syscallno);
 
 #ifdef CONFIG_AUDITSYSCALL
-	audit_syscall_entry(syscall_get_arch(), regs->syscallno,
-		regs->orig_x0, regs->regs[1], regs->regs[2], regs->regs[3]);
+	audit_syscall_entry(regs->syscallno, regs->orig_x0, regs->regs[1],
+			    regs->regs[2], regs->regs[3]);
 #endif
 
 	return regs->syscallno;
-- 
2.1.0.rc1

^ permalink raw reply related	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2014-08-18 16:40 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-07-17 11:26 [PATCH] arm64: audit: Fix build for audit changes Mark Brown
2014-07-17 11:59 ` Catalin Marinas
2014-07-17 14:50   ` Mark Brown
2014-07-17 14:58     ` Catalin Marinas
2014-07-17 15:01       ` Mark Brown
2014-07-17 16:26 ` Richard Guy Briggs
2014-07-24 19:12 ` Mark Brown
2014-07-25  9:21   ` Catalin Marinas
2014-07-25 11:04     ` Mark Brown
2014-08-11  9:09 ` Will Deacon
2014-08-11 13:22   ` Eric Paris
2014-08-11 13:33     ` Will Deacon
2014-08-11 15:15       ` Catalin Marinas
2014-08-11 15:47         ` Will Deacon
2014-08-17 14:26 Mark Brown
2014-08-18 16:40 ` Catalin Marinas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).