mirror of
https://github.com/cesanta/mongoose.git
synced 2024-12-27 06:51:04 +08:00
Rename driver data structure
This commit is contained in:
parent
21d3678fa7
commit
ddca518cca
@ -70,7 +70,7 @@ int main(void) {
|
||||
// Initialise Mongoose network stack
|
||||
// Specify MAC address, and IP/mask/GW in network byte order for static
|
||||
// IP configuration. If IP/mask/GW are unset, DHCP is going to be used
|
||||
struct mip_driver_stm32 driver_data = {.mdc_cr = 4}; // See driver_stm32.h
|
||||
struct mip_driver_stm32_data driver_data = {.mdc_cr = 4}; // See driver_stm32.h
|
||||
struct mip_if mif = {
|
||||
.mac = {2, 0, 1, 2, 3, 5},
|
||||
.driver = &mip_driver_stm32,
|
||||
|
@ -48,7 +48,7 @@ static void server(void *args) {
|
||||
// IP configuration. If IP/mask/GW are unset, DHCP is going to be used
|
||||
MG_INFO(("Initializing Ethernet driver"));
|
||||
ethernet_init();
|
||||
struct mip_driver_stm32 driver_data = {.mdc_cr = 4}; // See driver_stm32.h
|
||||
struct mip_driver_stm32_data driver_data = {.mdc_cr = 4}; // See driver_stm32.h
|
||||
struct mip_if mif = {
|
||||
.mac = {2, 0, 1, 2, 3, 5},
|
||||
.driver = &mip_driver_stm32,
|
||||
|
@ -70,7 +70,7 @@ int main(void) {
|
||||
// Initialise Mongoose network stack
|
||||
// Specify MAC address, and IP/mask/GW in network byte order for static
|
||||
// IP configuration. If IP/mask/GW are unset, DHCP is going to be used
|
||||
struct mip_driver_stm32 driver_data = {.mdc_cr = 4}; // See driver_stm32.h
|
||||
struct mip_driver_stm32_data driver_data = {.mdc_cr = 4}; // See driver_stm32.h
|
||||
struct mip_if mif = {
|
||||
.mac = {2, 0, 1, 2, 3, 5},
|
||||
.driver = &mip_driver_stm32,
|
||||
|
@ -47,7 +47,7 @@ static void server(void *args) {
|
||||
// IP configuration. If IP/mask/GW are unset, DHCP is going to be used
|
||||
MG_INFO(("Initializing Ethernet driver"));
|
||||
ethernet_init();
|
||||
struct mip_driver_stm32 driver_data = {.mdc_cr = 4}; // See driver_stm32.h
|
||||
struct mip_driver_stm32_data driver_data = {.mdc_cr = 4}; // See driver_stm32.h
|
||||
struct mip_if mif = {
|
||||
.mac = {2, 0, 1, 2, 3, 5},
|
||||
.driver = &mip_driver_stm32,
|
||||
|
@ -102,7 +102,7 @@ static int guess_mdc_cr(void) {
|
||||
}
|
||||
|
||||
static bool mip_driver_stm32_init(struct mip_if *ifp) {
|
||||
struct mip_driver_stm32 *d = (struct mip_driver_stm32 *) ifp->driver_data;
|
||||
struct mip_driver_stm32_data *d = (struct mip_driver_stm32_data *) ifp->driver_data;
|
||||
s_ifp = ifp;
|
||||
|
||||
// Init RX descriptors
|
||||
|
@ -1,6 +1,6 @@
|
||||
#pragma once
|
||||
|
||||
struct mip_driver_stm32 {
|
||||
struct mip_driver_stm32_data {
|
||||
// MDC clock divider. MDC clock is derived from HCLK, must not exceed 2.5MHz
|
||||
// HCLK range DIVIDER mdc_cr VALUE
|
||||
// -------------------------------------
|
||||
|
@ -6029,7 +6029,7 @@ static int guess_mdc_cr(void) {
|
||||
}
|
||||
|
||||
static bool mip_driver_stm32_init(struct mip_if *ifp) {
|
||||
struct mip_driver_stm32 *d = (struct mip_driver_stm32 *) ifp->driver_data;
|
||||
struct mip_driver_stm32_data *d = (struct mip_driver_stm32_data *) ifp->driver_data;
|
||||
s_ifp = ifp;
|
||||
|
||||
// Init RX descriptors
|
||||
|
@ -1504,7 +1504,7 @@ void qp_init(void);
|
||||
#endif
|
||||
|
||||
|
||||
struct mip_driver_stm32 {
|
||||
struct mip_driver_stm32_data {
|
||||
// MDC clock divider. MDC clock is derived from HCLK, must not exceed 2.5MHz
|
||||
// HCLK range DIVIDER mdc_cr VALUE
|
||||
// -------------------------------------
|
||||
|
Loading…
x
Reference in New Issue
Block a user