mirror of
https://github.com/hathach/tinyusb.git
synced 2025-04-25 03:02:26 +00:00
strengthen include policy. Only limited headers are allowed to included from a header file. Missing needed to be included in *.c
This commit is contained in:
parent
f56f6b6749
commit
d6548d0063
@ -279,9 +279,12 @@ void test_register_portsc(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
//--------------------------------------------------------------------+
|
//--------------------------------------------------------------------+
|
||||||
// EHCI Data Organiztion
|
// EHCI Data Organization
|
||||||
//--------------------------------------------------------------------+
|
//--------------------------------------------------------------------+
|
||||||
|
void test_(void)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
//--------------------------------------------------------------------+
|
//--------------------------------------------------------------------+
|
||||||
// Helper
|
// Helper
|
||||||
|
@ -62,12 +62,13 @@ extern "C"
|
|||||||
// Compile-time Assert
|
// Compile-time Assert
|
||||||
//--------------------------------------------------------------------+
|
//--------------------------------------------------------------------+
|
||||||
#ifdef __COUNTER__
|
#ifdef __COUNTER__
|
||||||
#define STATIC_ASSSERT(const_expr) enum { XSTRING_CONCAT(static_assert_, __COUNTER__) = 1/(!!(const_expr)) }
|
#define STATIC_ASSSERT(const_expr) enum { XSTRING_CONCAT(static_assert_, __COUNTER__) = 1/(!!(const_expr)) }
|
||||||
#else
|
#else
|
||||||
#define STATIC_ASSSERT(const_expr) enum { XSTRING_CONCAT(static_assert_, __LINE__) = 1/(!!(const_expr)) }
|
#define STATIC_ASSSERT(const_expr) enum { XSTRING_CONCAT(static_assert_, __LINE__) = 1/(!!(const_expr)) }
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
//#if ( defined CFG_PRINTF_UART || defined CFG_PRINTF_USBCDC || defined CFG_PRINTF_DEBUG )
|
//#if ( defined CFG_PRINTF_UART || defined CFG_PRINTF_USBCDC || defined CFG_PRINTF_DEBUG )
|
||||||
#if TUSB_CFG_DEBUG
|
#if TUSB_CFG_DEBUG == 3
|
||||||
#define _PRINTF(...) printf(__VA_ARGS__)
|
#define _PRINTF(...) printf(__VA_ARGS__)
|
||||||
#else
|
#else
|
||||||
#define _PRINTF(...)
|
#define _PRINTF(...)
|
||||||
|
@ -55,8 +55,6 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "primitive_types.h"
|
|
||||||
|
|
||||||
/// n-th Bit
|
/// n-th Bit
|
||||||
#define BIT_(n) (1 << (n))
|
#define BIT_(n) (1 << (n))
|
||||||
|
|
||||||
|
@ -35,6 +35,7 @@
|
|||||||
* This file is part of the tinyUSB stack.
|
* This file is part of the tinyUSB stack.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "primitive_types.h"
|
||||||
#include "errors.h"
|
#include "errors.h"
|
||||||
|
|
||||||
#if TUSB_CFG_DEBUG == 3
|
#if TUSB_CFG_DEBUG == 3
|
||||||
|
@ -49,8 +49,7 @@
|
|||||||
#ifndef _TUSB_ERRORS_H_
|
#ifndef _TUSB_ERRORS_H_
|
||||||
#define _TUSB_ERRORS_H_
|
#define _TUSB_ERRORS_H_
|
||||||
|
|
||||||
#include "primitive_types.h"
|
#include "tusb_option.h"
|
||||||
#include "../tusb_option.h"
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
extern "C" {
|
extern "C" {
|
||||||
|
@ -51,9 +51,7 @@
|
|||||||
#ifndef _TUSB_TIMEOUT_TTIMER_H_
|
#ifndef _TUSB_TIMEOUT_TTIMER_H_
|
||||||
#define _TUSB_TIMEOUT_TTIMER_H_
|
#define _TUSB_TIMEOUT_TTIMER_H_
|
||||||
|
|
||||||
#include "primitive_types.h"
|
|
||||||
#include "compiler/compiler.h"
|
#include "compiler/compiler.h"
|
||||||
#include "osal/osal.h"
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
extern "C" {
|
extern "C" {
|
||||||
|
@ -52,11 +52,6 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "tusb_option.h"
|
|
||||||
#include "common/primitive_types.h"
|
|
||||||
#include "common/compiler/compiler.h"
|
|
||||||
#include "common/binary.h"
|
|
||||||
|
|
||||||
//--------------------------------------------------------------------+
|
//--------------------------------------------------------------------+
|
||||||
// STANDARD DESCRIPTORS
|
// STANDARD DESCRIPTORS
|
||||||
//--------------------------------------------------------------------+
|
//--------------------------------------------------------------------+
|
||||||
|
@ -55,11 +55,6 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "tusb_option.h"
|
|
||||||
#include "common/primitive_types.h"
|
|
||||||
#include "common/compiler/compiler.h"
|
|
||||||
#include "common/binary.h"
|
|
||||||
|
|
||||||
typedef ATTR_PREPACKED struct ATTR_PACKED {
|
typedef ATTR_PREPACKED struct ATTR_PACKED {
|
||||||
ATTR_PREPACKED struct ATTR_PACKED {
|
ATTR_PREPACKED struct ATTR_PACKED {
|
||||||
uint8_t recipient : 5; /**< Recipient type. */
|
uint8_t recipient : 5; /**< Recipient type. */
|
||||||
|
@ -53,11 +53,6 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "tusb_option.h"
|
|
||||||
#include "common/primitive_types.h"
|
|
||||||
#include "common/compiler/compiler.h"
|
|
||||||
#include "common/binary.h"
|
|
||||||
|
|
||||||
/// defined base on EHCI specs value for Endpoint Speed
|
/// defined base on EHCI specs value for Endpoint Speed
|
||||||
typedef enum {
|
typedef enum {
|
||||||
TUSB_SPEED_FULL = 0,
|
TUSB_SPEED_FULL = 0,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user