Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1670266 > unrolled thread
| Started by | Stephen Rothwell <sfr@canb.auug.org.au> |
|---|---|
| First post | 2017-06-20 07:00 +0200 |
| Last post | 2017-06-28 07:50 +0200 |
| Articles | 8 — 4 participants |
Back to article view | Back to linux.kernel
linux-next: build failure after merge of the kspp tree Stephen Rothwell <sfr@canb.auug.org.au> - 2017-06-20 07:00 +0200
Re: linux-next: build failure after merge of the kspp tree Kees Cook <keescook@google.com> - 2017-06-20 07:40 +0200
Re: linux-next: build failure after merge of the kspp tree John Johansen <john.johansen@canonical.com> - 2017-06-20 07:50 +0200
Re: linux-next: build failure after merge of the kspp tree John Johansen <john.johansen@canonical.com> - 2017-06-20 07:50 +0200
Re: linux-next: build failure after merge of the kspp tree Kees Cook <keescook@google.com> - 2017-06-26 20:20 +0200
Re: linux-next: build failure after merge of the kspp tree James Morris <jmorris@namei.org> - 2017-06-27 05:40 +0200
Re: linux-next: build failure after merge of the kspp tree Kees Cook <keescook@google.com> - 2017-06-28 00:20 +0200
Re: linux-next: build failure after merge of the kspp tree James Morris <jmorris@namei.org> - 2017-06-28 07:50 +0200
| From | Stephen Rothwell <sfr@canb.auug.org.au> |
|---|---|
| Date | 2017-06-20 07:00 +0200 |
| Subject | linux-next: build failure after merge of the kspp tree |
| Message-ID | <tUjqF-3YW-1@gated-at.bofh.it> |
Hi all,
After merging the kspp tree, today's linux-next build (x86_64
allmodconfig) failed like this:
security/apparmor/file.c: In function 'aa_path_link':
security/apparmor/file.c:475:23: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
struct path link = { new_dir->mnt, new_dentry };
^
security/apparmor/file.c:475:23: note: (near initialization for 'link')
security/apparmor/file.c:475:37: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
struct path link = { new_dir->mnt, new_dentry };
^
security/apparmor/file.c:475:37: note: (near initialization for 'link')
security/apparmor/file.c:476:25: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
struct path target = { new_dir->mnt, old_dentry };
^
security/apparmor/file.c:476:25: note: (near initialization for 'target')
security/apparmor/file.c:476:39: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
struct path target = { new_dir->mnt, old_dentry };
^
security/apparmor/file.c:476:39: note: (near initialization for 'target')
Caused by commit
1a12979f61e4 ("randstruct: Mark various structs for randomization")
interacting with commit
8014370f1257 ("apparmor: move path_link mediation to using labels")
from the security tree.
I added the following merge fix patch for today:
From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Tue, 20 Jun 2017 14:50:36 +1000
Subject: [PATCH] apparmor: put back designators in struct initialisers
Fixes: 8014370f1257 ("apparmor: move path_link mediation to using labels")
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
security/apparmor/file.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/security/apparmor/file.c b/security/apparmor/file.c
index b6e8e5b11e05..3382518b87fa 100644
--- a/security/apparmor/file.c
+++ b/security/apparmor/file.c
@@ -472,8 +472,8 @@ static int profile_path_link(struct aa_profile *profile,
int aa_path_link(struct aa_label *label, struct dentry *old_dentry,
const struct path *new_dir, struct dentry *new_dentry)
{
- struct path link = { new_dir->mnt, new_dentry };
- struct path target = { new_dir->mnt, old_dentry };
+ struct path link = { .mnt = new_dir->mnt, .dentry = new_dentry };
+ struct path target = { .mnt = new_dir->mnt, .dentry = old_dentry };
struct path_cond cond = {
d_backing_inode(old_dentry)->i_uid,
d_backing_inode(old_dentry)->i_mode
--
2.11.0
--
Cheers,
Stephen Rothwell
[toc] | [next] | [standalone]
| From | Kees Cook <keescook@google.com> |
|---|---|
| Date | 2017-06-20 07:40 +0200 |
| Message-ID | <tUk3o-4sK-13@gated-at.bofh.it> |
| In reply to | #1670266 |
On Mon, Jun 19, 2017 at 9:56 PM, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> Hi all,
>
> After merging the kspp tree, today's linux-next build (x86_64
> allmodconfig) failed like this:
>
> security/apparmor/file.c: In function 'aa_path_link':
> security/apparmor/file.c:475:23: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
> struct path link = { new_dir->mnt, new_dentry };
> ^
> security/apparmor/file.c:475:23: note: (near initialization for 'link')
> security/apparmor/file.c:475:37: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
> struct path link = { new_dir->mnt, new_dentry };
> ^
> security/apparmor/file.c:475:37: note: (near initialization for 'link')
> security/apparmor/file.c:476:25: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
> struct path target = { new_dir->mnt, old_dentry };
> ^
> security/apparmor/file.c:476:25: note: (near initialization for 'target')
> security/apparmor/file.c:476:39: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
> struct path target = { new_dir->mnt, old_dentry };
> ^
> security/apparmor/file.c:476:39: note: (near initialization for 'target')
>
> Caused by commit
>
> 1a12979f61e4 ("randstruct: Mark various structs for randomization")
>
> interacting with commit
>
> 8014370f1257 ("apparmor: move path_link mediation to using labels")
>
> from the security tree.
>
> I added the following merge fix patch for today:
>
> From: Stephen Rothwell <sfr@canb.auug.org.au>
> Date: Tue, 20 Jun 2017 14:50:36 +1000
> Subject: [PATCH] apparmor: put back designators in struct initialisers
>
> Fixes: 8014370f1257 ("apparmor: move path_link mediation to using labels")
> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> ---
> security/apparmor/file.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/security/apparmor/file.c b/security/apparmor/file.c
> index b6e8e5b11e05..3382518b87fa 100644
> --- a/security/apparmor/file.c
> +++ b/security/apparmor/file.c
> @@ -472,8 +472,8 @@ static int profile_path_link(struct aa_profile *profile,
> int aa_path_link(struct aa_label *label, struct dentry *old_dentry,
> const struct path *new_dir, struct dentry *new_dentry)
> {
> - struct path link = { new_dir->mnt, new_dentry };
> - struct path target = { new_dir->mnt, old_dentry };
> + struct path link = { .mnt = new_dir->mnt, .dentry = new_dentry };
> + struct path target = { .mnt = new_dir->mnt, .dentry = old_dentry };
> struct path_cond cond = {
> d_backing_inode(old_dentry)->i_uid,
> d_backing_inode(old_dentry)->i_mode
> --
> 2.11.0
Thanks for the fix! That looks correct to me. It seems the refactoring
in 8014370f1257 ("apparmor: move path_link mediation to using labels")
didn't take 8486adf0d755 ("apparmor: use designated initializers")
into account. John, if this looks okay, can you Ack it for James to
carry in security-next?
-Kees
--
Kees Cook
Pixel Security
[toc] | [prev] | [next] | [standalone]
| From | John Johansen <john.johansen@canonical.com> |
|---|---|
| Date | 2017-06-20 07:50 +0200 |
| Message-ID | <tUkd4-4w2-19@gated-at.bofh.it> |
| In reply to | #1670298 |
On 06/19/2017 10:39 PM, Kees Cook wrote:
> On Mon, Jun 19, 2017 at 9:56 PM, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>> Hi all,
>>
>> After merging the kspp tree, today's linux-next build (x86_64
>> allmodconfig) failed like this:
>>
>> security/apparmor/file.c: In function 'aa_path_link':
>> security/apparmor/file.c:475:23: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
>> struct path link = { new_dir->mnt, new_dentry };
>> ^
>> security/apparmor/file.c:475:23: note: (near initialization for 'link')
>> security/apparmor/file.c:475:37: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
>> struct path link = { new_dir->mnt, new_dentry };
>> ^
>> security/apparmor/file.c:475:37: note: (near initialization for 'link')
>> security/apparmor/file.c:476:25: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
>> struct path target = { new_dir->mnt, old_dentry };
>> ^
>> security/apparmor/file.c:476:25: note: (near initialization for 'target')
>> security/apparmor/file.c:476:39: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
>> struct path target = { new_dir->mnt, old_dentry };
>> ^
>> security/apparmor/file.c:476:39: note: (near initialization for 'target')
>>
>> Caused by commit
>>
>> 1a12979f61e4 ("randstruct: Mark various structs for randomization")
>>
>> interacting with commit
>>
>> 8014370f1257 ("apparmor: move path_link mediation to using labels")
>>
>> from the security tree.
>>
>> I added the following merge fix patch for today:
>>
>> From: Stephen Rothwell <sfr@canb.auug.org.au>
>> Date: Tue, 20 Jun 2017 14:50:36 +1000
>> Subject: [PATCH] apparmor: put back designators in struct initialisers
>>
>> Fixes: 8014370f1257 ("apparmor: move path_link mediation to using labels")
>> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
>> ---
>> security/apparmor/file.c | 4 ++--
>> 1 file changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/security/apparmor/file.c b/security/apparmor/file.c
>> index b6e8e5b11e05..3382518b87fa 100644
>> --- a/security/apparmor/file.c
>> +++ b/security/apparmor/file.c
>> @@ -472,8 +472,8 @@ static int profile_path_link(struct aa_profile *profile,
>> int aa_path_link(struct aa_label *label, struct dentry *old_dentry,
>> const struct path *new_dir, struct dentry *new_dentry)
>> {
>> - struct path link = { new_dir->mnt, new_dentry };
>> - struct path target = { new_dir->mnt, old_dentry };
>> + struct path link = { .mnt = new_dir->mnt, .dentry = new_dentry };
>> + struct path target = { .mnt = new_dir->mnt, .dentry = old_dentry };
>> struct path_cond cond = {
>> d_backing_inode(old_dentry)->i_uid,
>> d_backing_inode(old_dentry)->i_mode
>> --
>> 2.11.0
>
> Thanks for the fix! That looks correct to me. It seems the refactoring
> in 8014370f1257 ("apparmor: move path_link mediation to using labels")
> didn't take 8486adf0d755 ("apparmor: use designated initializers")
> into account. John, if this looks okay, can you Ack it for James to
> carry in security-next?
>
yep, already done. Sorry I missed that one :(
[toc] | [prev] | [next] | [standalone]
| From | John Johansen <john.johansen@canonical.com> |
|---|---|
| Date | 2017-06-20 07:50 +0200 |
| Message-ID | <tUkd5-4w2-29@gated-at.bofh.it> |
| In reply to | #1670266 |
On 06/19/2017 09:56 PM, Stephen Rothwell wrote:
> Hi all,
>
> After merging the kspp tree, today's linux-next build (x86_64
> allmodconfig) failed like this:
>
> security/apparmor/file.c: In function 'aa_path_link':
> security/apparmor/file.c:475:23: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
> struct path link = { new_dir->mnt, new_dentry };
> ^
> security/apparmor/file.c:475:23: note: (near initialization for 'link')
> security/apparmor/file.c:475:37: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
> struct path link = { new_dir->mnt, new_dentry };
> ^
> security/apparmor/file.c:475:37: note: (near initialization for 'link')
> security/apparmor/file.c:476:25: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
> struct path target = { new_dir->mnt, old_dentry };
> ^
> security/apparmor/file.c:476:25: note: (near initialization for 'target')
> security/apparmor/file.c:476:39: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
> struct path target = { new_dir->mnt, old_dentry };
> ^
> security/apparmor/file.c:476:39: note: (near initialization for 'target')
>
> Caused by commit
>
> 1a12979f61e4 ("randstruct: Mark various structs for randomization")
>
> interacting with commit
>
> 8014370f1257 ("apparmor: move path_link mediation to using labels")
>
> from the security tree.
>
> I added the following merge fix patch for today:
>
> From: Stephen Rothwell <sfr@canb.auug.org.au>
> Date: Tue, 20 Jun 2017 14:50:36 +1000
> Subject: [PATCH] apparmor: put back designators in struct initialisers
>
> Fixes: 8014370f1257 ("apparmor: move path_link mediation to using labels")
> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Acked-by: John Johansen <john.johansen@canonical.com>
> ---
> security/apparmor/file.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/security/apparmor/file.c b/security/apparmor/file.c
> index b6e8e5b11e05..3382518b87fa 100644
> --- a/security/apparmor/file.c
> +++ b/security/apparmor/file.c
> @@ -472,8 +472,8 @@ static int profile_path_link(struct aa_profile *profile,
> int aa_path_link(struct aa_label *label, struct dentry *old_dentry,
> const struct path *new_dir, struct dentry *new_dentry)
> {
> - struct path link = { new_dir->mnt, new_dentry };
> - struct path target = { new_dir->mnt, old_dentry };
> + struct path link = { .mnt = new_dir->mnt, .dentry = new_dentry };
> + struct path target = { .mnt = new_dir->mnt, .dentry = old_dentry };
> struct path_cond cond = {
> d_backing_inode(old_dentry)->i_uid,
> d_backing_inode(old_dentry)->i_mode
>
[toc] | [prev] | [next] | [standalone]
| From | Kees Cook <keescook@google.com> |
|---|---|
| Date | 2017-06-26 20:20 +0200 |
| Message-ID | <tWGMa-5KY-11@gated-at.bofh.it> |
| In reply to | #1670307 |
On Mon, Jun 19, 2017 at 10:39 PM, John Johansen
<john.johansen@canonical.com> wrote:
> On 06/19/2017 09:56 PM, Stephen Rothwell wrote:
>> Hi all,
>>
>> After merging the kspp tree, today's linux-next build (x86_64
>> allmodconfig) failed like this:
>>
>> security/apparmor/file.c: In function 'aa_path_link':
>> security/apparmor/file.c:475:23: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
>> struct path link = { new_dir->mnt, new_dentry };
>> ^
>> security/apparmor/file.c:475:23: note: (near initialization for 'link')
>> security/apparmor/file.c:475:37: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
>> struct path link = { new_dir->mnt, new_dentry };
>> ^
>> security/apparmor/file.c:475:37: note: (near initialization for 'link')
>> security/apparmor/file.c:476:25: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
>> struct path target = { new_dir->mnt, old_dentry };
>> ^
>> security/apparmor/file.c:476:25: note: (near initialization for 'target')
>> security/apparmor/file.c:476:39: error: positional initialization of field in 'struct' declared with 'designated_init' attribute [-Werror=designated-init]
>> struct path target = { new_dir->mnt, old_dentry };
>> ^
>> security/apparmor/file.c:476:39: note: (near initialization for 'target')
>>
>> Caused by commit
>>
>> 1a12979f61e4 ("randstruct: Mark various structs for randomization")
>>
>> interacting with commit
>>
>> 8014370f1257 ("apparmor: move path_link mediation to using labels")
>>
>> from the security tree.
>>
>> I added the following merge fix patch for today:
>>
>> From: Stephen Rothwell <sfr@canb.auug.org.au>
>> Date: Tue, 20 Jun 2017 14:50:36 +1000
>> Subject: [PATCH] apparmor: put back designators in struct initialisers
>>
>> Fixes: 8014370f1257 ("apparmor: move path_link mediation to using labels")
>> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> Acked-by: John Johansen <john.johansen@canonical.com>
Hi James,
Just a ping; this needs to get into -next to avoid build errors.
Please consider it also:
Acked-by: Kees Cook <keescook@chromium.org>
Thanks!
-Kees
--
Kees Cook
Pixel Security
[toc] | [prev] | [next] | [standalone]
| From | James Morris <jmorris@namei.org> |
|---|---|
| Date | 2017-06-27 05:40 +0200 |
| Message-ID | <tWPw5-37c-1@gated-at.bofh.it> |
| In reply to | #1674987 |
On Mon, 26 Jun 2017, Kees Cook wrote:
> >> Fixes: 8014370f1257 ("apparmor: move path_link mediation to using labels")
> >> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> > Acked-by: John Johansen <john.johansen@canonical.com>
>
> Hi James,
>
> Just a ping; this needs to get into -next to avoid build errors.
Surely Linus will resolve this when he pulls the trees in?
--
James Morris
<jmorris@namei.org>
[toc] | [prev] | [next] | [standalone]
| From | Kees Cook <keescook@google.com> |
|---|---|
| Date | 2017-06-28 00:20 +0200 |
| Message-ID | <tX6ZY-6Ou-17@gated-at.bofh.it> |
| In reply to | #1675270 |
On Mon, Jun 26, 2017 at 8:33 PM, James Morris <jmorris@namei.org> wrote:
> On Mon, 26 Jun 2017, Kees Cook wrote:
>
>> >> Fixes: 8014370f1257 ("apparmor: move path_link mediation to using labels")
>> >> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
>> > Acked-by: John Johansen <john.johansen@canonical.com>
>>
>> Hi James,
>>
>> Just a ping; this needs to get into -next to avoid build errors.
>
> Surely Linus will resolve this when he pulls the trees in?
It's not a merge glitch, it's a refactoring glitch. John's commit in
security-next ("apparmor: move path_link mediation to using labels")
undid an earlier commit 8486adf0d755 ("apparmor: use designated
initializers") from v4.11. This patch is needed for security-next.
-Kees
--
Kees Cook
Pixel Security
[toc] | [prev] | [next] | [standalone]
| From | James Morris <jmorris@namei.org> |
|---|---|
| Date | 2017-06-28 07:50 +0200 |
| Message-ID | <tXe1r-2Mb-9@gated-at.bofh.it> |
| In reply to | #1676216 |
On Tue, 27 Jun 2017, Kees Cook wrote:
> On Mon, Jun 26, 2017 at 8:33 PM, James Morris <jmorris@namei.org> wrote:
> > On Mon, 26 Jun 2017, Kees Cook wrote:
> >
> >> >> Fixes: 8014370f1257 ("apparmor: move path_link mediation to using labels")
> >> >> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> >> > Acked-by: John Johansen <john.johansen@canonical.com>
> >>
> >> Hi James,
> >>
> >> Just a ping; this needs to get into -next to avoid build errors.
> >
> > Surely Linus will resolve this when he pulls the trees in?
>
> It's not a merge glitch, it's a refactoring glitch. John's commit in
> security-next ("apparmor: move path_link mediation to using labels")
> undid an earlier commit 8486adf0d755 ("apparmor: use designated
> initializers") from v4.11. This patch is needed for security-next.
>
Thanks.
Applied to
git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security.git next
--
James Morris
<jmorris@namei.org>
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web