Skip to contentSkip to conversation

package/kexec: fix build on pre 4.4 kernels

PATCH New Federico Pellegrin 2 participants 5 messages Jan 29, 2021 – Feb 23, 2021

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 package/kexec: fix build on pre 4.4 kernels

kexec build will fail on older kernels (pre 4.4) as the define VIDEO_CAPABILITY_64BIT_BASE was not present at that time.

This patch adds it, as per linux/include/uapi/linux/screen_info.h, if not present.

---
 ...-kexec-tools-video-capability-64bit-define.patch | 13 +++++++++++++
 1 file changed, 13 insertions(+)
 create mode 100644 package/kexec/0003-kexec-tools-video-capability-64bit-define.patch
package/kexec/0003-kexec-tools-video-capability-64bit-define.patch new file +13 -0
new file mode 100644
index 0000000000..93a66bb1a7
@@ -0,0 +1,13 @@
+--- a/kexec/arch/i386/x86-linux-setup.c
++++ b/kexec/arch/i386/x86-linux-setup.c
+@@ -37,6 +37,10 @@
+ #include "x86-linux-setup.h"
+ #include "../../kexec/kexec-syscall.h"
+ 
++#ifndef VIDEO_CAPABILITY_64BIT_BASE
++#define VIDEO_CAPABILITY_64BIT_BASE (1 << 1)	/* Frame buffer base is 64-bit */
++#endif
++
+ void init_linux_parameters(struct x86_linux_param_header *real_mode)
+ {
+ 	/* Fill in the values that are usually provided by the kernel. */
Signature · 1 line
2.26.2
#1 lore raw

PATCH 1/1 package/kexec: fix build on pre 4.4 kernels

Hello Federico,

Quoted 5 lines · On Fri, 29 Jan 2021 06:03:12 +0100 Federico Pellegrin <[email protected]> wrote:

kexec build will fail on older kernels (pre 4.4) as the define VIDEO_CAPABILITY_64BIT_BASE was not present at that time.

This patch adds it, as per linux/include/uapi/linux/screen_info.h, if not present.

Thanks a lot for your contribution! However, we need all patches added to packages to have a proper commit log and Signed-off-by line, and be generated using git format-patch. Could you adjust your patch accordingly ?

Also, did you submit this change to upstream kexec ?

Thanks a lot!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
#2 lore raw

PATCH 1/1 package/kexec: fix build on pre 4.4 kernels

Hi Thomas,
I apologize for the very bad patch I sent last time, very sorry I missed a level of patch indirection :-)

I've just resubmitted a few moments ago, I hope it is fine this time.

As for upstream: I contacted them on the kexec mailing list (describing the problem, proposing informally the solution and asking if a patch would be welcome) but got no response as of now. I will wait a bit more and ping in case. I'm not really sure if they are interested to support very old kernels (which may be somehow also true for Buildroot, but I guess given that Buildroot proposes as of now also that versions in the configuration stage, we should try to keep all the tooling working with them as well)

Many thanks!
Federico

Il giorno dom 31 gen 2021 alle ore 23:24 Thomas Petazzoni <[email protected]> ha scritto:

Quoted 26 lines

Hello Federico,

Quoted 5 lines · On Fri, 29 Jan 2021 06:03:12 +0100 Federico Pellegrin <[email protected]> wrote:

kexec build will fail on older kernels (pre 4.4) as the define VIDEO_CAPABILITY_64BIT_BASE was not present at that time.

This patch adds it, as per linux/include/uapi/linux/screen_info.h, if not present.

Thanks a lot for your contribution! However, we need all patches added to packages to have a proper commit log and Signed-off-by line, and be generated using git format-patch. Could you adjust your patch accordingly ?

Also, did you submit this change to upstream kexec ?

Thanks a lot!

Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

#3 lore raw

PATCH 1/1 package/kexec: fix build on pre 4.4 kernels

Hi Thomas,
Just wanted to revive this thread/patch even if not with very useful
info: pinged a few times in kexec mailing list but nothing yet, just one partecipant kindly forwarded directly also to the developer that wrote the specific code, but then everything stopped still sadly (~3 week now since first patch post).

For the time being we keep it as a local patch, I'm not sure how you proceed in buildroot in such cases.

Cheers,
Federico

Il giorno mer 3 feb 2021 alle ore 11:15 Federico Pellegrin <[email protected]> ha scritto:

Quoted 48 lines

Hi Thomas,
I apologize for the very bad patch I sent last time, very sorry I missed a level of patch indirection :-)

I've just resubmitted a few moments ago, I hope it is fine this time.

As for upstream: I contacted them on the kexec mailing list (describing the problem, proposing informally the solution and asking if a patch would be welcome) but got no response as of now. I will wait a bit more and ping in case. I'm not really sure if they are interested to support very old kernels (which may be somehow also true for Buildroot, but I guess given that Buildroot proposes as of now also that versions in the configuration stage, we should try to keep all the tooling working with them as well)

Many thanks!
Federico

Il giorno dom 31 gen 2021 alle ore 23:24 Thomas Petazzoni <[email protected]> ha scritto:

Quoted 26 lines

Hello Federico,

Quoted 5 lines · On Fri, 29 Jan 2021 06:03:12 +0100 Federico Pellegrin <[email protected]> wrote:

kexec build will fail on older kernels (pre 4.4) as the define VIDEO_CAPABILITY_64BIT_BASE was not present at that time.

This patch adds it, as per linux/include/uapi/linux/screen_info.h, if not present.

Thanks a lot for your contribution! However, we need all patches added to packages to have a proper commit log and Signed-off-by line, and be generated using git format-patch. Could you adjust your patch accordingly ?

Also, did you submit this change to upstream kexec ?

Thanks a lot!

Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

#4 lore raw

PATCH 1/1 package/kexec: fix build on pre 4.4 kernels

Hi Thomas,
Very funny enough, I got a feedback today from the original author soon after I sent the email to the list, giving an ok with his review. So seems to be probably the right way to solve the problem, but still needs to be merged and not sure how much this may take.

The feedback:

----
Thanks for the fix, I didn't notice pre 4.4 kernels don't have this defined when I submitted that patch.

-----

Cheers!
Federico

Federico

Il giorno mar 23 feb 2021 alle ore 09:30 Federico Pellegrin <[email protected]> ha scritto:

Quoted 65 lines

Hi Thomas,
Just wanted to revive this thread/patch even if not with very useful
info: pinged a few times in kexec mailing list but nothing yet, just one partecipant kindly forwarded directly also to the developer that wrote the specific code, but then everything stopped still sadly (~3 week now since first patch post).

For the time being we keep it as a local patch, I'm not sure how you proceed in buildroot in such cases.

Cheers,
Federico

Il giorno mer 3 feb 2021 alle ore 11:15 Federico Pellegrin <[email protected]> ha scritto:

Quoted 48 lines

Hi Thomas,
I apologize for the very bad patch I sent last time, very sorry I missed a level of patch indirection :-)

I've just resubmitted a few moments ago, I hope it is fine this time.

As for upstream: I contacted them on the kexec mailing list (describing the problem, proposing informally the solution and asking if a patch would be welcome) but got no response as of now. I will wait a bit more and ping in case. I'm not really sure if they are interested to support very old kernels (which may be somehow also true for Buildroot, but I guess given that Buildroot proposes as of now also that versions in the configuration stage, we should try to keep all the tooling working with them as well)

Many thanks!
Federico

Il giorno dom 31 gen 2021 alle ore 23:24 Thomas Petazzoni <[email protected]> ha scritto:

Quoted 26 lines

Hello Federico,

Quoted 5 lines · On Fri, 29 Jan 2021 06:03:12 +0100 Federico Pellegrin <[email protected]> wrote:

kexec build will fail on older kernels (pre 4.4) as the define VIDEO_CAPABILITY_64BIT_BASE was not present at that time.

This patch adds it, as per linux/include/uapi/linux/screen_info.h, if not present.

Thanks a lot for your contribution! However, we need all patches added to packages to have a proper commit log and Signed-off-by line, and be generated using git format-patch. Could you adjust your patch accordingly ?

Also, did you submit this change to upstream kexec ?

Thanks a lot!

Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com