* [Buildroot] [PATCH] u-boot: add config option to disable patching
@ 2008-11-14 7:54 Markus Heidelberg
2008-11-14 13:37 ` Peter Korsgaard
0 siblings, 1 reply; 13+ messages in thread
From: Markus Heidelberg @ 2008-11-14 7:54 UTC (permalink / raw)
To: buildroot
The patches in target/u-boot/ can conflict with custom board specific
patches, so this option is necessary.
Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de>
---
target/u-boot/Config.in | 8 ++++++++
target/u-boot/Makefile.in | 2 ++
2 files changed, 10 insertions(+), 0 deletions(-)
diff --git a/target/u-boot/Config.in b/target/u-boot/Config.in
index 8159485..84b2ef5 100644
--- a/target/u-boot/Config.in
+++ b/target/u-boot/Config.in
@@ -12,6 +12,14 @@ config BR2_TARGET_UBOOT_BOARDNAME
One of U-Boot supported boards to be built.
This will be suffixed with _config to meet U-Boot standard naming.
+config BR2_TARGET_UBOOT_DISABLE_GENERAL_PATCHES
+ bool "disable general patches"
+ depends on BR2_TARGET_UBOOT
+ help
+ Select this option to disable patching U-Boot with the patches from
+ target/u-boot/. This can be necessary if they conflict with your
+ custom patch.
+
config BR2_TARGET_UBOOT_CUSTOM_PATCH
string "custom patch"
depends on BR2_TARGET_UBOOT
diff --git a/target/u-boot/Makefile.in b/target/u-boot/Makefile.in
index 4df575a..0ea4b75 100644
--- a/target/u-boot/Makefile.in
+++ b/target/u-boot/Makefile.in
@@ -46,9 +46,11 @@ $(U_BOOT_DIR)/.unpacked: $(DL_DIR)/$(U_BOOT_SOURCE)
touch $@
$(U_BOOT_DIR)/.patched: $(U_BOOT_DIR)/.unpacked
+ifneq ($(strip $(BR2_TARGET_UBOOT_DISABLE_GENERAL_PATCHES)),y)
toolchain/patch-kernel.sh $(U_BOOT_DIR) target/u-boot/ \
u-boot-$(U_BOOT_VERSION)-\*.patch \
u-boot-$(U_BOOT_VERSION)-\*.patch.$(ARCH)
+endif
ifneq ($(strip $(BR2_TARGET_UBOOT_CUSTOM_PATCH)),"")
@mkdir -p $(U_BOOT_PATCH_DIR)
cp -dpr $(BR2_TARGET_UBOOT_CUSTOM_PATCH) $(U_BOOT_PATCH_DIR)
--
1.6.0.4.620.g87fa
^ permalink raw reply related [flat|nested] 13+ messages in thread
* [Buildroot] [PATCH] u-boot: add config option to disable patching
2008-11-14 7:54 [Buildroot] [PATCH] u-boot: add config option to disable patching Markus Heidelberg
@ 2008-11-14 13:37 ` Peter Korsgaard
2008-11-15 10:56 ` Markus Heidelberg
0 siblings, 1 reply; 13+ messages in thread
From: Peter Korsgaard @ 2008-11-14 13:37 UTC (permalink / raw)
To: buildroot
>>>>> "Markus" == Markus Heidelberg <markus.heidelberg@web.de> writes:
Markus> The patches in target/u-boot/ can conflict with custom board specific
Markus> patches, so this option is necessary.
But there aren't any patches under target/u-boot?
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Buildroot] [PATCH] u-boot: add config option to disable patching
2008-11-14 13:37 ` Peter Korsgaard
@ 2008-11-15 10:56 ` Markus Heidelberg
2009-01-08 14:10 ` [Buildroot] [PATCH] u-boot: add config option to disable general patches Markus Heidelberg
0 siblings, 1 reply; 13+ messages in thread
From: Markus Heidelberg @ 2008-11-15 10:56 UTC (permalink / raw)
To: buildroot
Peter Korsgaard, 14.11.2008:
> >>>>> "Markus" == Markus Heidelberg <markus.heidelberg@web.de> writes:
>
> Markus> The patches in target/u-boot/ can conflict with custom board specific
> Markus> patches, so this option is necessary.
>
> But there aren't any patches under target/u-boot?
I use Atmel's buildroot for AVR32, they added a patch there. Then do you think
we should just delete the 3 patch-kernel.sh lines I've surrounded with the new
option because it is never used?
Markus
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Buildroot] [PATCH] u-boot: add config option to disable general patches
2008-11-15 10:56 ` Markus Heidelberg
@ 2009-01-08 14:10 ` Markus Heidelberg
2009-01-08 14:33 ` Peter Korsgaard
0 siblings, 1 reply; 13+ messages in thread
From: Markus Heidelberg @ 2009-01-08 14:10 UTC (permalink / raw)
To: buildroot
The patches in target/u-boot/$(U_BOOT_VERSION)/ can conflict with custom
board specific patches, so this option is necessary.
Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de>
---
Markus Heidelberg, 15.11.2008:
> Peter Korsgaard, 14.11.2008:
> > >>>>> "Markus" == Markus Heidelberg <markus.heidelberg@web.de> writes:
> >
> > Markus> The patches in target/u-boot/ can conflict with custom board specific
> > Markus> patches, so this option is necessary.
> >
> > But there aren't any patches under target/u-boot?
Now there are.
> I use Atmel's buildroot for AVR32, they added a patch there. Then do you think
> we should just delete the 3 patch-kernel.sh lines I've surrounded with the new
> option because it is never used?
target/u-boot/Config.in | 8 ++++++++
target/u-boot/Makefile.in | 2 ++
2 files changed, 10 insertions(+), 0 deletions(-)
diff --git a/target/u-boot/Config.in b/target/u-boot/Config.in
index 9ab6224..f916852 100644
--- a/target/u-boot/Config.in
+++ b/target/u-boot/Config.in
@@ -54,6 +54,14 @@ config BR2_U_BOOT_SITE
default "$(BR2_ATMEL_MIRROR)" if BR2_TARGET_UBOOT_1_2_0_ATMEL
default "ftp://ftp.denx.de/pub/u-boot"
+config BR2_TARGET_UBOOT_DISABLE_GENERAL_PATCHES
+ bool "disable general patches"
+ depends on BR2_TARGET_UBOOT
+ help
+ Select this option to disable applying the patches from
+ target/u-boot/$(U_BOOT_VERSION)/. This can be necessary if they
+ conflict with your custom patch.
+
config BR2_TARGET_UBOOT_CUSTOM_PATCH
string "custom patch"
depends on BR2_TARGET_UBOOT
diff --git a/target/u-boot/Makefile.in b/target/u-boot/Makefile.in
index b5bb8e1..6319cea 100644
--- a/target/u-boot/Makefile.in
+++ b/target/u-boot/Makefile.in
@@ -85,9 +85,11 @@ $(U_BOOT_DIR)/.unpacked: $(DL_DIR)/$(U_BOOT_SOURCE)
touch $@
$(U_BOOT_DIR)/.patched: $(U_BOOT_DIR)/.unpacked
+ifneq ($(BR2_TARGET_UBOOT_DISABLE_GENERAL_PATCHES),y)
toolchain/patch-kernel.sh $(U_BOOT_DIR) target/u-boot/$(U_BOOT_VERSION) \
u-boot-$(U_BOOT_VERSION)-\*.patch \
u-boot-$(U_BOOT_VERSION)-\*.patch.$(ARCH)
+endif
ifneq ($(strip $(BR2_TARGET_UBOOT_CUSTOM_PATCH)),"")
@mkdir -p $(U_BOOT_PATCH_DIR)
cp -dpr $(BR2_TARGET_UBOOT_CUSTOM_PATCH) $(U_BOOT_PATCH_DIR)
--
1.6.1.35.g0c23
^ permalink raw reply related [flat|nested] 13+ messages in thread
* [Buildroot] [PATCH] u-boot: add config option to disable general patches
2009-01-08 14:10 ` [Buildroot] [PATCH] u-boot: add config option to disable general patches Markus Heidelberg
@ 2009-01-08 14:33 ` Peter Korsgaard
2009-01-08 18:17 ` Markus Heidelberg
2009-01-08 21:56 ` Ulf Samuelsson
0 siblings, 2 replies; 13+ messages in thread
From: Peter Korsgaard @ 2009-01-08 14:33 UTC (permalink / raw)
To: buildroot
>>>>> "Markus" == Markus Heidelberg <markus.heidelberg@web.de> writes:
Markus> The patches in target/u-boot/$(U_BOOT_VERSION)/ can conflict with custom
Markus> board specific patches, so this option is necessary.
I would rather get rid of any patches that are not strictly needed. We
should only have patches for criticial bugfixes or build issues.
The number of configuration options we have in target/u-boot nowadays
is getty silly.
Ulf, let me know what you think.
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Buildroot] [PATCH] u-boot: add config option to disable general patches
2009-01-08 14:33 ` Peter Korsgaard
@ 2009-01-08 18:17 ` Markus Heidelberg
2009-01-09 10:54 ` Peter Korsgaard
2009-01-08 21:56 ` Ulf Samuelsson
1 sibling, 1 reply; 13+ messages in thread
From: Markus Heidelberg @ 2009-01-08 18:17 UTC (permalink / raw)
To: buildroot
Peter Korsgaard, 08.01.2009:
> >>>>> "Markus" == Markus Heidelberg <markus.heidelberg@web.de> writes:
>
> Markus> The patches in target/u-boot/$(U_BOOT_VERSION)/ can conflict with custom
> Markus> board specific patches, so this option is necessary.
>
> I would rather get rid of any patches that are not strictly needed. We
> should only have patches for criticial bugfixes or build issues.
It's not that only big/many/feature patches can lead to conflicts, it's
rather possible that patches containing fixes conflict with custom
patches, at least with my current workflow. I don't base U-Boot
development on the state in Buildroot, but on U-Boot's git tree and then
create a patch against the release and put it into Buildroot.
It's the same as with the Linux kernel: you wouldn't like patches lying
around in Buildroot, which you can't disable and always get applied.
> The number of configuration options we have in target/u-boot nowadays
> is getty silly.
That's right, but this option is not one to be passed to U-Boot like all
this board specific stuff currently in Config.in.
Markus
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Buildroot] [PATCH] u-boot: add config option to disable general patches
2009-01-08 14:33 ` Peter Korsgaard
2009-01-08 18:17 ` Markus Heidelberg
@ 2009-01-08 21:56 ` Ulf Samuelsson
2009-01-09 11:07 ` Thomas Lundquist
2009-01-09 11:26 ` Peter Korsgaard
1 sibling, 2 replies; 13+ messages in thread
From: Ulf Samuelsson @ 2009-01-08 21:56 UTC (permalink / raw)
To: buildroot
tor 2009-01-08 klockan 15:33 +0100 skrev Peter Korsgaard:
> >>>>> "Markus" == Markus Heidelberg <markus.heidelberg@web.de> writes:
>
> Markus> The patches in target/u-boot/$(U_BOOT_VERSION)/ can conflict with custom
> Markus> board specific patches, so this option is necessary.
>
> I would rather get rid of any patches that are not strictly needed. We
> should only have patches for criticial bugfixes or build issues.
>
> The number of configuration options we have in target/u-boot nowadays
> is getty silly.
>
> Ulf, let me know what you think.
I can see a few alternatives.
1) Get rid of the patches, and introduce the possibility
to select a prepatched version with these patches
2) Keep the patches and prune them once
they are in mainstream.
I am only interested in maintaing one set of patches
for one version, so as I mentioned before,
I submitted about half a dozen patches the last two days
and it looks like they can enter the main tree,
with maybe a little rework.
3) Do it the same way I did the Advanced Linux support
Keep target/u-boot, but allow patches
to be taken from the target/device/<whatever>
In this case, the patches would go into
target/device/Atmel/arch-at91/u-boot-2009.01-rc1
The last option is appealing.
BR
Ulf Samuelsson
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Buildroot] [PATCH] u-boot: add config option to disable general patches
2009-01-08 18:17 ` Markus Heidelberg
@ 2009-01-09 10:54 ` Peter Korsgaard
2009-01-09 15:08 ` Markus Heidelberg
0 siblings, 1 reply; 13+ messages in thread
From: Peter Korsgaard @ 2009-01-09 10:54 UTC (permalink / raw)
To: buildroot
>>>>> "Markus" == Markus Heidelberg <markus.heidelberg@web.de> writes:
Hi,
Markus> It's the same as with the Linux kernel: you wouldn't like
Markus> patches lying around in Buildroot, which you can't disable
Markus> and always get applied.
I've been pondering about adding a bit of flexibility to the packages
that often need platform specific handling
(E.G. Linux/U-Boot). Building upstream versions of those rarely make
sense for custom boards, so having the option to apply custom patches
or grabbing the entire tree from other version control system seems
sensible.
Grant Likely once sent a patch series adding support for using other
git trees to the kernel build, that I still need to look into.
>> The number of configuration options we have in target/u-boot nowadays
>> is getty silly.
Markus> That's right, but this option is not one to be passed to
Markus> U-Boot like all this board specific stuff currently in
Markus> Config.in.
True.
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Buildroot] [PATCH] u-boot: add config option to disable general patches
2009-01-08 21:56 ` Ulf Samuelsson
@ 2009-01-09 11:07 ` Thomas Lundquist
2009-01-09 11:26 ` Peter Korsgaard
1 sibling, 0 replies; 13+ messages in thread
From: Thomas Lundquist @ 2009-01-09 11:07 UTC (permalink / raw)
To: buildroot
On Thu, Jan 08, 2009 at 10:56:39PM +0100, Ulf Samuelsson wrote:
>
> 3) Do it the same way I did the Advanced Linux support
> Keep target/u-boot, but allow patches
> to be taken from the target/device/<whatever>
> In this case, the patches would go into
> target/device/Atmel/arch-at91/u-boot-2009.01-rc1
>
> The last option is appealing.
I like that approach. (Except the versioning of course :=)
But not sure how to make this work without too much hassle.
Thomas.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Buildroot] [PATCH] u-boot: add config option to disable general patches
2009-01-08 21:56 ` Ulf Samuelsson
2009-01-09 11:07 ` Thomas Lundquist
@ 2009-01-09 11:26 ` Peter Korsgaard
1 sibling, 0 replies; 13+ messages in thread
From: Peter Korsgaard @ 2009-01-09 11:26 UTC (permalink / raw)
To: buildroot
>>>>> "Ulf" == Ulf Samuelsson <ulf.samuelsson@atmel.com> writes:
Hi,
Ulf> I can see a few alternatives.
Ulf> 1) Get rid of the patches, and introduce the possibility
Ulf> to select a prepatched version with these patches
I take it that's already there with your BR2_U_BOOT_SITE addition?
Ulf> 2) Keep the patches and prune them once
Ulf> they are in mainstream.
Ulf> I am only interested in maintaing one set of patches
Ulf> for one version, so as I mentioned before,
Ulf> I submitted about half a dozen patches the last two days
Ulf> and it looks like they can enter the main tree,
Ulf> with maybe a little rework.
We'll see how they are received, We'll need to get rid of them sooner
or later atleast.
Ulf> 3) Do it the same way I did the Advanced Linux support
Ulf> Keep target/u-boot, but allow patches
Ulf> to be taken from the target/device/<whatever>
Ulf> In this case, the patches would go into
Ulf> target/device/Atmel/arch-at91/u-boot-2009.01-rc1
Ulf> The last option is appealing.
Yes, or more generally - Provide more flexibility for the U-Boot/Linux
source, see my earlier mail.
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Buildroot] [PATCH] u-boot: add config option to disable general patches
2009-01-09 10:54 ` Peter Korsgaard
@ 2009-01-09 15:08 ` Markus Heidelberg
2009-01-09 15:15 ` Peter Korsgaard
0 siblings, 1 reply; 13+ messages in thread
From: Markus Heidelberg @ 2009-01-09 15:08 UTC (permalink / raw)
To: buildroot
Peter Korsgaard, 09.01.2009:
> >>>>> "Markus" == Markus Heidelberg <markus.heidelberg@web.de> writes:
>
> Hi,
>
> Markus> It's the same as with the Linux kernel: you wouldn't like
> Markus> patches lying around in Buildroot, which you can't disable
> Markus> and always get applied.
>
> I've been pondering about adding a bit of flexibility to the packages
> that often need platform specific handling
> (E.G. Linux/U-Boot). Building upstream versions of those rarely make
> sense for custom boards, so having the option to apply custom patches
Which is available, but only in addition to the general patches lying
around.
> or grabbing the entire tree from other version control system seems
> sensible.
Yes, that would be a possible alternative.
> Grant Likely once sent a patch series adding support for using other
> git trees to the kernel build, that I still need to look into.
I just had a look at it. Some sort of checking for newer commits and
then updating the cloned tree would be nice.
Markus
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Buildroot] [PATCH] u-boot: add config option to disable general patches
2009-01-09 15:08 ` Markus Heidelberg
@ 2009-01-09 15:15 ` Peter Korsgaard
2009-01-09 16:07 ` Markus Heidelberg
0 siblings, 1 reply; 13+ messages in thread
From: Peter Korsgaard @ 2009-01-09 15:15 UTC (permalink / raw)
To: buildroot
>>>>> "Markus" == Markus Heidelberg <markus.heidelberg@web.de> writes:
>> (E.G. Linux/U-Boot). Building upstream versions of those rarely make
>> sense for custom boards, so having the option to apply custom patches
Markus> Which is available, but only in addition to the general patches lying
Markus> around.
Exactly, it should ofcourse be INSTEAD.
>> Grant Likely once sent a patch series adding support for using other
>> git trees to the kernel build, that I still need to look into.
Markus> I just had a look at it. Some sort of checking for newer commits and
Markus> then updating the cloned tree would be nice.
Yes, indeed.
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Buildroot] [PATCH] u-boot: add config option to disable general patches
2009-01-09 15:15 ` Peter Korsgaard
@ 2009-01-09 16:07 ` Markus Heidelberg
0 siblings, 0 replies; 13+ messages in thread
From: Markus Heidelberg @ 2009-01-09 16:07 UTC (permalink / raw)
To: buildroot
Peter Korsgaard, 09.01.2009:
> >>>>> "Markus" == Markus Heidelberg <markus.heidelberg@web.de> writes:
>
> >> (E.G. Linux/U-Boot). Building upstream versions of those rarely make
> >> sense for custom boards, so having the option to apply custom patches
>
> Markus> Which is available, but only in addition to the general patches lying
> Markus> around.
>
> Exactly, it should ofcourse be INSTEAD.
Which was the reason for the config option in my patch.
Or do you think of the following, without an additional option? Maybe
this would make sense!?
--- a/target/u-boot/Makefile.in
+++ b/target/u-boot/Makefile.in
@@ -85,13 +85,14 @@ $(U_BOOT_DIR)/.unpacked: $(DL_DIR)/$(U_BOOT_SOURCE)
touch $@
$(U_BOOT_DIR)/.patched: $(U_BOOT_DIR)/.unpacked
- toolchain/patch-kernel.sh $(U_BOOT_DIR) target/u-boot/$(U_BOOT_VERSION) \
- u-boot-$(U_BOOT_VERSION)-\*.patch \
- u-boot-$(U_BOOT_VERSION)-\*.patch.$(ARCH)
ifneq ($(strip $(BR2_TARGET_UBOOT_CUSTOM_PATCH)),"")
@mkdir -p $(U_BOOT_PATCH_DIR)
cp -dpr $(BR2_TARGET_UBOOT_CUSTOM_PATCH) $(U_BOOT_PATCH_DIR)
toolchain/patch-kernel.sh $(U_BOOT_DIR) $(U_BOOT_PATCH_DIR) \*.patch
+else
+ toolchain/patch-kernel.sh $(U_BOOT_DIR) target/u-boot/$(U_BOOT_VERSION) \
+ u-boot-$(U_BOOT_VERSION)-\*.patch \
+ u-boot-$(U_BOOT_VERSION)-\*.patch.$(ARCH)
endif
touch $@
^ permalink raw reply [flat|nested] 13+ messages in thread
end of thread, other threads:[~2009-01-09 16:07 UTC | newest]
Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-11-14 7:54 [Buildroot] [PATCH] u-boot: add config option to disable patching Markus Heidelberg
2008-11-14 13:37 ` Peter Korsgaard
2008-11-15 10:56 ` Markus Heidelberg
2009-01-08 14:10 ` [Buildroot] [PATCH] u-boot: add config option to disable general patches Markus Heidelberg
2009-01-08 14:33 ` Peter Korsgaard
2009-01-08 18:17 ` Markus Heidelberg
2009-01-09 10:54 ` Peter Korsgaard
2009-01-09 15:08 ` Markus Heidelberg
2009-01-09 15:15 ` Peter Korsgaard
2009-01-09 16:07 ` Markus Heidelberg
2009-01-08 21:56 ` Ulf Samuelsson
2009-01-09 11:07 ` Thomas Lundquist
2009-01-09 11:26 ` Peter Korsgaard
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox