gts3l-common: wlan: Add TetheringOverlay

It will handle Wifi Tethering more properly.

Refers:
- 6419ffb0f8

Signed-off-by: Deokgyu Yang <secugyu@gmail.com>
Change-Id: Ie916cb5ec8be4cf837efd4de8444cc327013b1af
This commit is contained in:
Deokgyu Yang 2021-12-19 17:10:40 +09:00
parent aa77b19aef
commit 3bc8e6628e
4 changed files with 93 additions and 42 deletions

View file

@ -68,48 +68,6 @@
in hardware. --> in hardware. -->
<bool name="config_setColorTransformAccelerated">true</bool> <bool name="config_setColorTransformAccelerated">true</bool>
<!-- List of regexpressions describing the interface (if any) that represent tetherable
Wifi interfaces. If the device doesn't want to support tethering over Wifi this
should be empty. An example would be "softap.*" -->
<string-array translatable="false" name="config_tether_wifi_regexs">
<item>softap0</item>
<item>wigig0</item>
<item>wifi_br0</item>
</string-array>
<!-- Dhcp range (min, max) to use for tethering purposes -->
<string-array translatable="false" name="config_tether_dhcp_range">
<item>192.168.42.2</item>
<item>192.168.42.254</item>
<item>192.168.43.2</item>
<item>192.168.43.254</item>
<item>192.168.44.2</item>
<item>192.168.44.254</item>
<item>192.168.45.2</item>
<item>192.168.45.254</item>
<item>192.168.46.2</item>
<item>192.168.46.254</item>
<item>192.168.47.2</item>
<item>192.168.47.254</item>
<item>192.168.48.2</item>
<item>192.168.48.254</item>
<item>192.168.49.2</item>
<item>192.168.49.254</item>
<item>192.168.50.2</item>
<item>192.168.50.254</item>
<item>192.168.51.2</item>
<item>192.168.51.254</item>
</string-array>
<!-- List of regexpressions describing the interface (if any) that represent tetherable
bluetooth interfaces. If the device doesn't want to support tethering over bluetooth this
should be empty. -->
<string-array translatable="false" name="config_tether_bluetooth_regexs">
<item>bnep\\d</item>
<item>bt-pan</item>
</string-array>
<!-- Array of light sensor lux values to define our levels for auto backlight brightness support. <!-- Array of light sensor lux values to define our levels for auto backlight brightness support.
The N entries of this array define N + 1 control points as follows: The N entries of this array define N + 1 control points as follows:
(1-based arrays) (1-based arrays)

View file

@ -0,0 +1,6 @@
runtime_resource_overlay {
name: "TetheringConfigOverlay",
theme: "TetheringConfigOverlay",
sdk_version: "current",
product_specific: true
}

View file

@ -0,0 +1,11 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.networkstack.tethering.samsung_gts3l"
android:versionCode="1"
android:versionName="1.0">
<application android:hasCode="false" />
<overlay
android:targetPackage="com.android.networkstack.tethering"
android:targetName="TetheringConfig"
android:isStatic="true"
android:priority="0"/>
</manifest>

View file

@ -0,0 +1,76 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
/*
** Copyright 2020, The Android Open Source Project
**
** Licensed under the Apache License, Version 2.0 (the "License");
** you may not use this file except in compliance with the License.
** You may obtain a copy of the License at
**
** http://www.apache.org/licenses/LICENSE-2.0
**
** Unless required by applicable law or agreed to in writing, software
** distributed under the License is distributed on an "AS IS" BASIS,
** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
** See the License for the specific language governing permissions and
** limitations under the License.
*/
-->
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<!-- Use the BPF offload for tethering when the kernel has support. True by default.
If the device doesn't want to support tether BPF offload, this should be false.
Note that this setting could be overridden by device config.
-->
<bool translatable="false" name="config_tether_enable_bpf_offload">false</bool>
<!-- List of regexpressions describing the interface (if any) that represent tetherable
USB interfaces. If the device doesn't want to support tethering over USB this should
be empty. An example would be "usb.*" -->
<string-array translatable="false" name="config_tether_usb_regexs">
<item>"usb\\d"</item>
<item>"rndis\\d"</item>
</string-array>
<!-- List of regexpressions describing the interface (if any) that represent tetherable
Wifi interfaces. If the device doesn't want to support tethering over Wifi this
should be empty. An example would be "softap.*" -->
<string-array name="config_tether_wifi_regexs">
<item>"wlan0"</item>
<item>"wigig0"</item>
</string-array>
<!-- List of regexpressions describing the interface (if any) that represent tetherable
bluetooth interfaces. If the device doesn't want to support tethering over bluetooth this
should be empty. -->
<string-array translatable="false" name="config_tether_bluetooth_regexs">
<item>"bnep\\d"</item>
<item>"bt-pan"</item>
</string-array>
<!-- Dhcp range (min, max) to use for tethering purposes -->
<string-array translatable="false" name="config_tether_dhcp_range">
<item>192.168.42.2</item>
<item>192.168.42.254</item>
<item>192.168.43.2</item>
<item>192.168.43.254</item>
<item>192.168.44.2</item>
<item>192.168.44.254</item>
<item>192.168.45.2</item>
<item>192.168.45.254</item>
<item>192.168.46.2</item>
<item>192.168.46.254</item>
<item>192.168.47.2</item>
<item>192.168.47.254</item>
<item>192.168.48.2</item>
<item>192.168.48.254</item>
<item>192.168.49.2</item>
<item>192.168.49.254</item>
<item>192.168.50.2</item>
<item>192.168.50.254</item>
<item>192.168.51.2</item>
<item>192.168.51.254</item>
</string-array>
</resources>