]> rtime.felk.cvut.cz Git - pes-rpp/rpp-lib.git/commitdiff
Cleanup cyclic include dependencies in hal.h
authorMichal Sojka <sojkam1@fel.cvut.cz>
Tue, 7 Jul 2015 10:12:48 +0000 (12:12 +0200)
committerMichal Sojka <sojkam1@fel.cvut.cz>
Tue, 7 Jul 2015 10:12:48 +0000 (12:12 +0200)
rpp/include/hal/hal.h
rpp/include/hal/spi.h
rpp/include/hal/spi_resp_transl.h
rpp/include/hal/spi_tms570.h
rpp/include/ul/ul_utdefs.h
rpp/src/drv/hbridge.c
rpp/src/hal/_tms570_rpp/port_def.c
rpp/src/hal/spi_tms570.c

index f1581f1a289115b0060b451948a5f37172b43fc6..3a0ee571e69e53fd67f380b950f5163da6edbae6 100644 (file)
 #elif defined(TARGET_TMS570_RPP)
 #include "hal/_tms570_rpp/gpio_def.h"
 #include "hal/_tms570_rpp/port_def.h"
-#include "hal/port_spi.h"
-#include "hal/spi_tms570.h"
-#include "hal/spi.h"
-#include "hal/spi_resp_transl.h"
 #else
 #error No supported target specified!
 #endif
index b4b70fdac35253e78fbdc4cc5bf2a86436413640..2fd0187b4920158bdc9bb55129a6cf9e0930e964 100644 (file)
@@ -9,11 +9,7 @@
 #ifndef _SPI_DRV_H_
 #define _SPI_DRV_H_
 
-//#include "sys_common.h"
-//#include "string.h"
-//#include "cpu_def.h"
-#include "hal/hal.h"
-
+#include "hal/spi_tms570.h"
 
 UL_LIST_CUST_DEC(spi_rq_queue, spi_drv_t, spi_msg_head_t, rq_queue, node)
 
index 98150c8483c57c3473ce5a9636125385c8cde963..c7cc41020681c5e36f615621c34c419ba2fdadd3 100644 (file)
@@ -12,7 +12,6 @@
 
 //#include "hal_port_def.h"
 //#include "cmdproc_utils.h"
-#include "hal/hal.h"
 
 #define NUM_SPI_DEVICES 7
 #define DIN_NUM_GLOB_FD     24
index 13c1455e5f1543b861b636969f2fd644ce211307..cde2f336e33b057c456f95be04299ee46f215fb2 100644 (file)
@@ -13,7 +13,8 @@
 //#include "sys_common.h"
 //#include "drv_spi.h"
 #include "ul/ul_list.h"
-#include "hal/hal.h"
+#include "types.h"
+#include "sys/cpu_def.h"
 
 #define SPI_IFC_ON 1
 #define SPI_CTRL_WAKE_RQ 1
index 0f45a03612d1a434c408580bd951c5d4a0a4ab4a..c53e8ae8a626fadf22bb9307da7d9420b4be8d78 100644 (file)
@@ -9,6 +9,8 @@
 #ifndef _UL_UTDEFS_H
 #define _UL_UTDEFS_H
 
+#include <stddef.h> /* For size_t */
+
 #ifdef __cplusplus
 extern "C" {
 #endif
index bf2ded9373e4378ee66533a5cd4bcb83f9dce3cb..f3d49738849d97092dbb201ff45050b0f33afcba 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 2013 Czech Technical University in Prague
+/* Copyright (C) 2013, 2015 Czech Technical University in Prague
  *
  * Authors:
  *     - Michal Horn
@@ -22,6 +22,7 @@
 // PWM is available for HBR control.
 #include "drv/drv.h"
 #include <os/semphr.h>
+#include "hal/spi.h"
 
 //Flag variable if pwm was initialized and is ready to start.
 static boolean_t pwm_initialized = FALSE;
index 9b099b5a61c92e7819f87752ed31fbddefb0b317..456d7d29b91a1e4c0fd267d3c95ad8111f851495 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 2012-2013 Czech Technical University in Prague
+/* Copyright (C) 2012-2013, 2015 Czech Technical University in Prague
  *
  * Authors:
  *     - Michal Horn <hornmich@fel.cvut.cz>
@@ -25,6 +25,9 @@
 
 #include "hal/hal.h"
 
+#include "hal/port_spi.h"
+#include "hal/spi.h"
+
 // Lists of pins assigned to the ports
 static uint32_t port_cfg_dinmcu[] = PORT_CFG_DINMCU;
 static uint32_t port_cfg_dinspi[] = PORT_CFG_DINSPI;
index b0ba5506385f714b86716d8091249703aecc96b3..b221b2c35cff8f89dca8a3bd73296a4fb9b3044e 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 2012-2013 Czech Technical University in Prague
+/* Copyright (C) 2012-2013, 2015 Czech Technical University in Prague
  *
  * This document contains proprietary information belonging to Czech
  * Technical University in Prague. Passing on and copying of this
  * Code based on Halcogen generated source code
  */
 
-//#include "spi_tms570.h"
+#include "hal/spi.h"
+#include "sys/port.h"
 //#include "drv_spi.h"
 //#include "sys_common.h"
 //#include "ti_drv_dmm.h"
-#include "hal/hal.h"
+#include "sys/ti_drv_dmm.h"
 
 static int spi_tms570_ctrl_fnc(spi_drv_t *ifc, int ctrl, void *p);