FS#57303 - [linux] CONFIG_INTEL_ATOMISP=y causes kernel panic on laptop

Attached to Project: Arch Linux
Opened by Arsalan (afzalarsalan) - Wednesday, 31 January 2018, 06:12 GMT
Last edited by Jan Alexander Steffens (heftig) - Sunday, 04 February 2018, 13:18 GMT
Task Type Bug Report
Category Packages: Testing
Status Closed
Assigned To Tobias Powalowski (tpowa)
Jan Alexander Steffens (heftig)
Architecture x86_64
Severity High
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
With the update to Linux 4.15, it seems that someone has decided to restart work on getting front facing cameras connected to Intel SOCs finally working in Linux. Unfortunately while this happens, this staging driver seems to be half enabled and is causing kernel panics on my Surface Book, which implements one of these weird front facing cameras connected to the Intel SOC. Easiest way to avert this issue is to not set this particular config and remove the associated items underneath it. I don't think this should result in a loss as there's a good reason why this media driver is still in staging.

Additional info:
* package version(s)
* config and/or log files etc.
Linux 4.15-1


Steps to reproduce:
Boot Linux 4.15-1 on a Microsoft Surface Book
This task depends upon

Closed by  Jan Alexander Steffens (heftig)
Sunday, 04 February 2018, 13:18 GMT
Reason for closing:  Fixed
Additional comments about closing:  4.15.1-1
Comment by Jan Alexander Steffens (heftig) - Wednesday, 31 January 2018, 09:48 GMT
If the modules cause trouble you can blacklist them. They are:

atomisp
atomisp-gc0310
atomisp-gc2235
atomisp-libmsrlisthelper
atomisp-lm3554
atomisp-mt9m114
atomisp-ov2680
atomisp-ov2722
atomisp-ov5693

Blacklisting the atomisp module might be enough.

What do you mean by "half-enabled"?
Comment by Arsalan (afzalarsalan) - Wednesday, 31 January 2018, 20:31 GMT
Well it seems that in Linux 4.15, some patches were merged to do some sprucing up of the driver's organization and with that it seems some added compatibility. Unfortunately, this issue also causes the atomisp-ov5693 driver to actually attempt to set up the device and proceed to rather inelegantly fail and cause a kernel panic where as in Linux 4.14 and prior would simply have an error message about the i2c bus being unable to instantiated with no real side effects other than an annoying boot message. I understand that it may seem drastic to remove an entire subset of drivers from building in the kernel but as a reference point neither Fedora nor Ubuntu have this driver subset enabled in their kernels. The way I see it is that benefits you get for disabling it and enabling devices like the Surface Book to boot will outway the small minority of people using this staging driver who probably build their own kernels for development and debugging purposes. Ultimately it's an upstream issue but they're probably going to take a while to properly fix it.

Associated kernel bug

Jan 30 22:31:40 arsalan-SurfaceBook kernel: ov5693 i2c-INT33BE:00: Failed to get clk from pmc_plt_clk_0 : -2
Jan 30 22:31:40 arsalan-SurfaceBook kernel: BUG: unable to handle kernel NULL pointer dereference at 0000000000000058
Jan 30 22:31:40 arsalan-SurfaceBook kernel: IP: gmin_camera_platform_data+0x2a/0x60
Jan 30 22:31:40 arsalan-SurfaceBook kernel: PGD 0 P4D 0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: Oops: 0002 [#1] SMP PTI
Jan 30 22:31:40 arsalan-SurfaceBook kernel: Modules linked in: snd_compress ac97_bus snd_pcm_dmaengine rfkill tpm_crb i915(+) snd_hda_intel snd_hda_codec snd_hda_core snd_hwdep drm_kms_helper snd_pcm snd_timer s
Jan 30 22:31:40 arsalan-SurfaceBook kernel: hid_multitouch hid
Jan 30 22:31:40 arsalan-SurfaceBook kernel: CPU: 1 PID: 336 Comm: systemd-udevd Tainted: G C 4.15.0-1 #1
Jan 30 22:31:40 arsalan-SurfaceBook kernel: Hardware name: Microsoft Corporation Surface Book/Surface Book, BIOS 91.1926.768 12/06/2017
Jan 30 22:31:40 arsalan-SurfaceBook kernel: RIP: 0010:gmin_camera_platform_data+0x2a/0x60
Jan 30 22:31:40 arsalan-SurfaceBook kernel: RSP: 0018:ffff9f97c120b3b8 EFLAGS: 00010246
Jan 30 22:31:40 arsalan-SurfaceBook kernel: RAX: 0000000000000000 RBX: 0000000000000002 RCX: 0000000000000006
Jan 30 22:31:40 arsalan-SurfaceBook kernel: RDX: 0000000000000000 RSI: 0000000000000096 RDI: ffff9cb72f496590
Jan 30 22:31:40 arsalan-SurfaceBook kernel: RBP: 000000000000000f R08: 0000000000000305 R09: 0000000000000001
Jan 30 22:31:40 arsalan-SurfaceBook kernel: R10: ffffc59dc9823980 R11: 0000000000000001 R12: ffff9cb7251ba010
Jan 30 22:31:40 arsalan-SurfaceBook kernel: R13: ffff9cb7222289a8 R14: 0000000000000000 R15: ffff9cb7251ba010
Jan 30 22:31:40 arsalan-SurfaceBook kernel: FS: 00007f08d4bb88c0(0000) GS:ffff9cb72f480000(0000) knlGS:0000000000000000
Jan 30 22:31:40 arsalan-SurfaceBook kernel: CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
Jan 30 22:31:40 arsalan-SurfaceBook kernel: CR2: 0000000000000058 CR3: 0000000262260005 CR4: 00000000003606e0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
Jan 30 22:31:40 arsalan-SurfaceBook kernel: DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Jan 30 22:31:40 arsalan-SurfaceBook kernel: Call Trace:
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ov5693_probe+0xf4/0x7b0 [atomisp_ov5693]
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? wakeup_source_add+0x48/0x80
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? wakeup_source_register+0x1f/0x30
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? _cond_resched+0x15/0x40
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? mutex_lock+0xe/0x30
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? acpi_device_wakeup_disable+0x15/0x50
Jan 30 22:31:40 arsalan-SurfaceBook kernel: i2c_device_probe+0x15f/0x330
Jan 30 22:31:40 arsalan-SurfaceBook kernel: driver_probe_device+0x315/0x480
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? __driver_attach+0xe0/0xe0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: bus_for_each_drv+0x66/0xb0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: __device_attach+0xd9/0x150
Jan 30 22:31:40 arsalan-SurfaceBook kernel: bus_probe_device+0x8a/0xa0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: device_add+0x463/0x6b0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: i2c_new_device+0x172/0x350
Jan 30 22:31:40 arsalan-SurfaceBook kernel: i2c_acpi_register_device+0x20/0x60
Jan 30 22:31:40 arsalan-SurfaceBook kernel: i2c_acpi_add_device+0x69/0x70
Jan 30 22:31:40 arsalan-SurfaceBook kernel: acpi_ns_walk_namespace+0x134/0x283
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? i2c_acpi_register_device+0x60/0x60
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? i2c_acpi_register_device+0x60/0x60
Jan 30 22:31:40 arsalan-SurfaceBook kernel: acpi_walk_namespace+0xf5/0x13d
Jan 30 22:31:40 arsalan-SurfaceBook kernel: i2c_acpi_register_devices+0x40/0x60
Jan 30 22:31:40 arsalan-SurfaceBook kernel: i2c_register_adapter+0x17d/0x450
Jan 30 22:31:40 arsalan-SurfaceBook kernel: i2c_add_adapter+0x9a/0x100
Jan 30 22:31:40 arsalan-SurfaceBook kernel: i2c_dw_probe+0x125/0x1c0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: dw_i2c_plat_probe+0x636/0x760
Jan 30 22:31:40 arsalan-SurfaceBook kernel: platform_drv_probe+0x4d/0xa0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: driver_probe_device+0x315/0x480
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? __driver_attach+0xe0/0xe0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: bus_for_each_drv+0x66/0xb0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: __device_attach+0xd9/0x150
Jan 30 22:31:40 arsalan-SurfaceBook kernel: bus_probe_device+0x8a/0xa0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: device_add+0x463/0x6b0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? __kmalloc_track_caller+0x171/0x200
Jan 30 22:31:40 arsalan-SurfaceBook kernel: platform_device_add+0x10e/0x260
Jan 30 22:31:40 arsalan-SurfaceBook kernel: mfd_add_device+0x419/0x550
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? _cond_resched+0x15/0x40
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? inode_init_always+0x123/0x1d0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? _cond_resched+0x15/0x40
Jan 30 22:31:40 arsalan-SurfaceBook kernel: mfd_add_devices+0xb1/0x110
Jan 30 22:31:40 arsalan-SurfaceBook kernel: intel_lpss_probe+0x4ac/0x5c0 [intel_lpss]
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? pci_conf1_write+0xb2/0xe0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: intel_lpss_pci_probe+0x7a/0xa8 [intel_lpss_pci]
Jan 30 22:31:40 arsalan-SurfaceBook kernel: local_pci_probe+0x42/0xa0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? pci_assign_irq+0x27/0x130
Jan 30 22:31:40 arsalan-SurfaceBook kernel: pci_device_probe+0x146/0x1b0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: driver_probe_device+0x315/0x480
Jan 30 22:31:40 arsalan-SurfaceBook kernel: __driver_attach+0xa0/0xe0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? driver_probe_device+0x480/0x480
Jan 30 22:31:40 arsalan-SurfaceBook kernel: bus_for_each_dev+0x6b/0xb0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: bus_add_driver+0x1c2/0x260
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? 0xffffffffc03d6000
Jan 30 22:31:40 arsalan-SurfaceBook kernel: driver_register+0x57/0xc0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? 0xffffffffc03d6000
Jan 30 22:31:40 arsalan-SurfaceBook kernel: do_one_initcall+0x4e/0x190
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? _cond_resched+0x15/0x40
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? kmem_cache_alloc_trace+0xaa/0x1b0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? do_init_module+0x22/0x1fb
Jan 30 22:31:40 arsalan-SurfaceBook kernel: do_init_module+0x5b/0x1fb
Jan 30 22:31:40 arsalan-SurfaceBook kernel: load_module+0x259c/0x2aa0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? SyS_init_module+0x168/0x1a0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ? _cond_resched+0x15/0x40
Jan 30 22:31:40 arsalan-SurfaceBook kernel: SyS_init_module+0x168/0x1a0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: do_syscall_64+0x67/0x1a0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: entry_SYSCALL64_slow_path+0x25/0x25
Jan 30 22:31:40 arsalan-SurfaceBook kernel: RIP: 0033:0x7f08d44f05ea
Jan 30 22:31:40 arsalan-SurfaceBook kernel: RSP: 002b:00007ffc50aad128 EFLAGS: 00000246 ORIG_RAX: 00000000000000af
Jan 30 22:31:40 arsalan-SurfaceBook kernel: RAX: ffffffffffffffda RBX: 000055a728b4cc40 RCX: 00007f08d44f05ea
Jan 30 22:31:40 arsalan-SurfaceBook kernel: RDX: 00007f08d3da9cb5 RSI: 0000000000006868 RDI: 000055a728b99e80
Jan 30 22:31:40 arsalan-SurfaceBook kernel: RBP: 00007f08d3da9cb5 R08: 0000000000000005 R09: 000055a728b7a688
Jan 30 22:31:40 arsalan-SurfaceBook kernel: R10: 0000000000000005 R11: 0000000000000246 R12: 000055a728b99e80
Jan 30 22:31:40 arsalan-SurfaceBook kernel: R13: 000055a728b3f400 R14: 0000000000020000 R15: 00007ffc50aadc20
Jan 30 22:31:40 arsalan-SurfaceBook kernel: Code: 00 0f 1f 44 00 00 55 48 c7 c1 a0 0e 62 9b 53 89 f5 89 d3 31 c0 48 3b 39 74 21 83 c0 01 48 83 c1 68 83 f8 08 75 ef e8 26 fc ff ff <89> 68 58 89 58 5c 48 c7 c0 a0
Jan 30 22:31:40 arsalan-SurfaceBook kernel: RIP: gmin_camera_platform_data+0x2a/0x60 RSP: ffff9f97c120b3b8
Jan 30 22:31:40 arsalan-SurfaceBook kernel: CR2: 0000000000000058
Jan 30 22:31:40 arsalan-SurfaceBook kernel: ---[ end trace 21f0b3bacf36342f ]---

Loading...