Re: [PATCH] mvebu: create bbu handler for kwb images and use it on cubox

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Jun 08, 2018 at 10:42:44AM +0200, Uwe Kleine-König wrote:
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx>
> ---
> Hello,
> 
> together with the fixup for write_file_flash to not use O_TRUNC and
> O_CREAT, this was tested on top of next.
> 
> Best regards
> Uwe
> 
>  arch/arm/boards/solidrun-cubox/board.c | 15 ++++++-
>  arch/arm/mach-mvebu/Makefile           |  1 +
>  arch/arm/mach-mvebu/include/mach/bbu.h |  3 ++
>  arch/arm/mach-mvebu/kwb_bbu.c          | 54 ++++++++++++++++++++++++++
>  4 files changed, 72 insertions(+), 1 deletion(-)
>  create mode 100644 arch/arm/mach-mvebu/include/mach/bbu.h
>  create mode 100644 arch/arm/mach-mvebu/kwb_bbu.c
> 
> diff --git a/arch/arm/boards/solidrun-cubox/board.c b/arch/arm/boards/solidrun-cubox/board.c
> index a28f4197dfd4..aac93afb0c89 100644
> --- a/arch/arm/boards/solidrun-cubox/board.c
> +++ b/arch/arm/boards/solidrun-cubox/board.c
> @@ -14,4 +14,17 @@
>   *
>   */
>  
> -/* empty */
> +#include <common.h>
> +#include <init.h>
> +#include <mach/bbu.h>
> +
> +static int cubox_devices_init(void)
> +{
> +	if (!of_machine_is_compatible("solidrun,cubox"))
> +		return 0;
> +
> +	mvebu_bbu_flash_register_handler("flash", "/dev/m25p0", 0, true);

This breaks linking when bbu support is disabled. You'll have to
provide some static inline wrapper for this case.

Sascha


-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox




[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux