From: Masami Hiramatsu
Add 'mkfwumdata' tool to generate FWU metadata image for the meta-data
partition to be used in A/B Update imeplementation.
Signed-off-by: Masami Hiramatsu
Signed-off-by: Sughosh Ganu
Signed-off-by: Jassi Brar
---
tools/Kconfig | 9 ++
tools/Makefile | 4 +
From: Jassi Brar
Add code to support FWU_MULTI_BANK_UPDATE.
The platform does not have gpt-partition storage for
Banks and MetaData, rather it used SPI-NOR backed
mtd regions for the purpose.
Signed-off-by: Jassi Brar
---
board/socionext/developerbox/Makefile | 1 +
board/socionext/dev
From: Masami Hiramatsu
Add helper functions needed for accessing the FWU metadata which
contains information on the updatable images.
Signed-off-by: Masami Hiramatsu
Signed-off-by: Jassi Brar
---
include/fwu.h | 34
lib/fwu_updates/Makefile | 1 +
lib/fwu_updates/fwu_
From: Jassi Brar
Specify Bank-0/1 and fwu metadata mtd regions.
Signed-off-by: Jassi Brar
---
.../synquacer-sc2a11-developerbox-u-boot.dtsi | 49 +--
1 file changed, 46 insertions(+), 3 deletions(-)
diff --git a/arch/arm/dts/synquacer-sc2a11-developerbox-u-boot.dtsi
b/arch/ar
From: Jassi Brar
Towards enabling FWU and supporting new firmware layout in NOR flash,
make u-boot PIC and adjust uboot env offset in flash.
Signed-off-by: Jassi Brar
---
configs/synquacer_developerbox_defconfig | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/configs/sy
From: Masami Hiramatsu
In the FWU Multi Bank Update feature, the information about the
updatable images is stored as part of the metadata, on a separate
region. Add a driver for reading from and writing to the metadata
when the updatable images and the metadata are stored on a raw
MTD region.
Si
From: Jassi Brar
Introduce support for mtd backed storage for FWU feature and enable it on
Synquacer platform based DeveloperBox.
This revision is rebased onto patchset that trims the FWU api
https://lore.kernel.org/u-boot/20230306231747.1888513-1-jassisinghb...@gmail.com/
Changes since v3:
From: Jassi Brar
fwu_get_mdata() no more requires 'dev' argument and
fwu_check_mdata_validity() has been rendered useless and dropped.
Fix the test cases to work with aforementioned changes.
Signed-off-by: Jassi Brar
---
test/dm/fwu_mdata.c | 22 +++---
1 file changed, 3 insert
From: Jassi Brar
The common code can now read, verify and fix meta-data copies
while exposing one consistent structure to users.
Only the .read_mdata() and .write_mdata() callbacks of fwu_mdata_ops
are needed. Get rid of .get_mdata() .update_mdata() .get_mdata_part_num()
.read_mdata_partition()
From: Jassi Brar
fwu_get_mdata() sounds more appropriate than fwu_get_verified_mdata()
Signed-off-by: Jassi Brar
Reviewed-by: Etienne Carriere
Reviewed-by: Ilias Apalodimas
---
cmd/fwu_mdata.c | 2 +-
include/fwu.h | 4 ++--
lib/fwu_updates/fwu.c | 6 +++---
3 files changed, 6
From: Jassi Brar
Moving towards using common code for meta-data management,
implement the read/write mdata hooks.
Signed-off-by: Jassi Brar
Reviewed-by: Etienne Carriere
Reviewed-by: Ilias Apalodimas
---
drivers/fwu-mdata/gpt_blk.c | 36
1 file changed, 3
From: Jassi Brar
Instead of each i/f having to implement their own meta-data verification
and storage, move the logic in common code. This simplifies the i/f code
much simpler and compact.
Signed-off-by: Jassi Brar
---
drivers/fwu-mdata/fwu-mdata-uclass.c | 34 +++
include/fwu.h
From: Jassi Brar
Use cached values and avoid parsing and scanning through partitions
everytime for meta-data partitions because they can't change after bootup.
Acked-by: Etienne Carriere
Reviewed-by: Ilias Apalodimas
Signed-off-by: Jassi Brar
---
drivers/fwu-mdata/gpt_blk.c | 43
From: Jassi Brar
Any requirement of FWU should not require changes to bindings
of other subsystems. For example, for mtd-backed storage we
can do without requiring 'fixed-partitions' children to also
carry 'uuid', a property which is non-standard and not in the
bindings.
There exists no code ye
From: Jassi Brar
The patchset reduces ~400 lines of code, while keeping the functionality same
and making
meta-data operations much faster (by using cached structures).
Issue:
meta-data copies (primary and secondary) are being handled by the
backend/storage layer
instead of the common core in
From: Jassi Brar
fwu_get_mdata() sounds more appropriate than fwu_get_verified_mdata()
Signed-off-by: Jassi Brar
Reviewed-by: Etienne Carriere
Reviewed-by: Ilias Apalodimas
---
cmd/fwu_mdata.c | 2 +-
include/fwu.h | 4 ++--
lib/fwu_updates/fwu.c | 6 +++---
3 files changed, 6
From: Jassi Brar
The common code can now read, verify and fix meta-data copies
while exposing one consistent structure to users.
Only the .read_mdata() and .write_mdata() callbacks of fwu_mdata_ops
are needed. Get rid of .get_mdata() .update_mdata() .get_mdata_part_num()
.read_mdata_partition()
From: Jassi Brar
Moving towards using common code for meta-data management,
implement the read/write mdata hooks.
Signed-off-by: Jassi Brar
Reviewed-by: Etienne Carriere
Reviewed-by: Ilias Apalodimas
---
drivers/fwu-mdata/gpt_blk.c | 36
1 file changed, 3
From: Jassi Brar
Instead of each i/f having to implement their own meta-data verification
and storage, move the logic in common code. This simplifies the i/f code
much simpler and compact.
Signed-off-by: Jassi Brar
---
drivers/fwu-mdata/fwu-mdata-uclass.c | 34 +++
include/fwu.h
From: Jassi Brar
Use cached values and avoid parsing and scanning through partitions
everytime for meta-data partitions because they can't change after bootup.
Acked-by: Etienne Carriere
Reviewed-by: Ilias Apalodimas
Signed-off-by: Jassi Brar
---
drivers/fwu-mdata/gpt_blk.c | 43
From: Jassi Brar
Any requirement of FWU should not require changes to bindings
of other subsystems. For example, for mtd-backed storage we
can do without requiring 'fixed-partitions' children to also
carry 'uuid', a property which is non-standard and not in the
bindings.
There exists no code ye
From: Jassi Brar
The patchset reduces ~400 lines of code, while keeping the functionality same
and making
meta-data operations much faster (by using cached structures).
Issue:
meta-data copies (primary and secondary) are being handled by the
backend/storage layer
instead of the common core in
From: Jassi Brar
fwu_get_mdata() sounds more appropriate than fwu_get_verified_mdata()
Signed-off-by: Jassi Brar
Reviewed-by: Etienne Carriere
Reviewed-by: Ilias Apalodimas
---
cmd/fwu_mdata.c | 2 +-
include/fwu.h | 4 ++--
lib/fwu_updates/fwu.c | 6 +++---
3 files changed, 6
From: Jassi Brar
The common code can now read, verify and fix meta-data copies
while exposing one consistent structure to users.
Only the .read_mdata() and .write_mdata() callbacks of fwu_mdata_ops
are needed. Get rid of .get_mdata() .update_mdata() .get_mdata_part_num()
.read_mdata_partition()
From: Jassi Brar
Moving towards using common code for meta-data management,
implement the read/write mdata hooks.
Signed-off-by: Jassi Brar
Reviewed-by: Etienne Carriere
Reviewed-by: Ilias Apalodimas
---
drivers/fwu-mdata/gpt_blk.c | 36
1 file changed, 3
From: Jassi Brar
Instead of each i/f having to implement their own meta-data verification
and storage, move the logic in common code. This simplifies the i/f code
much simpler and compact.
Signed-off-by: Jassi Brar
---
drivers/fwu-mdata/fwu-mdata-uclass.c | 34 +++
include/fwu.h
From: Jassi Brar
Use cached values and avoid parsing and scanning through partitions
everytime for meta-data partitions because they can't change after bootup.
Acked-by: Etienne Carriere
Reviewed-by: Ilias Apalodimas
Signed-off-by: Jassi Brar
---
drivers/fwu-mdata/gpt_blk.c | 43
From: Jassi Brar
The patchset reduces ~400 lines of code, while keeping the functionality same
and making
meta-data operations much faster (by using cached structures).
Issue:
meta-data copies (primary and secondary) are being handled by the
backend/storage layer
instead of the common core in
From: Jassi Brar
fwu_get_mdata() sounds more appropriate than fwu_get_verified_mdata()
Signed-off-by: Jassi Brar
---
Forgot to send this patch previously in v2
cmd/fwu_mdata.c | 2 +-
include/fwu.h | 4 ++--
lib/fwu_updates/fwu.c | 6 +++---
3 files changed, 6 insertions(+), 6 d
From: Jassi Brar
The common code can now read, verify and fix meta-data copies
while exposing one consistent structure to users.
Only the .read_mdata() and .write_mdata() callbacks of fwu_mdata_ops
are needed. Get rid of .get_mdata() .update_mdata() .get_mdata_part_num()
.read_mdata_partition()
From: Jassi Brar
Moving towards using common code for meta-data management,
implement the read/write mdata hooks.
Signed-off-by: Jassi Brar
---
drivers/fwu-mdata/gpt_blk.c | 40 +++--
1 file changed, 38 insertions(+), 2 deletions(-)
diff --git a/drivers/fwu-mda
From: Jassi Brar
Instead of each i/f having to implement their own meta-data verification
and storage, move the logic in common code. This simplifies the i/f code
much simpler and compact.
Signed-off-by: Jassi Brar
---
drivers/fwu-mdata/fwu-mdata-uclass.c | 34 +++
include/fwu.h
From: Jassi Brar
Use cached values and avoid parsing and scanning through partitions
everytime for meta-data partitions because they can't change after bootup.
Acked-by: Etienne Carriere
Signed-off-by: Jassi Brar
---
drivers/fwu-mdata/gpt_blk.c | 43 +
1 fi
From: Jassi Brar
The patchset reduces ~400 lines of code, while keeping the functionality same
and making
meta-data operations much faster (by using cached structures).
Issue:
meta-data copies (primary and secondary) are being handled by the
backend/storage layer
instead of the common core in
From: Jassi Brar
The common code can now read, verify and fix meta-data copies
while exposing one consistent structure to users.
Only the .read_mdata() and .write_mdata() callbacks of fwu_mdata_ops
are needed. Get rid of .get_mdata() .update_mdata() .get_mdata_part_num()
.read_mdata_partition()
From: Jassi Brar
Moving towards using common code for meta-data management,
implement the read/write mdata hooks.
Signed-off-by: Jassi Brar
---
drivers/fwu-mdata/gpt_blk.c | 36
1 file changed, 36 insertions(+)
diff --git a/drivers/fwu-mdata/gpt_blk.c b/dr
From: Jassi Brar
Instead of each i/f having to implement their own meta-data verification
and storage, move the logic in common code. This simplifies the i/f code
much simpler and compact.
Signed-off-by: Jassi Brar
---
drivers/fwu-mdata/fwu-mdata-uclass.c | 34 +++
include/fwu.h
From: Jassi Brar
Use cached values and avoid parsing and scanning through partitions
everytime for meta-data partitions because they can't change after bootup.
Signed-off-by: Jassi Brar
---
drivers/fwu-mdata/gpt_blk.c | 43 +
1 file changed, 24 insertions(+)
From: Jassi Brar
Hi,
The patchset reduces 400 lines of code, while keeping the functionality same
and making
meta-data operations much faster (by using cached structures).
Issue:
meta-data copies (primary and secondary) are being handled by the
backend/storage layer
instead of the common c
From: Masami Hiramatsu
Add 'mkfwumdata' tool to generate FWU metadata image for the meta-data
partition to be used in A/B Update imeplementation.
Signed-off-by: Masami Hiramatsu
Signed-off-by: Sughosh Ganu
Signed-off-by: Jassi Brar
---
tools/Kconfig | 9 ++
tools/Makefile | 4 +
From: Masami Hiramatsu
Add code to support FWU_MULTI_BANK_UPDATE.
The platform does not have gpt-partition storage for
Banks and MetaData, rather it used SPI-NOR backed
mtd regions for the purpose.
Signed-off-by: Masami Hiramatsu
Signed-off-by: Jassi Brar
---
board/socionext/developerbox/Make
From: Masami Hiramatsu
Specify Bank-0/1 and fwu metadata mtd regions.
Signed-off-by: Masami Hiramatsu
Signed-off-by: Jassi Brar
---
.../synquacer-sc2a11-developerbox-u-boot.dtsi | 22 ++-
1 file changed, 21 insertions(+), 1 deletion(-)
diff --git a/arch/arm/dts/synquacer-sc2a
From: Sughosh Ganu
Add helper functions needed for accessing the FWU metadata which
contains information on the updatable images.
Signed-off-by: Sughosh Ganu
Signed-off-by: Jassi Brar
---
include/fwu.h | 27 ++
lib/fwu_updates/Makefile | 1 +
lib/fwu_updates/fwu_mtd.c | 17
From: Sughosh Ganu
In the FWU Multi Bank Update feature, the information about the
updatable images is stored as part of the metadata, on a separate
region. Add a driver for reading from and writing to the metadata
when the updatable images and the metadata are stored on a raw
MTD region.
Signed
From: Jassi Brar
Introduce support for mtd backed storage for FWU feature and enable it on
Synquacer platform based DeveloperBox.
The patchset has been rebased on latest(v11) submission of FWU Multi Bank Update
feature by Sughosh[1].
[1]
https://lore.kernel.org/u-boot/20220928092956.2535777-1-
From: Jassi Brar
dram_init() can't modify global/static variables, so
move the mem_map setup later when bss is available.
Signed-off-by: Jassi Brar
---
board/socionext/developerbox/developerbox.c | 57 -
1 file changed, 34 insertions(+), 23 deletions(-)
diff --git a/board/
From: Jassi Brar
Identity-map the second and later memory banks which are located >4GB.
Signed-off-by: Jassi Brar
---
board/socionext/developerbox/developerbox.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/board/socionext/developerbox/developerbox.c
b/board/socionext/d
From: Jassi Brar
Add code to support FWU_MULTI_BANK_UPDATE.
The platform does not have gpt-partition storage for
Banks and MetaData, rather it used SPI-NOR backed
mtd regions for the purpose.
Signed-off-by: Masami Hiramatsu
Signed-off-by: Jassi Brar
---
board/socionext/developerbox/Makefile
From: Jassi Brar
specify Bank-0/1 and fwu metadata mtd regions.
Signed-off-by: Masami Hiramatsu
Signed-off-by: Jassi Brar
---
.../synquacer-sc2a11-developerbox-u-boot.dtsi | 22 ++-
1 file changed, 21 insertions(+), 1 deletion(-)
diff --git a/arch/arm/dts/synquacer-sc2a11-dev
From: Sughosh Ganu
Add helper functions needed for accessing the FWU metadata which
contains information on the updatable images.
Signed-off-by: Sughosh Ganu
Signed-off-by: Jassi Brar
---
lib/fwu_updates/Makefile | 1 +
lib/fwu_updates/fwu_mtd.c | 173 ++
From: Sughosh Ganu
In the FWU Multi Bank Update feature, the information about the
updatable images is stored as part of the metadata, on a separate
region. Add a driver for reading from and writing to the metadata
when the updatable images and the metadata are stored on a raw
MTD region.
Signed
From: Sughosh Ganu
Add bindings needed for accessing the FWU metadata regions.
These include the compatible string which point to the access
method, the actual device which stores the FWU metadata and
the offsets for both metadata regions.
The current patch adds basic bindings needed for accessi
From: Jassi Brar
The mtd and synquacer (developerbox) support was dropped from v6[1]
This patchset re-introduces the support over last v7[2] submission of the
patchset.
All the comments on this code over v5 submission have been addressed. Moving
forward
a changelog will be maintained.
[1]
ht
From: Jassi Brar
The mtd and synquacer (developerbox) support was dropped from v6[1]
This patchset re-introduces the support over last v7[2] submission of the
patchset.
All the comments on this code over v5 submission have been addressed. Moving
forward
a changelog will be maintained.
[1]
ht
From: Jassi Brar
MAX3420 implements FullSpeed USB Device over SPI.
Another version MAX3421, also implements USB Host mode.
This driver should be good for the device mode of max3421 as well.
Signed-off-by: Jassi Brar
---
Changes since v2:
- used FIELD_PREP instead of simple left shift operat
From: Jassi Brar
MAX3420 implements FullSpeed USB Device over SPI.
Another version MAX3421, also implements USB Host mode.
This driver should be good for the device mode of max3421 as well.
Signed-off-by: Jassi Brar
---
drivers/usb/gadget/Kconfig| 6 +
drivers/usb/gadget/Makefile
From: Jassi Brar
MAX3420 implements FullSpeed USB Device over SPI.
Another version MAX3421, also implements USB Host mode.
This driver should be good for the device mode of max3421 as well.
Signed-off-by: Jassi Brar
---
drivers/usb/gadget/Kconfig| 6 +
drivers/usb/gadget/Makefile
From: Jassi Brar
MAX3420 implements FullSpeed USB Device over SPI.
Another version MAX3421, also implements USB Host mode.
This driver should be good for the device mode of max3421 as well.
Signed-off-by: Jassi Brar
---
drivers/usb/gadget/Kconfig| 6 +
drivers/usb/gadget/Makefile
From: Jassi Brar
MAX3420 implements FullSpeed USB Device over SPI.
Another version MAX3421, also implements USB Host mode.
This driver should be good for the device mode of max3421 as well.
Signed-off-by: Jassi Brar
---
drivers/usb/gadget/Kconfig| 6 +
drivers/usb/gadget/Makefile
From: Jassi Brar
write_sparse_image could be useful for non-fastboot users.
For ex a platform, without usb-device/fastboot support, could
get sparse images over tftp and write using the mmc command.
Or non-android systems could also leverage the sparse format.
Towards that, this patch removes an
From: Jassi Brar
Provide an alternate path for sparse-images to be
written to MMC. For example, via tftp on platforms
that don't support fastboot protocol. Or when an
image is to written at some offset, rather than the
start of a partition.
Signed-off-by: Jassi Brar
---
cmd/mmc.c | 67
From: Jassi Brar
'sz' has no use for write_sparse_image, remove it simplifying the api.
Signed-off-by: Jassi Brar
---
common/fb_mmc.c| 3 +--
common/fb_nand.c | 3 +--
common/image-sparse.c | 2 +-
include/image-sparse.h | 2 +-
4 files changed, 4 insertions(+), 6 deletions(-)
From: Jassi Brar
Hi,
Having capability to flash sparse images from mmc subsystem could be useful.
For example, non-android/fastboot platforms could leverage the concept. Or
some platforms that need to 'pull' updates (get images over tftp and flash
using mmc). Or when we want to flash image at s
63 matches
Mail list logo