Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,734,299 Members 49,001 Now Online
XDA Developers Android and Mobile Development Forum

[DEV][Info] BoardConfig.mk for kernel developer and AOSP (platform) developer

Tip us?
 
F3niX
Old
#11  
F3niX's Avatar
Senior Member
Thanks Meter 293
Posts: 674
Join Date: Jul 2010
Location: Hyderabad
Where have you been Mate?? Awesome Work!! Continue!!
Daily Driver:
Moto G XT1033 || 16GB || Amzer Pudding Case

My Paperweights :
Galaxy R || Lumia 520
Hit THANKS If I have Helped you

Development Guides for Interested Developers (Galaxy R Subforum Link)
Development Guides for Interested Developers (Main Page Link)
 
UnknownzD
Old
(Last edited by UnknownzD; 2nd May 2012 at 04:21 PM.)
#12  
Senior Member - OP
Thanks Meter 388
Posts: 224
Join Date: Oct 2011
So I have figured out our right BoardConfig.mk. Do not change the TARGET_ARCH_VARIANT_FPU, otherwise the boot.img won't boot @ all.

LOCAL_PATH := $(call my-dir)
#USE_CAMERA_STUB := true

# inherit from the proprietary version
-include vendor/samsung/I9103/BoardConfigVendor.mk

TARGET_CPU_ABI := armeabi-v7a
TARGET_CPU_ABI2 := armeabi
TARGET_ARCH_VARIANT := armv7-a
TARGET_ARCH_VARIANT_CPU := cortex-a9
# DO NOT change the following line to vfpv3 as it is not supported on our device!
TARGET_ARCH_VARIANT_FPU := vfpv3-d16
TARGET_CPU_SMP := true
ARCH_ARM_HAVE_TLS_REGISTER := true
TARGET_HAVE_TEGRA_ERRATA_657451 := true
TARGET_BOARD_PLATFORM := tegra
TARGET_BOARD_PLATFORM_GPU := tegra # Useless for CM7 build
TARGET_BOOTLOADER_BOARD_NAME := n1
TARGET_USERIMAGES_USE_EXT4 := true

BOARD_KERNEL_CMDLINE :=
BOARD_KERNEL_BASE := 0x10000000
BOARD_KERNEL_PAGESIZE := 2048

# fix this up by examining /proc/mtd on a running device
# Boot image size is 16384 x 512 bytes = 8388608
# You can double check it with fdisk -l /dev/block/mmcblk0p8
BOARD_BOOTIMAGE_PARTITION_SIZE := 0x00800000
# Recovery image size is 10240 x 512 bytes = 5242880
# You can double check it with fdisk -l /dev/block/mmcblk0p8
BOARD_RECOVERYIMAGE_PARTITION_SIZE := 0x00500000
# System image size is 1228800 x 512 bytes = 629145600
# You can double check it with fdisk -l /dev/block/mmcblk0p2
BOARD_SYSTEMIMAGE_PARTITION_SIZE := 0x25800000
# User data image size is 4194304 x 512 bytes = 2147483648
# You can double check it with fdisk -l /dev/block/mmcblk0p6
BOARD_USERDATAIMAGE_PARTITION_SIZE := 0x80000000
BOARD_FLASH_BLOCK_SIZE := 2048

TARGET_PREBUILT_KERNEL := device/samsung/I9103/kernel

TARGET_NO_KERNEL := false
TARGET_NO_RECOVERY := false
TARGET_NO_BOOTLOADER := true
TARGET_NO_RADIOIMAGE := true

BOARD_HAS_NO_SELECT_BUTTON := true
# Use this flag if the board has a ext4 partition larger than 2gb
BOARD_HAS_LARGE_FILESYSTEM := true
The Following 6 Users Say Thank You to UnknownzD For This Useful Post: [ Click to Expand ]
 
UnknownzD
Old
#13  
Senior Member - OP
Thanks Meter 388
Posts: 224
Join Date: Oct 2011
btw the errata fix is for our cpu and is only needed on userland (non-kernel side binary), do not remove that errata fix otherwise the SMP part doesn't work. It requires the errata patch to make it working.
The Following 4 Users Say Thank You to UnknownzD For This Useful Post: [ Click to Expand ]
 
FranzJesus
Old
#14  
Senior Member
Thanks Meter 201
Posts: 119
Join Date: May 2010
Quote:
Originally Posted by UnknownzD View Post
So I have figured out our right BoardConfig.mk. Do not change the TARGET_ARCH_VARIANT_FPU, otherwise the boot.img won't boot @ all.

LOCAL_PATH := $(call my-dir)
#USE_CAMERA_STUB := true

# inherit from the proprietary version
-include vendor/samsung/I9103/BoardConfigVendor.mk

TARGET_CPU_ABI := armeabi-v7a
TARGET_CPU_ABI2 := armeabi
TARGET_ARCH_VARIANT := armv7-a
TARGET_ARCH_VARIANT_CPU := cortex-a9
# DO NOT change the following line to vfpv3 as it is not supported on our device!
TARGET_ARCH_VARIANT_FPU := vfpv3-d16
TARGET_CPU_SMP := true
ARCH_ARM_HAVE_TLS_REGISTER := true
TARGET_HAVE_TEGRA_ERRATA_657451 := true
TARGET_BOARD_PLATFORM := tegra
TARGET_BOARD_PLATFORM_GPU := tegra # Useless for CM7 build
TARGET_BOOTLOADER_BOARD_NAME := n1
TARGET_USERIMAGES_USE_EXT4 := true

BOARD_KERNEL_CMDLINE :=
BOARD_KERNEL_BASE := 0x10000000
BOARD_KERNEL_PAGESIZE := 2048

# fix this up by examining /proc/mtd on a running device
# Boot image size is 16384 x 512 bytes = 8388608
# You can double check it with fdisk -l /dev/block/mmcblk0p8
BOARD_BOOTIMAGE_PARTITION_SIZE := 0x00800000
# Recovery image size is 10240 x 512 bytes = 5242880
# You can double check it with fdisk -l /dev/block/mmcblk0p8
BOARD_RECOVERYIMAGE_PARTITION_SIZE := 0x00500000
# System image size is 1228800 x 512 bytes = 629145600
# You can double check it with fdisk -l /dev/block/mmcblk0p2
BOARD_SYSTEMIMAGE_PARTITION_SIZE := 0x25800000
# User data image size is 4194304 x 512 bytes = 2147483648
# You can double check it with fdisk -l /dev/block/mmcblk0p6
BOARD_USERDATAIMAGE_PARTITION_SIZE := 0x80000000
BOARD_FLASH_BLOCK_SIZE := 2048

TARGET_PREBUILT_KERNEL := device/samsung/I9103/kernel

TARGET_NO_KERNEL := false
TARGET_NO_RECOVERY := false
TARGET_NO_BOOTLOADER := true
TARGET_NO_RADIOIMAGE := true

BOARD_HAS_NO_SELECT_BUTTON := true
# Use this flag if the board has a ext4 partition larger than 2gb
BOARD_HAS_LARGE_FILESYSTEM := true
Compiling a CM7 build right now!!!
Will be back soon...
Thank you soo much!!
The Following 3 Users Say Thank You to FranzJesus For This Useful Post: [ Click to Expand ]
 
UnknownzD
Old
#15  
Senior Member - OP
Thanks Meter 388
Posts: 224
Join Date: Oct 2011
Quote:
Originally Posted by FranzJesus View Post
Compiling a CM7 build right now!!!
Will be back soon...
Thank you soo much!!
If you guys want to see the difference between the old armv7-a.mk and my version, look it here : http://review.cyanogenmod.com/#/c/15...arm/armv7-a.mk

Now I need some time to finish my CWM, by working on the ramdisk.
The Following 4 Users Say Thank You to UnknownzD For This Useful Post: [ Click to Expand ]
 
UnknownzD
Old
#16  
Senior Member - OP
Thanks Meter 388
Posts: 224
Join Date: Oct 2011
I have a minor update on the first post as changing the line
TARGET_ARCH_VARIANT_FPU := vfpv3
to
TARGET_ARCH_VARIANT_FPU := vfpv3-d16

That is because our device won't boot with the code compiled with -mfpu=vfpv3. Please refer to the first post for more info.
The Following User Says Thank You to UnknownzD For This Useful Post: [ Click to Expand ]
 
CallMeVentus
Old
#17  
CallMeVentus's Avatar
Recognized Contributor
Thanks Meter 2866
Posts: 9,968
Join Date: Jul 2011
Location: Singapore

 
DONATE TO ME
Wow you're good . My hat's off to you sire

This was sent from a Galaxy Ace. Problem?
Current phone: Sony Xperia SP LTE (C5303), Samsung Galaxy S Advance NFC (GT-I9070P)
Here's my Twitter. Follow me, block me, suit yourself.
Old phones: Galaxy R, Motorola Defy, Samsung Galaxy Ace, Motorola Backflip



Galaxy Ace newbie guide: http://forum.xda-developers.com/show....php?t=1225493

 
"The unholy offspring of lightning and death itself"
 
CallMeVentus
Old
#18  
CallMeVentus's Avatar
Recognized Contributor
Thanks Meter 2866
Posts: 9,968
Join Date: Jul 2011
Location: Singapore

 
DONATE TO ME
Will the errata patch update the ARMv7 revision ?

This was sent from a Galaxy Ace. Problem?
Current phone: Sony Xperia SP LTE (C5303), Samsung Galaxy S Advance NFC (GT-I9070P)
Here's my Twitter. Follow me, block me, suit yourself.
Old phones: Galaxy R, Motorola Defy, Samsung Galaxy Ace, Motorola Backflip



Galaxy Ace newbie guide: http://forum.xda-developers.com/show....php?t=1225493

 
"The unholy offspring of lightning and death itself"
 
UnknownzD
Old
#19  
Senior Member - OP
Thanks Meter 388
Posts: 224
Join Date: Oct 2011
Quote:
Originally Posted by EmoBoiix3 View Post
Will the errata patch update the ARMv7 revision ?

This was sent from a Galaxy Ace. Problem?
The errata patch does not update the ARM revision (if you are talking the one captured from cpuinfo). That is because basically all the erratas cannot be patched as it is a hardware problem or bug. However, we can avoid such thing happens (such as errata in race condition) by applying the so called 'patch'. Therefore those patches are NOT fixing the problem at all, instead they just try to avoid it.
The Following User Says Thank You to UnknownzD For This Useful Post: [ Click to Expand ]
 
CallMeVentus
Old
#20  
CallMeVentus's Avatar
Recognized Contributor
Thanks Meter 2866
Posts: 9,968
Join Date: Jul 2011
Location: Singapore

 
DONATE TO ME
Quote:
Originally Posted by UnknownzD View Post
The errata patch does not update the ARM revision (if you are talking the one captured from cpuinfo). That is because basically all the erratas cannot be patched as it is a hardware problem or bug. However, we can avoid such thing happens (such as errata in race condition) by applying the so called 'patch'. Therefore those patches are NOT fixing the problem at all, instead they just try to avoid it.
Ohh , you meant by workarounds !
Current phone: Sony Xperia SP LTE (C5303), Samsung Galaxy S Advance NFC (GT-I9070P)
Here's my Twitter. Follow me, block me, suit yourself.
Old phones: Galaxy R, Motorola Defy, Samsung Galaxy Ace, Motorola Backflip



Galaxy Ace newbie guide: http://forum.xda-developers.com/show....php?t=1225493

 
"The unholy offspring of lightning and death itself"

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes