samsung-j7y17lte: new device (MR 4502)

[ci:skip-build]: Already built successfully in CI.
This commit is contained in:
Eray Tutmaz 2024-02-14 19:51:51 -03:00 committed by Clayton Craft
parent d33abab084
commit 93f68f6253
No known key found for this signature in database
GPG key ID: 4A4CED6D7EDF950A
21 changed files with 5526 additions and 0 deletions

View file

@ -0,0 +1,73 @@
# Reference: <https://postmarketos.org/devicepkg>
# Maintainer: Eray Tutmaz <tarkanttmz261@gmail.com>
pkgname=device-samsung-j7y17lte
pkgdesc="Samsung Galaxy J7 2017"
pkgver=1
pkgrel=0
url="https://postmarketos.org"
license="MIT"
arch="aarch64"
options="!check !archcheck"
depends="
alsa-utils
mkbootimg
postmarketos-base
samsungipcd
util-linux
postmarketos-base-downstream
linux-samsung-j7y17lte
msm-fb-refresher
pipewire
pipewire-pulse
"
replaces="
pipewire-media-session
udev-init-scripts-openrc
"
makedepends="devicepkg-dev"
install="$pkgname.post-install"
source="
deviceinfo
etc-conf.d-samsungipcd
etc-init.d-udev-settle
etc-init.d-wlan0-up
NetworkManager-conf.d-wlan0-unmanaged.conf
usr-libexec-samsungipcd-voicecall.sh
usr-share-alsa-ucm2-conf.d-Universal7870-I-HiFi.conf
usr-share-alsa-ucm2-conf.d-Universal7870-I-Universal7870-I.conf
usr-share-alsa-ucm2-conf.d-Universal7870-I-VoiceCall.conf
usr-share-pipewire-media-session.d-alsa-monitor.conf
"
# pulseaudio does not seem to work on this device. Will use pipewire-pulse instead.
# (For downstream kernel, mainline does not have audio yet and I'd like to run Phosh)
build() {
devicepkg_build $startdir $pkgname
}
package() {
devicepkg_package $startdir $pkgname
install -Dm644 etc-conf.d-samsungipcd "$pkgdir"/etc/conf.d/samsungipcd
install -Dm755 etc-init.d-udev-settle "$pkgdir"/etc/init.d/udev-settle
install -Dm755 etc-init.d-wlan0-up "$pkgdir"/etc/init.d/wlan0-up
install -Dm644 NetworkManager-conf.d-wlan0-unmanaged.conf "$pkgdir"/usr/lib/NetworkManager/conf.d/swlan0-unmanaged.conf
install -Dm755 usr-libexec-samsungipcd-voicecall.sh "$pkgdir"/usr/libexec/samsungipcd/voicecall.sh
install -Dm644 usr-share-alsa-ucm2-conf.d-Universal7870-I-HiFi.conf "$pkgdir"/usr/share/alsa/ucm2/conf.d/Universal7870-I/HiFi.conf
install -Dm644 usr-share-alsa-ucm2-conf.d-Universal7870-I-Universal7870-I.conf "$pkgdir"/usr/share/alsa/ucm2/conf.d/Universal7870-I/Universal7870-I.conf
install -Dm644 usr-share-alsa-ucm2-conf.d-Universal7870-I-VoiceCall.conf "$pkgdir"/usr/share/alsa/ucm2/conf.d/Universal7870-I/VoiceCall.conf
install -Dm644 usr-share-pipewire-media-session.d-alsa-monitor.conf "$pkgdir"/usr/share/pipewire/media-session.d/alsa-monitor.conf
}
sha512sums="
ec63da7e446e81427dd60b1ad23f0a1615760697aa68de00e40af410c92c1bb0086813dfa85994af30fd592bffba5ec16ffdff61e674312558e19e0d54ae61c6 deviceinfo
3e5bb764529010d2b6b1f2759a7799f665d140aebcee2dd63433e68cd4282e09b5d3b34fb7c21e737595b406501e7f02ece4592651c60e4c2b9419de4aedb438 etc-conf.d-samsungipcd
203b832a7080d5f1351c5e024e444f9fe509f6e0fd4b376a60c7d73359b7e356863a4f15caf9b2e4e733dc44d2971722083e7c69ca94a012eb004b4b8ded9d09 etc-init.d-udev-settle
7caddfe4659c969a33adcc27a760bc78d4f70ca4b7a4a5ec28a6411c12f3e6dd6d427b59f75976a737a5fe0f09806f8b6d65798f6358bd1e1954ad2a28fbfdc8 etc-init.d-wlan0-up
8a8720d86b4c98f02d3a6cd8ed97ed77b1c341548f5917c81133810c632780e118c178ae0496c222882da6403035c2ebace6e1b589995e153e9068876dc9591a NetworkManager-conf.d-wlan0-unmanaged.conf
abe1c4a2f59fe862cebef75c54b8806bd86ce06aeb15d8c0699ab1338c9d575cb72a4d5b099f94272b1d9c9c3f4960af209a9e058ea9e57733b7d905dad0d33f usr-libexec-samsungipcd-voicecall.sh
cdee42ea2766397dfa0a93fd9041489328b087a594e0fa8252bf36a8e44f7fca1f1b084b453b50205d434ea8eed248259e03f397ea41ba9d24110deefbc250f6 usr-share-alsa-ucm2-conf.d-Universal7870-I-HiFi.conf
5f460a5951a8255b2456babc72ad38470888e2ba02ab4545d05a7f91d85fcaf99123776416967d4a111c70610a5e2cd9ba66e4bdbb8be25342f82f822deab51d usr-share-alsa-ucm2-conf.d-Universal7870-I-Universal7870-I.conf
482e881e9a5e3a6130bdb0a04143e21d4accb3e00ff2d11755f79cea5ef0ee7d6dc4e9877caf0460c9b812c32e51689aa5efec9c905c6fd77793d614a687b1e2 usr-share-alsa-ucm2-conf.d-Universal7870-I-VoiceCall.conf
2976dbbd02f514c3b7dfba8da63bb54678eb019bc236927a3caa4f70fc38101ce7fab78d1ced823bff5110adcf34e710a3eba75b7ec9ce98f7fce3918426d91c usr-share-pipewire-media-session.d-alsa-monitor.conf
"

View file

@ -0,0 +1,5 @@
[main]
plugins=keyfile
[keyfile]
unmanaged-devices=interface-name:wlan0;interface-name:p2p0

View file

@ -0,0 +1,19 @@
#!/bin/sh
# Create mount point and /efs mount point in fstab
if ! grep -q /efs /etc/fstab; then
mkdir -p /efs
echo "/dev/disk/by-partlabel/EFS /efs auto ro 0 0" >> /etc/fstab
fi
if ! grep -q /vendor /etc/fstab; then
mkdir -p /vendor
echo "/dev/disk/by-partlabel/VENDOR /vendor auto ro 0 0" >> /etc/fstab
fi
if ! grep -q /sdcard1 /etc/fstab; then
mkdir -p /sdcard1
echo "/dev/mmcblk1p1 /sdcard1 auto rw 0 0" >> /etc/fstab
fi
rc-update add wlan0-up sysinit

View file

@ -0,0 +1,31 @@
# Reference: <https://postmarketos.org/deviceinfo>
# Please use double quotes only. You can source this file in shell
# scripts.
deviceinfo_format_version="0"
deviceinfo_name="Samsung Galaxy J7 Pro"
deviceinfo_manufacturer="Samsung"
deviceinfo_codename="samsung-j7y17lte"
deviceinfo_year="2017"
deviceinfo_arch="aarch64"
# Device related
deviceinfo_chassis="handset"
deviceinfo_keyboard="false"
deviceinfo_external_storage="true"
# Bootloader related
deviceinfo_flash_method="heimdall-bootimg"
deviceinfo_kernel_cmdline="androidboot.selinux=permissive androidboot.selinux=permissive"
deviceinfo_generate_bootimg="true"
deviceinfo_bootimg_qcdt="true"
deviceinfo_bootimg_mtk_mkimage="false"
deviceinfo_bootimg_dtb_second="false"
deviceinfo_flash_pagesize="2048"
deviceinfo_flash_offset_base="0x10000000"
deviceinfo_flash_offset_kernel="0x00008000"
deviceinfo_flash_offset_ramdisk="0x01000000"
deviceinfo_flash_offset_second="0x00f00000"
deviceinfo_flash_offset_tags="0x00000100"
deviceinfo_flash_heimdall_partition_kernel="BOOT"
deviceinfo_flash_heimdall_partition_system="SYSTEM"

View file

@ -0,0 +1 @@
IPC_DEVICE_NAME="herolte"

View file

@ -0,0 +1,17 @@
#!/sbin/openrc-run
# Copyright 2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
depend() {
need udev
after udev-trigger
provide dev-settle
keyword -containers
}
# udev-settle takes 3 minutes to start (and fails anyway, after which the device boots). Nuking it.
start() {
ebegin "Not waiting for uevents to be processed"
eend $?
}

View file

@ -0,0 +1,8 @@
#!/sbin/openrc-run
description="Hack to fix wlan0 EINVAL if rfkilled on boot"
start () {
ifconfig wlan0 up
ifconfig wlan0 down
}

View file

@ -0,0 +1,61 @@
#!/bin/sh
# This script sets up the audio subsystem to route audio to and from the modem.
# Called by samsungipcd when the call starts. When the call ends, we receive a
# newline and terminate ourselves.
# Note: as a side effect, software on the phone cannot access the microphone
# during a call.
# Put ourselves into a PID namespace. This is an easy and non-racey way to
# ensure that all child processes get killed on our exit.
if [ "$$" != 1 ]; then
unshare -p sh "$0"
exitcode="$?"
# Restore MIC1 state to normal. We should be the only entity fiddling
# with that.
amixer -D sysdefault cset name='MIC1 MIC1 On' 1
exit "$exitcode"
fi
# callaudiod has already changed the UCM verb, no need to do it manually
#alsaucm set _verb 'Voice Call'
# In order for sound to be forwarded, there must be applictions that are
# currently playing and recording audio. To ensure that they exists, we
# connect to each user's PipeWire and start ones.
# Playback
for i in /run/user/*/; do
# To avoid vulnerabilities in PulseAudio becoming LPEs, setuid to the
# user running PipeWire.
XDG_RUNTIME_DIR="$i" su -c 'aplay /dev/zero' "$(grep "^[^:]*:[^:]*:$(basename "$i"):" /etc/passwd | cut -d : -f 1-1)" &
done
# Same for recording
for i in /run/user/*/; do
XDG_RUNTIME_DIR="$i" su -c 'arecord /dev/null' "$(grep "^[^:]*:[^:]*:$(basename "$i"):" /etc/passwd | cut -d : -f 1-1)" &
done
# Microphone switching logic
for i in /run/user/*/; do
XDG_RUNTIME_DIR="$i" su -c '
# Set locale to C to avoid parsing localized command output
export LANG=C
# Report microphone mute events
( echo; pactl subscribe; ) | while read; do pactl get-source-mute @DEFAULT_SOURCE@; done
' "$(grep "^[^:]*:[^:]*:$(basename "$i"):" /etc/passwd | cut -d : -f 1-1)" &
done | while read line; do
if [[ "$line" == "Mute: yes" ]]; then
amixer -D sysdefault cset name='MIC1 MIC1 On' 0
elif [[ "$line" == "Mute: no" ]]; then
amixer -D sysdefault cset name='MIC1 MIC1 On' 1
fi
done &
# Wait for newline from samsungipcd. This means that the call has ended.
read
# No need to clean up, closing the PID namespace will kill all children
#jobs -p | xargs kill
# Again, callaudiod will switch UCM verbs for us
#alsaucm set _verb 'HiFi'

View file

@ -0,0 +1,59 @@
SectionVerb {
EnableSequence [
]
}
SectionDevice."Speaker" {
Comment "Internal speaker"
EnableSequence [
cset 'name="SPK SPK On" 1'
]
DisableSequence [
cset 'name="SPK SPK On" 0'
]
Value {
PlaybackPriority 101
PlaybackPCM "hw:${CardId}"
}
}
SectionDevice."Mic" {
Comment "Internal microphone"
EnableSequence [
cset 'name="MIC1 MIC1 On" 1'
]
DisableSequence [
cset 'name="MIC1 MIC1 On" 0'
]
Value {
CapturePriority 100
CapturePCM "hw:${CardId}"
}
}
SectionDevice."Earpiece" {
Comment "Earpiece"
EnableSequence [
cset 'name="EP EP On" 1'
cset 'name="EP Mixer DACL Switch" 1'
cset 'name="EP Mixer DACR Switch" 1'
]
DisableSequence [
cset 'name="EP Mixer DACR Switch" 0'
cset 'name="EP Mixer DACL Switch" 0'
cset 'name="EP EP On" 0'
]
Value {
PlaybackPriority 100
PlaybackPCM "hw:${CardId}"
}
}

View file

@ -0,0 +1,43 @@
Syntax 2
SectionUseCase."HiFi" {
Comment "Hi-Fi"
File "HiFi.conf"
}
SectionUseCase."Voice Call" {
Comment "Voice Call"
File "VoiceCall.conf"
}
SectionDefaults [
cset "name='AudioMixer Mixer En' 1"
cset "name='AudioMixer CH1 Mixer En' 1"
cset "name='AudioMixer CH2 Mixer En' 1"
cset "name='AudioMixer CH3 Mixer En' 1"
cset "name='AudioMixer CH4 Mixer En' 1"
cset "name='MonoMix Mode' 0"
cset "name='Chargepump Mode' 0"
cset "name='DNC ZCD Enable' 1"
cset "name='DNC ZCD Timeout' 1"
cset "name='DNC Max Gain' 12"
cset "name='HP HP On' 1"
cset "name='EP EP On' 1"
cset "name='SPK SPK On' 1"
cset "name='AudioMixer MIX1_LVL' 0"
cset "name='AudioMixer CH1 DOUT Select' 1"
cset "name='ADCL Mixer MIC1L Switch' 0"
cset "name='ADCL Mixer MIC2L Switch' 0"
cset "name='ADCL Mixer MIC3L Switch' 0"
cset "name='ADCL Mixer LINELL Switch' 0"
cset "name='ADCL Mixer LINERL Switch' 0"
cset "name='ADCR Mixer MIC1R Switch' 0"
cset "name='ADCR Mixer MIC2R Switch' 0"
cset "name='ADCR Mixer MIC3R Switch' 0"
cset "name='ADCR Mixer LINELR Switch' 0"
cset "name='ADCR Mixer LINERR Switch' 0"
cset "name='MIC1 MIC1 On' 0"
cset "name='MIC2 MIC2 On' 0"
cset "name='MIC3 MIC3 On' 0"
cset "name='LINEIN LINEIN On' 0"
]

View file

@ -0,0 +1,91 @@
SectionVerb {
EnableSequence [
cset 'name="AudioMixer SRC2 En" 1'
cset 'name="AudioMixer CH2 Mixer En" 1'
cset 'name="AudioMixer CH1 DOUT Select" 2'
cset 'name="AudioMixer CH2 DOUT Select" 1'
cset 'name="AudioMixer CH1 I2S Data Length" 0'
cset 'name="AudioMixer CH1 XFS" 1'
cset 'name="AudioMixer CH2 I2S Data Length" 0'
cset 'name="AudioMixer CH2 XFS" 0'
cset 'name="SPK SPK On" 0'
cset 'name="EP EP On" 1'
cset 'name="EP Mixer DACL Switch" 1'
cset 'name="EP Mixer DACR Switch" 1'
cset "name='MIC1 MIC1 On' 1"
cset "name='ADCR Mixer MIC1R Switch' 1"
cset "name='ADCL Mixer MIC1L Switch' 1"
]
DisableSequence [
cset 'name="EP Mixer DACR Switch" 0'
cset 'name="EP Mixer DACL Switch" 0'
cset 'name="EP EP On" 0'
cset 'name="SPK SPK On" 1'
cset 'name="AudioMixer CH2 DOUT Select" 0'
cset 'name="AudioMixer CH1 DOUT Select" 1'
cset 'name="AudioMixer CH2 Mixer En" 0'
cset 'name="AudioMixer SRC2 En" 0'
cset "name='MIC1 MIC1 On' 0"
cset "name='ADCR Mixer MIC1R Switch' 0"
cset "name='ADCL Mixer MIC1L Switch' 0"
]
}
SectionDevice."Speaker" {
Comment "Internal speaker"
EnableSequence [
cset 'name="SPK SPK On" 1'
]
DisableSequence [
cset 'name="SPK SPK On" 0'
]
Value {
PlaybackPriority 100
PlaybackPCM "hw:${CardId}"
}
}
SectionDevice."Mic" {
Comment "Internal microphone"
EnableSequence [
cset "name='MIC1 MIC1 On' 1"
cset "name='ADCR Mixer MIC1R Switch' 1"
cset "name='ADCL Mixer MIC1L Switch' 1"
]
DisableSequence [
cset "name='MIC1 MIC1 On' 0"
cset "name='ADCR Mixer MIC1R Switch' 0"
cset "name='ADCL Mixer MIC1L Switch' 0"
]
Value {
CapturePriority 100
CapturePCM "hw:${CardId}"
}
}
SectionDevice."Earpiece" {
Comment "Earpiece"
EnableSequence [
cset 'name="EP EP On" 1'
cset 'name="EP Mixer DACL Switch" 1'
cset 'name="EP Mixer DACR Switch" 1'
]
DisableSequence [
cset 'name="EP Mixer DACR Switch" 0'
cset 'name="EP Mixer DACL Switch" 0'
cset 'name="EP EP On" 0'
]
Value {
PlaybackPriority 101
PlaybackPCM "hw:${CardId}"
}
}

View file

@ -0,0 +1,126 @@
# ALSA monitor config file for PipeWire version 0.4.1 #
#
# Copy and edit this file in /etc/pipewire/media-session.d/
# for system-wide changes or in
# ~/.config/pipewire/media-session.d/ for local changes.
properties = {
# Create a JACK device. This is not enabled by default because
# it requires that the PipeWire JACK replacement libraries are
# not used by the session manager, in order to be able to
# connect to the real JACK server.
#alsa.jack-device = false
# Reserve devices.
#alsa.reserve = true
}
rules = [
# An array of matches/actions to evaluate.
{
# Rules for matching a device or node. Each dictionary in this array
# specifies the property to match as key and a string or regex match
# as value. A successful match requires all dictionary keys (i.e.
# properties) to match.
#
# Actions are are executed for the object if at least one successful
# match exists.
#
# Regular expressions are prefixed with the ~ (tilde) character,
# otherwise a standard string comparison is used.
# The special value "null" matches against empty properties.
matches = [
{
# This matches all cards. These are regular expressions
# so "." matches one character and ".*" matches many.
device.name = "~alsa_card.*"
}
]
actions = {
# Actions can update properties on the matched object.
update-props = {
# Use ALSA-Card-Profile devices. They use UCM or
# the profile configuration to configure the device
# and mixer settings.
api.alsa.use-acp = true
# Use UCM instead of profile when available. Can be
# disabled to skip trying to use the UCM profile.
#api.alsa.use-ucm = true
# Don't use the hardware mixer for volume control. It
# will only use software volume. The mixer is still used
# to mute unused paths based on the selected port.
api.alsa.soft-mixer = true
# Ignore decibel settings of the driver. Can be used to
# work around buggy drivers that report wrong values.
#api.alsa.ignore-dB = false
# The profile set to use for the device. Usually this is
# "default.conf" but can be changed with a udev rule
# or here.
#device.profile-set = "profileset-name.conf"
# The default active profile. Is by default set to "Off".
#device.profile = "default profile name"
# Automatically select the best profile. This is the
# highest priority available profile. This is disabled
# here and instead implemented in the session manager
# where it can save and load previous preferences.
api.acp.auto-profile = false
# Automatically switch to the highest priority available
# port. This is disabled here and implemented in the
# session manager instead.
api.acp.auto-port = false
# Other properties can be set here.
#device.nick = "My Device"
}
}
}
{
matches = [
{
# Matches all sources. These are regular expressions
# so "." matches one character and ".*" matches many.
node.name = "~alsa_input.*"
}
{
# Matches all sinks.
node.name = "~alsa_output.*"
}
]
actions = {
update-props = {
#node.nick = "My Node"
#node.nick = null
#priority.driver = 100
#priority.session = 100
node.pause-on-idle = false
#resample.quality = 4
#channelmix.normalize = false
#channelmix.mix-lfe = false
#audio.channels = 2
#audio.format = "S16LE"
#audio.rate = 44100
#audio.position = "FL,FR"
#session.suspend-timeout-seconds = 0 # 0 disables suspend
#monitor.channel-volumes = false
#latency.internal.rate = 0 # internal latency in samples
#latency.internal.ns = 0 # internal latency in nanoseconds
#api.alsa.period-size = 1024
api.alsa.headroom = 1024
#api.alsa.start-delay = 0
#api.alsa.disable-mmap = false
#api.alsa.disable-batch = false
#api.alsa.use-chmap = false
#iec958.codecs = [ PCM DTS AC3 MPEG MPEG2-AAC EAC3 TrueHD DTS-HD ]
}
}
}
]

View file

@ -0,0 +1,84 @@
# Reference: <https://postmarketos.org/vendorkernel>
# Kernel config based on the stock Android one
pkgname=linux-samsung-j7y17lte
pkgver=3.18.140
pkgrel=0
pkgdesc="Samsung Galaxy J7 2017 kernel fork"
arch="aarch64"
_carch="arm64"
_flavor="samsung-j7y17lte"
url="https://kernel.org"
license="GPL-2.0-only"
options="!strip !check !tracedeps pmb:cross-native"
makedepends="
bash
bc
bison
devicepkg-dev
dtbtool-exynos
flex
gcc4
openssl-dev
perl
"
if [ "${CC:0:5}" != "gcc4-" ]; then
CC="gcc4-$CC"
HOSTCC="gcc4-gcc"
CROSS_COMPILE="gcc4-$CROSS_COMPILE"
fi
# Source
_repository="linux-3.18.140-kernel-source"
_commit="6fa3aaf35a35ee3acadacf158a364acc47ab6653"
_config="config-$_flavor.$arch"
source="
$pkgname-$_commit.tar.gz::https://gitlab.com/j7-pro-unofficial-development/$_repository/-/archive/$_commit.tar.gz
$_config
gcc10-extern_YYLOC_global_declaration.patch
zram-zs-create-pool-null.patch
decon-fb-colors.patch
proc_S-remove-text-init-line.patch
disable-fimc-is2.patch
disable-charging-bootmode.patch
fix-usb-gadget-random-mac.patch
"
builddir="$srcdir/$_repository-$_commit"
_outdir="."
prepare() {
export ANDROID_MAJOR_VERSION=q
default_prepare
. downstreamkernel_prepare
}
build() {
unset LDFLAGS
export ANDROID_MAJOR_VERSION=q
make ARCH="$_carch" CC="${CC:-gcc}" \
KBUILD_BUILD_VERSION="$((pkgrel + 1 ))-postmarketOS"
# Master DTB (deviceinfo_bootimg_qcdt)
dtbTool-exynos -o "$_outdir/arch/$_carch/boot"/dt.img \
$(find "$_outdir/arch/$_carch/boot/dts/" -name *j7y17lte*.dtb)
}
package() {
export ANDROID_MAJOR_VERSION=q
downstreamkernel_package "$builddir" "$pkgdir" "$_carch" \
"$_flavor" "$_outdir"
install -Dm644 "$_outdir/arch/$_carch/boot"/dt.img \
"$pkgdir"/boot/dt.img
}
sha512sums="
f124bce4d5e2108c07b54f575f452ee61e530e195869611e0059b7824bf60a75911847efc83deb16ddf03c082301bc92b688b9806a9efadbfb0a6b94c58dc631 linux-samsung-j7y17lte-6fa3aaf35a35ee3acadacf158a364acc47ab6653.tar.gz
247232a8c876a33bb0c608277e748e9b4f64035c2508e3153f83847b7a6db3bcbcdb62d2efa911d8d1146b0d7c598eb723c5176c6502078b67e869be50f93aa7 config-samsung-j7y17lte.aarch64
2b48f1bf0e3f70703d2cdafc47d5e615cc7c56c70bec56b2e3297d3fa4a7a1321d649a8679614553dde8fe52ff1051dae38d5990e3744c9ca986d92187dcdbeb gcc10-extern_YYLOC_global_declaration.patch
3f65a690e48f913fcb980718fae4dc03c29a6dc86eecb1e2af644488ad415de326a61d840399fb69915cbc5d56d5586f2df2287b3e7323a2927ae73a3b1b1373 zram-zs-create-pool-null.patch
5bd204239a5daff9f990757178398707ae5ec64f823ed9ec72a8d50ebe6d5f0a3cc9743e0d775094da4b3a7566f1ccceb56f39f3b0234d08ca05e537d86271ec decon-fb-colors.patch
99946ae80a642bb3daa34f55156c3803a813d60cc3863da422925f0a9a9564db66d3065633944080982b89d6448be40195687af68bfe65a34d870cd2eeba0aec proc_S-remove-text-init-line.patch
f429f40a8195e81d1c3ef86a5736bb29e09f3daaa2f415b9a992fb4dc8011c961c7b48fc97e08c3180ebacf8c2b97a5560022a9340eb44464e8ef98f3758e19e disable-fimc-is2.patch
32e51c6171bcb72b15f5f11a9c9b3279e03e630f2ea6d14b66fbfdd8a8c1587bdb7e88698197e9a81e05c47dba08d13c1ff4a5e4692d14b042f07dd2006c1cc0 disable-charging-bootmode.patch
0d56ba508408dc31961ad688f7fd960b0008851fd5729088658095417781b99962740e0c64d162a26f8389e4b4dc88e291252e7935e896fc70bf73c23150caea fix-usb-gadget-random-mac.patch
"

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,13 @@
diff --git a/drivers/video/fbdev/exynos/decon_7870/decon-int_drv.c b/drivers/video/fbdev/exynos/decon_7870/decon-int_drv.c
index 15e7e22b..29f1dc49 100644
--- a/drivers/video/fbdev/exynos/decon_7870/decon-int_drv.c
+++ b/drivers/video/fbdev/exynos/decon_7870/decon-int_drv.c
@@ -335,7 +335,7 @@ static u32 wincon(u32 bits_per_pixel, u32 transp_length)
case 32:
if (transp_length > 0) {
data |= WINCON_BLD_PIX;
- data |= WINCON_BPPMODE_ABGR8888;
+ data |= WINCON_BPPMODE_ARGB8888;
} else {
data |= WINCON_BPPMODE_XRGB8888;
}

View file

@ -0,0 +1,14 @@
diff --git a/drivers/staging/samsung/sec_batt.c b/drivers/staging/samsung/sec_batt.c
index 89960640..5de0b91e 100644
--- a/drivers/staging/samsung/sec_batt.c
+++ b/drivers/staging/samsung/sec_batt.c
@@ -20,9 +20,6 @@ EXPORT_SYMBOL(lpcharge);
static int sec_bat_is_lpm_check(char *str)
{
- if (strncmp(str, "charger", 7) == 0)
- lpcharge = 1;
-
pr_info("%s: Low power charging mode: %d\n", __func__, lpcharge);
return lpcharge;

View file

@ -0,0 +1,30 @@
diff --git a/drivers/leds/leds-s2mu005.c b/drivers/leds/leds-s2mu005.c
index 1e8c0b70..d7d6ac3d 100644
--- a/drivers/leds/leds-s2mu005.c
+++ b/drivers/leds/leds-s2mu005.c
@@ -24,7 +24,9 @@
#include <linux/platform_device.h>
#include <linux/sec_batt.h>
+#ifdef CONFIG_VIDEO_EXYNOS_FIMC_IS2
extern struct class *camera_class;
+#endif
struct device *flash_dev;
bool assistive_light = false;
#ifdef CONFIG_LEDS_SUPPORT_FRONT_FLASH
@@ -1139,6 +1141,7 @@ int create_flash_sysfs(void)
{
int err = -ENODEV;
+#ifdef CONFIG_VIDEO_EXYNOS_FIMC_IS2
if (IS_ERR_OR_NULL(camera_class)) {
pr_err("flash_sysfs: error, camera class not exist");
return -ENODEV;
@@ -1149,6 +1152,7 @@ int create_flash_sysfs(void)
pr_err("flash_sysfs: failed to create device(flash)\n");
return -ENODEV;
}
+#endif
err = device_create_file(flash_dev, &dev_attr_rear_flash);
if (unlikely(err < 0)) {

View file

@ -0,0 +1,24 @@
diff --git a/drivers/usb/gadget/function/u_ether.c b/drivers/usb/gadget/function/u_ether.c
index 2502ce1d..c6028edc 100755
--- a/drivers/usb/gadget/function/u_ether.c
+++ b/drivers/usb/gadget/function/u_ether.c
@@ -1262,18 +1262,13 @@ struct eth_dev *gether_setup_name(struct usb_gadget *g, u8 ethaddr[ETH_ALEN],
if (get_ether_addr(dev_addr, net->dev_addr))
dev_warn(&g->dev,
"using random %s ethernet address\n", "self");
-#ifdef CONFIG_USB_ANDROID_SAMSUNG_COMPOSITE
- memcpy(dev->host_mac, ethaddr, ETH_ALEN);
- printk(KERN_DEBUG "usb: set unique host mac\n");
-
-#else
if (get_ether_addr(host_addr, dev->host_mac))
dev_warn(&g->dev,
"using random %s ethernet address\n", "host");
if (ethaddr)
memcpy(ethaddr, dev->host_mac, ETH_ALEN);
-#endif
+
net->netdev_ops = &eth_netdev_ops;
net->ethtool_ops = &ops;

View file

@ -0,0 +1 @@
../../.shared-patches/linux/gcc10-extern_YYLOC_global_declaration.patch

View file

@ -0,0 +1,25 @@
From 44b07494ad40ce82eaf7fc98c58d498b947f6772 Mon Sep 17 00:00:00 2001
From: Eray Tutmaz <tarkanttmz261@gmail.com>
Date: Thu, 19 Oct 2023 08:31:12 +0000
Subject: [PATCH] Update file proc.S
---
arch/arm64/mm/proc.S | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm64/mm/proc.S b/arch/arm64/mm/proc.S
index 4e778b132..4179312e5 100644
--- a/arch/arm64/mm/proc.S
+++ b/arch/arm64/mm/proc.S
@@ -186,7 +186,7 @@ ENTRY(cpu_do_switch_mm)
ret
ENDPROC(cpu_do_switch_mm)
- .section ".text.init", #alloc, #execinstr
+
/*
* __cpu_setup
--
GitLab

View file

@ -0,0 +1,13 @@
diff --git a/drivers/block/zram/zram_drv.c b/drivers/block/zram/zram_drv.c
index 60d73ab2..595be443 100644
--- a/drivers/block/zram/zram_drv.c
+++ b/drivers/block/zram/zram_drv.c
@@ -380,7 +380,7 @@ static struct zram_meta *zram_meta_alloc(int device_id, u64 disksize)
}
snprintf(pool_name, sizeof(pool_name), "zram%d", device_id);
- meta->mem_pool = zs_create_pool(pool_name, GFP_NOIO | __GFP_HIGHMEM);
+ meta->mem_pool = zs_create_pool(pool_name, GFP_NOIO | __GFP_HIGHMEM, NULL);
if (!meta->mem_pool) {
pr_err("Error creating memory pool\n");
goto out_error;