OpenWrt – Diff between revs 2 and 3
?pathlinks?
Rev 2 | Rev 3 | |||
---|---|---|---|---|
Line 7... | Line 7... | |||
7 | # |
7 | # |
|
8 | include $(TOPDIR)/rules.mk |
8 | include $(TOPDIR)/rules.mk |
|
9 | include $(INCLUDE_DIR)/image.mk |
9 | include $(INCLUDE_DIR)/image.mk |
|
Line 10... | Line 10... | |||
10 | |
10 | |
|
11 | FAT32_BLOCK_SIZE=1024 |
11 | FAT32_BLOCK_SIZE=1024 |
|
Line 12... | Line 12... | |||
12 | FAT32_BLOCKS=$(shell echo $$(($(CONFIG_TARGET_KERNEL_PARTSIZE)*1024*1024/$(FAT32_BLOCK_SIZE)))) |
12 | FAT32_BLOCKS=$(shell echo $$(($(CONFIG_BRCM2708_SD_BOOT_PARTSIZE)*1024*1024/$(FAT32_BLOCK_SIZE)))) |
|
13 | |
13 | |
|
14 | define Build/Compile |
14 | define Build/Compile |
|
Line 27... | Line 27... | |||
27 | mcopy -i $@.boot $(KDIR)/COPYING.linux :: |
27 | mcopy -i $@.boot $(KDIR)/COPYING.linux :: |
|
28 | mcopy -i $@.boot $(KDIR)/bootcode.bin :: |
28 | mcopy -i $@.boot $(KDIR)/bootcode.bin :: |
|
29 | mcopy -i $@.boot $(KDIR)/LICENCE.broadcom :: |
29 | mcopy -i $@.boot $(KDIR)/LICENCE.broadcom :: |
|
30 | mcopy -i $@.boot $(KDIR)/start.elf :: |
30 | mcopy -i $@.boot $(KDIR)/start.elf :: |
|
31 | mcopy -i $@.boot $(KDIR)/start_cd.elf :: |
31 | mcopy -i $@.boot $(KDIR)/start_cd.elf :: |
|
32 | mcopy -i $@.boot $(KDIR)/start_x.elf :: |
- | ||
33 | mcopy -i $@.boot $(KDIR)/fixup.dat :: |
32 | mcopy -i $@.boot $(KDIR)/fixup.dat :: |
|
34 | mcopy -i $@.boot $(KDIR)/fixup_cd.dat :: |
33 | mcopy -i $@.boot $(KDIR)/fixup_cd.dat :: |
|
35 | mcopy -i $@.boot $(KDIR)/fixup_x.dat :: |
- | ||
36 | mcopy -i $@.boot cmdline.txt :: |
34 | mcopy -i $@.boot cmdline.txt :: |
|
37 | mcopy -i $@.boot config.txt :: |
35 | mcopy -i $@.boot config.txt :: |
|
38 | mcopy -i $@.boot $(IMAGE_KERNEL) ::$(KERNEL_IMG) |
36 | mcopy -i $@.boot $(IMAGE_KERNEL) ::$(KERNEL_IMG) |
|
39 | $(foreach dts,$(shell echo $(DEVICE_DTS)),mcopy -i $@.boot $(DTS_DIR)/$(dts).dtb ::;) |
37 | $(foreach dts,$(shell echo $(DEVICE_DTS)),mcopy -i $@.boot $(DTS_DIR)/$(dts).dtb ::;) |
|
40 | mmd -i $@.boot ::/overlays |
38 | mmd -i $@.boot ::/overlays |
|
Line 42... | Line 40... | |||
42 | mcopy -i $@.boot $(DTS_DIR)/overlays/README ::/overlays/ |
40 | mcopy -i $@.boot $(DTS_DIR)/overlays/README ::/overlays/ |
|
43 | endef |
41 | endef |
|
Line 44... | Line 42... | |||
44 | |
42 | |
|
45 | define Build/sdcard-img |
43 | define Build/sdcard-img |
|
46 | ./gen_rpi_sdcard_img.sh $@ $@.boot $(IMAGE_ROOTFS) \ |
44 | ./gen_rpi_sdcard_img.sh $@ $@.boot $(IMAGE_ROOTFS) \ |
|
47 | $(CONFIG_TARGET_KERNEL_PARTSIZE) $(CONFIG_TARGET_ROOTFS_PARTSIZE) |
45 | $(CONFIG_BRCM2708_SD_BOOT_PARTSIZE) $(CONFIG_TARGET_ROOTFS_PARTSIZE) |
|
Line 48... | Line 46... | |||
48 | endef |
46 | endef |
|
49 | |
47 | |
|
50 | ### Devices ### |
48 | ### Devices ### |
|
Line 57... | Line 55... | |||
57 | endef |
55 | endef |
|
Line 58... | Line 56... | |||
58 | |
56 | |
|
59 | define Device/rpi |
57 | define Device/rpi |
|
60 | DEVICE_TITLE := Raspberry Pi B/B+/CM/Zero/ZeroW |
58 | DEVICE_TITLE := Raspberry Pi B/B+/CM/Zero/ZeroW |
|
61 | DEVICE_DTS := bcm2708-rpi-b bcm2708-rpi-b-plus bcm2708-rpi-cm bcm2708-rpi-0-w |
- | ||
62 | SUPPORTED_DEVICES := \ |
- | ||
63 | rpi-b rpi-b-plus rpi-cm rpi-zero rpi-zero-w \ |
59 | DEVICE_DTS := bcm2708-rpi-b bcm2708-rpi-b-plus bcm2708-rpi-cm bcm2708-rpi-0-w |
|
64 | raspberrypi,model-b raspberrypi,model-b-plus raspberrypi,model-b-rev2 \ |
- | ||
65 | raspberrypi,compute-module raspberrypi,compute-module-1 \ |
- | ||
66 | raspberrypi,model-zero raspberrypi,model-zero-w |
- | ||
67 | DEVICE_PACKAGES := brcmfmac-firmware-43430-sdio brcmfmac-board-rpi2 kmod-brcmfmac wpad-basic |
60 | SUPPORTED_DEVICES := rpi-b rpi-b-plus rpi-cm rpi-zero rpi-zero-w raspberrypi,model-b raspberrypi,model-b-plus raspberrypi,compute-module-1 raspberrypi,model-b-rev2 raspberrypi,model-zero raspberrypi,model-zero-w |
|
68 | endef |
61 | endef |
|
69 | ifeq ($(SUBTARGET),bcm2708) |
62 | ifeq ($(SUBTARGET),bcm2708) |
|
70 | TARGET_DEVICES += rpi |
63 | TARGET_DEVICES += rpi |
|
Line 71... | Line 64... | |||
71 | endif |
64 | endif |
|
72 | |
65 | |
|
73 | define Device/rpi-2 |
66 | define Device/rpi-2 |
|
74 | DEVICE_TITLE := Raspberry Pi 2B/3B/3B+/3CM |
- | ||
75 | DEVICE_DTS := bcm2709-rpi-2-b bcm2710-rpi-3-b bcm2710-rpi-3-b-plus bcm2710-rpi-cm3 |
- | ||
76 | SUPPORTED_DEVICES := \ |
- | ||
77 | rpi-2-b rpi-3-b rpi-3-b-plus rpi-cm \ |
- | ||
78 | raspberrypi,2-model-b \ |
- | ||
79 | raspberrypi,3-model-b raspberrypi,3-model-b-plus \ |
67 | DEVICE_TITLE := Raspberry Pi 2B/3B/3B+/3CM |
|
80 | raspberrypi,3-compute-module raspberrypi,compute-module-3 |
68 | DEVICE_DTS := bcm2709-rpi-2-b bcm2710-rpi-3-b bcm2710-rpi-3-b-plus bcm2710-rpi-cm3 |
|
81 | DEVICE_PACKAGES := brcmfmac-firmware-43430-sdio brcmfmac-firmware-43455-sdio brcmfmac-board-rpi2 brcmfmac-board-rpi3 kmod-brcmfmac wpad-basic |
69 | SUPPORTED_DEVICES := rpi-2-b rpi-3-b rpi-3-b-plus rpi-cm raspberrypi,2-model-b raspberrypi,3-model-b raspberrypi,3-model-b-plus raspberrypi,compute-module-3 |
|
82 | endef |
70 | endef |
|
83 | ifeq ($(SUBTARGET),bcm2709) |
71 | ifeq ($(SUBTARGET),bcm2709) |
|
Line 84... | Line 72... | |||
84 | TARGET_DEVICES += rpi-2 |
72 | TARGET_DEVICES += rpi-2 |
|
85 | endif |
73 | endif |
|
86 | |
74 | |
|
87 | define Device/rpi-3 |
75 | define Device/rpi-3 |
|
88 | KERNEL_IMG := kernel8.img |
- | ||
89 | DEVICE_TITLE := Raspberry Pi 3B/3B+ |
- | ||
90 | DEVICE_DTS := broadcom/bcm2710-rpi-3-b broadcom/bcm2710-rpi-3-b-plus |
76 | KERNEL_IMG := kernel8.img |
|
91 | SUPPORTED_DEVICES := \ |
- | ||
92 | rpi-3-b rpi-3-b-plus \ |
- | ||
93 | raspberrypi,3-model-b raspberrypi,3-model-b-plus \ |
77 | DEVICE_TITLE := Raspberry Pi 3B/3B+ |
|
94 | raspberrypi,3-compute-module raspberrypi,compute-module-3 |
78 | DEVICE_DTS := broadcom/bcm2710-rpi-3-b broadcom/bcm2710-rpi-3-b-plus |
|
95 | DEVICE_PACKAGES := brcmfmac-firmware-43430-sdio brcmfmac-board-rpi2 brcmfmac-firmware-43455-sdio brcmfmac-board-rpi3 kmod-brcmfmac wpad-basic |
79 | SUPPORTED_DEVICES := rpi-3-b rpi-3-b-plus raspberrypi,3-model-b raspberrypi,3-model-b-plus |
|
96 | endef |
80 | endef |