Skip to content
Snippets Groups Projects
Commit 74336bc4 authored by Denis Pynkin's avatar Denis Pynkin
Browse files

Backport patches from Apertis U-Boot


Refresh pstore feature and bootcounter patches.

Signed-off-by: default avatarDenis Pynkin <denis.pynkin@collabora.com>
parent 2f83ad3f
No related branches found
No related tags found
No related merge requests found
This commit is part of merge request !25. Comments created here will be created in the context of that merge request.
......@@ -23,18 +23,17 @@ This command allows:
Signed-off-by: Frédéric Danis <frederic.danis@collabora.com>
---
cmd/Kconfig | 63 ++++++
cmd/Makefile | 1 +
cmd/pstore.c | 416 ++++++++++++++++++++++++++++++++++++++++
configs/mx6qsabrelite_defconfig | 1 +
4 files changed, 481 insertions(+)
cmd/Kconfig | 63 ++++++++
cmd/Makefile | 1 +
cmd/pstore.c | 416 +++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 480 insertions(+)
create mode 100644 cmd/pstore.c
diff --git a/cmd/Kconfig b/cmd/Kconfig
index ea1a325..32898b8 100644
index 6403bc45..7e78343c 100644
--- a/cmd/Kconfig
+++ b/cmd/Kconfig
@@ -1463,6 +1463,69 @@ config CMD_QFW
@@ -1736,6 +1736,69 @@ config CMD_QFW
feature is to allow easy loading of files passed to qemu-system
via -kernel / -initrd
......@@ -105,20 +104,20 @@ index ea1a325..32898b8 100644
config CMD_TERMINAL
diff --git a/cmd/Makefile b/cmd/Makefile
index 15ae4d2..5358025 100644
index f1dd513a..06d7ad73 100644
--- a/cmd/Makefile
+++ b/cmd/Makefile
@@ -106,6 +106,7 @@ obj-$(CONFIG_CMD_PCI) += pci.o
@@ -110,6 +110,7 @@ obj-$(CONFIG_CMD_PCI) += pci.o
endif
obj-y += pcmcia.o
obj-$(CONFIG_CMD_PINMUX) += pinmux.o
obj-$(CONFIG_CMD_PMC) += pmc.o
+obj-$(CONFIG_CMD_PSTORE) += pstore.o
obj-$(CONFIG_CMD_PXE) += pxe.o
obj-$(CONFIG_CMD_PXE) += pxe.o pxe_utils.o
obj-$(CONFIG_CMD_WOL) += wol.o
obj-$(CONFIG_CMD_QFW) += qfw.o
diff --git a/cmd/pstore.c b/cmd/pstore.c
new file mode 100644
index 0000000..1aa08c9
index 00000000..1aa08c95
--- /dev/null
+++ b/cmd/pstore.c
@@ -0,0 +1,416 @@
......@@ -538,15 +537,6 @@ index 0000000..1aa08c9
+ " in /sys/fs/pstore under Linux.\n"
+ " The 'directory-path' should already exist.\n"
+);
diff --git a/configs/mx6qsabrelite_defconfig b/configs/mx6qsabrelite_defconfig
index d059ba0..1990ab5 100644
--- a/configs/mx6qsabrelite_defconfig
+++ b/configs/mx6qsabrelite_defconfig
@@ -28,6 +28,7 @@ CONFIG_CMD_BMP=y
CONFIG_CMD_CACHE=y
CONFIG_CMD_TIME=y
CONFIG_CMD_EXT4_WRITE=y
+CONFIG_CMD_PSTORE=y
# CONFIG_ISO_PARTITION is not set
CONFIG_ENV_IS_IN_SPI_FLASH=y
CONFIG_DM=y
--
2.20.1
......@@ -27,7 +27,7 @@ Signed-off-by: Frédéric Danis <frederic.danis@collabora.com>
diff --git a/doc/README.bootcount b/doc/README.bootcount
new file mode 100644
index 0000000000..b1c22905c6
index 00000000..b1c22905
--- /dev/null
+++ b/doc/README.bootcount
@@ -0,0 +1,51 @@
......@@ -83,7 +83,7 @@ index 0000000000..b1c22905c6
+variables to 0, if a boot was successfully.
+This also prevents writes on all reboots.
diff --git a/drivers/bootcount/bootcount_ext.c b/drivers/bootcount/bootcount_ext.c
index 075e590896..9639e638e9 100644
index 075e5908..9639e638 100644
--- a/drivers/bootcount/bootcount_ext.c
+++ b/drivers/bootcount/bootcount_ext.c
@@ -7,11 +7,21 @@
......@@ -170,5 +170,5 @@ index 075e590896..9639e638e9 100644
unmap_sysmem(buf);
--
2.18.0
2.20.1
......@@ -32,4 +32,6 @@ pinebook-pro/0005-Add-initial-support-for-the-Pinebook-Pro-laptop-from.patch
pinebook-pro/0006-drivers-video-rockchip-fix-building-eDP-and-LVDS-dri.patch
# Apertis patches
apertis/0006-Add-pstore-command.patch
apertis/0007-Add-flag-to-enable-disable-bootcount.patch
apertis/0008-bootcount_ext-Add-Ext4-build-dependency.patch
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment