Category: LINUX
/opt/freescale/usr/local/gcc-4.4.4-glibc-2.11.1-multilib-1.0/arm-fsl-linux-gnueabi/bin/arm-linux-strip UDHCPD 1. #PATH = $PATH:/etc/apache/bin/home/liyun/work/ltib/rpm/build/linux-2.6.35.3/home/liyun/maye9/ltib/rpm/build
One: DHCP server side: (compiler)
1. Modify Makefile: Add: cross_compile=arm-linux-2. #make, download the generated DHCPD file to the board. Make ldflags= "-static" when I compile I am prompted to have a C file error because the switch case in the file is missing a break.
Use/usr/local/arm/2.95.3/bin/arm-linux-strip to handle, 3. #cp samples/udhcpd.conf/etc/#copy The files under Udhcp/samples to the target board's/etc directory 4. # vi/etc/udhcpd.conf: Modified as follows: 3 # The start and end of the IP lease block
4
5 Start 192.168.1.20 #default: 192.168.0.20 IP address range for WinXP
6 End 192.168.1.25 #default: 192.168.0.254
9 # The interface that UDHCPD would use
10
One interface Wlan0 #default: ETH 0# target Board wireless network card Wlan0, according to the actual situation to rewrite such as RA0 #Examles
222.201.130.30-opt DNS 222.201.130.33 #dns服务器
Option Subnet 255.255.255.0
Router 192.168.1.10 #wlan的 IP address as the gateway address
#opt wins 192.168.10.10 #注释掉
* Option DNS 192.168.1.10 # appened to above DNS servers for a total of 3
Option Domain local
Option Lease 864000 # ten days of seconds aa./DHCPD//Run DHCPD server to this DHCP server to run successfully. II: Softap functional transplant. Refer to the http://my.oschina.net/wuying/blog/54939 blog. Thanks for sharing here. /////////////////////////////////////////////////////////////////
Environment:
Compile System:ubantu 10.04
Target system:imx28
Resource:rt3070_softap_v2.4.0.rar
Ltib---l2.6.35_10.11.01_er_source.tar.gz
Cross compile:arm-none-linux-gnueabi-
Ps:my 中文版 is the primary level (most of Youdao)--Welcome Guidance
reference:http://blog.csdn.net/king_sundi/article/details/6158475
http://blog.csdn.net/linfeng999/article/details/6410224
Compile rt3070ap//////// ///////////////////////
("-" Remove row, "+" add Row)
$ CD 2010_0203_RT3070_SOFTAP_V2.4.0.1_DPA
$ vim Module/makefile
-platform = PC
+platform = SMDK ifeq ($ (PLATFORM), SMDK)
-LINUX_SRC =/home/bhushan/itcenter/may28/linux-2.6-samsung
-cross_compile =/usr/local/arm/4.2.2-eabi/usr/bin/arm-linux-
+LINUX_SRC =/home/lin/desktop/linux-2.6.35.3
+cross_compile =/opt/freescale/usr/local/gcc-4.4.4-glibc-2.11.1-multilib-1.0/arm-fsl-linux-gnueabi/bin/ arm-none-linux-gnueabi-
endif
$ vim Netif/makefile
$ vim Util/makefile
Repair the same as Module/makefile
Repair Usb_buffer_free and Usb_buffer_allow error
$ vim UTIL/OS/LINUX/RT_USB_UTIL.C
Repair following:
#if linux_version_code >= kernel_version (2,5,0)
void *rausb_buffer_alloc (struct usb_device *dev,
size_t size,
gfp_t Mem_flags,
dma_addr_t *DMA)
{
-Return Usb_buffer_alloc (dev, size, mem_flags, DMA);
+ Return usb_alloc_coherent (dev, size, mem_flags, DMA);
}
Export_symbol (Rausb_buffer_alloc);
void Rausb_buffer_free (struct usb_device *dev,
size_t size,
void *addr,
dma_addr_t DMA)
{
-Usb_buffer_free (Dev, size, addr, DMA);
+ usb_free_coherent (dev, size, addr, DMA);
}
Export_symbol (Rausb_buffer_free);
#endif//Linux_version_code//
Repair Rt3070ap:module License ' RALINK ' taints kernel.
$ vim NETIF/OS/LINUX/USB_MAIN_DEV.C
+module_license ("GPL"); $ vim module/common/rtmp_init.c
Repair following:
#ifdef RTMP_MAC_USB
-Module_license ("RALINK");
+ Module_license ("GPL");
#endif//RTMP_MAC_USB//
+ #ifndef RTMP_MAC_USB
+ Module_license ("GPL");
+ #endif
$ sudo make arch=arm kbuild_nopedantic=1//compile dhcpd
$ CD ltib/
$./ltib-c Package List--->
[*] DHCP
[*] Include DHCP Server
[*] Include DHCP Client Support $ CP ROOTFS/USR/SBIN/DHCPD @target ROOTFS/USR/LOCAL/BIN/DHCPD//////////////////////configu Ration dhcpd/////////////////////reference Google (DHCPD configuration)
Example
Ddns-update-style Ad-hoc; Deny Client-updates; Subnet 192.168.1.0 netmask 255.255.255.0 {default-lease-time 21600; max-lease-time 43200; option routers 192.168.1.1; opt Ion Subnet-mask 255.255.255.0; Option broadcast-address 192.168.1.255; Option Domain-name "Http://my.oschina.net/wuying"; Option Domain-name-servers 192.169.1.10; Option Netbios-name-servers 192.168.1.10; Option Www-server 192.168.1.10; Range 192.168.1.20 192.168.1.25;
} $ mkdir-p @target rootfs/var/state/dhcp/
$ Touch @target rootfs/var/state/dhcp/dhcpd.leases
powerboot/////////////////////////
CP *.ko to FileSystem
$ TAR-JXVF rootfs.tar.bz2/tftpboot/
$ sudo make-p/tftpboot/usr/local/module
$ sudo cp module/os/linux/*.ko/tftpboot/usr/local/module
$ sudo cp netif/os/linux/*.ko/tftpboot/usr/local/module
$ sudo cp util/os/linux/*.ko/tftpboot/usr/local/module//CP Ap-set.dat to FileSystem
$ sudo make-p/tftpboot/etc/wireless/rt2870ap
$ sudo cp module/rt2870ap.dat/tftpboot/etc/wireless/rt2870ap/
Set AP Argument
$ vim/tftpboot/etc/wireless/rt2870ap/rt2870ap.dat//Set Powerboot
$ vim/etc/rc.d/rcs
----Added to the last line of behind
+ #install Rc3070ap
+ Insmod/usr/local/module/rtutil3070ap.ko
+ Insmod/usr/local/module/rt3070ap.ko
+ Insmod/usr/local/module/rtnet3070ap.ko + #run Rc3070ap
+ ifconfig RA0 192.168.1.19
+/USR/LOCAL/BIN/DHCPD occurs during migration Insmod, the following error code:
# DMESG | grep atl1c
Atl1c:disagrees about version of symbol Alloc_etherdev_mqs
Atl1c:unknown symbol Alloc_etherdev_mqs (err-22)
Atl1c:disagrees about version of symbol __VLAN_HWACCEL_RX
Atl1c:unknown symbol __VLAN_HWACCEL_RX (err-22)
Atl1c:disagrees about version of symbol Skb_put
Atl1c:unknown symbol Skb_put (err-22)
Atl1c:disagrees about version of symbol CONSUME_SKB
Atl1c:unknown symbol CONSUME_SKB (err-22)
Atl1c:disagrees about version of symbol __netif_schedule
Atl1c:unknown symbol __netif_schedule (err-22)
Atl1c:disagrees about version of symbol Unregister_netdev
Atl1c:unknown symbol Unregister_netdev (err-22)
Atl1c:disagrees about version of symbol ___pskb_trim
Atl1c:unknown symbol ___pskb_trim (err-22)
Atl1c:disagrees about version of symbol ETH_VALIDATE_ADDR
Atl1c:unknown symbol ETH_VALIDATE_ADDR (err-22)
Atl1c:disagrees about version of symbol Pskb_expand_head
Atl1c:unknown symbol Pskb_expand_head (err-22)
Atl1c:disagrees about version of symbol Eth_type_trans
Atl1c:unknown symbol Eth_type_trans (err-22)
Atl1c:disagrees about version of symbol __napi_schedule
Atl1c:unknown symbol __napi_schedule (err-22)
Atl1c:disagrees about version of symbol ETHTOOL_OP_SET_SG
Atl1c:unknown symbol ETHTOOL_OP_SET_SG (err-22)
Atl1c:disagrees about version of symbol Netif_device_detach
Atl1c:unknown symbol Netif_device_detach (err-22)
Atl1c:disagrees about version of symbol Netif_device_attach
Atl1c:unknown symbol Netif_device_attach (err-22)
Atl1c:disagrees about version of symbol DEV_KFREE_SKB_IRQ
Atl1c:unknown symbol DEV_KFREE_SKB_IRQ (err-22)
Atl1c:disagrees about version of symbol Dev_kfree_skb_any
Atl1c:unknown symbol Dev_kfree_skb_any (err-22)
Atl1c:disagrees about version of symbol Netif_napi_add
Atl1c:unknown symbol Netif_napi_add (err-22)
Atl1c:disagrees about version of symbol NETIF_RECEIVE_SKB
Atl1c:unknown symbol NETIF_RECEIVE_SKB (err-22)
Atl1c:disagrees about version of symbol Register_netdev
Atl1c:unknown symbol Register_netdev (err-22)
Atl1c:disagrees about version of symbol Free_netdev
Atl1c:unknown symbol Free_netdev (err-22)
Atl1c:disagrees about version of symbol Ethtool_op_get_link
Atl1c:unknown symbol Ethtool_op_get_link (err-22)
Atl1c:disagrees about version of symbol DEV_ALLOC_SKB
Atl1c:unknown symbol DEV_ALLOC_SKB (err-22)
Atl1c:disagrees about version of symbol Netif_carrier_off
Atl1c:unknown symbol Netif_carrier_off (err-22)
Atl1c:disagrees about version of symbol ETHTOOL_OP_GET_SG
Atl1c:unknown symbol ETHTOOL_OP_GET_SG (err-22)
Atl1c:disagrees about version of symbol netif_carrier_on
Atl1c:unknown symbol netif_carrier_on (err-22)
Atl1c:disagrees about version of symbol Napi_complete
Atl1c:unknown symbol Napi_complete (err-22)
Search solution: The "disagrees about version of symbol" errors seem to imply, your kernel and atl1c modules were built with D ifferent compiler versions or very different configurations. Try rebuilding the kernel (including the Atheros/attansic modules) from scratch:
Make clean
Make
Make Modules_install Strange, the--clean argument should has helped. But perhaps doing the following would make a difference:1. Back up your kernel. config file (cp/usr/src/linux/.config/us R/src/my.config)
2. Cd/usr/src/linux; Make Mrproper
3. Restore the. config file (cp/usr/src/my.config/usr/src/linux/.config)
4. And finally, run Genkernel. is because of the wrong kernel, the kernel porting to be maintained and compiled, including the compiler version. Udhcpd.conf the interface wlan0 #default: ETH 0 changed to RA0.