Use MBED_ALIGN and remove mbed.h from header

pull/14075/head
Ahmet Alincak 2021-01-11 15:08:14 +03:00
parent 1fd7de0eee
commit 2ca990eb53
3 changed files with 4 additions and 12 deletions

View File

@ -18,7 +18,6 @@
#ifndef USBPHYHW_H
#define USBPHYHW_H
#include "mbed.h"
#include "USBPhy.h"

View File

@ -18,6 +18,7 @@
#if defined(DEVICE_USBDEVICE) && (DEVICE_USBDEVICE) && \
(defined(TARGET_MAX32620) || defined(TARGET_MAX32625) || defined(TARGET_MAX32630))
#include "mbed.h"
#include "USBPhyHw.h"
#include "usb_phy_api.h"
#include "USBEndpoints_Maxim.h"
@ -57,19 +58,11 @@ static enum {
} control_state;
// Static storage for endpoint buffer descriptor table. Must be 512 byte aligned for DMA.
#ifdef __IAR_SYSTEMS_ICC__
#pragma data_alignment = 512
#else
__attribute__ ((aligned (512)))
#endif
MBED_ALIGN(512)
ep_buffer_descriptor_t ep_buffer_descriptor;
// static storage for temporary data buffers. Must be 32 byte aligned.
#ifdef __IAR_SYSTEMS_ICC__
#pragma data_alignment = 4
#else
__attribute__ ((aligned (4)))
#endif
MBED_ALIGN(4)
static uint8_t aligned_buffer[NUMBER_OF_LOGICAL_ENDPOINTS][MXC_USB_MAX_PACKET];
static uint8_t* read_buf_addr[NUMBER_OF_LOGICAL_ENDPOINTS];

View File

@ -5094,7 +5094,7 @@
"STDIO_MESSAGES",
"USTICKER",
"MPU",
"SLEEP"
"SLEEP",
"USBDEVICE"
],
"release_versions": [