package/rpi-firmware: add overlays/README
PATCH 1/1 package/rpi-firmware: add overlays/README
If a custom os_prefix directory is specified then the Raspberry Pi firmware probes for the README file in overlays directory.
Since the README file is small let's include it, otherwise, the firmware won't recognize the overlays directory if the user later moves it to an os_prefix specific sub-directory.
From
https://www.raspberrypi.com/documentation/computers/config_txt.html#overlay_prefix
Unless ${os_prefix}${overlay_prefix}README exists, overlays are shared with the main OS (i.e. os_prefix is ignored).
--- package/rpi-firmware/rpi-firmware.mk | 1 + 1 file changed, 1 insertion(+)
package/rpi-firmware/rpi-firmware.mk +1 -0
@@ -48,6 +48,7 @@ define RPI_FIRMWARE_INSTALL_DTB_OVERLAYS $(foreach ovldtb,$(wildcard $(@D)/boot/overlays/*.dtbo), \ $(INSTALL) -D -m 0644 $(ovldtb) $(BINARIES_DIR)/rpi-firmware/overlays/$(notdir $(ovldtb)) ) + $(INSTALL) -D -m 0644 $(@D)/boot/overlays/README $(BINARIES_DIR)/rpi-firmware/overlays/ $(INSTALL) -D -m 0644 $(@D)/boot/overlays/overlay_map.dtb $(BINARIES_DIR)/rpi-firmware/overlays/ endef else
Signature · 6 lines
2.25.1 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Tim, All,
On 2022-10-31 11:46 +0000, Tim Gover spake thusly:
Quoted 4 lines
If a custom
os_prefixdirectory is specified then the Raspberry Pi firmware probes for the README file in overlays directory.Since the README file is small let's include it, otherwise,
197KiB is _not_ small. In fact, the README is bigger than every dtbo, and accounts for ~25% of the size of all dtbo combined.
Quoted 2 lines
the firmware won't recognize the overlays directory if the user later moves it to an
os_prefixspecific sub-directory.
What is the goal here, in the context of Buildroot, where we only install one set of overlays?
If a user moved the overlays, they already have a script that does that, so they should also ensure that script properly prepares config.txt to specify the proper os_prefix, and so it is just a matter of adding a 'touch' on the README in the same script.
Regards,
Yann E. MORIN.
Quoted 30 lines
From
https://www.raspberrypi.com/documentation/computers/config_txt.html#overlay_prefixUnless ${os_prefix}${overlay_prefix}README exists, overlays are shared with the main OS (i.e.
os_prefixis ignored).Signed-off-by Tim Gover <[email protected]>--- package/rpi-firmware/rpi-firmware.mk | 1 + 1 file changed, 1 insertion(+)package/rpi-firmware/rpi-firmware.mk +1
-0@@ -48,6 +48,7 @@ define RPI_FIRMWARE_INSTALL_DTB_OVERLAYS $(foreach ovldtb,$(wildcard $(@D)/boot/overlays/*.dtbo), \ $(INSTALL) -D -m 0644 $(ovldtb) $(BINARIES_DIR)/rpi-firmware/overlays/$(notdir $(ovldtb)) ) + $(INSTALL) -D -m 0644 $(@D)/boot/overlays/README $(BINARIES_DIR)/rpi-firmware/overlays/ $(INSTALL) -D -m 0644 $(@D)/boot/overlays/overlay_map.dtb $(BINARIES_DIR)/rpi-firmware/overlays/ endef elseSignature · 6 lines
2.25.1 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Signature · 10 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------' _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Quoted 11 lines · Yann E. MORIN
Tim, All,
On 2022-10-31 11:46 +0000, Tim Gover spake thusly:
Quoted 4 lines
If a custom
os_prefixdirectory is specified then the Raspberry Pi firmware probes for the README file in overlays directory.Since the README file is small let's include it, otherwise,
197KiB is _not_ small. In fact, the README is bigger than every dtbo, and accounts for ~25% of the size of all dtbo combined.
Good point. Would you be happy with simply creating an empty or small README file (a note indicating the purpose of the file) ?
Quoted 10 lines
Quoted 2 lines
the firmware won't recognize the overlays directory if the user later moves it to an
os_prefixspecific sub-directory.What is the goal here, in the context of Buildroot, where we only install one set of overlays?
If a user moved the overlays, they already have a script that does that, so they should also ensure that script properly prepares config.txt to specify the proper
os_prefix, and so it is just a matter of adding a 'touch' on the README in the same script.
It's fairly common for non-expert users to modify the output of a buildroot image
without re-building the image themselves. Adding a README file reduces the risk of them being tripped up by this difference in behaviour.
Quoted 37 lines
Regards,
Yann E. MORIN.Quoted 26 lines
From
https://www.raspberrypi.com/documentation/computers/config_txt.html#overlay_prefixUnless ${os_prefix}${overlay_prefix}README exists, overlays are shared with the main OS (i.e.
os_prefixis ignored).Signed-off-by Tim Gover <[email protected]>--- package/rpi-firmware/rpi-firmware.mk | 1 + 1 file changed, 1 insertion(+)package/rpi-firmware/rpi-firmware.mk +1
-1@@ -48,6 +48,7 @@ define RPI_FIRMWARE_INSTALL_DTB_OVERLAYS $(foreach ovldtb,$(wildcard $(@D)/boot/overlays/*.dtbo), \ $(INSTALL) -D -m 0644 $(ovldtb) $(BINARIES_DIR)/rpi-firmware/overlays/$(notdir $(ovldtb)) ) + $(INSTALL) -D -m 0644 $(@D)/boot/overlays/README $(BINARIES_DIR)/rpi-firmware/overlays/ $(INSTALL) -D -m 0644 $(@D)/boot/overlays/overlay_map.dtb $(BINARIES_DIR)/rpi-firmware/overlays/ endef else --2.25.1
Quoted 4 lines
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot--
.-----------------.--------------------.------------------.--------------------.
Quoted 5 lines
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Tim, All,
On 2022-10-31 12:52 +0000, Tim Gover spake thusly:
Quoted 9 lines · Yann E. MORIN
Quoted 6 lines
On 2022-10-31 11:46 +0000, Tim Gover spake thusly:
Quoted 3 lines
If a custom
os_prefixdirectory is specified then the Raspberry Pi firmware probes for the README file in overlays directory. Since the README file is small let's include it, otherwise,197KiB is _not_ small. In fact, the README is bigger than every dtbo, and accounts for ~25% of the size of all dtbo combined.
Good point. Would you be happy with simply creating an empty or small README file (a note indicating the purpose of the file) ?
Just touching the README should be enough I would say.
Quoted 8 lines
Quoted 8 lines
Quoted 2 lines
the firmware won't recognize the overlays directory if the user later moves it to an
os_prefixspecific sub-directory.What is the goal here, in the context of Buildroot, where we only install one set of overlays?
If a user moved the overlays, they already have a script that does that, so they should also ensure that script properly prepares config.txt to specify the properos_prefix, and so it is just a matter of adding a 'touch' on the README in the same script.
Quoted 4 lines
It's fairly common for non-expert users to modify the output of a buildroot image
without re-building the image themselves. Adding a README file reduces the risk of them being tripped up by this difference in behaviour.
So, if I read you correctly: non-expert users know they can move the overlays to a sub-dir; they also know they have to set the os_prefix accordingly in config.txt; but they don't know they have to create a README in there? ;-)
Sorry, I am still unconvinced.
Regards,
Yann E. MORIN.
Signature · 10 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------' _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Quoted 29 lines · Yann E. MORIN
Tim, All,
On 2022-10-31 12:52 +0000, Tim Gover spake thusly:
Quoted 9 lines · Yann E. MORIN
Quoted 6 lines
On 2022-10-31 11:46 +0000, Tim Gover spake thusly:
Quoted 3 lines
If a custom
os_prefixdirectory is specified then the Raspberry Pi firmware probes for the README file in overlays directory. Since the README file is small let's include it, otherwise,197KiB is _not_ small. In fact, the README is bigger than every dtbo, and accounts for ~25% of the size of all dtbo combined.
Good point. Would you be happy with simply creating an empty or small README file (a note indicating the purpose of the file) ?
Just touching the README should be enough I would say.
Quoted 8 lines
Quoted 8 lines
Quoted 2 lines
the firmware won't recognize the overlays directory if the user later moves it to an
os_prefixspecific sub-directory.What is the goal here, in the context of Buildroot, where we only install one set of overlays?
If a user moved the overlays, they already have a script that does that, so they should also ensure that script properly prepares config.txt to specify the properos_prefix, and so it is just a matter of adding a 'touch' on the README in the same script.Quoted 4 lines
It's fairly common for non-expert users to modify the output of a buildroot image
without re-building the image themselves. Adding a README file reduces the risk of them being tripped up by this difference in behaviour.
Quoted 4 lines
So, if I read you correctly: non-expert users know they can move the overlays to a sub-dir; they also know they have to set the
os_prefixaccordingly in config.txt; but they don't know they have to create a README in there? ;-)
We've found that many industrial customers prototype their software on Raspberry Pi OS before using Buildroot or Yocto to create a dedicated OS image. Using os_prefix + a GPIO conditional is a common pattern and it would be nice if this worked as easily on buildroot as elsewhere. I've resubmitted the patch with a zero byte README. If anyone wants to create a really small image then they would remove unused .dtbo files or just have a fixed DTB. Therefore, I think the overhead of having a single empty README file should be acceptable.
Quoted 6 lines
Sorry, I am still unconvinced.
Regards,
Yann E. MORIN.
Quoted 7 lines
--
.-----------------.--------------------.------------------.--------------------.| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot