From ca7145009db22011036819333146452ad7be891f Mon Sep 17 00:00:00 2001 From: Biju Das Date: Sun, 13 Dec 2020 20:36:30 +0000 Subject: [PATCH] plat: renesas: rcar: Fix coding style Sort the header includes alphabetically and fix checkpatch warnings. Signed-off-by: Biju Das Reviewed-by: Lad Prabhakar Change-Id: I08fd0d12ee1d8d61391e8afc33f8c67fcf70c4e5 --- plat/renesas/rcar/bl2_cpg_init.c | 14 +++++++------- plat/renesas/rcar/plat_storage.c | 24 +++++++++--------------- 2 files changed, 16 insertions(+), 22 deletions(-) diff --git a/plat/renesas/rcar/bl2_cpg_init.c b/plat/renesas/rcar/bl2_cpg_init.c index c3ca9ea16..175434469 100644 --- a/plat/renesas/rcar/bl2_cpg_init.c +++ b/plat/renesas/rcar/bl2_cpg_init.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015-2019, Renesas Electronics Corporation. All rights reserved. + * Copyright (c) 2015-2020, Renesas Electronics Corporation. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -7,8 +7,8 @@ #include #include -#include "rcar_def.h" #include "cpg_registers.h" +#include "rcar_def.h" #include "rcar_private.h" static void bl2_secure_cpg_init(void); @@ -77,7 +77,7 @@ static void bl2_secure_cpg_init(void) stop_cr5 = 0xBFFFFFFFU; #endif - /** Secure Module Stop Control Registers */ + /* Secure Module Stop Control Registers */ cpg_write(SCMSTPCR0, 0xFFFFFFFFU); cpg_write(SCMSTPCR1, 0xFFFFFFFFU); cpg_write(SCMSTPCR2, stop_cr2); @@ -91,7 +91,7 @@ static void bl2_secure_cpg_init(void) cpg_write(SCMSTPCR10, 0xFFFFFFFFU); cpg_write(SCMSTPCR11, 0xFFFFFFFFU); - /** Secure Software Reset Access Enable Control Registers */ + /* Secure Software Reset Access Enable Control Registers */ cpg_write(SCSRSTECR0, 0x00000000U); cpg_write(SCSRSTECR1, 0x00000000U); cpg_write(SCSRSTECR2, reset_cr2); @@ -152,7 +152,7 @@ static void bl2_system_cpg_init_h3(void) #if (RCAR_LSI == RCAR_AUTO) || (RCAR_LSI == RCAR_M3) static void bl2_realtime_cpg_init_m3(void) { - /** Realtime Module Stop Control Registers */ + /* Realtime Module Stop Control Registers */ cpg_write(RMSTPCR0, 0x00200000U); cpg_write(RMSTPCR1, 0xFFFFFFFFU); cpg_write(RMSTPCR2, 0x040E0FDCU); @@ -169,7 +169,7 @@ static void bl2_realtime_cpg_init_m3(void) static void bl2_system_cpg_init_m3(void) { - /** System Module Stop Control Registers */ + /* System Module Stop Control Registers */ cpg_write(SMSTPCR0, 0x00200000U); cpg_write(SMSTPCR1, 0xFFFFFFFFU); cpg_write(SMSTPCR2, 0x040E2FDCU); @@ -188,7 +188,7 @@ static void bl2_system_cpg_init_m3(void) #if (RCAR_LSI == RCAR_AUTO) || (RCAR_LSI == RCAR_M3N) static void bl2_realtime_cpg_init_m3n(void) { - /** Realtime Module Stop Control Registers */ + /* Realtime Module Stop Control Registers */ cpg_write(RMSTPCR0, 0x00210000U); cpg_write(RMSTPCR1, 0xFFFFFFFFU); cpg_write(RMSTPCR2, 0x040E0FDCU); diff --git a/plat/renesas/rcar/plat_storage.c b/plat/renesas/rcar/plat_storage.c index 05e3d9f0d..652456103 100644 --- a/plat/renesas/rcar/plat_storage.c +++ b/plat/renesas/rcar/plat_storage.c @@ -1,23 +1,22 @@ /* - * Copyright (c) 2015-2017, Renesas Electronics Corporation. All rights reserved. + * Copyright (c) 2015-2020, Renesas Electronics Corporation. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ #include -#include - #include #include #include #include #include "io_common.h" -#include "io_rcar.h" #include "io_memdrv.h" #include "io_emmcdrv.h" #include "io_private.h" +#include "io_rcar.h" +#include static uintptr_t emmcdrv_dev_handle; static uintptr_t memdrv_dev_handle; @@ -167,7 +166,7 @@ static int32_t open_rcar(const uintptr_t spec); struct plat_io_policy { uintptr_t *dev_handle; uintptr_t image_spec; - int32_t(*check) (const uintptr_t spec); + int32_t (*check)(const uintptr_t spec); }; static const struct plat_io_policy policies[] = { @@ -305,7 +304,7 @@ static const struct plat_io_policy policies[] = { (uintptr_t) &bl338_cert_file_spec, &open_rcar}, { #else - { + { #endif 0, 0, 0} }; @@ -322,16 +321,11 @@ static io_drv_spec_t io_drv_spec_emmcdrv = { 0, }; -static struct plat_io_policy drv_policies[] - __attribute__ ((section(".data"))) = { +static struct plat_io_policy drv_policies[] __attribute__ ((section(".data"))) = { /* FLASH_DEV_ID */ - { - &memdrv_dev_handle, - (uintptr_t) &io_drv_spec_memdrv, &open_memmap,}, - /* EMMC_DEV_ID */ - { - &emmcdrv_dev_handle, - (uintptr_t) &io_drv_spec_emmcdrv, &open_emmcdrv,} + { &memdrv_dev_handle, (uintptr_t) &io_drv_spec_memdrv, &open_memmap, }, + /* EMMC_DEV_ID */ + { &emmcdrv_dev_handle, (uintptr_t) &io_drv_spec_emmcdrv, &open_emmcdrv, } }; static int32_t open_rcar(const uintptr_t spec) -- 2.39.5