mirror of
https://github.com/libretro/Lakka-LibreELEC.git
synced 2024-12-02 14:26:47 +00:00
Lakka v5.x switchroot 5.1.2 (#1871)
* Update kernel to 5.1.1 * L4T: Switch: Build Xpadneo as module, as building in doesnt work * L4T:Switch: Update Switch Uboot * L4T: Switch: Update switch-bootloader * Packages: FFmpeg: L4T: Update nvv4l2 patchset to latest * [temp]Bluetooth fix * Update kernel to dev version * Update Switch U-Boot * Switch: Kernel: update to switchroot 5.1.2 kernel * Switch: Update Platform_init * Switch: Update Switch BSP package joycon pairing script * Switch: Update Bootloader to 5.1.2
This commit is contained in:
parent
5b413c99f6
commit
dc34f7aa87
@ -41,3 +41,8 @@ if [ $CPU_SCHEDUTIL_GOV -eq 1 ]; then
|
||||
echo 1024 > /sys/devices/system/cpu/cpufreq/schedutil/capacity_margin
|
||||
fi
|
||||
fi
|
||||
|
||||
# Fix permissions for OLED panel
|
||||
if [ -e "/sys/devices/50000000.host1x/tegradc.0/panel_color_mode" ]; then
|
||||
chmod 0666 /sys/devices/50000000.host1x/tegradc.0/panel_color_mode
|
||||
fi
|
||||
|
@ -557,9 +557,9 @@ CONFIG_SECCOMP=y
|
||||
CONFIG_KEXEC=y
|
||||
# CONFIG_XEN is not set
|
||||
CONFIG_FORCE_MAX_ZONEORDER=11
|
||||
CONFIG_HARDEN_BRANCH_PREDICTOR=y
|
||||
# CONFIG_HARDEN_BRANCH_PREDICTOR is not set
|
||||
# CONFIG_UNMAP_KERNEL_AT_EL0 is not set
|
||||
CONFIG_ARM64_SSBD=y
|
||||
# CONFIG_ARM64_SSBD is not set
|
||||
CONFIG_ARMV8_DEPRECATED=y
|
||||
CONFIG_SWP_EMULATION=y
|
||||
CONFIG_CP15_BARRIER_EMULATION=y
|
||||
@ -642,6 +642,8 @@ CONFIG_SERROR_HANDLER=y
|
||||
# CPU Idle
|
||||
#
|
||||
CONFIG_CPU_IDLE=y
|
||||
# CONFIG_CPU_IDLE_TEGRA18X is not set
|
||||
# CONFIG_CPU_IDLE_TEGRA19X is not set
|
||||
CONFIG_CPU_IDLE_MULTIPLE_DRIVERS=y
|
||||
# CONFIG_CPU_IDLE_GOV_LADDER is not set
|
||||
CONFIG_CPU_IDLE_GOV_MENU=y
|
||||
@ -1596,7 +1598,7 @@ CONFIG_WLAN=y
|
||||
CONFIG_WLAN_VENDOR_BROADCOM=y
|
||||
# CONFIG_B43_BUSES_BCMA is not set
|
||||
# CONFIG_B43_BUSES_SSB is not set
|
||||
CONFIG_B43_PCI_AUTOSELECT=y
|
||||
# CONFIG_B43_PCI_AUTOSELECT is not set
|
||||
# CONFIG_B43_SDIO is not set
|
||||
# CONFIG_B43_DEBUG is not set
|
||||
# CONFIG_B43LEGACY is not set
|
||||
@ -1922,7 +1924,8 @@ CONFIG_SERIAL_DEV_CTRL_TTYPORT=y
|
||||
# CONFIG_HVC_DCC is not set
|
||||
# CONFIG_IPMI_HANDLER is not set
|
||||
CONFIG_HW_RANDOM=y
|
||||
CONFIG_HW_RANDOM_TEGRA=y
|
||||
CONFIG_HW_RANDOM_TEGRA=n
|
||||
CONFIG_HW_RANDOM_TEGRA_TRNG=y
|
||||
# CONFIG_R3964 is not set
|
||||
# CONFIG_APPLICOM is not set
|
||||
|
||||
@ -2103,7 +2106,7 @@ CONFIG_PINCTRL_MAX77620=y
|
||||
CONFIG_PINCTRL_TEGRA=y
|
||||
CONFIG_PINCTRL_TEGRA210=y
|
||||
CONFIG_PINCTRL_TEGRA_XUSB=y
|
||||
#CONFIG_PINCTRL_TEGRA186 is not set
|
||||
# CONFIG_PINCTRL_TEGRA186 is not set
|
||||
# CONFIG_PINCTRL_TEGRA186_PADCTL is not set
|
||||
# CONFIG_PINCTRL_TEGRA186_DPAUX is not set
|
||||
# CONFIG_PINCTRL_TEGRA194 is not set
|
||||
@ -3329,7 +3332,7 @@ CONFIG_THRUSTMASTER_FF=y
|
||||
CONFIG_HID_WACOM=y
|
||||
CONFIG_HID_WIIMOTE=y
|
||||
CONFIG_HID_XINMO=y
|
||||
CONFIG_HID_XPADNEO=y
|
||||
CONFIG_HID_XPADNEO=m
|
||||
CONFIG_HID_ZEROPLUS=y
|
||||
# CONFIG_ZEROPLUS_FF is not set
|
||||
CONFIG_HID_ZYDACRON=y
|
||||
@ -3486,6 +3489,8 @@ CONFIG_USB_ULPI=y
|
||||
CONFIG_USB_ULPI_VIEWPORT=y
|
||||
CONFIG_DUAL_ROLE_USB_INTF=y
|
||||
CONFIG_USB_GADGET=y
|
||||
CONFIG_USB_GADGET_VBUS_DRAW=500
|
||||
|
||||
# CONFIG_USB_GADGET_DEBUG is not set
|
||||
# CONFIG_USB_GADGET_DEBUG_FILES is not set
|
||||
# CONFIG_USB_GADGET_DEBUG_FS is not set
|
||||
@ -3512,13 +3517,12 @@ CONFIG_USB_GADGET_STORAGE_NUM_BUFFERS=2
|
||||
CONFIG_USB_TEGRA_XUDC=y
|
||||
# CONFIG_USB_DUMMY_HCD is not set
|
||||
CONFIG_USB_TEGRA_CD=y
|
||||
CONFIG_USB_TEGRA_CD_NO_USERSPACE=y
|
||||
CONFIG_USB_LIBCOMPOSITE=y
|
||||
CONFIG_USB_F_ACM=y
|
||||
CONFIG_USB_U_SERIAL=y
|
||||
CONFIG_USB_F_FS=y
|
||||
CONFIG_USB_CONFIGFS=y
|
||||
# CONFIG_USB_CONFIGFS_SERIAL is not set
|
||||
CONFIG_USB_CONFIGFS_SERIAL=y
|
||||
CONFIG_USB_CONFIGFS_ACM=y
|
||||
# CONFIG_USB_CONFIGFS_OBEX is not set
|
||||
# CONFIG_USB_CONFIGFS_NCM is not set
|
||||
@ -4546,7 +4550,7 @@ CONFIG_HAVE_ARM_SMCCC=y
|
||||
# Tegra BPMP Driver
|
||||
#
|
||||
CONFIG_NV_TEGRA_BPMP=y
|
||||
CONFIG_BPMP_DEBUGFS_MOUNT_ON_BOOT=y
|
||||
# CONFIG_BPMP_DEBUGFS_MOUNT_ON_BOOT is not set
|
||||
# CONFIG_ACPI is not set
|
||||
|
||||
#
|
||||
|
@ -40,7 +40,7 @@ BOOTLOADER="switch-bootloader" # this is a fake bootloader since coreboot and u-
|
||||
|
||||
ADDITIONAL_DRIVERS+=" xf86-input-libinput"
|
||||
#Add proper version for kernel based upon switchroot version Only used for switch
|
||||
SWITCHROOT_VERSION=5.1.0
|
||||
SWITCHROOT_VERSION=5.1.2
|
||||
GENERIC_L4T_VERSION=32.3.1
|
||||
L4T_DEVICE_TYPE="t210"
|
||||
#L4T_COMBINED_KERNEL_SHA256="c3a8df6836cb4581162da6f4d380c2a730f69b3bac8bbaf4c2ec6c73ab5461cd"
|
||||
@ -48,12 +48,12 @@ L4T_DEVICE_TYPE="t210"
|
||||
L4T_DEVICE_CUSTOM_BOARD_NAME="nx"
|
||||
|
||||
L4T_KERNEL_4_9_REPO="https://github.com/CTCaer/switch-l4t-kernel-4.9.git"
|
||||
L4T_KERNEL_4_9_REPO_BRANCH="linux-5.1.0"
|
||||
L4T_KERNEL_4_9_REPO_SHA256="3eb000b1983eeeb7038b551b539c88458a42a1d6"
|
||||
L4T_KERNEL_4_9_REPO_BRANCH="linux-5.1.2"
|
||||
L4T_KERNEL_4_9_REPO_SHA256="2d0059fd3167a8df756de2aa0489d4aa70a9fc15"
|
||||
|
||||
L4T_KERNEL_NVIDIA_REPO="https://github.com/CTCaer/switch-l4t-kernel-nvidia.git"
|
||||
L4T_KERNEL_NVIDIA_REPO_BRANCH="linux-5.1.0"
|
||||
L4T_KERNEL_NVIDIA_REPO_SHA256="578d533b99cd5d5c3e57760431d2f621307265cf"
|
||||
L4T_KERNEL_NVIDIA_REPO_BRANCH="linux-5.1.2"
|
||||
L4T_KERNEL_NVIDIA_REPO_SHA256="a4cc21186653434c0362323b12354e6e713ad5af"
|
||||
|
||||
L4T_KERNEL_NVGPU_REPO="https://gitlab.com/switchroot/kernel/l4t-kernel-nvgpu.git"
|
||||
L4T_KERNEL_NVGPU_REPO_BRANCH="linux-3.4.0-r32.5"
|
||||
@ -77,5 +77,5 @@ L4T_DEVICE_T210_REPO_BRANCH="l4t/l4t-r32.3.1"
|
||||
|
||||
#Apply Custom Device DTS tree.
|
||||
L4T_DEVICE_CUSTOM_REPO="https://github.com/CTCaer/switch-l4t-platform-t210-nx.git"
|
||||
L4T_DEVICE_CUSTOM_REPO_BRANCH="linux-5.1.0"
|
||||
L4T_DEVICE_CUSTOM_REPO_SHA256="9af1d3a9f991b8c8761395986844c7b3c4446b6f"
|
||||
L4T_DEVICE_CUSTOM_REPO_BRANCH="linux-dev"
|
||||
L4T_DEVICE_CUSTOM_REPO_SHA256="cf785c4c176499b301170d79fe57b77f365b73cd"
|
||||
|
@ -24,7 +24,8 @@ Below you can find all supported keys and their defaults.
|
||||
[r2p_action=self]
|
||||
self: Reboots to self. [Default]
|
||||
bootloader: Reboots to bootloader menu.
|
||||
|
||||
normal: Reboots with no config. Allows default auto boot to be used.
|
||||
|
||||
[usb3_enable=0]
|
||||
1: Enable USB3 support.
|
||||
Enabling it can dramatically decrease WiFi 2.4GHz and Bluetooth signal quality.
|
||||
@ -49,6 +50,18 @@ Below you can find all supported keys and their defaults.
|
||||
[als_enable=1]
|
||||
1: Enable Ambient Light Sensor.
|
||||
|
||||
[jc_rail_disable=0]
|
||||
1: Disable railed Joycon support.
|
||||
|
||||
[touch_skip_tuning=0]
|
||||
1: Disables touch panel tuning on boot.
|
||||
Some panels with broken flex cable might need it.
|
||||
|
||||
[wifi_disable_vht80=0]
|
||||
1: Disable Wi-Fi VHT80 and VHT160 bonding (5GHz band).
|
||||
In case wifi card firmware hangs when fully used at such speeds and kernel
|
||||
panics, that might help to mitigate that issue.
|
||||
|
||||
[bootargs_extra=]
|
||||
Set extra kernel command line arguments.
|
||||
|
||||
@ -58,21 +71,146 @@ Below you can find all supported keys and their defaults.
|
||||
Can also allow higher CPU/GPU clocks. If OC is used, the reduced power draw
|
||||
is negated.
|
||||
|
||||
[gpu_dvfsc=0]
|
||||
1: Enable DVFS C-Side for GPU. T210B01 only.
|
||||
Reduces power draw drastically on GPU frequencies of 768/844 MHz and up.
|
||||
Allows up to 1228 MHz clocks on select speedo binnings.
|
||||
|
||||
[limit_gpu_clk=0]
|
||||
1: Set GPU clock hard limit to 1075 MHz. T210B01 only.
|
||||
Helps when `gpu_dvfsc` is enabled and GPU can't handle the higher frequencies
|
||||
in such low voltages.
|
||||
================================================================================
|
||||
|
||||
|
||||
============================== RAM Overclocking ================================
|
||||
|
||||
[ram_oc=0]
|
||||
Set RAM Overclock frequency in KHz.
|
||||
|
||||
If you hang or get corruption or artifacts, try to reduce it.
|
||||
`mem-bench` command can use almost all of the available bandwidth so it can be
|
||||
used for a quick testing.
|
||||
Actual stability can only be confirmed by `memtester` command on as high as
|
||||
possible temperature for several hours and with a big test size.
|
||||
Running a secondary GPU benchmark can help raise temperature.
|
||||
|
||||
On T210 (Erista max 1996 MHz):
|
||||
Only frequencies in the following list are supported:
|
||||
1728000, 1795200, 1862400, 1894400, 1932800, 1996800
|
||||
Suggested:
|
||||
- 1862400
|
||||
Any clock increase will also increase RAM power consumption like a CPU/GPU OC.
|
||||
For example on T210B01, with 1z-nm ram, going from 1866 to 2133 causes a
|
||||
146 mW increase on active reads/writes which is 19.8%.
|
||||
Any other state is affected only with a voltage change.
|
||||
|
||||
On T210B01 (Mariko max 2133 MHz):
|
||||
Any multiple of 38400 KHz can be used.
|
||||
Suggested:
|
||||
Warning: On T210B01, GPU minimum voltage might be raised if very high RAM
|
||||
frequency is used and GPU binning is low.
|
||||
|
||||
T210 (Erista max 2133 MHz):
|
||||
List of supported frequencies:
|
||||
1733000, 1800000, 1866000, 1900000, 1933000, 1966000, 2000000, 2033000,
|
||||
2066000, 2100000, 2133000, 2166000, 2200000, 2233000, 2266000, 2300000,
|
||||
2333000, 2366000.
|
||||
|
||||
Input frequency is generally normalized to one of the above.
|
||||
Actual frequency will differ a bit.
|
||||
|
||||
Suggested Jedec Frequencies:
|
||||
- 1866000
|
||||
- 2133000
|
||||
|
||||
Suggested Custom:
|
||||
- Any, if it works.
|
||||
|
||||
|
||||
T210B01 (Mariko max 3000 MHz):
|
||||
List of supported frequencies:
|
||||
1866000, 2133000, 2166000, 2200000, 2233000, 2266000, 2300000, 2333000,
|
||||
2366000, 2400000, 2433000, 2466000, 2500000, 2533000, 2566000, 2600000,
|
||||
2633000, 2666000, 2700000, 2733000, 2766000, 2800000, 2833000, 2866000,
|
||||
2900000, 2933000, 2966000, 3000000, 3033000, 3066000, 3100000, 3133000,
|
||||
3166000, 3200000.
|
||||
|
||||
Input frequency is generally normalized to one of the above.
|
||||
Actual frequency will be exactly one of these.
|
||||
|
||||
Suggested Jedec Frequencies:
|
||||
- 1866000
|
||||
- 2133000
|
||||
- 2400000
|
||||
- 2666000
|
||||
|
||||
Suggested Custom Frequencies:
|
||||
- Any, if it works.
|
||||
Very high ram frequencies might raise GPU power draw on some GPU frequencies
|
||||
if GPU binning is low.
|
||||
|
||||
Timing based overclocking:
|
||||
To enable that, edit the last [2 (T210) or 3 (T210B01) digits] of the frequency.
|
||||
|
||||
It's generally better to find a good base frequency before touching these.
|
||||
|
||||
Do not touch them at all for guaranteed stability on max possible frequency,
|
||||
since without these, the whole configuration is exactly per Nvidia's and
|
||||
RAM vendor's specifications.
|
||||
|
||||
Syntax:
|
||||
T210: Freq MHz + BA. FFFFF[BA]. (18624[00] -> 18624[52])
|
||||
T210B01: Freq MHz + CBA. FFFF[CBA]. (2133[000] -> 2133[252])
|
||||
|
||||
Description of F, A, B and C timing overclocking options:
|
||||
[F]: Actual clock frequency. Exceeding chip's real max is actual OC.
|
||||
|
||||
[A]: Base Latency reduction.
|
||||
Base latency decreases based on selected frequency bracket.
|
||||
Brackets: 1333/1600/1866/2133.
|
||||
- Range: 0 - 3. 0 to -3 bracket change.
|
||||
Example 1: 1866 with 2 is 1333 base latency. Originally 1866 bracket.
|
||||
Example 1: 1866 with 3 is 1333 base latency. Originally 1866 bracket.
|
||||
Example 2: 1996 with 3 is 1333 base latency. Originally 2133 bracket.
|
||||
Example 3: 2133 with 2 is 1600 base latency. Originally 2133 bracket.
|
||||
Example 4: 2400 with 0 is 2133 base latency. Originally 2133 bracket.
|
||||
|
||||
[B]: Core Timings reduction.
|
||||
Timings that massively get affected by temperatures are not touched.
|
||||
- Range: 0 - 9. 0% to 45% reduction.
|
||||
|
||||
[C]: BW Increase. T210B01/LPDDR4x only. RAM Temperature limited timings.
|
||||
Can cause significant ram data corruption if ram temperature exceeds max.
|
||||
Reason is not allowed on T210 and LPDDR4.
|
||||
- 0/1/2/3/4: for max 85/75/65/55/45 oC
|
||||
|
||||
RAM Temperature is only related to MEM/PLL sensors and not to Tdiode or Tboard.
|
||||
45oC is 50/51 oC MEM/PLL (around 43 oC Tdiode, depends on temp equilibrium).
|
||||
65oC is 68/69 oC MEM/PLL (around 60 oC Tdiode, depends on temp equilibrium).
|
||||
|
||||
Full Examples:
|
||||
Old (no timing adjustments) OC equivalents:
|
||||
- 1862 Old OC: 15% -> [A1,B3,C0] - 1866031
|
||||
- 1996 Old OC: 25% -> [A2,B5,C0] - 2000052
|
||||
|
||||
T210 Examples:
|
||||
- 19968[00] -> 1996800: 1996 MHz with read/write base latency of 2133 MHz
|
||||
and proper 1996 MHz core timings.
|
||||
- 19968[00] -> 1996852: 1996 MHz with read/write base latency of 1600 MHz
|
||||
and reduced core timings by 25%.
|
||||
T210B01 Examples:
|
||||
- 2666[000] -> 2666000: 2666 MHz with read/write base latency of 2133 MHz
|
||||
and proper 2666 MHz core timings.
|
||||
- 2666[000] -> 2666252: 2666 MHz with read/write base latency of 1600 MHz,
|
||||
reduced core timings by 25% and up to 65C operation.
|
||||
|
||||
Again, do not use them if you want the ram running like Nvidia and RAM vendor
|
||||
made the tables, and write the frequency `as is` in that case.
|
||||
|
||||
|
||||
[ram_oc_vdd2=0]
|
||||
Changes VDDIO/VDDQ voltage for T210. VDDIO only for T210B01.
|
||||
Can stabilize timing reduction or if at frequency limit.
|
||||
Do not use for zero reason. Limits are fully safe (official Jedec).
|
||||
Range: 1100 - 1175. (Unit in mV).
|
||||
|
||||
[ram_oc_vddq=0]
|
||||
Changes VDDQ voltage for T210B01.
|
||||
Can stabilize timing reduction or if at frequency limit.
|
||||
Do not use for zero reason. Limits are fully safe (official Jedec).
|
||||
Range: 600 - 650. (Unit in mV).
|
||||
|
||||
================================================================================
|
||||
|
@ -10,9 +10,46 @@ test -n ${als_enable} || setenv als_enable 1
|
||||
test -n ${usb3_enable} || setenv usb3_enable 0
|
||||
test -n ${4k60_disable} || setenv 4k60_disable 0
|
||||
test -n ${dvfsb} || setenv dvfsb 0
|
||||
test -n ${gpu_dvfsc} || setenv gpu_dvfsc 0
|
||||
test -n ${limit_gpu_clk} || setenv limit_gpu_clk 0
|
||||
test -n ${jc_rail_disable} || setenv jc_rail_disable 0
|
||||
test -n ${cec_enable} || setenv cec_enable 0
|
||||
test -n ${performance_mode} || setenv performance_mode 0
|
||||
test -n ${dock_freq_switch_enabled} || setenv dock_freq_switch_enabled 0
|
||||
test -n ${touch_skip_tuning} || setenv touch_skip_tuning 0
|
||||
test -n ${wifi_disable_vht80} || setenv wifi_disable_vht80 0
|
||||
# Built-in IMU.
|
||||
test -n ${acc_cal_off_x} || setenv acc_cal_off_x 0x0
|
||||
test -n ${acc_cal_off_y} || setenv acc_cal_off_y 0x0
|
||||
test -n ${acc_cal_off_z} || setenv acc_cal_off_z 0x0
|
||||
test -n ${acc_cal_scl_x} || setenv acc_cal_scl_x 0x0
|
||||
test -n ${acc_cal_scl_y} || setenv acc_cal_scl_y 0x0
|
||||
test -n ${acc_cal_scl_z} || setenv acc_cal_scl_z 0x0
|
||||
test -n ${gyr_cal_off_x} || setenv gyr_cal_off_x 0x0
|
||||
test -n ${gyr_cal_off_y} || setenv gyr_cal_off_y 0x0
|
||||
test -n ${gyr_cal_off_z} || setenv gyr_cal_off_z 0x0
|
||||
test -n ${gyr_cal_scl_x} || setenv gyr_cal_scl_x 0x0
|
||||
test -n ${gyr_cal_scl_y} || setenv gyr_cal_scl_y 0x0
|
||||
test -n ${gyr_cal_scl_z} || setenv gyr_cal_scl_z 0x0
|
||||
|
||||
# Lite Gamepad analog sticks calibration.
|
||||
test -n ${lite_cal_lx_lof} || setenv lite_cal_lx_lof 0x0
|
||||
test -n ${lite_cal_lx_cnt} || setenv lite_cal_lx_cnt 0x0
|
||||
test -n ${lite_cal_lx_rof} || setenv lite_cal_lx_rof 0x0
|
||||
test -n ${lite_cal_ly_dof} || setenv lite_cal_ly_dof 0x0
|
||||
test -n ${lite_cal_ly_cnt} || setenv lite_cal_ly_cnt 0x0
|
||||
test -n ${lite_cal_ly_uof} || setenv lite_cal_ly_uof 0x0
|
||||
|
||||
test -n ${lite_cal_rx_lof} || setenv lite_cal_rx_lof 0x0
|
||||
test -n ${lite_cal_rx_cnt} || setenv lite_cal_rx_cnt 0x0
|
||||
test -n ${lite_cal_rx_rof} || setenv lite_cal_rx_rof 0x0
|
||||
test -n ${lite_cal_ry_dof} || setenv lite_cal_ry_dof 0x0
|
||||
test -n ${lite_cal_ry_cnt} || setenv lite_cal_ry_cnt 0x0
|
||||
test -n ${lite_cal_ry_uof} || setenv lite_cal_ry_uof 0x0
|
||||
test -n ${lite_cal_lx_coff} || setenv lite_cal_lx_coff 0x0
|
||||
test -n ${lite_cal_ly_coff} || setenv lite_cal_ly_coff 0xFFFFFF00
|
||||
test -n ${lite_cal_rx_coff} || setenv lite_cal_rx_coff 0xFFFFFF00
|
||||
test -n ${lite_cal_ry_coff} || setenv lite_cal_ry_coff 0x0
|
||||
|
||||
# Set logging params for each serial type.
|
||||
setenv uarta "no_console_suspend console=ttyS0,115200,8n1 loglevel=8"
|
||||
@ -95,11 +132,47 @@ elif test ${uart_port} = 4; then
|
||||
setenv bootargs_extra ${usblg} ${bootargs_extra}; echoe USB Serial logging enabled
|
||||
fi
|
||||
|
||||
# Disable Joycon Rails.
|
||||
if test ${jc_rail_disable} = 1; then
|
||||
echoe Joycon Rails disabled
|
||||
fdt set /serial@70006040 status disabled
|
||||
fdt set /serial@70006040/joyconr status disabled
|
||||
fdt set /serial@70006200 status disabled
|
||||
fdt set /serial@70006200/joyconl status disabled
|
||||
fi
|
||||
|
||||
# Disable Touch panel tuning.
|
||||
if test ${touch_skip_tuning} = 1; then
|
||||
setenv bootargs_extra ${bootargs_extra} "ftm4.skip_tuning=1"
|
||||
fi
|
||||
|
||||
# Enable ALS sensor.
|
||||
if test ${als_enable} = 1; then
|
||||
fdt set /i2c@7000c400/bh1730fvc@29 status okay
|
||||
fi
|
||||
|
||||
+# Disable WiFi VHT80 bonding.
|
||||
if test ${wifi_disable_vht80} = 1; then
|
||||
echo WiFi VHT80 bonding disabled
|
||||
setenv bootargs_extra ${bootargs_extra} "brcmfmac.vht_mask=12"
|
||||
fi
|
||||
|
||||
# Set Sio calibration data.
|
||||
if test ${sku} = 2; then
|
||||
if load mmc ${devnum}:${distro_bootpart} ${enviraddr} /switchroot/switch.cal; then
|
||||
env import -t -r ${enviraddr} ${filesize}
|
||||
echo Sio Calibration set
|
||||
fdt set /serial@70006200/sio sio-stick-cal-l <$lite_cal_lx_lof $lite_cal_lx_cnt $lite_cal_lx_rof $lite_cal_ly_dof $lite_cal_ly_cnt $lite_cal_ly_uof>
|
||||
fdt set /serial@70006200/sio sio-stick-cal-r <$lite_cal_rx_lof $lite_cal_rx_cnt $lite_cal_rx_rof $lite_cal_ry_dof $lite_cal_ry_cnt $lite_cal_ry_uof>
|
||||
fdt set /serial@70006200/sio sio-acc-cal <$acc_cal_off_x $acc_cal_off_y $acc_cal_off_z $acc_cal_scl_x $acc_cal_scl_y $acc_cal_scl_z>
|
||||
fdt set /serial@70006200/sio sio-gyr-cal <$gyr_cal_off_x $gyr_cal_off_y $gyr_cal_off_z $gyr_cal_scl_x $gyr_cal_scl_y $gyr_cal_scl_z>
|
||||
|
||||
fdt set /serial@70006200/sio sio-stick-cnt-off-l <$lite_cal_lx_coff $lite_cal_ly_coff>
|
||||
fdt set /serial@70006200/sio sio-stick-cnt-off-r <$lite_cal_rx_coff $lite_cal_ry_coff>
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
# Get display panel handle.
|
||||
if test ${display_id} = f20; then echo Display is INN 6.2; fdt get value DHANDLE /host1x/dsi/panel-i-720p-6-2 phandle
|
||||
elif test ${display_id} = f30; then echo Display is AUO 6.2; fdt get value DHANDLE /host1x/dsi/panel-a-720p-6-2 phandle
|
||||
@ -144,9 +217,18 @@ fi
|
||||
# Set battery voltage limit via cell age for Vali.
|
||||
if test ${sku} = 2 -a -n "${VLIM}"; then
|
||||
echo VALI: voltage limits [${VLIM}, ${SOCLIM}]
|
||||
fdt set /i2c@7000c000/battery-charger@6b/charger ti,charge-voltage-limit-millivolt <0x$VLIM>
|
||||
fdt set /i2c@7000c000/battery-charger@6b/charger ti,charge-thermal-voltage-limit <0x$VLIM 0x$VLIM 0x$VLIM 0xFF0>
|
||||
fdt set /i2c@7000c000/battery-gauge@36 maxim,kernel-maximum-soc <0x$SOCLIM>
|
||||
if test "${VLIM}" != 1070; then
|
||||
# Newer Vali. 4320 mV / 1664 mA.
|
||||
fdt set /i2c@7000c000/battery-charger@6b/charger ti,charge-voltage-limit-millivolt <0x$VLIM>
|
||||
fdt set /i2c@7000c000/battery-charger@6b/charger ti,charge-thermal-voltage-limit <0x$VLIM 0x$VLIM 0x$VLIM 0xFF0>
|
||||
fdt set /i2c@7000c000/battery-gauge@36 maxim,kernel-maximum-soc <0x$SOCLIM>
|
||||
else
|
||||
# Old Vali. 4208 mV / 1536 mA. (Unreleased?)
|
||||
fdt set /i2c@7000c000/battery-charger@6b/charger ti,charge-voltage-limit-millivolt <0x1070>
|
||||
fdt set /i2c@7000c000/battery-charger@6b/charger ti,charge-thermal-voltage-limit <0x1070 0x1070 0x1070 0xF70>
|
||||
fdt set /i2c@7000c000/battery-charger@6b/charger ti,fast-charge-current-limit-milliamp <0x600>
|
||||
fdt set /i2c@7000c000/battery-charger@6b/charger ti,charge-current-limit <0x200 0x240 0x600 0x600>
|
||||
fi
|
||||
fi
|
||||
|
||||
# Enable SLT DVFS.
|
||||
@ -166,6 +248,58 @@ if test ${t210b01} = 1 -a ${dvfsb} = 1; then
|
||||
fi
|
||||
fi
|
||||
|
||||
# Enable DVFS B-Side.
|
||||
if test ${t210b01} = 1 -a ${dvfsb} = 1; then
|
||||
echoe DVFS B-Side enabled
|
||||
setenv bootargs_extra ${bootargs_extra} "speedo_tegra210.sku_id=0x83 speedo_tegra210.cspd_id=2 speedo_tegra210.sspd_id=2"
|
||||
fdt set /cpufreq/cpu-scaling-data max-frequency <0x249348>
|
||||
|
||||
if test ${gpu_dvfsc} != 1; then
|
||||
setenv bootargs_extra ${bootargs_extra} "speedo_tegra210.gspd_id=2"
|
||||
fi
|
||||
|
||||
if test ${sku} = 2; then
|
||||
# 2091 MHz CPU and 844 MHz GPU hard limit. Vali.
|
||||
fdt set /cpufreq/cpu-scaling-data max-frequency <0x1FE7F8>
|
||||
fdt set /dvfs nvidia,gpu-max-freq-khz <0xCE400>
|
||||
fi
|
||||
fi
|
||||
|
||||
# Enable GPU DVFS C-Side.
|
||||
if test ${t210b01} = 1 -a ${gpu_dvfsc} = 1; then
|
||||
echoe DVFS C-Side GPU enabled
|
||||
|
||||
if test ${dvfsb} != 1; then
|
||||
setenv bootargs_extra ${bootargs_extra} "speedo_tegra210.sku_id=0x83 speedo_tegra210.gspd_id=3"
|
||||
else
|
||||
setenv bootargs_extra ${bootargs_extra} "speedo_tegra210.gspd_id=3"
|
||||
fi
|
||||
fi
|
||||
|
||||
# Limit GPU clock.
|
||||
if test ${t210b01} = 1 -a ${limit_gpu_clk} = 1; then
|
||||
|
||||
if test ${sku} != 2; then
|
||||
# If not Vali set GPU hard limit to 1075 MHz.
|
||||
echoe GPU clock limit enabled
|
||||
fdt set /dvfs nvidia,gpu-max-freq-khz <0x106800>
|
||||
fi
|
||||
fi
|
||||
|
||||
# Set pmic type if special (devboard).
|
||||
if test ${t210b01} = 1 -a -n "${pmic_type}" -a ${pmic_type} = 1; then
|
||||
echoe GPU 15A Regulator enabled
|
||||
fdt set /i2c@7000d000/max77812@33 reg <0x31>
|
||||
fdt set /i2c@7000d000/max77812@33/m3vout status disabled
|
||||
fdt set /i2c@7000d000/fan53528@52 status okay
|
||||
fdt set /dvfs nvidia,gpu-max-volt-mv <0x3B6>
|
||||
fi
|
||||
|
||||
# Check if ptsa rework is done.
|
||||
if test ${t210b01} = 1 -a "${loader_rev}" > 1; then
|
||||
echo PTSA rework done
|
||||
setenv bootargs_extra ${bootargs_extra} "latency_allowance.ptsa_rework"
|
||||
fi
|
||||
|
||||
# Set serial number.
|
||||
if test -n ${device_serial}; then fdt set / serial-number ${device_serial}; fi
|
||||
|
@ -1,5 +1,5 @@
|
||||
PKG_NAME="switch-bootloader"
|
||||
PKG_VERSION="2.3"
|
||||
PKG_VERSION="2.5"
|
||||
PKG_ARCH="any"
|
||||
PKG_DEPENDS_TARGET="switch-u-boot:host switch-u-boot:target switch-atf:target"
|
||||
PKG_TOOLCHAIN="manual"
|
||||
|
@ -1,5 +1,5 @@
|
||||
PKG_NAME="switch-bsp"
|
||||
PKG_VERSION="1.0"
|
||||
PKG_VERSION="1.1"
|
||||
PKG_LICENSE="GPL"
|
||||
PKG_DEPENDS_TARGET="joycond rewritefs xdotool alsa-lib alsa-ucm-conf usb-gadget-scripts v4l-utils"
|
||||
PKG_SECTION="virtual"
|
||||
|
@ -6,12 +6,27 @@ if [[ -f /flash/switchroot/joycon_mac.ini ]]; then
|
||||
JOYCON_00_MAC=$(sed -nr "/^\[joycon_00\]/ { :l /^mac[ ]*=/ { s/.*=[ ]*//; p; q;}; n; b l;}" /flash/switchroot/joycon_mac.ini | tr -d "\\r\\n")
|
||||
JOYCON_00_HOST_MAC=$(sed -nr "/^\[joycon_00\]/ { :l /^host[ ]*=/ { s/.*=[ ]*//; p; q;}; n; b l;}" /flash/switchroot/joycon_mac.ini | tr -d "\\r\\n")
|
||||
JOYCON_00_LTK=$(sed -nr "/^\[joycon_00\]/ { :l /^ltk[ ]*=/ { s/.*=[ ]*//; p; q;}; n; b l;}" /flash/switchroot/joycon_mac.ini | tr -d "\\r\\n")
|
||||
if [[ -z ${JOYCON_00_TYPE} ]]; then
|
||||
JOYCON_00_TYPE="0"
|
||||
fi
|
||||
|
||||
# collect joycon_00 info from ini
|
||||
# collect joycon_01 info from ini
|
||||
JOYCON_01_TYPE=$(sed -nr "/^\[joycon_01\]/ { :l /^type[ ]*=/ { s/.*=[ ]*//; p; q;}; n; b l;}" /flash/switchroot/joycon_mac.ini | tr -d "\\r\\n")
|
||||
JOYCON_01_MAC=$(sed -nr "/^\[joycon_01\]/ { :l /^mac[ ]*=/ { s/.*=[ ]*//; p; q;}; n; b l;}" /flash/switchroot/joycon_mac.ini | tr -d "\\r\\n")
|
||||
JOYCON_01_HOST_MAC=$(sed -nr "/^\[joycon_01\]/ { :l /^host[ ]*=/ { s/.*=[ ]*//; p; q;}; n; b l;}" /flash/switchroot/joycon_mac.ini | tr -d "\\r\\n")
|
||||
JOYCON_01_LTK=$(sed -nr "/^\[joycon_01\]/ { :l /^ltk[ ]*=/ { s/.*=[ ]*//; p; q;}; n; b l;}" /flash/switchroot/joycon_mac.ini | tr -d "\\r\\n")
|
||||
if [[ -z ${JOYCON_01_TYPE} ]]; then
|
||||
JOYCON_01_TYPE="0"
|
||||
fi
|
||||
|
||||
# Collect joycon_02 info from ini
|
||||
JOYCON_02_TYPE=$(sed -nr "/^\[joycon_02\]/ { :l /^type[ ]*=/ { s/.*=[ ]*//; p; q;}; n; b l;}" /flash/switchroot/joycon_mac.ini | tr -d "\\r\\n")
|
||||
JOYCON_02_MAC=$(sed -nr "/^\[joycon_02\]/ { :l /^mac[ ]*=/ { s/.*=[ ]*//; p; q;}; n; b l;}" /flash/switchroot/joycon_mac.ini | tr -d "\\r\\n")
|
||||
JOYCON_02_HOST_MAC=$(sed -nr "/^\[joycon_02\]/ { :l /^host[ ]*=/ { s/.*=[ ]*//; p; q;}; n; b l;}" /flash/switchroot/joycon_mac.ini | tr -d "\\r\\n")
|
||||
JOYCON_02_LTK=$(sed -nr "/^\[joycon_02\]/ { :l /^ltk[ ]*=/ { s/.*=[ ]*//; p; q;}; n; b l;}" /flash/switchroot/joycon_mac.ini | tr -d "\\r\\n")
|
||||
if [[ -z ${JOYCON_02_TYPE} ]]; then
|
||||
JOYCON_02_TYPE="0"
|
||||
fi
|
||||
|
||||
# Handle Host BT MAC. Agnostically.
|
||||
if [[ ! ${JOYCON_00_TYPE} == "0" ]]; then
|
||||
@ -32,6 +47,12 @@ if [[ -f /flash/switchroot/joycon_mac.ini ]]; then
|
||||
BT_DEV_00_SERVICE_RECORDS="0x00000000=356E0900000A000000000900013503191000090004350D350619010009000135031900010900053503191002090006350909656E09006A090100090009350835061901000901000901002510576972656C6573732047616D65706164090101250747616D657061640902003503090100
|
||||
0x00010000=36017D0900000A000100000900013503191124090004350D350619010009001135031900110900053503191002090006350909656E09006A0901000900093508350619112409010109000D350F350D350619010009001335031900110901002510576972656C6573732047616D65706164090101250747616D6570616409010225084E696E74656E646F090201090111090202080809020308210902042801090205280109020635B035AE082225AA05010905A1010601FF8521092175089530810285300930750895308102853109317508966901810285320932750896690181028533093375089669018102853F05091901291015002501750195108102050109391500250775049501814205097504950181010501093009310933093416000027FFFF00007510950481020601FF85010901750895309102851009107508953091028511091175089530910285120912750895309102C009020735083506090409090100090209280109020A280109020C090C8009020D280009020E2800
|
||||
0x00010001=358C0900000A000100010900013503191200090004350D35061901000900013503190001090006350909656E09006A09010009000935083506191200090100090100251B576972656C6573732047616D6570616420506E5020536572766572090101250747616D6570616409020009010309020109057E0902020920070902030900010902042801090205090002"
|
||||
elif [[ ${JOYCON_00_TYPE} == "3" ]]; then
|
||||
BT_DEV_01_NAME="Pro Controller"
|
||||
BT_DEV_01_ID=8201
|
||||
BT_DEV_01_SERVICE_RECORDS="0x00000000=356E0900000A000000000900013503191000090004350D350619010009000135031900010900053503191002090006350909656E09006A090100090009350835061901000901000901002510576972656C6573732047616D65706164090101250747616D657061640902003503090100
|
||||
0x00010000=36017D0900000A000100000900013503191124090004350D350619010009001135031900110900053503191002090006350909656E09006A0901000900093508350619112409010109000D350F350D350619010009001335031900110901002510576972656C6573732047616D65706164090101250747616D6570616409010225084E696E74656E646F090201090111090202080809020308210902042801090205280109020635B035AE082225AA05010905A1010601FF8521092175089530810285300930750895308102853109317508966901810285320932750896690181028533093375089669018102853F05091901291015002501750195108102050109391500250775049501814205097504950181010501093009310933093416000027FFFF00007510950481020601FF85010901750895309102851009107508953091028511091175089530910285120912750895309102C009020735083506090409090100090209280109020A280109020C090C8009020D280009020E2800
|
||||
0x00010001=358C0900000A000100010900013503191200090004350D35061901000900013503190001090006350909656E09006A09010009000935083506191200090100090100251B576972656C6573732047616D6570616420506E5020536572766572090101250747616D6570616409020009010309020109057E0902020920090902030900010902042801090205090002"
|
||||
fi
|
||||
|
||||
if [[ ${JOYCON_01_TYPE} == "1" ]]; then
|
||||
@ -46,13 +67,40 @@ if [[ -f /flash/switchroot/joycon_mac.ini ]]; then
|
||||
BT_DEV_01_SERVICE_RECORDS="0x00000000=356E0900000A000000000900013503191000090004350D350619010009000135031900010900053503191002090006350909656E09006A090100090009350835061901000901000901002510576972656C6573732047616D65706164090101250747616D657061640902003503090100
|
||||
0x00010000=36017D0900000A000100000900013503191124090004350D350619010009001135031900110900053503191002090006350909656E09006A0901000900093508350619112409010109000D350F350D350619010009001335031900110901002510576972656C6573732047616D65706164090101250747616D6570616409010225084E696E74656E646F090201090111090202080809020308210902042801090205280109020635B035AE082225AA05010905A1010601FF8521092175089530810285300930750895308102853109317508966901810285320932750896690181028533093375089669018102853F05091901291015002501750195108102050109391500250775049501814205097504950181010501093009310933093416000027FFFF00007510950481020601FF85010901750895309102851009107508953091028511091175089530910285120912750895309102C009020735083506090409090100090209280109020A280109020C090C8009020D280009020E2800
|
||||
0x00010001=358C0900000A000100010900013503191200090004350D35061901000900013503190001090006350909656E09006A09010009000935083506191200090100090100251B576972656C6573732047616D6570616420506E5020536572766572090101250747616D6570616409020009010309020109057E0902020920070902030900010902042801090205090002"
|
||||
elif [[ ${JOYCON_01_TYPE} == "3" ]]; then
|
||||
BT_DEV_01_NAME="Pro Controller"
|
||||
BT_DEV_01_ID=8201
|
||||
BT_DEV_01_SERVICE_RECORDS="0x00000000=356E0900000A000000000900013503191000090004350D350619010009000135031900010900053503191002090006350909656E09006A090100090009350835061901000901000901002510576972656C6573732047616D65706164090101250747616D657061640902003503090100
|
||||
0x00010000=36017D0900000A000100000900013503191124090004350D350619010009001135031900110900053503191002090006350909656E09006A0901000900093508350619112409010109000D350F350D350619010009001335031900110901002510576972656C6573732047616D65706164090101250747616D6570616409010225084E696E74656E646F090201090111090202080809020308210902042801090205280109020635B035AE082225AA05010905A1010601FF8521092175089530810285300930750895308102853109317508966901810285320932750896690181028533093375089669018102853F05091901291015002501750195108102050109391500250775049501814205097504950181010501093009310933093416000027FFFF00007510950481020601FF85010901750895309102851009107508953091028511091175089530910285120912750895309102C009020735083506090409090100090209280109020A280109020C090C8009020D280009020E2800
|
||||
0x00010001=358C0900000A000100010900013503191200090004350D35061901000900013503190001090006350909656E09006A09010009000935083506191200090100090100251B576972656C6573732047616D6570616420506E5020536572766572090101250747616D6570616409020009010309020109057E0902020920090902030900010902042801090205090002"
|
||||
fi
|
||||
|
||||
if [[ ${JOYCON_02_TYPE} == "1" ]]; then
|
||||
BT_DEV_02_NAME="Joy-Con (L)"
|
||||
BT_DEV_02_ID=8198
|
||||
BT_DEV_02_SERVICE_RECORDS="0x00000000=356E0900000A000000000900013503191000090004350D350619010009000135031900010900053503191002090006350909656E09006A090100090009350835061901000901000901002510576972656C6573732047616D65706164090101250747616D657061640902003503090100
|
||||
0x00010000=36017D0900000A000100000900013503191124090004350D350619010009001135031900110900053503191002090006350909656E09006A0901000900093508350619112409010109000D350F350D350619010009001335031900110901002510576972656C6573732047616D65706164090101250747616D6570616409010225084E696E74656E646F090201090111090202080809020308210902042801090205280109020635B035AE082225AA05010905A1010601FF8521092175089530810285300930750895308102853109317508966901810285320932750896690181028533093375089669018102853F05091901291015002501750195108102050109391500250775049501814205097504950181010501093009310933093416000027FFFF00007510950481020601FF85010901750895309102851009107508953091028511091175089530910285120912750895309102C009020735083506090409090100090209280109020A280109020C090C8009020D280009020E2800
|
||||
0x00010001=358C0900000A000100010900013503191200090004350D35061901000900013503190001090006350909656E09006A09010009000935083506191200090100090100251B576972656C6573732047616D6570616420506E5020536572766572090101250747616D6570616409020009010309020109057E0902020920060902030900010902042801090205090002"
|
||||
elif [[ ${JOYCON_02_TYPE} == "2" ]]; then
|
||||
BT_DEV_02_NAME="Joy-Con (R)"
|
||||
BT_DEV_02_ID=8199
|
||||
BT_DEV_02_SERVICE_RECORDS="0x00000000=356E0900000A000000000900013503191000090004350D350619010009000135031900010900053503191002090006350909656E09006A090100090009350835061901000901000901002510576972656C6573732047616D65706164090101250747616D657061640902003503090100
|
||||
0x00010000=36017D0900000A000100000900013503191124090004350D350619010009001135031900110900053503191002090006350909656E09006A0901000900093508350619112409010109000D350F350D350619010009001335031900110901002510576972656C6573732047616D65706164090101250747616D6570616409010225084E696E74656E646F090201090111090202080809020308210902042801090205280109020635B035AE082225AA05010905A1010601FF8521092175089530810285300930750895308102853109317508966901810285320932750896690181028533093375089669018102853F05091901291015002501750195108102050109391500250775049501814205097504950181010501093009310933093416000027FFFF00007510950481020601FF85010901750895309102851009107508953091028511091175089530910285120912750895309102C009020735083506090409090100090209280109020A280109020C090C8009020D280009020E2800
|
||||
0x00010001=358C0900000A000100010900013503191200090004350D35061901000900013503190001090006350909656E09006A09010009000935083506191200090100090100251B576972656C6573732047616D6570616420506E5020536572766572090101250747616D6570616409020009010309020109057E0902020920070902030900010902042801090205090002"
|
||||
elif [[ ${JOYCON_02_TYPE} == "3" ]]; then
|
||||
BT_DEV_02_NAME="Pro Controller"
|
||||
BT_DEV_02_ID=8201
|
||||
BT_DEV_02_SERVICE_RECORDS="0x00000000=356E0900000A000000000900013503191000090004350D350619010009000135031900010900053503191002090006350909656E09006A090100090009350835061901000901000901002510576972656C6573732047616D65706164090101250747616D657061640902003503090100
|
||||
0x00010000=36017D0900000A000100000900013503191124090004350D350619010009001135031900110900053503191002090006350909656E09006A0901000900093508350619112409010109000D350F350D350619010009001335031900110901002510576972656C6573732047616D65706164090101250747616D6570616409010225084E696E74656E646F090201090111090202080809020308210902042801090205280109020635B035AE082225AA05010905A1010601FF8521092175089530810285300930750895308102853109317508966901810285320932750896690181028533093375089669018102853F05091901291015002501750195108102050109391500250775049501814205097504950181010501093009310933093416000027FFFF00007510950481020601FF85010901750895309102851009107508953091028511091175089530910285120912750895309102C009020735083506090409090100090209280109020A280109020C090C8009020D280009020E2800
|
||||
0x00010001=358C0900000A000100010900013503191200090004350D35061901000900013503190001090006350909656E09006A09010009000935083506191200090100090100251B576972656C6573732047616D6570616420506E5020536572766572090101250747616D6570616409020009010309020109057E0902020920090902030900010902042801090205090002"
|
||||
fi
|
||||
|
||||
if [[ ! -d /var/bluetoothconfig/${BT_MAC_ADDR}/cache ]]; then
|
||||
mkdir -p /var/bluetoothconfig/${BT_MAC_ADDR}/cache
|
||||
fi
|
||||
|
||||
if [[ ! ${JOYCON_00_TYPE} == "0" ]]; then
|
||||
if [[ ! -d /var/bluetoothconfig/${BT_MAC_ADDR}/${JOYCON_00_MAC} ]]; then
|
||||
if [[ ! -d /var/bluetoothconfig/${BT_MAC_ADDR}/${JOYCON_00_MAC} ]] || [[ ! $(grep -q ${JOYCON_00_LTK} /var/bluetoothconfig/${BT_MAC_ADDR}/${JOYCON_00_MAC}/info; echo $?) -eq 0 ]]; then
|
||||
mkdir -p /var/bluetoothconfig/${BT_MAC_ADDR}/${JOYCON_00_MAC}
|
||||
cat << EOF > /var/bluetoothconfig/${BT_MAC_ADDR}/${JOYCON_00_MAC}/info
|
||||
[General]
|
||||
@ -90,7 +138,7 @@ EOF
|
||||
fi
|
||||
|
||||
if [[ ! ${JOYCON_01_TYPE} == "0" ]]; then
|
||||
if [[ ! -d /var/bluetoothconfig/${BT_MAC_ADDR}/${JOYCON_01_MAC} ]]; then
|
||||
if [[ ! -d /var/bluetoothconfig/${BT_MAC_ADDR}/${JOYCON_01_MAC} ]] || [[ ! $(grep -q ${JOYCON_01_LTK} /var/bluetoothconfig/${BT_MAC_ADDR}/${JOYCON_01_MAC}/info; echo $?) -eq 0 ]]; then
|
||||
mkdir -p /var/bluetoothconfig/${BT_MAC_ADDR}/${JOYCON_01_MAC}
|
||||
cat << EOF > /var/bluetoothconfig/${BT_MAC_ADDR}/${JOYCON_01_MAC}/info
|
||||
[General]
|
||||
@ -123,6 +171,44 @@ Name=${BT_DEV_01_NAME}
|
||||
|
||||
[ServiceRecords]
|
||||
${BT_DEV_01_SERVICE_RECORDS}
|
||||
EOF
|
||||
|
||||
fi
|
||||
fi
|
||||
if [[ ! ${JOYCON_02_TYPE} == "0" ]]; then
|
||||
if [[ ! -d /var/bluetoothconfig/${BT_MAC_ADDR}/${JOYCON_02_MAC} ]] || [[ ! $(grep -q ${JOYCON_02_LTK} /var/bluetoothconfig/${BT_MAC_ADDR}/${JOYCON_02_MAC}/info; echo $?) -eq 0 ]]; then
|
||||
mkdir -p /var/bluetoothconfig/bluetooth/${BT_MAC_ADDR}/${JOYCON_02_MAC}
|
||||
cat << EOF > /var/bluetoothconfig/${BT_MAC_ADDR}/${JOYCON_02_MAC}/info
|
||||
[General]
|
||||
Name=${BT_DEV_02_NAME}
|
||||
Class=0x002508
|
||||
SupportedTechnologies=BR/EDR;
|
||||
Trusted=true
|
||||
Blocked=false
|
||||
Services=00001000-0000-1000-8000-00805f9b34fb;00001124-0000-1000-8000-00805f9b34fb;00001200-0000-1000-8000-00805f9b34fb;
|
||||
[LinkKey]
|
||||
Key=${JOYCON_02_LTK}
|
||||
Type=4
|
||||
PINLength=0
|
||||
|
||||
[DeviceID]
|
||||
Source=2
|
||||
Vendor=1406
|
||||
Product=${BT_DEV_02_ID}
|
||||
Version=1
|
||||
|
||||
[ConnectionParameters]
|
||||
MinInterval=5
|
||||
MaxInterval=15
|
||||
Latency=120
|
||||
Timeout=600
|
||||
EOF
|
||||
cat << EOF > /var/bluetoothconfig/${BT_MAC_ADDR}/cache/${JOYCON_02_MAC}
|
||||
[General]
|
||||
Name=${BT_DEV_02_NAME}
|
||||
|
||||
[ServiceRecords]
|
||||
${BT_DEV_02_SERVICE_RECORDS}
|
||||
EOF
|
||||
|
||||
fi
|
||||
|
@ -1,9 +1,9 @@
|
||||
PKG_NAME="switch-u-boot"
|
||||
PKG_VERSION="dd5432fa2ad727b3af159a704367a6e1fd6f246d"
|
||||
PKG_VERSION="69c0501a638f535424a4d045355f45c028110f82"
|
||||
PKG_GIT_CLONE_BRANCH="linux-hekatf"
|
||||
PKG_DEPENDS_HOST="toolchain Python3:host gcc:host swig:host"
|
||||
PKG_DEPENDS_TARGET="toolchain Python3 gcc:target swig:host"
|
||||
PKG_SITE="https://gitlab.com/switchroot/switch-uboot"
|
||||
PKG_SITE="https://github.com/CTCaer/switch-l4t-uboot"
|
||||
PKG_URL="${PKG_SITE}.git"
|
||||
PKG_TOOLCHAIN="make"
|
||||
|
||||
|
@ -1,31 +0,0 @@
|
||||
diff -Naur linux-Switch/nvidia/drivers/video/tegra/dc/dp_branch.c linux-Switch-2/nvidia/drivers/video/tegra/dc/dp_branch.c
|
||||
--- linux-Switch/nvidia/drivers/video/tegra/dc/dp_branch.c 2022-01-05 18:00:36.325665889 +0100
|
||||
+++ linux-Switch-2/nvidia/drivers/video/tegra/dc/dp_branch.c 2022-01-05 18:17:06.605838285 +0100
|
||||
@@ -66,6 +66,15 @@
|
||||
tegra_dc_dp_dpcd_write(dp, NV_DPCD_BRANCH_STDP_CEC_RX_INFO,
|
||||
dpcd_data);
|
||||
|
||||
+
|
||||
+
|
||||
+ printk(KERN_ALERT "dp: cec: rx data: ");
|
||||
+ for (i = 0; i < msg_len; i++)
|
||||
+ printk(KERN_CONT "%02X ", msg[i]);
|
||||
+ printk(KERN_CONT "\n");
|
||||
+
|
||||
+
|
||||
+
|
||||
return msg_len;
|
||||
}
|
||||
|
||||
@@ -332,6 +341,11 @@
|
||||
cec_transmit_done(data->adap, CEC_TX_STATUS_OK,
|
||||
0, 0, 0, 0);
|
||||
}
|
||||
+
|
||||
+ printk(KERN_ALERT "dp: cec: tx data: ");
|
||||
+ for (i = 0; i < data->cec_tx_len; i++)
|
||||
+ printk(KERN_CONT "%02X ", data->cec_tx_buf[i]);
|
||||
+ printk(KERN_CONT " (tries: %d/%d)\n", i, data->cec_tx_attempts);
|
||||
}
|
||||
|
||||
static void dpb_stm_cec_rx_worker(struct work_struct *work)
|
Loading…
Reference in New Issue
Block a user