Change include guards in tmk_core/ and drivers/ to pragma once (#11240)
This commit is contained in:
parent
48f4768d33
commit
1d1d5da43f
60 changed files with 96 additions and 258 deletions
|
@ -22,10 +22,9 @@
|
|||
* @{
|
||||
*/
|
||||
|
||||
#ifndef USB_DRIVER_H
|
||||
# define USB_DRIVER_H
|
||||
#pragma once
|
||||
|
||||
# include <hal_usb_cdc.h>
|
||||
#include <hal_usb_cdc.h>
|
||||
|
||||
/*===========================================================================*/
|
||||
/* Driver constants. */
|
||||
|
@ -35,9 +34,9 @@
|
|||
/* Derived constants and error checks. */
|
||||
/*===========================================================================*/
|
||||
|
||||
# if HAL_USE_USB == FALSE
|
||||
# error "The USB Driver requires HAL_USE_USB"
|
||||
# endif
|
||||
#if HAL_USE_USB == FALSE
|
||||
# error "The USB Driver requires HAL_USE_USB"
|
||||
#endif
|
||||
|
||||
/*===========================================================================*/
|
||||
/* Driver data structures and types. */
|
||||
|
@ -112,21 +111,21 @@ typedef struct {
|
|||
/**
|
||||
* @brief @p SerialDriver specific data.
|
||||
*/
|
||||
# define _qmk_usb_driver_data \
|
||||
_base_asynchronous_channel_data /* Driver state.*/ \
|
||||
qmkusbstate_t state; \
|
||||
/* Input buffers queue.*/ \
|
||||
input_buffers_queue_t ibqueue; \
|
||||
/* Output queue.*/ \
|
||||
output_buffers_queue_t obqueue; \
|
||||
/* End of the mandatory fields.*/ \
|
||||
/* Current configuration data.*/ \
|
||||
const QMKUSBConfig *config;
|
||||
#define _qmk_usb_driver_data \
|
||||
_base_asynchronous_channel_data /* Driver state.*/ \
|
||||
qmkusbstate_t state; \
|
||||
/* Input buffers queue.*/ \
|
||||
input_buffers_queue_t ibqueue; \
|
||||
/* Output queue.*/ \
|
||||
output_buffers_queue_t obqueue; \
|
||||
/* End of the mandatory fields.*/ \
|
||||
/* Current configuration data.*/ \
|
||||
const QMKUSBConfig *config;
|
||||
|
||||
/**
|
||||
* @brief @p SerialUSBDriver specific methods.
|
||||
*/
|
||||
# define _qmk_usb_driver_methods _base_asynchronous_channel_methods
|
||||
#define _qmk_usb_driver_methods _base_asynchronous_channel_methods
|
||||
|
||||
/**
|
||||
* @extends BaseAsynchronousChannelVMT
|
||||
|
@ -158,9 +157,9 @@ struct QMKUSBDriver {
|
|||
/* External declarations. */
|
||||
/*===========================================================================*/
|
||||
|
||||
# ifdef __cplusplus
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
# endif
|
||||
#endif
|
||||
void qmkusbInit(void);
|
||||
void qmkusbObjectInit(QMKUSBDriver *qmkusbp, const QMKUSBConfig *config);
|
||||
void qmkusbStart(QMKUSBDriver *qmkusbp, const QMKUSBConfig *config);
|
||||
|
@ -173,10 +172,8 @@ void qmkusbSOFHookI(QMKUSBDriver *qmkusbp);
|
|||
void qmkusbDataTransmitted(USBDriver *usbp, usbep_t ep);
|
||||
void qmkusbDataReceived(USBDriver *usbp, usbep_t ep);
|
||||
void qmkusbInterruptTransmitted(USBDriver *usbp, usbep_t ep);
|
||||
# ifdef __cplusplus
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
|
||||
#endif /* USB_DRIVER_H */
|
||||
#endif
|
||||
|
||||
/** @} */
|
||||
|
|
|
@ -15,8 +15,7 @@
|
|||
* GPL v2 or later.
|
||||
*/
|
||||
|
||||
#ifndef _USB_MAIN_H_
|
||||
#define _USB_MAIN_H_
|
||||
#pragma once
|
||||
|
||||
// TESTING
|
||||
// extern uint8_t blinkLed;
|
||||
|
@ -89,5 +88,3 @@ int8_t sendchar(uint8_t c);
|
|||
void console_flush_output(void);
|
||||
|
||||
#endif /* CONSOLE_ENABLE */
|
||||
|
||||
#endif /* _USB_MAIN_H_ */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue