Skip to content

Commit 0663321

Browse files
committed
hal: renesas: rx: Restore r_bsp_locking inclusion in r_bsp.h
r_bsp_locking header must included in the r_bsp header file Restore the missing inclusion and remove from the source file Signed-off-by: Quy Tran <[email protected]>
1 parent 5214369 commit 0663321

File tree

6 files changed

+31
-40
lines changed

6 files changed

+31
-40
lines changed

drivers/rx/README

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,6 @@ Patch List:
5757

5858
* Fix the build warnings in RSPI driver
5959
Impacted files:
60-
drivers/rx/rdp/src/r_rspi_rx/src/r_rspi_rx.c
6160
drivers/rx/rdp/src/r_rspi_rx/src/r_rspi_rx_private.h
6261

6362
* Remove the static definition in RIIC driver
@@ -68,17 +67,12 @@ Patch List:
6867
* Fix the build warnings in RIIC driver
6968
Impacted files:
7069
drivers/rx/rdp/src/r_riic_rx/src/r_riic_rx.c
71-
drivers/rx/rdp/src/r_riic_rx/src/targets/rx130/r_riic_rx130.c
7270

7371
* Replace the __builtin_rx_xchg with actual implementation
7472
because Zephyr SDK hasn't support it yet
7573
Impacted files:
7674
drivers/rx/rdp/src/r_bsp/mcu/all/r_rx_intrinsic_functions.h
7775

78-
* Fix the build warnings in IWDT driver
79-
Impacted files:
80-
drivers/rx/rdp/src/r_iwdt_rx/src/r_iwdt_rx.c
81-
8276
* Remove the static definition in LVD isr function
8377
Impacted files:
8478
drivers/rx/rdp/src/r_lvd_rx/src/r_lvd_rx_hw.c

drivers/rx/rdp/src/r_bsp/board/generic_rx130/r_bsp.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ INCLUDE APPROPRIATE MCU AND BOARD FILES
5757
#include "mcu/rx130/register_access/iccrx/iodefine.h"
5858
#endif /* defined(__CCRX__), defined(__GNUC__), defined(__ICCRX__) */
5959
#include "mcu/rx130/r_bsp_cpu.h"
60+
#include "mcu/rx130/r_bsp_locking.h"
6061
#include "mcu/rx130/mcu_clocks.h"
6162
#include "mcu/rx130/mcu_info.h"
6263
#include "mcu/rx130/mcu_init.h"

drivers/rx/rdp/src/r_iwdt_rx/src/r_iwdt_rx.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@ Includes <System Includes> , "Project Includes"
3737
/* Defines for IWDT support */
3838
#include "r_iwdt_rx_config.h"
3939
#include "r_iwdt_rx_if.h"
40-
#include "r_bsp_locking.h"
4140

4241
/***********************************************************************************************************************
4342
Macro definitions

drivers/rx/rdp/src/r_riic_rx/src/targets/rx130/r_riic_rx130.c

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@
55
***********************************************************************************************************************/
66
/***********************************************************************************************************************
77
* File Name : r_riic_rx130.c
8-
* Description : Functions for using RIIC on RX devices.
8+
* Description : Functions for using RIIC on RX devices.
99
**********************************************************************************************************************/
1010
/**********************************************************************************************************************
1111
* History : DD.MM.YYYY Version Description
1212
* : 31.10.2015 1.80 First Release
1313
* : 04.03.2016 1.90 Changed about the pin definisions.
1414
* : 01.10.2016 2.00 Fixed a program according to the Renesas coding rules.
1515
* : 02.06.2017 2.10 Changed include path becuase changed file structure.
16-
* Changed about the calculation processing for address of PFS, PCR,
16+
* Changed about the calculation processing for address of PFS, PCR,
1717
* PDR and PMR register.
1818
* : 20.05.2019 2.41 Added support for GNUC and ICCRX.
1919
* Fixed coding style.
@@ -31,7 +31,6 @@
3131
#if defined(BSP_MCU_RX130)
3232

3333
#include "r_riic_rx_private.h"
34-
#include "r_bsp_locking.h"
3534

3635
/***********************************************************************************************************************
3736
Exported global variables (to be accessed by other files)
@@ -382,14 +381,14 @@ void riic_mcu_power_on (uint8_t channel)
382381
{
383382
#if (1U == RIIC_CFG_CH0_INCLUDED)
384383
case 0x00 :
385-
384+
386385
#if ((R_BSP_VERSION_MAJOR == 5) && (R_BSP_VERSION_MINOR >= 30)) || (R_BSP_VERSION_MAJOR >= 6)
387386
R_BSP_InterruptControl(BSP_INT_SRC_EMPTY, BSP_INT_CMD_FIT_INTERRUPT_DISABLE, &int_ctrl);
388387
#endif
389-
388+
390389
/* Bring module out of stop state. */
391390
MSTP(RIIC0) = 0U;
392-
391+
393392
#if ((R_BSP_VERSION_MAJOR == 5) && (R_BSP_VERSION_MINOR >= 30)) || (R_BSP_VERSION_MAJOR >= 6)
394393
R_BSP_InterruptControl(BSP_INT_SRC_EMPTY, BSP_INT_CMD_FIT_INTERRUPT_ENABLE, &int_ctrl);
395394
#endif
@@ -427,14 +426,14 @@ void riic_mcu_power_off (uint8_t channel)
427426
{
428427
#if (1U == RIIC_CFG_CH0_INCLUDED)
429428
case 0x00 :
430-
429+
431430
#if ((R_BSP_VERSION_MAJOR == 5) && (R_BSP_VERSION_MINOR >= 30)) || (R_BSP_VERSION_MAJOR >= 6)
432431
R_BSP_InterruptControl(BSP_INT_SRC_EMPTY, BSP_INT_CMD_FIT_INTERRUPT_DISABLE, &int_ctrl);
433432
#endif
434-
433+
435434
/* Put module in stop state. */
436435
MSTP(RIIC0) = 1U;
437-
436+
438437
#if ((R_BSP_VERSION_MAJOR == 5) && (R_BSP_VERSION_MINOR >= 30)) || (R_BSP_VERSION_MAJOR >= 6)
439438
R_BSP_InterruptControl(BSP_INT_SRC_EMPTY, BSP_INT_CMD_FIT_INTERRUPT_ENABLE, &int_ctrl);
440439
#endif
@@ -696,7 +695,7 @@ double riic_mcu_check_freq (void)
696695
* Function Name: riic0_eei_isr
697696
* Description : Interrupt EEI handler for channel 0.
698697
* Types of interrupt requests transfer error or event generation.
699-
* The event generations are arbitration-lost, NACK detection, timeout detection,
698+
* The event generations are arbitration-lost, NACK detection, timeout detection,
700699
* start condition detection, and stop condition detection.
701700
* Arguments : None
702701
* Return Value : None

drivers/rx/rdp/src/r_rspi_rx/src/r_rspi_rx.c

Lines changed: 18 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* File Name : r_rspi_rx.c
88
* Description : Functions for using RSPI on RX devices.
99
************************************************************************************************************************
10-
* History : DD.MM.YYYY Version Description
10+
* History : DD.MM.YYYY Version Description
1111
* 25.10.2013 1.00 First Release
1212
* 01.05.2014 1.20 Added support for RX62N. Minor bug fixes.
1313
* 19.01.2014 1.30 Added support for RX113, RX64M, and RX71M
@@ -22,7 +22,7 @@
2222
* 20.12.2018 2.00 Added double buffer and dmadtc transfer mode.
2323
* Supported RX72T.
2424
* 20.05.2019 2.01 Added support for GNUC and ICCRX.
25-
* Fixed coding style.
25+
* Fixed coding style.
2626
* 20.06.2019 2.02 Supported RX23W.
2727
* 30.07.2019 2.03 Supported RX72M.
2828
* 22.11.2019 2.04 Supported RX72N and RX66N.
@@ -35,7 +35,7 @@
3535
* Fixed bug. Set the RSPCK auto-stop function enable bit(SPCR2.SCKASE) and update
3636
* functions rspi_sptiX_isr (X = 0, 1, 2) to ensure RSPI can communication normally when it
3737
* is in high speed reception.
38-
* Fixed two warning when the MCU is RX111 etc., the unused function(rspi_spei_grp_isr)
38+
* Fixed two warning when the MCU is RX111 etc., the unused function(rspi_spei_grp_isr)
3939
* and variable(int_ctrl) will be valid.
4040
* Added communication completion interrupt for rx671.
4141
* 31.07.2021 3.02 Supported RX140.
@@ -46,10 +46,10 @@
4646
* Added idle interrupt for RX671.
4747
* 29.05.2023 3.20 Supported RX23E-B.
4848
* Fixed to comply with GSCE Coding Standards Rev.6.5.0.
49-
* 18.08.2023 3.30 Modified comments of the following API functions: R_RSPI_IntSptiIerClear,
49+
* 18.08.2023 3.30 Modified comments of the following API functions: R_RSPI_IntSptiIerClear,
5050
* R_RSPI_IntSpriIerClear, R_RSPI_DisableSpti, R_RSPI_DisableRSPI.
5151
* 05.10.2023 3.40 Implemented code to clear the SPRF flag at the start of SPI communication.
52-
* Modified the order of disabling the error interrupt and canceling the error
52+
* Modified the order of disabling the error interrupt and canceling the error
5353
* handler registration when disabling interrupts.
5454
* Modified the order of disabling interrupts between SPTI and SPRI
5555
* when disabling interrupts.
@@ -63,7 +63,6 @@ Includes <System Includes> , "Project Includes"
6363
/* Defines for RSPI support */
6464
#include "platform.h"
6565
#include "r_rspi_rx_if.h"
66-
#include "r_bsp_locking.h"
6766

6867
#if RSPI_CFG_LONGQ_ENABLE == 1
6968
/* Uses LONGQ driver header file. */
@@ -492,7 +491,7 @@ rspi_err_t R_RSPI_Open(uint8_t channel, // @suppress("6.6a Sour
492491
{
493492
R_BSP_NOP();
494493
}
495-
494+
496495
/* Peripheral Initialized */
497496
g_rspi_handles[channel].rspi_chnl_opened = true;
498497
g_rspi_handles[channel].pcallback = pcallback;
@@ -1131,7 +1130,7 @@ static rspi_err_t rspi_write_read_common(rspi_handle_t handle,
11311130
* @retval RSPI_ERR_NULL_PTR
11321131
* A required pointer argument is NULL
11331132
* @details Use this function when disabling interrupt from within the callback function generated at DMAC
1134-
* transfer-end or an intentional cancellation of transmission.\n
1133+
* transfer-end or an intentional cancellation of transmission.\n
11351134
* Please call this function after calling R_RSPI_DisableSpti().
11361135
* @note Do not use this function during transmission other than an intentional cancellation of transmission.\n
11371136
* Doing so could disrupt the transfer.
@@ -1204,7 +1203,7 @@ rspi_err_t R_RSPI_IntSptiIerClear(rspi_handle_t handle)
12041203
* @retval RSPI_ERR_NULL_PTR
12051204
* A required pointer argument is NULL
12061205
* @details Use this function when disabling interrupt from within the callback function generated at DMAC
1207-
* transfer-end or an intentional cancellation of transmission.\n
1206+
* transfer-end or an intentional cancellation of transmission.\n
12081207
* Please call this function before calling R_RSPI_DisableRSPI().
12091208
* @note Do not use this function during transmission other than an intentional cancellation of transmission.\n
12101209
* Doing so could disrupt the transfer.
@@ -1277,7 +1276,7 @@ rspi_err_t R_RSPI_IntSpriIerClear(rspi_handle_t handle)
12771276
* @retval RSPI_ERR_NULL_PTR
12781277
* A required pointer argument is NULL
12791278
* @details Use this function when disabling interrupt from within the callback function generated at DMAC
1280-
* transfer-end or an intentional cancellation of transmission.\n
1279+
* transfer-end or an intentional cancellation of transmission.\n
12811280
* Please call this function before calling R_RSPI_IntSptiIerClear().
12821281
* @note Do not use this function during transmission other than an intentional cancellation of transmission.\n
12831282
* Doing so could disrupt the transfer.
@@ -1311,7 +1310,7 @@ rspi_err_t R_RSPI_DisableSpti(rspi_handle_t handle)
13111310
* @retval RSPI_ERR_NULL_PTR
13121311
* A required pointer argument is NULL
13131312
* @details Use this function when disabling the RSPI function from within the callback function generated at DMAC
1314-
* transfer-end or an intentional cancellation of transmission.\n
1313+
* transfer-end or an intentional cancellation of transmission.\n
13151314
* Please call this function after calling R_RSPI_IntSpriIerClear().
13161315
* @note Do not use this function during transmission other than an intentional cancellation of transmission.\n
13171316
* Doing so could disrupt the transfer.
@@ -1865,7 +1864,7 @@ static void rspi_interrupts_clear(uint8_t channel)
18651864
#if defined BSP_MCU_RX671 || defined BSP_MCU_RX26T
18661865
/* Clear any pending communication end interrupts */
18671866
IR(RSPI0, SPCI0) = 0;
1868-
#endif
1867+
#endif
18691868
#if !(defined(BSP_MCU_RX64M) || defined(BSP_MCU_RX71M) || defined(BSP_MCU_RX65N)\
18701869
|| defined(BSP_MCU_RX66T) || defined(BSP_MCU_RX72T) || defined(BSP_MCU_RX72M)\
18711870
|| defined(BSP_MCU_RX72N) || defined(BSP_MCU_RX66N) || defined(BSP_MCU_RX671)\
@@ -1895,7 +1894,7 @@ static void rspi_interrupts_clear(uint8_t channel)
18951894
|| defined(BSP_MCU_RX671))
18961895
/* Clear any pending error interrupt */
18971896
IR(RSPI1, SPEI1) = 0;
1898-
#endif
1897+
#endif
18991898
if (0 == IR(RSPI1, SPTI1))
19001899
{
19011900
R_BSP_NOP();
@@ -2003,7 +2002,7 @@ static void rspi_interrupts_enable(uint8_t channel, bool enabled)
20032002
{
20042003
R_BSP_NOP();
20052004
}
2006-
2005+
20072006
#if defined BSP_MCU_RX64M || defined BSP_MCU_RX71M || defined BSP_MCU_RX65N || defined BSP_MCU_RX66T\
20082007
|| defined BSP_MCU_RX72T || defined BSP_MCU_RX72M || defined BSP_MCU_RX72N || defined BSP_MCU_RX66N\
20092008
|| defined BSP_MCU_RX671 || defined BSP_MCU_RX660 || defined BSP_MCU_RX26T
@@ -2097,7 +2096,7 @@ static void rspi_interrupts_enable(uint8_t channel, bool enabled)
20972096
{
20982097
R_BSP_InterruptRequestEnable(VECT(RSPI1,SPRI1));
20992098
R_BSP_InterruptRequestEnable(VECT(RSPI1,SPTI1));
2100-
#ifdef BSP_MCU_RX671
2099+
#ifdef BSP_MCU_RX671
21012100
R_BSP_InterruptRequestEnable(VECT(RSPI1,SPCI1));
21022101
#endif
21032102
}
@@ -2875,7 +2874,7 @@ static void rspi_spei_isr_common(uint8_t channel)
28752874
/* Clear error source: OVRF flag. */
28762875
(*g_rspi_channels[channel]).SPSR.BIT.OVRF = 0;
28772876
}
2878-
2877+
28792878
if (status_flags & RSPI_SPSR_MODF)
28802879
{
28812880
if (status_flags & RSPI_SPSR_UDRF)
@@ -2899,7 +2898,7 @@ static void rspi_spei_isr_common(uint8_t channel)
28992898
(*g_rspi_channels[channel]).SPSR.BIT.MODF = 0;
29002899
}
29012900
}
2902-
2901+
29032902
if (status_flags & RSPI_SPSR_PERF)
29042903
{
29052904
if (RSPI_EVT_ERR_UNDEF == event)
@@ -3014,7 +3013,7 @@ static void rspi_spei_grp_isr(void *pdata)
30143013
}
30153014
#endif
30163015
#endif
3017-
3016+
30183017
#if defined BSP_MCU_RX65N || defined BSP_MCU_RX72M || defined BSP_MCU_RX72N || defined BSP_MCU_RX66N \
30193018
|| defined BSP_MCU_RX671
30203019
#if RSPI_CFG_USE_CHAN2 == 1
@@ -3219,7 +3218,7 @@ static void rspi_spii_grp_isr(void *pdata)
32193218
}
32203219
#endif
32213220
#endif
3222-
3221+
32233222
#if defined BSP_MCU_RX65N || defined BSP_MCU_RX72M || defined BSP_MCU_RX72N || defined BSP_MCU_RX66N \
32243223
|| defined BSP_MCU_RX671
32253224
#if RSPI_CFG_USE_CHAN2 == 1

drivers/rx/rdp/src/r_s12ad_rx/src/targets/rx130/r_s12ad_rx130.c

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@ Includes <System Includes> , "Project Includes"
3535
/* Includes board and MCU related header files. */
3636
#include <stdio.h>
3737
#include "platform.h"
38-
#include "r_bsp_locking.h"
3938

4039
#if defined (BSP_MCU_RX130)
4140
#include "r_s12ad_rx_config.h"
@@ -217,9 +216,9 @@ adc_err_t adc_open(uint8_t const unit,
217216

218217
p_regs->ADADS0.WORD = 0;
219218
p_regs->ADADS1.WORD = 0;
220-
219+
221220
p_regs->ADADC.BYTE = 0;
222-
221+
223222
p_regs->ADCER.WORD = 0;
224223
p_regs->ADSTRGR.WORD = 0;
225224

@@ -266,7 +265,7 @@ adc_err_t adc_open(uint8_t const unit,
266265
p_regs->ADCMPBSR.BYTE = 0; /* target bit clear by read-modify-write */
267266
p_regs->ADBUFEN.BYTE = 0;
268267
p_regs->ADBUFPTR.BYTE = 0;
269-
268+
270269
/* SET MODE RELATED REGISTER FIELDS */
271270
g_dcb.mode = mode;
272271

0 commit comments

Comments
 (0)