Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 443296

Summary: crashes lvm&mkfs.xfs on mdraid10 with sys-kernel/hardened-sources > 3.2
Product: Gentoo Linux Reporter: Evgeny <worklord>
Component: HardenedAssignee: The Gentoo Linux Hardened Kernel Team (OBSOLETE) <hardened-kernel+disabled>
Severity: critical CC: alexanderyt
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Package list:
Runtime testing required: ---

Description Evgeny 2012-11-15 11:50:22 UTC
I'm compiled sys-kernel/hardened-sources newer 3.2 with next options


(compile built-in take same result)

Use next software: sys-fs/mdadm-{3.1.4,3.2.6} and sys-fs/lvm2-2.02.88. After create raid10 on lvm volume I try pvcreate on this one and get OOPS.

Any another raid types works fine. Only mkfs.xfs crashes on this environment. This configration fully works fine on kernel <=3.2

Reproducible: Always

Steps to Reproduce:
1. Create lvs: lvcreate -L 200M -n clean1 vg; lvcreate -L 200M -n clean2 vg
2. Create raid10 and wait sync: mdadm --create /dev/md0 --level=10 --raid-devices=2 /dev/vg/clean1 /dev/vg/clean2
3. Try pvcreate (or mkfs.xfs): pvcreate /dev/md0

Actual Results:  

Expected Results:  
Must works fine with any levels raid&lvm

BUG: unable to handle kernel NULL pointer dereference at 0000000000000008
IP: [<ffffffff811283f4>] __bio_add_page+0x114/0x230
PGD 0 
Oops: 0000 [#1] SMP 
CPU 0 
Modules linked in: ipv6 processor floppy button thermal_sys virtio_net intel_agp intel_gtt i2c_piix4 i2c_core dm_zero dm_thin_pool dm_persistent_data libcrc32c dm_service_time dm_round_robin dm_queue_length dm_multipath dm_bufio xts gf128mul aes_x86_64 aes_generic cbc sha256_generic scsi_transport_iscsi fuse nfs auth_rpcgss lockd sunrpc multipath linear raid10 raid0 dm_raid raid456 async_raid6_recov async_memcpy async_pq async_xor xor async_tx raid6_pq raid1 md_mod dm_snapshot dm_crypt dm_mirror dm_region_hash dm_log dm_mod scsi_wait_scan hid_sunplus hid_sony hid_samsung hid_pl hid_petalynx hid_gyration sl811_hcd usbhid ohci_hcd uhci_hcd usb_storage ehci_hcd usbcore usb_common scsi_transport_fc scsi_tgt sx8 DAC960 cciss sg pdc_adma sata_inic162x ata_piix ahci libahci sata_qstor sata_sx4 sata_sil24 libata

Pid: 8887, comm: pvcreate Not tainted 3.5.4-hardened-r1 #6 Bochs Bochs
RIP: 0010:[<ffffffff811283f4>]  [<ffffffff811283f4>] __bio_add_page+0x114/0x230
RSP: 0018:ffff88003dd419b8  EFLAGS: 00010246
RAX: 0000000000001000 RBX: 0000000000000000 RCX: 0000000000000002
RDX: 0000000000000000 RSI: ffff88003dbffaa0 RDI: ffff88003c461400
RBP: ffff880000000001 R08: 0000000000000001 R09: 0000000000000000
R10: 0000000000000008 R11: 0000000000000002 R12: ffff880000000000
R13: 0000000000001000 R14: ffffea0000ce1850 R15: 0000000000000000
FS:  00007f8a8aeff700(0000) GS:ffff88003fc00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000000008 CR3: 000000003dd8f000 CR4: 00000000000006f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
Process pvcreate (pid: 8887, threadinfo ffff88003c86b460, task ffff88003c86b040)
 0000000000000000 00000000000000d0 ffff88003e1da980 0000000000000100
 ffff880000000000 0000000000000000 ffff88003cd99cc0 ffff88003e1da380
 ffff88003cd3fd40 0000000000000000 ffff880039d80a40 0000000000000001
Call Trace:
 [<ffffffff81128541>] ? bio_add_page+0x31/0x40
 [<ffffffff8112cbb6>] ? __blockdev_direct_IO+0x9b6/0x32e0
 [<ffffffff8112b45f>] ? __blkdev_get+0x1bf/0x490
 [<ffffffff810f306b>] ? mem_cgroup_update_page_stat+0x1b/0x60
 [<ffffffff8112a802>] ? blkdev_direct_IO+0x52/0x60
 [<ffffffff81129d70>] ? blkdev_get_block+0x70/0x70
 [<ffffffff810b732a>] ? generic_file_aio_read+0x6fa/0x780
 [<ffffffff810d440f>] ? handle_pte_fault+0xef/0x9e0
 [<ffffffff810f5e62>] ? do_sync_read+0xe2/0x120
 [<ffffffff81129f6c>] ? block_ioctl+0x3c/0x40
 [<ffffffff81108697>] ? do_vfs_ioctl+0x97/0x700
 [<ffffffff81115096>] ? mntput_no_expire+0x46/0x150
 [<ffffffff810f67ce>] ? vfs_read+0xee/0x1d0
 [<ffffffff810f68fc>] ? sys_read+0x4c/0x90
 [<ffffffff81108d4a>] ? sys_ioctl+0x4a/0x80
 [<ffffffff814844c0>] ? system_call_fastpath+0x18/0x1d
Code: 74 2f 48 8b 33 48 8b 53 20 48 8b 7b 10 8b 4b 30 48 89 75 b8 48 89 55 c8 48 8d 75 b0 48 89 7d b0 89 4d c0 4c 89 fa 4c 89 e7 ff d0 <41> 3b 47 08 72 76 0f b7 4b 28 66 85 c9 74 55 41 8b 47 fc 41 8b 
RIP  [<ffffffff811283f4>] __bio_add_page+0x114/0x230
 RSP <ffff88003dd419b8>
CR2: 0000000000000008
---[ end trace 75d8a996004001c9 ]---
Comment 1 Anthony Basile gentoo-dev 2013-04-13 22:49:28 UTC
I  know this is an old bug, but can you try to reproduce with the newer kernels?
Comment 2 Anthony Basile gentoo-dev 2013-06-24 21:52:18 UTC
Please reopen if this is still an issue