Skip to content

Commit

Permalink
Updates for new kernel
Browse files Browse the repository at this point in the history
  • Loading branch information
Quarx2k committed Aug 7, 2015
1 parent b59a4f0 commit 8fa4eb9
Show file tree
Hide file tree
Showing 11 changed files with 116 additions and 55 deletions.
2 changes: 1 addition & 1 deletion BoardConfig.mk
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ TARGET_BOOTLOADER_BOARD_NAME := w7
BOARD_KERNEL_SEPARATED_DT := true
BOARD_CUSTOM_BOOTIMG_MK := device/lge/w7/mkbootimg.mk
TARGET_KERNEL_SOURCE := kernel/lge/msm8226
TARGET_KERNEL_CONFIG := cm11_msm8226_defconfig
TARGET_KERNEL_CONFIG := w7ds_cyanogenmod_defconfig
BOARD_KERNEL_CMDLINE := console=ttyHSL0,115200,n8 androidboot.console=ttyHSL0 user_debug=31 msm_rtb.filter=0x37 androidboot.hardware=w7 androidboot.selinux=enforcing
BOARD_KERNEL_BASE := 0x00000000
BOARD_KERNEL_PAGESIZE := 2048
Expand Down
6 changes: 4 additions & 2 deletions cmhw/org/cyanogenmod/hardware/TapToWake.java
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@

public class TapToWake {

private static String CONTROL_PATH = "/sys/devices/virtual/input/lge_touch/touch_gesture";
// private static String CONTROL_PATH = "/sys/devices/virtual/input/lge_touch/touch_gesture";
private static String CONTROL_PATH = "/sys/devices/virtual/input/lge_touch/lpwg_notify";
private static boolean mEnabled = true;

public static boolean isSupported() {
Expand All @@ -33,6 +34,7 @@ public static boolean isEnabled() {

public static boolean setEnabled(boolean state) {
mEnabled = state;
return FileUtils.writeLine(CONTROL_PATH, (state ? "1" : "0"));
// return FileUtils.writeLine(CONTROL_PATH, (state ? "1" : "0"));
return FileUtils.writeLine(CONTROL_PATH, (state ? "1 1 0 0" : "1 0 0 0"));
}
}
14 changes: 8 additions & 6 deletions device_w7.mk
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,6 @@ PRODUCT_COPY_FILES += \
PRODUCT_COPY_FILES += \
device/lge/w7/prebuilt/etc/wifi/p2p_supplicant_overlay.conf:system/etc/wifi/p2p_supplicant_overlay.conf \
device/lge/w7/prebuilt/etc/wifi/wpa_supplicant_overlay.conf:system/etc/wifi/wpa_supplicant_overlay.conf \
device/lge/w7/prebuilt/etc/wifi/WCNSS_qcom_wlan_nv.bin:system/etc/firmware/wlan/prima/WCNSS_qcom_wlan_nv.bin \
device/lge/w7/prebuilt/etc/wifi/WCNSS_qcom_wlan_nv.bin:system/etc/wifi/WCNSS_qcom_wlan_nv.bin \
device/lge/w7/prebuilt/etc/hostapd/hostapd.accept:system/etc/hostapd/hostapd.accept \
device/lge/w7/prebuilt/etc/hostapd/hostapd.deny:system/etc/hostapd/hostapd.deny \
device/lge/w7/prebuilt/etc/hostapd/hostapd_default.conf:system/etc/hostapd/hostapd_default.conf \
Expand All @@ -78,9 +76,13 @@ PRODUCT_COPY_FILES += \
device/lge/w7/prebuilt/etc/nfc-nci.conf:system/etc/nfc-nci.conf \
device/lge/w7/prebuilt/etc/libnfc-nxp.conf:system/etc/libnfc-nxp.conf \
device/lge/w7/prebuilt/etc/nfcee_access.xml:system/etc/nfcee_access.xml \
kernel/lge/msm8226/drivers/staging/prima/firmware_bin/WCNSS_cfg.dat:system/etc/firmware/wlan/prima/WCNSS_cfg.dat \
kernel/lge/msm8226/drivers/staging/prima/firmware_bin/WCNSS_qcom_cfg.ini:system/etc/firmware/wlan/prima/WCNSS_qcom_cfg.ini \
kernel/lge/msm8226/drivers/staging/prima/firmware_bin/WCNSS_qcom_cfg.ini:system/etc/wifi/WCNSS_qcom_cfg.ini \
device/lge/w7/prebuilt/etc/wifi/WCNSS_cfg.dat:system/etc/firmware/wlan/prima/WCNSS_cfg.dat \
device/lge/w7/prebuilt/etc/wifi/WCNSS_qcom_cfg.ini:system/etc/firmware/wlan/prima/WCNSS_qcom_cfg.ini \
device/lge/w7/prebuilt/etc/wifi/WCNSS_qcom_wlan_nv.bin:system/etc/firmware/wlan/prima/WCNSS_qcom_wlan_nv.bin \
device/lge/w7/prebuilt/etc/wifi/WCNSS_qcom_wlan_nv.bin:system/etc/firmware/wlan/prima/WCNSS_qcom_wlan_nv_boot.bin \
device/lge/w7/prebuilt/etc/wifi/WCNSS_qcom_wlan_nv.bin:system/etc/wifi/WCNSS_qcom_wlan_nv.bin \
device/lge/w7/prebuilt/etc/wifi/WCNSS_qcom_wlan_nv.bin:system/etc/wifi/WCNSS_qcom_wlan_nv_boot.bin \
device/lge/w7/prebuilt/etc/wifi/WCNSS_qcom_cfg.ini:system/etc/wifi/WCNSS_qcom_cfg.ini

# Ramdisk
PRODUCT_COPY_FILES += \
Expand Down Expand Up @@ -336,7 +338,7 @@ PRODUCT_PROPERTY_OVERRIDES += \
persist.call_recording.enabled=1

PRODUCT_DEFAULT_PROPERTY_OVERRIDES += \
persist.sys.usb.config=mtp
persist.sys.usb.config=mtp,adb

# NFC packages
PRODUCT_PACKAGES += \
Expand Down
Binary file added prebuilt/etc/wifi/WCNSS_cfg.dat
Binary file not shown.
140 changes: 94 additions & 46 deletions prebuilt/etc/wifi/WCNSS_qcom_cfg.ini
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ gEnableImps=1
gEnableIdleScan=0


# Enable/Disable vsta based on MAX Assoc limit
gEnableVSTASupport=1


# Increase sleep duration (seconds) during IMPS
# 0 implies no periodic wake up from IMPS. Periodic wakeup is
# unnecessary if Idle Scan is disabled.
Expand All @@ -26,7 +30,6 @@ gEnableBmps=1

gEnableSuspend=3


# Phy Mode (auto, b, g, n, etc)
# Valid values are 0-9, with 0 = Auto, 4 = 11n, 9 = 11ac
gDot11Mode=0
Expand Down Expand Up @@ -58,6 +61,8 @@ InfraUapsdBeSrvIntv=0

InfraUapsdBkSrvIntv=0

# Flag to allow STA send AddTspec even when ACM is Off
gAddTSWhenACMIsOff=1

# Make 1x1 the default antenna configuration

Expand All @@ -80,15 +85,17 @@ gNthBeaconFilter=50

# 2: Filter all Broadcast. 3: Filter all Mcast abd Bcast

McastBcastFilter=0
McastBcastFilter=3


#Flag to enable HostARPOffload feature or not

hostArpOffload=1

# Flag to enable Host IPv6 NS Offload feature or not
hostNSOffload=1

#Flag to enable HostNSOffload feature or not

hostNSOffload=0

#SoftAP Related Parameters

Expand All @@ -104,7 +111,7 @@ gEnableApProt=1

#Enable OBSS protection

gEnableApOBSSProt=0
gEnableApOBSSProt=1


#Enable/Disable UAPSD for SoftAP
Expand Down Expand Up @@ -144,31 +151,47 @@ WmmIsEnabled=0

# 802.11d support

g11dSupportEnabled=0
g11dSupportEnabled=1

# 802.11h support

g11hSupportEnabled=1

# CCX Support and fast transition
CcxEnabled=0
FastTransitionEnabled=1
ImplicitQosIsEnabled=1
ImplicitQosIsEnabled=0
gNeighborScanTimerPeriod=200

gNeighborLookupThreshold=78
gNeighborLookupThreshold=76
gNeighborReassocThreshold=81

gNeighborScanChannelMinTime=20
gNeighborScanChannelMaxTime=30
gMaxNeighborReqTries=3

# Legacy (non-CCX, non-802.11r) Fast Roaming Support
# To enable, set FastRoamEnabled=1
# To disable, set FastRoamEnabled=0
FastRoamEnabled=1
gEnableFWRssiMonitoring=1
# To enable, set FastRoamEnabled=1, gEnableFWRssiMonitoring=1, FastTransitionEnabled=1
# To disable, set FastRoamEnabled=0, gEnableFWRssiMonitoring=0, FastTransitionEnabled=0

#Check if the AP to which we are roaming is better than current AP in terms of RSSI.
#Checking is disabled if set to Zero.Otherwise it will use this value as to how better
#Checking is disabled if set to Zero.Otherwise it will use this value as to how better
#the RSSI of the new/roamable AP should be for roaming
RoamRssiDiff=15
RoamRssiDiff=3

# If the RSSI of any available candidate is better than currently associated
# AP by at least gImmediateRoamRssiDiff, then being to roam immediately (without
# registering for reassoc threshold).
# NOTE: Value of 0 means that we would register for reassoc threshold.
gImmediateRoamRssiDiff=10

# To enable, set gRoamIntraBand=1 (Roaming within band)
# To disable, set gRoamIntraBand=0 (Roaming across band)

gRoamIntraBand=0

# SAP Country code
#SAP Country code

# Default Country Code is 2 bytes, 3rd byte is optional indoor or out door.

Expand Down Expand Up @@ -250,22 +273,22 @@ BtAmpPreferredChannel=0

#Preferred band (both or 2.4 only or 5 only)

BandCapability=1
BandCapability=0


#Beacon Early Termination (1 = enable the BET feature, 0 = disable)

enableBeaconEarlyTermination=1
enableBeaconEarlyTermination=0

beaconEarlyTerminationWakeInterval=11
beaconEarlyTerminationWakeInterval=3


#Bluetooth Alternate Mac Phy (1 = enable the BT AMP feature, 0 = disable)

gEnableBtAmp=0


#SOFTAP Channel Range selection
#SOFTAP Channel Range selection

gAPChannelSelectStartChannel=1

Expand All @@ -285,7 +308,7 @@ gChannelBondingMode5GHz=1

#Enable Keep alive with non-zero period value

gStaKeepAlivePeriod = 30
#gStaKeepAlivePeriod = 30

#AP LINK MONITOR TIMEOUT is used for both SAP and GO mode.
#It is used to change the frequency of keep alive packets in the AP Link Monitor period which is by
Expand Down Expand Up @@ -327,43 +350,68 @@ gDataInactivityTimeout=200
gVhtRxMCS=2
gVhtTxMCS=2

gEnableLpwrImgTransition=1
# Enable CRDA regulatory support by settings default country code
#gCrdaDefaultCountryCode=TW

# Enable Tx beamforming
gTxBFEnable=0
# Scan Timing Parameters
# gPassiveMaxChannelTime=110
# gPassiveMinChannelTime=60
# gActiveMaxChannelTime=40
# gActiveMinChannelTime=20

# Enable Tx LDPC
#gTxLdpcEnable = 1 for HT mode, 2 for VHT mode,3 for both HT and VHT
gTxLdpcEnable=3
#If set to 0, MCC is not allowed.
gEnableMCCMode=1

# Oxygen network (prop IE for IBSS)
gEnableOxygenNwk=0
# 1=enable STBC; 0=disable STBC
gEnableRXSTBC=1

# Enable Active mode offload
gEnableActiveModeOffload=1

#Enable Scan Results Aging based on timer
#Timer value is in seconds
#If Set to 0 it will not enable the feature
gScanAgingTime=0

#Enable Power saving mechanism Based on Android Framework
#If set to 0 Driver internally control the Power saving mechanism
#If set to 1 Android Framwrok control the Power saving mechanism
isAndroidPsEn=0

# Valid values are 2048,4096,8192 and so on
# Please don't use values other than the ones mentioned above
gMaxMediumTime=4096
#disable LDPC in STA mode if the AP is TXBF capable
gDisableLDPCWithTxbfAP=1

# LGE_CHANGE_S, [WiFi][[email protected]], 2013-10-23, To improve running current consumption
# Set Listen Interval
gBmpsMinListenInterval=1
gBmpsMaxListenInterval=10
gBmpsModListenInterval=5
gPowerUsage=Mod
#Enable thermal mitigation
gThermalMitigationEnable=1

#DTIM Skip
gEnableModulatedDTIM=3
# LGE_CHANGE_E, [WiFi][[email protected]], 2013-10-23, To improve running current consumption
gEnableFastRoamInConcurrency=1

# LGE_CHANGE_S, [WiFi][[email protected]], 2013-10-25, P2p connection issue .
isP2pDeviceAddrAdministrated=1
# LGE_CHANGE_E, [WiFi][[email protected]], 2013-10-25, P2p connection issue .
#List of Country codes for which 11ac needs to be disabled
#Each country code must be delimited by comma(,)
gListOfNon11acCountryCode=RU,UA,ZA

gScanResultAgeCount=1
#Maxium Channel time in msec
gMaxMediumTime = 6000

# 802.11K support
gRrmEnable=1
gRrmOperChanMax=8
gRrmNonOperChanMax=8
gRrmRandIntvl=100

#Scan offload
gEnableDirectedScanOffload=0

# Oxygen network (prop IE for IBSS)
gEnableOxygenNwk=0

gApLinkMonitorPeriod=30
#FlexConnect Power Factor
#Default is set to 0 (disable)
gFlexConnectPowerFactor=0

#enable/disable PNO scan support.(background)
gPNOScanSupport=0
#SAP/P2P-GO mode traffic monitor
gEnableTrafficMonitor=1
gTrafficIdleTimeout=3000

END

Expand Down
2 changes: 2 additions & 0 deletions sepolicy/bootanim.te
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
allow bootanim socket_device:sock_file write;

1 change: 1 addition & 0 deletions sepolicy/file.te
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
type kcal_dev, file_type;
type vibe_dev, file_type;
type touchpanel_sysfs, sysfs_type, file_type;
1 change: 1 addition & 0 deletions sepolicy/kernel.te
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@ allow kernel kcal_dev:file relabelto;
allow kernel kcal_dev:lnk_file relabelto;
allow kernel lge_touch_sysfs:file relabelto;
allow kernel vibe_dev:file relabelto;

1 change: 1 addition & 0 deletions sepolicy/sensors.te
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,4 @@ allow sensors apk_data_file:sock_file unlink;
allow sensors apk_data_file:sock_file write;
allow sensors apk_data_file:sock_file create;


2 changes: 2 additions & 0 deletions sepolicy/ueventd.te
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,6 @@ allow ueventd kcal_dev:lnk_file r_file_perms;
allow ueventd vibe_dev:file { getattr relabelto };
allow ueventd vfat:dir search;
allow ueventd vfat:file { read getattr open };
allow ueventd unlabeled:lnk_file { read getattr open write };
allow ueventd unlabeled:file { read getattr open write };

2 changes: 2 additions & 0 deletions sepolicy/wcnss_service.te
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
allow wcnss_service block_device:dir search;
allow wcnss_service misc_partition:blk_file r_file_perms;
allow wcnss_service mmc_block_device:dir search;
allow wcnss_service unlabeled:file { read write getattr open };

0 comments on commit 8fa4eb9

Please sign in to comment.