mirror of
git://git.openwrt.org/openwrt/openwrt.git
synced 2024-12-26 16:42:47 +00:00
mediatek: mt7623: rename gen_banana_pi_img.sh → gen_mtk_mmc_img.sh
As I buy more hardware and continue to work on consolidation, This will apply to a lot of MediaTek platforms; rename it accordingly. Signed-off-by: David Woodhouse <dwmw2@infradead.org>
This commit is contained in:
parent
f5cebbe2e4
commit
1113dcab05
@ -1,4 +1,4 @@
|
||||
config BANANA_PI_BOOT_PARTSIZE
|
||||
int "Boot (SD Card) filesystem partition size (in MiB)"
|
||||
config MTK_BOOT_PARTSIZE
|
||||
int "Boot (SD Card/eMMC) filesystem partition size (in MiB)"
|
||||
depends on TARGET_mediatek_mt7623_DEVICE_bpi_bananapi-r2 || TARGET_DEVICE_mediatek_mt7623_DEVICE_bpi_bananapi-r2
|
||||
default 32
|
||||
|
@ -27,7 +27,7 @@
|
||||
# The second partition is a FAT file system containing the kernel
|
||||
# image and a uboot.env file, which is provided to this script as
|
||||
# $4 (bootfs image). Its size is configurable with the
|
||||
# CONFIG_BANANA_PI_BOOT_PARTSIZE option; by default 32MiB.
|
||||
# CONFIG_MTK_BOOT_PARTSIZE option; by default 32MiB.
|
||||
#
|
||||
# The root filesystem comes next in the third partition.
|
||||
#
|
||||
@ -56,7 +56,7 @@
|
||||
# |----------------------|
|
||||
# | MBR partition #2 |
|
||||
# | |
|
||||
# | FAT partition | ( BANANA_PI_BOOT_PARTSIZE
|
||||
# | FAT partition | ( MTK_BOOT_PARTSIZE
|
||||
# . . default 32MiB )
|
||||
# . (kernel, uEnv) .
|
||||
# | |
|
@ -1,30 +1,30 @@
|
||||
KERNEL_LOADADDR := 0x80008000
|
||||
DEVICE_VARS += UBOOT_TARGET UBOOT_OFFSET UBOOT_ENVSIZE
|
||||
|
||||
ifneq ($(CONFIG_BANANA_PI_BOOT_PARTSIZE),)
|
||||
ifneq ($(CONFIG_MTK_BOOT_PARTSIZE),)
|
||||
BOOTFS_BLOCK_SIZE := 1024
|
||||
BOOTFS_BLOCKS := $(shell echo $$(($(CONFIG_BANANA_PI_BOOT_PARTSIZE)*1024*1024/$(BOOTFS_BLOCK_SIZE))))
|
||||
BOOTFS_BLOCKS := $(shell echo $$(($(CONFIG_MTK_BOOT_PARTSIZE)*1024*1024/$(BOOTFS_BLOCK_SIZE))))
|
||||
endif
|
||||
|
||||
define Build/banana-pi-sdcard
|
||||
define Build/mtk-mmc-img
|
||||
rm -f $@.boot
|
||||
mkfs.fat -C $@.boot $(BOOTFS_BLOCKS)
|
||||
|
||||
if [ -r $(STAGING_DIR_IMAGE)/$(UBOOT_TARGET)-preloader.bin ]; then \
|
||||
./gen_banana_pi_img.sh emmc $@.emmc \
|
||||
./gen_mtk_mmc_img.sh emmc $@.emmc \
|
||||
$(STAGING_DIR_IMAGE)/$(UBOOT_TARGET)-preloader.bin; \
|
||||
mcopy -i $@.boot $@.emmc ::eMMCboot.bin; \
|
||||
fi
|
||||
mkenvimage -s $(UBOOT_ENVSIZE) -o $(STAGING_DIR_IMAGE)/$(UBOOT_TARGET)-uboot.env $(UBOOT_TARGET)-uEnv.txt
|
||||
mcopy -i $@.boot $(STAGING_DIR_IMAGE)/$(UBOOT_TARGET)-uboot.env ::uboot.env
|
||||
mcopy -i $@.boot $(IMAGE_KERNEL) ::uImage
|
||||
./gen_banana_pi_img.sh sd $@ \
|
||||
./gen_mtk_mmc_img.sh sd $@ \
|
||||
$(STAGING_DIR_IMAGE)/$(UBOOT_TARGET)-preloader.bin \
|
||||
$(STAGING_DIR_IMAGE)/$(UBOOT_TARGET)-u-boot*.bin \
|
||||
$(UBOOT_OFFSET) \
|
||||
$@.boot \
|
||||
$(IMAGE_ROOTFS) \
|
||||
$(CONFIG_BANANA_PI_BOOT_PARTSIZE) \
|
||||
$(CONFIG_MTK_BOOT_PARTSIZE) \
|
||||
$(CONFIG_TARGET_ROOTFS_PARTSIZE)
|
||||
endef
|
||||
|
||||
@ -47,7 +47,7 @@ define Device/bpi_bananapi-r2
|
||||
UBOOT_OFFSET := 320k
|
||||
UBOOT_TARGET := mt7623n_bpir2
|
||||
IMAGES := img.gz
|
||||
IMAGE/img.gz := banana-pi-sdcard | gzip | append-metadata
|
||||
IMAGE/img.gz := mtk-mmc-img | gzip | append-metadata
|
||||
ARTIFACT/preloader.bin := preloader $$(UBOOT_TARGET)
|
||||
ARTIFACT/scatter.txt := scatterfile $$(firstword $$(FILESYSTEMS))-$$(firstword $$(IMAGES))
|
||||
ARTIFACTS = preloader.bin scatter.txt
|
||||
|
Loading…
Reference in New Issue
Block a user