This page is not fully translated, yet. Please help completing the translation.
(remove this paragraph once the translation is finished)
grep -lri mt300a target/
该文件夹对应固件中的/sbin文件夹, 一般为通用的<arch_name> sbin脚本和工具.
设备树源文件(Device tree source files, 简写为dts).
子目录 patches-xxx 是对一个 目标版本xxx 的内核补丁.
0xx - upstream backports
1xx - code awaiting upstream merge
2xx - kernel build / config / header patches
3xx - architecture specific patches
4xx - mtd related patches (subsystem and drivers)
5xx - filesystem related patches
6xx - generic network patches
7xx - network / phy driver patches
8xx - other drivers
9xx - uncategorized other patches
All patches must be written in a way that they are potentially upstreamable, meaning:
- they must contain a proper subject
- they must contain a proper commit message explaining what they change
- they must contain a valid Signed-off-by line
Test firmware images without writing them to flash by using ramdisk images.
In make menuconfig select Target Images and then you can select the ramdisk option.
This will create an image with kernel + initramfs, that will have initramfs in the name. The resulting image can be loaded in the device through the bootloader's tftp function and should boot to a prompt without relying on flash/filesystem support.
In order to collect relevant data for a port of LEDE to the device of interest one wants shell access. Most devices though do not offer a way to get a shell with telnet or ssh.
With netgear-telnetenable many Netgear devices can be opened up for telnet access. Also see GitHub: insanid/NetgearTelnetEnable. When such means cannot be used, one could try to flash an image build from the sources published by the vendor with telnetd enabled.
With nmrpflash many Netgear devices can be flashed. Devices that are compatible with this tool become effectively unbrickable.
On WikiDevi lots of information can be found, e.g. the FCC ID is very useful when searching for documentation, datasheets and internal photo's (to be able to distinguish used chips without having to open the casing).
Typically one can use the following commands:
dmesg # log buffer might be to small, see note 1. cat /proc/cmdline cat /proc/cpuinfo cat /proc/meminfo cat /proc/devices ls /sys/devices/platform cat /proc/mtd cat /sys/class/mtd/mtd*/offset # Linux 4.1 and newer, see note 2. ifconfig -a ls /sys/class/net brctl show
Note 1: Often the log buffer is to small and the earliest messages may be missing from the information retrieved with
dmesg. If one build a stock image from the sources the vendor has published, a larger buffer size can be set within the kernel config.
Another useful tool for getting information for setting LEDs might be gpiodump, a MT7620 GPIOMODE register dumper (RAMIPS).
Sometimes no normal means such as scp or ftp are available for retrieving files from a device. Still one could use httpd and busybox its mount command to do so. How?
Assume the files with relevant data on the device with IP address
192.168.0.123 are stored under
/tmp and pages of the web interface are served from
On the device do:
cp important-data.txt /tmp mount -o bind /tmp /www
After that the data on the host connected to the device do: