From f56533b70259b94e57e382275c74187b6ef634c6 Mon Sep 17 00:00:00 2001 From: Kaspar Schleiser Date: Fri, 25 Jan 2019 10:58:54 +0100 Subject: [PATCH 1/3] uncrustify: add indentation section comment --- uncrustify-riot.cfg | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/uncrustify-riot.cfg b/uncrustify-riot.cfg index d67a512f6f..54e46a5858 100644 --- a/uncrustify-riot.cfg +++ b/uncrustify-riot.cfg @@ -1,3 +1,7 @@ +# +# indentation +# + indent_with_tabs = 0 # 1=indent to level only, 2=indent with tabs input_tab_size = 4 # original tab size output_tab_size = 4 # new tab size From 99d79969828e5974173b28b09f17c87b9e8b1d99 Mon Sep 17 00:00:00 2001 From: Kaspar Schleiser Date: Fri, 25 Jan 2019 11:01:37 +0100 Subject: [PATCH 2/3] uncrustify: change en/disable markers --- uncrustify-riot.cfg | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/uncrustify-riot.cfg b/uncrustify-riot.cfg index 54e46a5858..5a0cb26bd7 100644 --- a/uncrustify-riot.cfg +++ b/uncrustify-riot.cfg @@ -85,3 +85,10 @@ align_right_cmt_span = 3 # # set PROTO_WRAP ISR # Wrap ISR macros like functions + +# +# enable / disable marker config +# + +disable_processing_cmt = " begin{code-style-ignore}" +enable_processing_cmt = " end{code-style-ignore}" From 674128ea271c371bf7813a7484b6734c94415047 Mon Sep 17 00:00:00 2001 From: Kaspar Schleiser Date: Fri, 25 Jan 2019 11:04:01 +0100 Subject: [PATCH 3/3] boards/hifive1: adapt to RIOT uncrustify markers --- boards/hifive1/board.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/boards/hifive1/board.c b/boards/hifive1/board.c index 78b588504e..038a6527ae 100644 --- a/boards/hifive1/board.c +++ b/boards/hifive1/board.c @@ -96,7 +96,7 @@ void board_init_clock(void) /* Note: The range is limited to ~100MHz and depends on PLL settings */ PRCI_set_hfrosctrim_for_f_cpu(CPU_DESIRED_FREQ, PRCI_FREQ_UNDERSHOOT); - /* disable uncrustify *INDENT-OFF* */ + /* begin{code-style-ignore} */ SPI0_REG(SPI_REG_FFMT) = /* setup "Fast Read Dual I/O" 1-1-2 */ SPI_INSN_CMD_EN | /* Enable memory-mapped flash */ SPI_INSN_ADDR_LEN(3) | /* 25LP128 read commands have 3 address bytes */ @@ -106,7 +106,7 @@ void board_init_clock(void) SPI_INSN_DATA_PROTO(SPI_PROTO_D) | /* data protocol for given instruction */ SPI_INSN_CMD_CODE(0xbb) | /* Set the instruction to "Fast Read Dual I/O" */ SPI_INSN_PAD_CODE(0x00); /* Dummy cycle sends 0 value bits */ - /* *INDENT-ON* */ + /* end{code-style-ignore} */ SPI0_REG(SPI_REG_SCKDIV) = SCKDIV; }