Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions arch/arm/src/nrf52/nrf52_tickless_rtc.c
Original file line number Diff line number Diff line change
Expand Up @@ -202,8 +202,6 @@ static void rtc_cancel_ack(void)
g_tickless_dev.alarm_set = false;

leave_critical_section(flags);

return OK;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why code changes when PR is about Docker configuration update? This is out of scope and hidden change that impacts existing code. If this fixes some other issue this should be provided as separate PR.

Please give a careful read to: https://github.com/apache/nuttx/blob/master/CONTRIBUTING.md

}

/****************************************************************************
Expand Down
2 changes: 0 additions & 2 deletions arch/arm/src/nrf53/nrf53_tickless_rtc.c
Original file line number Diff line number Diff line change
Expand Up @@ -200,8 +200,6 @@ static void rtc_cancel_ack(void)
g_tickless_dev.alarm_set = false;

leave_critical_section(flags);

return OK;
}

/****************************************************************************
Expand Down
2 changes: 0 additions & 2 deletions arch/arm/src/nrf91/nrf91_tickless_rtc.c
Original file line number Diff line number Diff line change
Expand Up @@ -196,8 +196,6 @@ static void rtc_cancel_ack(void)
g_tickless_dev.alarm_set = false;

leave_critical_section(flags);

return OK;
}

/****************************************************************************
Expand Down
5 changes: 5 additions & 0 deletions boards/arm/nrf91/nrf9160-dk/src/Make.defs
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,11 @@ endif

ifeq ($(CONFIG_NRF91_MODEM),y)
CSRCS += nrf91_modem.c

# The modem glue pulls in headers from the proprietary NRFXlib drop, so make
# sure the board objects see the same include path the arch build relies on.
NRFXLIB_DIR = $(TOPDIR)$(DELIM)arch$(DELIM)$(CONFIG_ARCH)$(DELIM)src$(DELIM)chip$(DELIM)sdk-nrfxlib
CFLAGS += ${INCDIR_PREFIX}$(NRFXLIB_DIR)$(DELIM)nrf_modem$(DELIM)include
endif

DEPPATH += --dep-path board
Expand Down
6 changes: 6 additions & 0 deletions boards/arm/nrf91/thingy91/src/Make.defs
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,12 @@ endif

ifeq ($(CONFIG_NRF91_MODEM),y)
CSRCS += nrf91_modem.c

# Give the board objects access to the NRFXlib headers required by the modem
# glue. The archive is downloaded into the chip directory when the feature
# is enabled, so reuse that location here as well.
NRFXLIB_DIR = $(TOPDIR)$(DELIM)arch$(DELIM)$(CONFIG_ARCH)$(DELIM)src$(DELIM)chip$(DELIM)sdk-nrfxlib
CFLAGS += ${INCDIR_PREFIX}$(NRFXLIB_DIR)$(DELIM)nrf_modem$(DELIM)include
endif

DEPPATH += --dep-path board
Expand Down
20 changes: 20 additions & 0 deletions boards/arm/sama5/giant-board/include/board_sdram.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,26 @@

#include <nuttx/config.h>

#ifndef __ASSEMBLY__

#include <stdint.h>

#ifdef __cplusplus
extern "C"
{
#endif

uint32_t sam_pllack_frequency(uint32_t mainclk);
uint32_t sam_plladiv2_frequency(uint32_t mainclk);
uint32_t sam_pck_frequency(uint32_t mainclk);
uint32_t sam_mck_frequency(uint32_t mainclk);

#ifdef __cplusplus
}
#endif

#endif /* __ASSEMBLY__ */

/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
Expand Down
20 changes: 20 additions & 0 deletions boards/arm/sama5/jupiter-nano/include/board_sdram.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,26 @@

#include <nuttx/config.h>

#ifndef __ASSEMBLY__

#include <stdint.h>

#ifdef __cplusplus
extern "C"
{
#endif

uint32_t sam_pllack_frequency(uint32_t mainclk);
uint32_t sam_plladiv2_frequency(uint32_t mainclk);
uint32_t sam_pck_frequency(uint32_t mainclk);
uint32_t sam_mck_frequency(uint32_t mainclk);

#ifdef __cplusplus
}
#endif

#endif /* __ASSEMBLY__ */

/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
Expand Down
72 changes: 46 additions & 26 deletions boards/arm/sama5/sama5d2-xult/include/board_sdram.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,25 @@

#include <nuttx/config.h>

#ifndef __ASSEMBLY__

#include <stdint.h>

#ifdef __cplusplus
extern "C" {

Check failure on line 37 in boards/arm/sama5/sama5d2-xult/include/board_sdram.h

View workflow job for this annotation

GitHub Actions / check

Left bracket not on separate line
#endif

uint32_t sam_pllack_frequency(uint32_t mainclk);
uint32_t sam_plladiv2_frequency(uint32_t mainclk);
uint32_t sam_pck_frequency(uint32_t mainclk);
uint32_t sam_mck_frequency(uint32_t mainclk);

#ifdef __cplusplus
}
#endif

#endif /* __ASSEMBLY__ */

/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
Expand All @@ -47,22 +66,23 @@
* crystal.
*/

#define BOARD_MAINCK_FREQUENCY BOARD_MAINOSC_FREQUENCY
#define BOARD_PLLA_FREQUENCY (sam_pllack_frequency(BOARD_MAINOSC_FREQUENCY))
#define BOARD_PLLADIV2_FREQUENCY (sam_plladiv2_frequency(BOARD_MAINOSC_FREQUENCY))
#define BOARD_PCK_FREQUENCY (sam_pck_frequency(BOARD_MAINOSC_FREQUENCY))
#define BOARD_MCK_FREQUENCY (sam_mck_frequency(BOARD_MAINOSC_FREQUENCY))
#define BOARD_MAINCK_FREQUENCY BOARD_MAINOSC_FREQUENCY
#define BOARD_PLLA_FREQUENCY (sam_pllack_frequency(BOARD_MAINOSC_FREQUENCY))
#define BOARD_PLLADIV2_FREQUENCY \
(sam_plladiv2_frequency(BOARD_MAINOSC_FREQUENCY))
#define BOARD_PCK_FREQUENCY (sam_pck_frequency(BOARD_MAINOSC_FREQUENCY))
#define BOARD_MCK_FREQUENCY (sam_mck_frequency(BOARD_MAINOSC_FREQUENCY))

/* Clocking to certain peripherals may be MCK/2.
*
* REVISIT: I am not sure why this is. Perhaps because of H32MXDIV?
*/

#define BOARD_PIT_FREQUENCY (BOARD_MCK_FREQUENCY >> 1)
#define BOARD_USART_FREQUENCY (BOARD_MCK_FREQUENCY >> 1)
#define BOARD_FLEXCOM_FREQUENCY (BOARD_MCK_FREQUENCY >> 1)
#define BOARD_PIT_FREQUENCY (BOARD_MCK_FREQUENCY >> 1)
#define BOARD_USART_FREQUENCY (BOARD_MCK_FREQUENCY >> 1)
#define BOARD_FLEXCOM_FREQUENCY (BOARD_MCK_FREQUENCY >> 1)

#if defined(CONFIG_SAMA5_EHCI) || defined(CONFIG_SAMA5_OHCI) || \
#if defined(CONFIG_SAMA5_EHCI) || defined(CONFIG_SAMA5_OHCI) || \
defined(CONFIG_SAMA5_UDPHS)

/* The USB Host High Speed requires a 480 MHz clock (UPLLCK) for the embedded
Expand Down Expand Up @@ -90,10 +110,10 @@
* driver is initialized.
*/

# define BOARD_USE_UPLL 1 /* Use UPLL for clock source */
# define BOARD_CKGR_UCKR_UPLLCOUNT (15) /* Maximum value */
# define BOARD_CKGR_UCKR_BIASCOUNT (15) /* Maximum value */
# define BOARD_UPLL_OHCI_DIV (10) /* Divide by 10 */
#define BOARD_USE_UPLL 1 /* Use UPLL for clock source */
#define BOARD_CKGR_UCKR_UPLLCOUNT (15) /* Maximum value */
#define BOARD_CKGR_UCKR_BIASCOUNT (15) /* Maximum value */
#define BOARD_UPLL_OHCI_DIV (10) /* Divide by 10 */
#endif

/* ADC Configuration
Expand All @@ -102,14 +122,15 @@
* PRESCAL = (MCK / (2 * ADCClock) - 1)
*/

#define BOARD_ADCCLK_FREQUENCY (8000000) /* ADCCLK: MCK / ((7+1)*2) */
#define BOARD_ADCCLK_FREQUENCY \
((BOARD_PLLADIV2_FREQUENCY / (2 *BOARD_PLLADIV2_FREQUENCY)) - 1)
#define BOARD_ADCCLK_FREQUENCY (8000000) /* ADCCLK: MCK / ((7+1)*2) */
#define BOARD_ADCCLK_FREQUENCY \
((BOARD_PLLADIV2_FREQUENCY / (2 * BOARD_PLLADIV2_FREQUENCY)) - 1)

#define BOARD_ADC_PRESCAL (7)
#define BOARD_TSD_STARTUP (40) /* 40 nanoseconds */
#define BOARD_TSD_TRACKTIM (2000) /* Min 1µs at 8MHz */
#define BOARD_TSD_DEBOUNCE (10000000) /* 10 milliseconds (units nanoseconds) */
#define BOARD_ADC_PRESCAL (7)
#define BOARD_TSD_STARTUP (40) /* 40 nanoseconds */
#define BOARD_TSD_TRACKTIM (2000) /* Min 1µs at 8MHz */
#define BOARD_TSD_DEBOUNCE (10000000) /* 10 milliseconds (units nanoseconds) \
*/

/* HSMCI clocking
*
Expand All @@ -128,17 +149,17 @@

/* Initial clock: 400 KHz (target) */

#define HSMCI_INIT_CLKDIV sam_hsmci_clkdiv(400000)
#define HSMCI_INIT_CLKDIV sam_hsmci_clkdiv(400000)

/* MMC transfer clock: 20 MHz (target) */

#define HSMCI_MMCXFR_CLKDIV sam_hsmci_clkdiv(20000000)
#define HSMCI_MMCXFR_CLKDIV sam_hsmci_clkdiv(20000000)

/* SD transfer clock: 25 MHz (target) */

#define HSMCI_SDXFR_CLKDIV sam_hsmci_clkdiv(25000000)
#define HSMCI_SDXFR_CLKDIV sam_hsmci_clkdiv(25000000)

#define HSMCI_SDWIDEXFR_CLKDIV HSMCI_SDXFR_CLKDIV
#define HSMCI_SDWIDEXFR_CLKDIV HSMCI_SDXFR_CLKDIV

/****************************************************************************
* Public Data
Expand All @@ -149,8 +170,7 @@
#undef EXTERN
#if defined(__cplusplus)
#define EXTERN extern "C"
extern "C"
{
extern "C" {

Check failure on line 173 in boards/arm/sama5/sama5d2-xult/include/board_sdram.h

View workflow job for this annotation

GitHub Actions / check

Left bracket not on separate line
#else
#define EXTERN extern
#endif
Expand Down
20 changes: 20 additions & 0 deletions boards/arm/sama5/sama5d3-xplained/include/board_sdram.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,26 @@

#include <nuttx/config.h>

#ifndef __ASSEMBLY__

#include <stdint.h>

#ifdef __cplusplus
extern "C"
{
#endif

uint32_t sam_pllack_frequency(uint32_t mainclk);
uint32_t sam_plladiv2_frequency(uint32_t mainclk);
uint32_t sam_pck_frequency(uint32_t mainclk);
uint32_t sam_mck_frequency(uint32_t mainclk);

#ifdef __cplusplus
}
#endif

#endif /* __ASSEMBLY__ */

/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
Expand Down
20 changes: 20 additions & 0 deletions boards/arm/sama5/sama5d3x-ek/include/board_sdram.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,26 @@

#include <nuttx/config.h>

#ifndef __ASSEMBLY__

#include <stdint.h>

#ifdef __cplusplus
extern "C"
{
#endif

uint32_t sam_pllack_frequency(uint32_t mainclk);
uint32_t sam_plladiv2_frequency(uint32_t mainclk);
uint32_t sam_pck_frequency(uint32_t mainclk);
uint32_t sam_mck_frequency(uint32_t mainclk);

#ifdef __cplusplus
}
#endif

#endif /* __ASSEMBLY__ */

/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
Expand Down
20 changes: 20 additions & 0 deletions boards/arm/sama5/sama5d4-ek/include/board_sdram.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,26 @@

#include <nuttx/config.h>

#ifndef __ASSEMBLY__

#include <stdint.h>

#ifdef __cplusplus
extern "C"
{
#endif

uint32_t sam_pllack_frequency(uint32_t mainclk);
uint32_t sam_plladiv2_frequency(uint32_t mainclk);
uint32_t sam_pck_frequency(uint32_t mainclk);
uint32_t sam_mck_frequency(uint32_t mainclk);

#ifdef __cplusplus
}
#endif

#endif /* __ASSEMBLY__ */

/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
Expand Down
3 changes: 1 addition & 2 deletions boards/sim/sim/sim/src/sim_gpio.c
Original file line number Diff line number Diff line change
Expand Up @@ -131,15 +131,14 @@ static struct simgpint_dev_s g_gpint =
* Private Functions
****************************************************************************/

static int sim_interrupt(wdparm_t arg)
static void sim_interrupt(wdparm_t arg)
{
struct simgpint_dev_s *simgpint = (struct simgpint_dev_s *)arg;

DEBUGASSERT(simgpint != NULL && simgpint->callback != NULL);
gpioinfo("Interrupt! callback=%p\n", simgpint->callback);

simgpint->callback(&simgpint->simgpio.gpio, simgpint->simgpio.id);
return OK;
}

static int gpin_read(struct gpio_dev_s *dev, bool *value)
Expand Down
44 changes: 22 additions & 22 deletions drivers/video/isx019.c
Original file line number Diff line number Diff line change
Expand Up @@ -2593,18 +2593,18 @@ static int calc_spot_position_regval(uint16_t val,
static int set_spot_position(FAR isx019_dev_t *priv,
imgsensor_value_t val)
{
uint8_t regval;
uint8_t reg_x;
uint8_t reg_y;
uint16_t w;
uint16_t h;
uint16_t clip_w;
uint16_t clip_h;
uint16_t offset_x;
uint16_t offset_y;
uint8_t regval = 0;
uint8_t reg_x = 0;
uint8_t reg_y = 0;
uint16_t w = 0;
uint16_t h = 0;
uint16_t clip_w = 0;
uint16_t clip_h = 0;
uint16_t offset_x = 0;
uint16_t offset_y = 0;
uint16_t x = (uint16_t)(val.value32 >> 16);
uint16_t y = (uint16_t)(val.value32 & 0xffff);
int split;
int split = 0;

/* Spot position of ISX019 is divided into 9x7 sections.
* - Horizontal direction is divided into 9 sections.
Expand Down Expand Up @@ -3319,18 +3319,18 @@ static uint32_t restore_spot_position(uint16_t regval,
static int get_spot_position(FAR isx019_dev_t *priv,
FAR imgsensor_value_t *val)
{
uint8_t regval;
uint8_t regx;
uint8_t regy;
uint16_t w;
uint16_t h;
uint32_t x;
uint32_t y;
uint16_t clip_w;
uint16_t clip_h;
uint16_t offset_x;
uint16_t offset_y;
int split;
uint8_t regval = 0;
uint8_t regx = 0;
uint8_t regy = 0;
uint16_t w = 0;
uint16_t h = 0;
uint32_t x = 0;
uint32_t y = 0;
uint16_t clip_w = 0;
uint16_t clip_h = 0;
uint16_t offset_x = 0;
uint16_t offset_y = 0;
int split = 0;

isx019_i2c_read(priv, CAT_CATAE, SPOT_FRM_NUM, &regval, 1);

Expand Down
Loading
Loading