Skip to contentSkip to conversation

linux-next: manual merge of the hid tree with the mm tree

DISCUSSION Stephen Rothwell 1 participant 2 messages Jul 9, 2024 – Jul 18, 2024 Linux-next tree

lore
Share & tools
lore
#0 lore raw

Hi all,

Today's linux-next merge of the hid tree got a conflict in:

include/linux/hid_bpf.h

between commit:

bad8443fbbca ("mm: add comments for allocation helpers explaining why they are macros")

from the mm-unstable branch of the mm tree and commit:

6cd735f0e57a ("HID: bpf: protect HID-BPF prog_list access by a SRCU")

from the hid tree.

I fixed it up (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.

Signature · 20 lines
Cheers,
Stephen Rothwell

diff --cc include/linux/hid_bpf.h
index 99a3edb6cf07,9ca96fc90449..000000000000
--- a/include/linux/hid_bpf.h
+++ b/include/linux/hid_bpf.h
@@@ -151,12 -227,7 +227,12 @@@ static inline int dispatch_hid_bpf_outp
  static inline int hid_bpf_connect_device(struct hid_device *hdev) { return 0; }
  static inline void hid_bpf_disconnect_device(struct hid_device *hdev) {}
  static inline void hid_bpf_destroy_device(struct hid_device *hid) {}
- static inline void hid_bpf_device_init(struct hid_device *hid) {}
+ static inline int hid_bpf_device_init(struct hid_device *hid) { return 0; }
 +/*
 + * This specialized allocator has to be a macro for its allocations to be
 + * accounted separately (to have a separate alloc_tag). The typecast is
 + * intentional to enforce typesafety.
 + */
  #define call_hid_bpf_rdesc_fixup(_hdev, _rdesc, _size)	\
  		((u8 *)kmemdup(_rdesc, *(_size), GFP_KERNEL))
#1 lore raw

Hi all,

Quoted 30 lines · On Tue, 9 Jul 2024 11:25:44 +1000 Stephen Rothwell <[email protected]> wrote:

Today's linux-next merge of the hid tree got a conflict in:

include/linux/hid_bpf.h

between commit:

bad8443fbbca ("mm: add comments for allocation helpers explaining why they are macros")

from the mm-unstable branch of the mm tree and commit:

6cd735f0e57a ("HID: bpf: protect HID-BPF prog_list access by a SRCU")

from the hid tree.

I fixed it up (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.

include/linux/hid_bpf.h +0 -0
diff --cc include/linux/hid_bpf.h
index 99a3edb6cf07,9ca96fc90449..000000000000
@@@ -151,12 -227,7 +227,12 @@@ static inline int dispatch_hid_bpf_outp
  static inline int hid_bpf_connect_device(struct hid_device *hdev) { return 0; }
  static inline void hid_bpf_disconnect_device(struct hid_device *hdev) {}

include/linux/hid_bpf.h

Quoted 10 lines
include/linux/hid_bpf.h +1 -1
  static inline void hid_bpf_destroy_device(struct hid_device *hid) {}
- static inline void hid_bpf_device_init(struct hid_device *hid) {}
+ static inline int hid_bpf_device_init(struct hid_device *hid) { return 0; }
 +/*
 + * This specialized allocator has to be a macro for its allocations to be
 + * accounted separately (to have a separate alloc_tag). The typecast is
 + * intentional to enforce typesafety.
 + */
  #define call_hid_bpf_rdesc_fixup(_hdev, _rdesc, _size)	\
  		((u8 *)kmemdup(_rdesc, *(_size), GFP_KERNEL))

This is now a conflict between the mm-stable branch of the mm tree and Linus' tree.

Signature · 2 lines
Cheers,
Stephen Rothwell