[Xperia Z1 Compact Android Development] munjeni:
Status update. After switch to xml based audio policy and using custom audio policy, fm, headphones and etc is broken now :( I'm using configuration from https://github.com/LineageOS/androi...mmit/17936dee4f745b1e5b99badf547230543ef9fedf

This is a result:

10-12 16:32:00.687 20845 20845 D audio_hw_extn: audio_extn_get_parameters: returns
10-12 16:32:00.688 20845 20845 I hash_map_utils: key: 'all_call_states' value: ''
10-12 16:32:00.691 20845 20861 D PermissionCache: checking android.permission.MODIFY_AUDIO_SETTINGS for uid=1000 => granted (3481 us)
10-12 16:32:00.691 20845 20861 D AudioPolicyManagerCustom: setForceUse() usage 1, config 10, mPhoneState 0
10-12 16:32:00.700 20845 20845 D PermissionCache: checking android.permission.MODIFY_AUDIO_SETTINGS for uid=1001 => granted (8633 us)
10-12 16:32:00.700 20845 20845 D audio_hw_primary: adev_set_parameters: enter: vsid=268443648;call_state=1
10-12 16:32:00.709 20845 20845 D audio_hw_extn: audio_extn_get_parameters: returns
10-12 16:32:00.710 20845 20845 I hash_map_utils: key: 'all_call_states' value: ''
10-12 16:32:00.711 20845 20845 D audio_hw_primary: adev_set_parameters: enter: vsid=281026560;call_state=1
10-12 16:32:00.713 20845 20861 D audio_hw_extn: audio_extn_get_parameters: returns
10-12 16:32:00.713 20845 20861 I hash_map_utils: key: 'all_call_states' value: ''
10-12 16:32:00.717 20845 20862 D audio_hw_primary: adev_set_parameters: enter: vsid=281022464;call_state=1
10-12 16:32:00.730 20845 20861 D AudioPolicyManagerCustom: setDeviceConnectionStateInt() device: 0x80000010, state 1, address name
10-12 16:32:00.730 20845 20861 D audio_hw_primary: adev_open_input_stream: enter: sample_rate(48000) channel_mask(0xc) devices(0x80000010) stream_handle(0xb53043c0) io_handle(30) source(1)
10-12 16:32:00.738 20845 20851 D audio_hw_primary: adev_set_parameters: enter: connect=-2147483632
10-12 16:32:00.739 20845 20863 I AudioFlinger: AudioFlinger's thread 0xb4d03400 ready to run
10-12 16:32:00.740 20845 20861 D audio_hw_primary: adev_close_input_stream: enter:stream_handle(0xb53043c0)
10-12 16:32:00.740 20845 20861 D audio_hw_primary: in_standby: enter: stream (0xb53043c0) usecase(9: audio-record)
10-12 16:32:00.742 849 1297 E AudioService: Audioserver started.
10-12 16:32:00.745 20845 20845 D audio_hw_primary: adev_set_parameters: enter: restarting=true
10-12 16:32:00.746 20845 20862 D AudioPolicyManagerCustom: setDeviceConnectionStateInt() device: 0x80000010, state 1, address name
10-12 16:32:00.747 20845 20862 W AudioPolicyManagerCustom: setDeviceConnectionState() device already connected: -2147483632
10-12 16:32:00.747 20845 20845 D AudioPolicyManagerCustom: setDeviceConnectionStateInt() device: 0x4, state 1, address name
10-12 16:32:00.747 20845 20845 I AudioFlinger: openOutput(), module 10 Device 4, SamplingRate 8000, Format 0x3036310a, Channels 1, flags 801
10-12 16:32:00.747 20845 20845 D audio_hw_primary: adev_open_output_stream: enter: sample_rate(8000) channel_mask(0x1) devices(0x4) flags(0x801) stream_handle(0xb5fc3440)
[COLOR="Red"]10-12 16:32:00.747 20845 20845 F audio_hw_primary: pcm_format_from_audio_format: invalid audio format 0x3036310a[/COLOR]
10-12 16:32:00.748 20845 20845 F libc : Fatal signal 6 (SIGABRT), code -6 in tid 20845 (audioserver)
10-12 16:32:00.749 202 202 W : debuggerd: handling request: pid=20845 uid=1041 gid=1005 tid=20845
10-12 16:32:00.828 20864 20864 F DEBUG : *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
10-12 16:32:00.828 20864 20864 F DEBUG : LineageOS Version: '14.1-20171011-UNOFFICIAL-amami'
10-12 16:32:00.828 20864 20864 F DEBUG : Build fingerprint: 'Sony/D5503/D5503:5.1.1/14.6.A.1.236/2031203603:user/release-keys'
10-12 16:32:00.828 20864 20864 F DEBUG : Revision: '0'
10-12 16:32:00.828 20864 20864 F DEBUG : ABI: 'arm'
10-12 16:32:00.828 20864 20864 F DEBUG : pid: 20845, tid: 20845, name: audioserver >>> /system/bin/audioserver <<<
10-12 16:32:00.828 20864 20864 F DEBUG : signal 6 (SIGABRT), code -6 (SI_TKILL), fault addr --------
10-12 16:32:00.828 20864 20864 F DEBUG : r0 00000000 r1 0000516d r2 00000006 r3 ed62cbd7
10-12 16:32:00.828 20864 20864 F DEBUG : r4 b6f0458c r5 00000006 r6 b6f04534 r7 0000010c
10-12 16:32:00.828 20864 20864 F DEBUG : r8 00000001 r9 0000001b sl 00000000 fp 00000001
10-12 16:32:00.828 20864 20864 F DEBUG : ip 00000000 sp becdc120 lr b63d1fa1 pc b63d4984 cpsr 200f0010
10-12 16:32:00.842 20864 20864 F DEBUG :
10-12 16:32:00.842 20864 20864 F DEBUG : backtrace:
10-12 16:32:00.842 20864 20864 F DEBUG : #00 pc 00050984 /system/lib/libc.so (tgkill+12)
10-12 16:32:00.842 20864 20864 F DEBUG : #01 pc 0004df9d /system/lib/libc.so (pthread_kill+36)
10-12 16:32:00.842 20864 20864 F DEBUG : #02 pc 0001deed /system/lib/libc.so (raise+10)
10-12 16:32:00.842 20864 20864 F DEBUG : #03 pc 000194f1 /system/lib/libc.so (__libc_android_abort+34)
10-12 16:32:00.842 20864 20864 F DEBUG : #04 pc 00017378 /system/lib/libc.so (abort+4)
10-12 16:32:00.842 20864 20864 F DEBUG : #05 pc 00005cc7 /system/lib/liblog.so (__android_log_assert+118)
10-12 16:32:00.842 20864 20864 F DEBUG : #06 pc 00007d1d /system/lib/hw/audio.primary.msm8974.so
10-12 16:32:00.842 20864 20864 F DEBUG : #07 pc 0005233f /system/lib/libaudioflinger.so
10-12 16:32:00.842 20864 20864 F DEBUG : #08 pc 00052065 /system/lib/libaudioflinger.so
10-12 16:32:00.842 20864 20864 F DEBUG : #09 pc 0003b711 /system/lib/libaudioflinger.so
10-12 16:32:00.842 20864 20864 F DEBUG : #10 pc 0003ba71 /system/lib/libaudioflinger.so
10-12 16:32:00.842 20864 20864 F DEBUG : #11 pc 0000c501 /system/lib/libaudiopolicyservice.so
10-12 16:32:00.842 20864 20864 F DEBUG : #12 pc 0001f3cf /system/lib/libaudiopolicymanagerdefault.so (_ZN7android18AudioPolicyManager21checkOutputsForDeviceENS_2spINS_16DeviceDescriptorEEE24audio_policy_dev_state_tRNS_12SortedVectorIiEENS_7String8E+1814)
10-12 16:32:00.842 20864 20864 F DEBUG : #13 pc 00006bb5 /system/lib/libaudiopolicymanager.so (_ZN7android24AudioPolicyManagerCustom27setDeviceConnectionStateIntEj24audio_policy_dev_state_tPKcS3_+1816)
10-12 16:32:00.842 20864 20864 F DEBUG : #14 pc 0000b14b /system/lib/libaudiopolicyservice.so
10-12 16:32:00.842 20864 20864 F DEBUG : #15 pc 000a59a7 /system/lib/libmedia.so (_ZN7android20BnAudioPolicyService10onTransactEjRKNS_6ParcelEPS1_j+1146)
10-12 16:32:00.843 20864 20864 F DEBUG : #16 pc 00035d4b /system/lib/libbinder.so (_ZN7android7BBinder8transactEjRKNS_6ParcelEPS1_j+74)
10-12 16:32:00.843 20864 20864 F DEBUG : #17 pc 0003dd4f /system/lib/libbinder.so (_ZN7android14IPCThreadState14executeCommandEi+598)
10-12 16:32:00.843 20864 20864 F DEBUG : #18 pc 0003d9f1 /system/lib/libbinder.so (_ZN7android14IPCThreadState20getAndExecuteCommandEv+128)
10-12 16:32:00.843 20864 20864 F DEBUG : #19 pc 0003deeb /system/lib/libbinder.so (_ZN7android14IPCThreadState14joinThreadPoolEb+38)
10-12 16:32:00.843 20864 20864 F DEBUG : #20 pc 00001b75 /system/bin/audioserver
10-12 16:32:00.843 20864 20864 F DEBUG : #21 pc 00016ee9 /system/lib/libc.so (__libc_init+48)
10-12 16:32:00.843 20864 20864 F DEBUG : #22 pc 0000183c /system/bin/audioserver
10-12 16:32:01.077 849 1339 W NativeCrashListener: Couldn't find ProcessRecord for pid 20845
10-12 16:32:01.079 202 202 W : debuggerd: resuming target 20845
10-12 16:32:01.080 849 902 I BootReceiver: Copying /data/tombstones/tombstone_01 to DropBox (SYSTEM_TOMBSTONE)
10-12 16:32:01.090 849 1534 W AudioSystem: AudioFlinger server died!
10-12 16:32:01.090 340 340 I ServiceManager: service 'media.sound_trigger_hw' died
10-12 16:32:01.090 849 1534 W AudioSystem: AudioPolicyService server died!
10-12 16:32:01.090 340 340 I ServiceManager: service 'media.radio' died
10-12 16:32:01.090 2129 2158 W AudioSystem: AudioPolicyService server died!
10-12 16:32:01.090 340 340 I ServiceManager: service 'media.audio_flinger' died
10-12 16:32:01.090 368 616 W AudioSystem: AudioFlinger server died!
10-12 16:32:01.090 340 340 I ServiceManager: service 'media.audio_policy' died
10-12 16:32:01.091 2129 2129 I ServiceManager: Waiting for service media.audio_policy...
10-12 16:32:01.091 849 1297 I ServiceManager: Waiting for service media.audio_policy...
10-12 16:32:01.091 368 610 I ServiceManager: Waiting for service media.audio_flinger...
10-12 16:32:02.047 849 1081 V WiredAccessoryManager: notifyWiredAccessoryChanged: when=11757476802000 bits= mask=14
10-12 16:32:02.048 849 1081 V WiredAccessoryManager: newName=h2w newState=0 headsetState=0 prev headsetState=1
10-12 16:32:02.050 849 1081 I WiredAccessoryManager: MSG_NEW_DEVICE_STATE
10-12 16:32:02.093 368 610 I ServiceManager: Waiting for service media.audio_flinger...
10-12 16:32:02.093 2129 2129 I ServiceManager: Waiting for service media.audio_policy...
10-12 16:32:02.094 849 1297 I ServiceManager: Waiting for service media.audio_policy...
10-12 16:32:03.095 2129 2129 I ServiceManager: Waiting for service media.audio_policy...
10-12 16:32:03.095 849 1297 I ServiceManager: Waiting for service media.audio_policy...
10-12 16:32:03.096 368 610 I ServiceManager: Waiting for service media.audio_flinger

dmesg log:

[10735.692876] init: Starting service 'audioserver'...
[10735.962272] hdmi_tx_get_audio_edid_blk: failed. HDMI is not connected/ready for audio
[10735.982358] hdmi_tx_get_audio_edid_blk: failed. HDMI is not connected/ready for audio
[10736.235164] msm_routing_get_dolby_dap_param_to_get_control, port_id not set, returning error
[10736.235711] msm_pcm_volume_ctl_get substream runtime not found
[10736.235870] msm_pcm_volume_ctl_get substream runtime not found
[10736.236183] msm_pcm_volume_ctl_get substream runtime not found
[10736.236620] msm_pcm_volume_ctl_get substream runtime not found
[10736.263775] msm_audio_ion_import: DMA Buf name=audio_acdb_client, fd=11 handle=00000000
[10736.272428] q6asm_callback: cmd = 0x10bcd returned error = 0x5
[10736.283230] q6asm_callback: cmd = 0x10bcd returned error = 0x5
[10736.299148] q6asm_callback: cmd = 0x10bcd returned error = 0x5
[10736.314176] q6asm_callback: cmd = 0x10bcd returned error = 0x5
[10737.609309] init: Service 'audioserver' (pid 20100) killed by signal 6
[10737.609577] init: Service 'audioserver' (pid 20100) killing any children in process group
[10740.615305] init: Starting service 'audioserver'...

We need custom audio policy for many reasons. What might be a problem, ideas?

Edit:

Seems media profiles? Or codecs missing?

Edit:

voip_rx profile cause this :) Even we don't had it in (now) obsolete audio policy! Removing voip_rx profile from policy configuration solved SIGABRT. I'm believing media codec for voip_rx is missing or probably media profile is missing. Hope we solve voip_rx too soon.