📄 net.cdl
字号:
# Description and control over different interfaces
cdl_interface CYGHWR_NET_DRIVER_ETH0 {
display "Does the hardware provide an 'eth0' device?"
requires { CYGHWR_NET_DRIVER_ETH0 <= 1 }
flavor bool
}
cdl_component CYGHWR_NET_DRIVER_ETH0_SETUP_OPTIONS {
display "Initialization options for 'eth0'"
active_if (CYGHWR_NET_DRIVER_ETH0 == 1)
flavor none
no_define
cdl_interface CYGHWR_NET_DRIVER_ETH0_SETUP {
display "Initialization options for 'eth0'"
requires 1 == CYGHWR_NET_DRIVER_ETH0_SETUP
no_define
}
cdl_component CYGHWR_NET_DRIVER_ETH0_MANUAL {
display "Initialize 'eth0' manually?"
default_value 0
implements CYGHWR_NET_DRIVER_ETH0_SETUP
description "
If this option is selected, the eCos library provides no
initialization code for this interface; you must perform
all the initialization in the application, by means of
appropriate ioctl() calls, or by calling init_net() with an
appropriate bootp record you have constructed yourself."
}
cdl_component CYGHWR_NET_DRIVER_ETH0_BOOTP {
display "Use BOOTP/DHCP to initialize 'eth0'?"
default_value 1
implements CYGHWR_NET_DRIVER_ETH0_SETUP
description "
If this option is selected, init_all_network_interfaces()
will use DHCP or BOOTP to acquire initialization data for
this interface, and then set it up accordingly."
cdl_option CYGHWR_NET_DRIVER_ETH0_DHCP {
display "Use DHCP rather than BOOTP for 'eth0'?"
flavor bool
default_value 1
active_if CYGPKG_NET_DHCP
}
cdl_option CYGHWR_NET_DRIVER_ETH0_BOOTP_SHOW {
display "Show BOOTP/DHCP initialization values?"
flavor bool
default_value 1
}
}
cdl_option CYGHWR_NET_DRIVER_ETH0_IPV6_PREFIX {
display "Static IPv6 address prefix for 'eth0'"
flavor booldata
active_if CYGPKG_NET_INET6
default_value { "3ffe:302:11:2" }
description "
This option allows a specific, static address prefix to be set
for an interface running IPv6. When used, the lower 64 bits
of the address will be set to the IPv4 IP address. Note: this
should not be confused with the standard IPv4->IPv6 mapped
addresses, but rather just a simple way to assign addresses
to nodes within an IPv6 network."
}
cdl_component CYGHWR_NET_DRIVER_ETH0_ADDRS {
display "Address setups for 'eth0'"
implements CYGHWR_NET_DRIVER_ETH0_SETUP
no_define
description "
These options let you configure all the initialization data
that init_all_network_interfaces() will use
for 'eth0' statically. Be careful when doing this, because
if you run the same application image on multiple boards,
they will have identical IP addresses and so on; this is a
Bad Thing.
The values you set are inserted in a bootp-style record
that is fed into a common setup routine to configure the
interface. That routine does not in fact use the 'Server
IP address' field.
The bootp record is also available to application code, and
some eCos networking test programs use the 'Server IP
address' field to mean 'a machine we can interact with' for
example to ping or perform ftp with. That is the rationale
for its inclusion here.
The gateway address is used to set up a default route if
nonzero. If you have more than one interface, setting up
more than one default route is will cause malfunctions. A
gateway address of 0.0.0.0 can be set to prevent that route
setup. Of course, your application can add real routes
once the interface(s) initialization is complete."
cdl_option CYGHWR_NET_DRIVER_ETH0_ADDRS_IP {
display "IP address for 'eth0'"
flavor data
default_value { "192.168.1.2" }
}
cdl_option CYGHWR_NET_DRIVER_ETH0_ADDRS_NETMASK {
display "Network mask address for 'eth0'"
flavor data
default_value { "255.255.255.0" }
}
cdl_option CYGHWR_NET_DRIVER_ETH0_ADDRS_BROADCAST {
display "Broadcast address for 'eth0'"
flavor data
default_value { "192.168.1.255" }
}
cdl_option CYGHWR_NET_DRIVER_ETH0_ADDRS_GATEWAY {
display "Gateway/router IP address for 'eth0'"
flavor data
default_value { "192.168.1.1" }
}
cdl_option CYGHWR_NET_DRIVER_ETH0_ADDRS_SERVER {
display "Server IP address for 'eth0'"
flavor data
default_value { "192.168.1.101" }
}
}
}
cdl_interface CYGHWR_NET_DRIVER_ETH1 {
display "Does the hardware provide an 'eth1' device?"
requires { CYGHWR_NET_DRIVER_ETH1 <= 1 }
flavor bool
}
cdl_component CYGHWR_NET_DRIVER_ETH1_SETUP_OPTIONS {
display "Initialization options for 'eth1'"
active_if (CYGHWR_NET_DRIVER_ETH1 == 1)
flavor none
no_define
cdl_interface CYGHWR_NET_DRIVER_ETH1_SETUP {
display "Initialization options for 'eth1'"
requires 1 == CYGHWR_NET_DRIVER_ETH1_SETUP
no_define
}
cdl_component CYGHWR_NET_DRIVER_ETH1_MANUAL {
display "Initialize 'eth1' manually?"
default_value 0
implements CYGHWR_NET_DRIVER_ETH1_SETUP
description "
If this option is selected, the eCos library provides no
initialization code for this interface; you must perform
all the initialization in the application, by means of
appropriate ioctl() calls, or by calling init_net() with an
appropriate bootp record you have constructed yourself."
}
cdl_component CYGHWR_NET_DRIVER_ETH1_BOOTP {
display "Use BOOTP/DHCP to initialize 'eth1'?"
default_value 1
implements CYGHWR_NET_DRIVER_ETH1_SETUP
description "
If this option is selected, init_all_network_interfaces()
will use DHCP or BOOTP to acquire initialization data for
this interface, and then set it up accordingly."
cdl_option CYGHWR_NET_DRIVER_ETH1_DHCP {
display "Use DHCP rather than BOOTP for 'eth1'?"
flavor bool
default_value 1
active_if CYGPKG_NET_DHCP
}
cdl_option CYGHWR_NET_DRIVER_ETH1_BOOTP_SHOW {
display "Show BOOTP/DHCP initialization values?"
flavor bool
default_value 1
}
}
cdl_option CYGHWR_NET_DRIVER_ETH1_IPV6_PREFIX {
display "Static IPv6 address prefix for 'eth1'"
flavor booldata
active_if CYGPKG_NET_INET6
default_value { "3ffe:302:12:2" }
description "
This option allows a specific, static address prefix to be set
for an interface running IPv6. When used, the lower 64 bits
of the address will be set to the IPv4 IP address. Note: this
should not be confused with the standard IPv4->IPv6 mapped
addresses, but rather just a simple way to assign addresses
to nodes within an IPv6 network."
}
cdl_component CYGHWR_NET_DRIVER_ETH1_ADDRS {
display "Address setups for 'eth1'"
implements CYGHWR_NET_DRIVER_ETH1_SETUP
no_define
description "
These options let you configure all the initialization data
that init_all_network_interfaces() will use
for 'eth1' statically. Be careful when doing this, because
if you run the same application image on multiple boards,
they will have identical IP addresses and so on; this is a
Bad Thing.
The values you set are inserted in a bootp-style record
that is fed into a common setup routine to configure the
interface. That routine does not in fact use the 'Server
IP address' field.
The bootp record is also available to application code, and
some eCos networking test programs use the 'Server IP
address' field to mean 'a machine we can interact with' for
example to ping or perform ftp with. That is the rationale
for its inclusion here.
The gateway address is used to set up a default route if
nonzero. If you have more than one interface, setting up
more than one default route is will cause malfunctions. A
gateway address of 0.0.0.0 can be set to prevent that route
setup. Of course, your application can add real routes
once the interface(s) initialization is complete.
This interface 'eth1' has no route set up in the default
configuration."
cdl_option CYGHWR_NET_DRIVER_ETH1_ADDRS_IP {
display "IP address for 'eth1'"
flavor data
default_value { "192.168.1.2" }
}
cdl_option CYGHWR_NET_DRIVER_ETH1_ADDRS_NETMASK {
display "Network mask address for 'eth1'"
flavor data
default_value { "255.255.255.0" }
}
cdl_option CYGHWR_NET_DRIVER_ETH1_ADDRS_BROADCAST {
display "Broadcast address for 'eth1'"
flavor data
default_value { "192.168.1.255" }
}
cdl_option CYGHWR_NET_DRIVER_ETH1_ADDRS_GATEWAY {
display "Gateway/router IP address for 'eth1'"
flavor data
default_value { "0.0.0.0" }
}
cdl_option CYGHWR_NET_DRIVER_ETH1_ADDRS_SERVER {
display "Server IP address for 'eth1'"
flavor data
default_value { "192.168.1.101" }
}
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -