Bug 1795585

Summary: Kernel fails to boot on qemu on armv7: Unable to handle kernel NULL pointer dereference at virtual address 00000000 in function ata_attach_transport+0xc0/0x264
Product: [Fedora] Fedora Reporter: Richard W.M. Jones <rjones>
Component: kernelAssignee: Kernel Maintainer List <kernel-maint>
Status: CLOSED WONTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 30CC: airlied, bskeggs, hdegoede, ichavero, itamar, jarodwilson, jeremy, jglisse, john.j5live, jonathan, josef, kernel-maint, linville, masami256, mchehab, mjg59, rjones, steved
Target Milestone: ---   
Target Release: ---   
Hardware: armv7hl   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-03-09 10:20:31 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 910269    
Attachments:
Description Flags
build.log none

Description Richard W.M. Jones 2020-01-28 11:35:45 UTC
1. Please describe the problem:

Kernel fails to boot on qemu.

We have a tool called qemu-sanity-check which could be used to
automatically test this case and prevent regressions.
https://people.redhat.com/~rjones/qemu-sanity-check/

2. What is the Version-Release number of the kernel:

5.4.12-100.fc30.armv7hl

3. Did it work previously in Fedora? If so, what kernel version did the issue
   *first* appear?  Old kernels are available for download at
   https://koji.fedoraproject.org/koji/packageinfo?packageID=8 :

Seems to have started in the 5.4.x stable branch.  Doesn't affect
F31 or Rawhide.

4. Can you reproduce this issue? If so, please provide the steps to reproduce
   the issue below:

Run libguestfs-test-tool or qemu-sanity-check.

5. Does this problem occur with the latest Rawhide kernel? To install the
   Rawhide kernel, run ``sudo dnf install fedora-repos-rawhide`` followed by
   ``sudo dnf update --enablerepo=rawhide kernel``:

No.

6. Are you running any modules that not shipped with directly Fedora's kernel?:

No.

7. Please attach the kernel logs. You can get the complete kernel log
   for a boot with ``journalctl --no-hostname -k > dmesg.txt``. If the
   issue occurred on a previous boot, use the journalctl ``-b`` flag.

Comment 1 Richard W.M. Jones 2020-01-28 11:38:28 UTC
Created attachment 1655995 [details]
build.log

Full build log is attached.  The part related to this bug is right at
the end of the log, also extracted here:

[    2.616325] SCSI subsystem initialized
[    2.624983] 8<--- cut here ---
[    2.626143] Unable to handle kernel NULL pointer dereference at virtual address 00000000
[    2.627863] pgd = (ptrval)
[    2.628264] [00000000] *pgd=00000000
[    2.631779] Internal error: Oops: 5 [#1] SMP ARM
[    2.632781] Modules linked in:
[    2.634100] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 5.4.12-100.fc30.armv7hl #1
[    2.634877] Hardware name: Generic DT based system
[    2.636789] PC is at ata_attach_transport+0xc0/0x264
[    2.638120] LR is at 0x124
[    2.638494] pc : [<c086fd88>]    lr : [<00000124>]    psr: 60000053
[    2.639003] sp : eb505e90  ip : c0c47640  fp : c14ceffc
[    2.639487] r10: ffffffff  r9 : 00000000  r8 : c119b84c
[    2.639948] r7 : c11d1218  r6 : 00000000  r5 : eb6138bc  r4 : eb613800
[    2.640543] r3 : 00000000  r2 : 00000000  r1 : 00000000  r0 : 00000000
[    2.641229] Flags: nZCv  IRQs on  FIQs off  Mode SVC_32  ISA ARM  Segment none
[    2.641916] Control: 10c5387d  Table: 4020406a  DAC: 00000051
[    2.642530] Process swapper/0 (pid: 1, stack limit = 0x(ptrval))
[    2.643215] Stack: (0xeb505e90 to 0xeb506000)
[    2.644170] 5e80:                                     00000000 00000000 00000000 c1177de0
[    2.645286] 5ea0: c119b84c ffffffff c1177af4 60000053 ffffffff eb505ef4 c119b84c c0301a8c
[    2.646284] 5ec0: 00000000 c1177af4 c1308de0 c1308de0 ffffe000 c1177af4 00000000 00000117
[    2.647251] 5ee0: c119b84c c1457d80 c11004d4 ffffe000 c1177af4 00000000 00000117 c119b84c
[    2.648213] 5f00: c1457d80 c11004d4 c123a96c c0302c54 ffffffff eb505f54 c119b800 c0301a8c
[    2.649173] 5f20: c11745b4 2a6c3000 c1335a20 c123aa48 00000005 c1457d80 c119b82c 00000117
[    2.650124] 5f40: c119b84c c1457d80 c11004d4 c123a918 00000020 eb505f70 c11011bc 00000005
[    2.651064] 5f60: c1457d80 c119b82c 00000117 c11011bc 00000004 00000004 00000000 c11004d4
[    2.652027] 5f80: 00000000 00000000 c0b4123c 00000000 00000000 00000000 00000000 00000000
[    2.653051] 5fa0: 00000000 c0b4124c 00000000 c03010e8 00000000 00000000 00000000 00000000
[    2.654074] 5fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
[    2.655083] 5fe0: 00000000 00000000 00000000 00000000 00000013 00000000 00000000 00000000
[    2.658176] [<c086fd88>] (ata_attach_transport) from [<c1177de0>] (ata_init+0x2ec/0x340)
[    2.659244] [<c1177de0>] (ata_init) from [<c0302c54>] (do_one_initcall+0x74/0x1f0)
[    2.659972] [<c0302c54>] (do_one_initcall) from [<c11011bc>] (kernel_init_freeable+0x220/0x270)
[    2.660809] [<c11011bc>] (kernel_init_freeable) from [<c0b4124c>] (kernel_init+0x10/0x11c)
[    2.661598] [<c0b4124c>] (kernel_init) from [<c03010e8>] (ret_from_fork+0x14/0x2c)
[    2.662263] Exception stack(0xeb505fb0 to 0xeb505ff8)
[    2.662876] 5fa0:                                     00000000 00000000 00000000 00000000
[    2.663897] 5fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
[    2.664797] 5fe0: 00000000 00000000 00000000 00000000 00000013 00000000
[    2.666278] Code: e28c3010 e28450cc e893000f e1c4ecb0 (e885000f) 
[    2.669967] ---[ end trace 21642b3bf2beda32 ]---
[    2.672649] Kernel panic - not syncing: Attempted to kill init! exitcode=0x0000000b
[    2.674493] Rebooting in 1 seconds..

Comment 2 Justin M. Forbes 2020-03-03 16:23:07 UTC
*********** MASS BUG UPDATE **************

We apologize for the inconvenience.  There are a large number of bugs to go through and several of them have gone stale.  Due to this, we are doing a mass bug update across all of the Fedora 30 kernel bugs.

Fedora 30 has now been rebased to 5.5.7-100.fc30.  Please test this kernel update (or newer) and let us know if you issue has been resolved or if it is still present with the newer kernel.

If you have moved on to Fedora 31, and are still experiencing this issue, please change the version to Fedora 31.

If you experience different issues, please open a new bug report for those.

Comment 3 Richard W.M. Jones 2020-03-09 10:20:31 UTC
I don't know why I bother with kernel bugs.