state: use the given backend storage type name
This ports the following barebox commit:

| commit 84ec155
| Author: Juergen Borleis <jbe@pengutronix.de>
| Date:   Thu Aug 17 11:32:32 2017 +0200
|
|     state: use the given backend storage type name
|
|     Change 119f92b already tried to fix it, but
|     forgets the 'direct' usecase.
|
|     The 'backend-storage-type' node is optional. Its default depends on the
|     capability of the used backend memory, which means "circular" or NULL.
|     The latter defaults to 'direct' in the routines.
|     If it is NULL, the devicetree fixup routine skips exporting a
|     'backend-storage-type' node to the kernel's devicetree.
|
|     But currently if the 'backend-storage-type' node is explicitly given as
|     'direct', it will be skipped silently and set to NULL instead. In this
|     case the user of the 'barebox-state' tool then ends up with the warning:
|
|     "No backend-storage-type found, using default"
|
|     which is annoying, because it was given.
|
|     Storing the given value will still use a NULL if the
|     'backend-storage-type' node isn't defined, but stores everything else if
|     it is defined. Then the 'backend-storage-type' node is present in the
|     kernel's devicetree as well.
|
|     Signed-off-by: Juergen Borleis <jbe@pengutronix.de>
|     Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>

Signed-off-by: Ulrich Ölmann <u.oelmann@pengutronix.de>
Signed-off-by: Roland Hieber <rhi@pengutronix.de>
1 parent 13fe6c4 commit 5562d51ae4b2ed0f7a660b65593c32fede3e6ca3
@Ulrich Ölmann Ulrich Ölmann authored on 18 Dec 2018
Roland Hieber committed on 7 Jan 2019
Showing 1 changed file
View
src/barebox-state/backend_storage.c