From 0d9078995804d4344b356c08a8770e5820e2a8de Mon Sep 17 00:00:00 2001 From: Pawit Pornkitprasan Date: Sat, 24 Nov 2012 08:25:55 +0700 Subject: aries-common: Jellybean 4.2 bring up Change-Id: I96c39dc243c3cf2379ee6a41eda74cde75ba3bf9 --- BoardConfigCommon.mk | 6 +- device_base.mk | 5 +- init.aries.rc | 26 ++++----- libbt_vndcfg.txt | 8 +++ libcamera/SecCameraHWInterface.cpp | 2 +- main.conf | 66 ---------------------- .../frameworks/base/core/res/res/values/config.xml | 12 ++-- releasetools/aries_ota_from_target_files | 13 +++-- 8 files changed, 38 insertions(+), 100 deletions(-) create mode 100644 libbt_vndcfg.txt delete mode 100644 main.conf diff --git a/BoardConfigCommon.mk b/BoardConfigCommon.mk index e141e18..fa61dfc 100644 --- a/BoardConfigCommon.mk +++ b/BoardConfigCommon.mk @@ -22,6 +22,7 @@ BOARD_USES_GENERIC_AUDIO := false BOARD_USES_LIBSECRIL_STUB := true +TARGET_ARCH := arm TARGET_CPU_ABI := armeabi-v7a TARGET_CPU_ABI2 := armeabi TARGET_ARCH_VARIANT := armv7-a-neon @@ -67,7 +68,7 @@ BOARD_KERNEL_PAGESIZE := 4096 BOARD_KERNEL_CMDLINE := console=ttyFIQ0,115200 init=/init no_console_suspend BOARD_BOOTIMAGE_PARTITION_SIZE := 7864320 -BOARD_SYSTEMIMAGE_PARTITION_SIZE := 262144000 +BOARD_SYSTEMIMAGE_PARTITION_SIZE := 419430400 BOARD_USERDATAIMAGE_PARTITION_SIZE := 2013265920 BOARD_FLASH_BLOCK_SIZE := 4096 @@ -84,6 +85,9 @@ WIFI_DRIVER_FW_PATH_PARAM := "/sys/module/bcmdhd/parameters/firmware_path" WIFI_DRIVER_FW_PATH_STA := "/vendor/firmware/fw_bcmdhd.bin" WIFI_DRIVER_FW_PATH_AP := "/vendor/firmware/fw_bcmdhd_apsta.bin" +# Bluetooth +BOARD_BLUEDROID_VENDOR_CONF := device/samsung/aries-common/libbt_vndcfg.txt + # Vold BOARD_VOLD_EMMC_SHARES_DEV_MAJOR := true TARGET_USE_CUSTOM_LUN_FILE_PATH := "/sys/devices/platform/s3c-usbgadget/gadget/lun%d/file" diff --git a/device_base.mk b/device_base.mk index 7e03db3..5f0a8d1 100644 --- a/device_base.mk +++ b/device_base.mk @@ -44,8 +44,7 @@ DEVICE_PACKAGE_OVERLAYS := device/samsung/aries-common/overlay PRODUCT_COPY_FILES := \ device/samsung/aries-common/vold.fstab:system/etc/vold.fstab \ device/samsung/aries-common/egl.cfg:system/lib/egl/egl.cfg \ - device/samsung/aries-common/mxt224_ts_input.idc:system/usr/idc/mxt224_ts_input.idc \ - device/samsung/aries-common/main.conf:system/etc/bluetooth/main.conf + device/samsung/aries-common/mxt224_ts_input.idc:system/usr/idc/mxt224_ts_input.idc # Init files PRODUCT_COPY_FILES += \ @@ -153,7 +152,7 @@ PRODUCT_PROPERTY_OVERRIDES := \ # be reachable from resources or other mechanisms. PRODUCT_PROPERTY_OVERRIDES += \ wifi.interface=wlan0 \ - ro.telephony.ril_class=SamsungRIL \ + ro.telephony.ril_class=SamsungExynos3RIL \ ro.telephony.ril.v3=icccardstatus,datacall,signalstrength,facilitylock \ mobiledata.interfaces=pdp0,eth0,gprs,ppp0 \ ro.vold.switchablepair=/mnt/emmc,/mnt/sdcard \ diff --git a/init.aries.rc b/init.aries.rc index acc6cec..f758e97 100644 --- a/init.aries.rc +++ b/init.aries.rc @@ -9,9 +9,8 @@ on init # FIXME: Market checks this variable for space-checking, but downloads to /datadata export DOWNLOAD_CACHE /data/download - mkdir /storage 0050 system sdcard_r - mkdir /storage/sdcard0 0000 system system - mkdir /storage/sdcard1 0000 system system + mkdir /storage/sdcard0 0000 root root + mkdir /storage/sdcard1 0000 root root symlink /storage/sdcard0 /sdcard symlink /storage/sdcard0 /mnt/sdcard symlink /storage/sdcard1 /emmc @@ -59,11 +58,11 @@ on fs chmod 770 /efs/imei # permissions for bluetooth. - chown bluetooth bluetooth /dev/s3c2410_serial0 + chown bluetooth net_bt_stack /dev/s3c2410_serial0 chmod 0600 /dev/s3c2410_serial0 chmod 0660 /sys/class/rfkill/rfkill0/state - chown bluetooth bluetooth /sys/class/rfkill/rfkill0/state - chown bluetooth bluetooth /sys/class/rfkill/rfkill0/type + chown bluetooth net_bt_stack /sys/class/rfkill/rfkill0/state + chown bluetooth net_bt_stack /sys/class/rfkill/rfkill0/type # Permissions for System Server and daemons. chown system system /sys/class/backlight/s5p_bl/brightness @@ -72,6 +71,9 @@ on fs chown radio radio /sys/class/sec/uart_switch/UART_SEL/value chmod 660 /sys/class/sec/uart_switch/UART_SEL/value +# load wifi module + insmod /system/lib/modules/bcmdhd.ko + on post-fs chown system system /datadata chmod 0771 /datadata @@ -115,7 +117,7 @@ service aries-ril-daemon /system/bin/rild socket rild stream 660 root radio socket rild-debug stream 660 radio system user root - group radio cache inet misc audio sdcard_rw log + group radio cache inet misc audio log # 3D init service pvrsrvinit /system/vendor/bin/pvrsrvinit @@ -135,7 +137,7 @@ service wpa_supplicant /system/bin/wpa_supplicant \ disabled oneshot -service dhcpcd_wlan0 /system/bin/dhcpcd -aABKL +service dhcpcd_wlan0 /system/bin/dhcpcd -aABDKL class main disabled oneshot @@ -164,14 +166,6 @@ service bdaddr /system/bin/bdaddr_read on property:init.svc.bootanim=running start bdaddr -service hciattach /system/bin/brcm_patchram_plus --enable_hci --enable_lpm \ - --baudrate 3000000 --patchram /vendor/firmware/bcm4329.hcd /dev/s3c2410_serial0 - class main - user bluetooth - group bluetooth net_bt_admin - disabled - oneshot - # bugreport is triggered by holding down volume down, volume up and power # service bugreport /system/bin/dumpstate -d -v -o /sdcard/bugreports/bugreport # class main diff --git a/libbt_vndcfg.txt b/libbt_vndcfg.txt new file mode 100644 index 0000000..2ba0780 --- /dev/null +++ b/libbt_vndcfg.txt @@ -0,0 +1,8 @@ +BLUETOOTH_UART_DEVICE_PORT = "/dev/s3c2410_serial0" +FW_PATCHFILE_LOCATION = "/vendor/firmware/" +LPM_IDLE_TIMEOUT_MULTIPLE = 5 +SCO_PCM_IF_CLOCK_RATE = 0 +BTVND_DBG = FALSE +BTHW_DBG = TRUE +VNDUSERIAL_DBG = FALSE +UPIO_DBG = FALSE diff --git a/libcamera/SecCameraHWInterface.cpp b/libcamera/SecCameraHWInterface.cpp index d66f12f..2d4999c 100755 --- a/libcamera/SecCameraHWInterface.cpp +++ b/libcamera/SecCameraHWInterface.cpp @@ -979,7 +979,7 @@ void CameraHardwareSec::save_postview(const char *fname, uint8_t *buf, uint32_t uint32_t written = 0; ALOGD("opening file [%s]\n", fname); - int fd = open(fname, O_RDWR | O_CREAT); + int fd = open(fname, O_RDWR | O_CREAT, 0600); if (fd < 0) { ALOGE("failed to create file [%s]: %s", fname, strerror(errno)); return; diff --git a/main.conf b/main.conf deleted file mode 100644 index 3989580..0000000 --- a/main.conf +++ /dev/null @@ -1,66 +0,0 @@ -[General] - -# List of plugins that should not be loaded on bluetoothd startup -#DisablePlugins = network,input - -# Default adaper name -# %h - substituted for hostname -# %d - substituted for adapter id -# %b - substituted for ro.product.brand -# %m - substituted for ro.product.model -# %n - substituted for ro.product.name -Name = %m - -# Default device class. Only the major and minor device class bits are -# considered. -# Local device class -# 0x400000 - Service class: Telephony -# 0x000200 - Major class: Phone -# 0x00000C - Minor class: Smart phone -Class = 0x40020C - -# How long to stay in discoverable mode before going back to non-discoverable -# The value is in seconds. Default is 180, i.e. 3 minutes. -# 0 = disable timer, i.e. stay discoverable forever -DiscoverableTimeout = 120 - -# How long to stay in pairable mode before going back to non-discoverable -# The value is in seconds. Default is 0. -# 0 = disable timer, i.e. stay pairable forever -PairableTimeout = 0 - -# Use some other page timeout than the controller default one -# which is 16384 (10 seconds). -PageTimeout = 8192 - -# Discover scheduler interval used in Adapter.DiscoverDevices -# The value is in seconds. Defaults is 0 to use controller scheduler. -DiscoverSchedulerInterval = 0 - -# What value should be assumed for the adapter Powered property when -# SetProperty(Powered, ...) hasn't been called yet. Defaults to true -InitiallyPowered = true - -# Remember the previously stored Powered state when initializing adapters -RememberPowered = true - -# Use vendor, product and version information for DID profile support. -# The values are separated by ":" and VID, PID and version. -DeviceID = android:generic:1.5 - -# Do reverse service discovery for previously unknown devices that connect to -# us. This option is really only needed for qualification since the BITE tester -# doesn't like us doing reverse SDP for some test cases (though there could in -# theory be other useful purposes for this too). Defaults to true. -ReverseServiceDiscovery = true - -# Enable name resolving after inquiry. Set it to 'false' if you don't need -# remote devices name and want shorter discovery cycle. Defaults to 'true'. -NameResolving = true - -# The link policy for connections. By default it's set to 15(0x000f) which is -# a bitwise OR of role switch(0x0001), hold mode(0x0002), sniff mode(0x0004) -# and park state(0x0008) are all enabled. However, some devices have -# connection stability issue or fail to setup SCO when the link is in park -# state, which requires park state bit cleared. -DefaultLinkPolicy = 7 diff --git a/overlay/frameworks/base/core/res/res/values/config.xml b/overlay/frameworks/base/core/res/res/values/config.xml index e7d9d15..6ae2c58 100644 --- a/overlay/frameworks/base/core/res/res/values/config.xml +++ b/overlay/frameworks/base/core/res/res/values/config.xml @@ -100,12 +100,10 @@ 9000 - - com.google.android.location - - - com.google.android.location - + + com.android.location.fused + com.google.android.location + @@ -155,7 +153,7 @@ bluetooth interfaces. If the device doesn't want to support tethering over bluetooth this should be empty. --> - "bnep\\d" + "bt-pan" diff --git a/releasetools/aries_ota_from_target_files b/releasetools/aries_ota_from_target_files index 8dbbf34..e607fd4 100755 --- a/releasetools/aries_ota_from_target_files +++ b/releasetools/aries_ota_from_target_files @@ -56,9 +56,9 @@ def WriteFullOTAPackage(input_zip, output_zip): # change very often. script = edify_generator.EdifyGenerator(3, OPTIONS.info_dict) - metadata = {"post-build": GetBuildProp("ro.build.fingerprint", input_zip), - "pre-device": GetBuildProp("ro.product.device", input_zip), - "post-timestamp": GetBuildProp("ro.build.date.utc", input_zip), + metadata = {"post-build": GetBuildProp("ro.build.fingerprint", OPTIONS.info_dict), + "pre-device": GetBuildProp("ro.product.device", OPTIONS.info_dict), + "post-timestamp": GetBuildProp("ro.build.date.utc", OPTIONS.info_dict), } device_specific = common.DeviceSpecificParams( @@ -78,6 +78,7 @@ def WriteFullOTAPackage(input_zip, output_zip): AppendAssertions(script, input_zip) device_specific.FullOTA_Assertions() + device_specific.FullOTA_InstallBegin() if OPTIONS.backuptool: script.Mount("/system") @@ -87,6 +88,9 @@ def WriteFullOTAPackage(input_zip, output_zip): if OPTIONS.wipe_user_data: script.FormatPartition("/data") + if "selinux_fc" in OPTIONS.info_dict: + WritePolicyConfig(OPTIONS.info_dict["selinux_fc"], output_zip) + script.FormatPartition("/system") script.Mount("/system") script.ShowProgress(0.7, 30); @@ -104,9 +108,6 @@ def WriteFullOTAPackage(input_zip, output_zip): script.ShowProgress(0.2, 10) script.RunBackup("restore") - if OPTIONS.modelidcfg: - script.RunConfig("") - CopyBootFiles(input_zip, output_zip) CopyBMLoverMTD(output_zip) -- cgit v1.1