public inbox for linux-next@vger.kernel.org
 help / color / mirror / Atom feed
From: Stephen Rothwell <sfr@canb.auug.org.au>
To: Shuah Khan <skhan@linuxfoundation.org>,
	Brendan Higgins <brendanhiggins@google.com>,
	John Johansen <john.johansen@canonical.com>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Linux Next Mailing List <linux-next@vger.kernel.org>,
	Rae Moar <rmoar@google.com>
Subject: Re: linux-next: manual merge of the kunit-next tree with the apparmor tree
Date: Tue, 13 Dec 2022 14:22:56 +1100	[thread overview]
Message-ID: <20221213142256.3d3ee811@canb.auug.org.au> (raw)
In-Reply-To: <20221208135327.01364529@canb.auug.org.au>

[-- Attachment #1: Type: text/plain, Size: 3437 bytes --]

Hi all,

On Thu, 8 Dec 2022 13:53:27 +1100 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>
> Today's linux-next merge of the kunit-next tree got a conflict in:
> 
>   security/apparmor/policy_unpack.c
> 
> between commits:
> 
>   371e50a0b19f ("apparmor: make unpack_array return a trianary value")
>   73c7e91c8bc9 ("apparmor: Remove unnecessary size check when unpacking trans_table")
>   217af7e2f4de ("apparmor: refactor profile rules and attachments")
> (and probably others)
> 
> from the apparmor tree and commit:
> 
>   2c92044683f5 ("apparmor: test: make static symbols visible during kunit testing")
> 
> from the kunit-next tree.
> 
> This is somewhat of a mess ... pity there is not a shared branch (or
> better routing if the patches).
> 
> I fixed it up (hopefully - see below) and can carry the fix as
> necessary. This is now fixed as far as linux-next is concerned, but any
> non trivial conflicts should be mentioned to your upstream maintainer
> when your tree is submitted for merging.  You may also want to consider
> cooperating with the maintainer of the conflicting tree to minimise any
> particularly complex conflicts.
> 
> I also had to add this patch:

This merge fix patch is now:

From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Thu, 8 Dec 2022 13:47:43 +1100
Subject: [PATCH] fixup for "apparmor: make unpack_array return a trianary value"

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
 security/apparmor/include/policy_unpack.h | 7 ++++++-
 security/apparmor/policy_unpack.c         | 5 -----
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/security/apparmor/include/policy_unpack.h b/security/apparmor/include/policy_unpack.h
index 940da8a33e0c..67d59b9736de 100644
--- a/security/apparmor/include/policy_unpack.h
+++ b/security/apparmor/include/policy_unpack.h
@@ -165,6 +165,11 @@ static inline void aa_put_loaddata(struct aa_loaddata *data)
 		kref_put(&data->count, aa_loaddata_kref);
 }
 
+#define tri int
+#define TRI_TRUE 1
+#define TRI_NONE 0
+#define TRI_FALSE -1
+
 #if IS_ENABLED(CONFIG_KUNIT)
 bool aa_inbounds(struct aa_ext *e, size_t size);
 size_t aa_unpack_u16_chunk(struct aa_ext *e, char **chunk);
@@ -172,7 +177,7 @@ bool aa_unpack_X(struct aa_ext *e, enum aa_code code);
 bool aa_unpack_nameX(struct aa_ext *e, enum aa_code code, const char *name);
 bool aa_unpack_u32(struct aa_ext *e, u32 *data, const char *name);
 bool aa_unpack_u64(struct aa_ext *e, u64 *data, const char *name);
-size_t aa_unpack_array(struct aa_ext *e, const char *name);
+tri aa_unpack_array(struct aa_ext *e, const char *name, u16 *size);
 size_t aa_unpack_blob(struct aa_ext *e, char **blob, const char *name);
 int aa_unpack_str(struct aa_ext *e, const char **string, const char *name);
 int aa_unpack_strdup(struct aa_ext *e, char **string, const char *name);
diff --git a/security/apparmor/policy_unpack.c b/security/apparmor/policy_unpack.c
index 6513545dad5e..173d832fc4ee 100644
--- a/security/apparmor/policy_unpack.c
+++ b/security/apparmor/policy_unpack.c
@@ -30,11 +30,6 @@
 #include "include/policy_unpack.h"
 #include "include/policy_compat.h"
 
-#define tri int
-#define TRI_TRUE 1
-#define TRI_NONE 0
-#define TRI_FALSE -1
-
 /* audit callback for unpack fields */
 static void audit_cb(struct audit_buffer *ab, void *va)
 {
-- 
2.35.1

-- 
Cheers,
Stephen Rothwell

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

  parent reply	other threads:[~2022-12-13  3:23 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-08  2:53 linux-next: manual merge of the kunit-next tree with the apparmor tree Stephen Rothwell
2022-12-08 20:10 ` John Johansen
2022-12-12 17:52   ` Shuah Khan
2022-12-12 18:03     ` Shuah Khan
2022-12-12 19:20       ` John Johansen
2022-12-12 19:48         ` Shuah Khan
2022-12-12 19:53           ` John Johansen
2022-12-12 23:19             ` Shuah Khan
2022-12-12 23:56               ` David Gow
2022-12-13  3:22 ` Stephen Rothwell [this message]
2022-12-14  0:00 ` Stephen Rothwell
2022-12-14  0:55   ` John Johansen
2022-12-14 18:38   ` John Johansen
  -- strict thread matches above, loose matches on Subject: below --
2022-12-08  1:46 Stephen Rothwell
2022-12-13 23:58 ` Stephen Rothwell
2022-12-14 18:38   ` John Johansen
2022-04-05  2:55 Stephen Rothwell
2022-07-04 23:13 ` Stephen Rothwell
2022-07-05  8:57   ` David Gow
2022-07-05 18:22     ` John Johansen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20221213142256.3d3ee811@canb.auug.org.au \
    --to=sfr@canb.auug.org.au \
    --cc=brendanhiggins@google.com \
    --cc=john.johansen@canonical.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=rmoar@google.com \
    --cc=skhan@linuxfoundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox