[Pkg-xen-devel] Bug#870007: blktap-2.0.93: blktap (blktap-2.0.93) kernel module crashes when the blktap_device_create() function is invoked.

Mahantesh Salimath mahantesh.openxt at gmail.com
Fri Jul 28 19:48:18 UTC 2017


Package: blktap-dkms
Version: 2.0.93-0.8
Severity: important
File: blktap-2.0.93

Dear Maintainer,

   * What led up to the situation?
        I installed debain kernel(Linux 4.9.0-0.bpo.3-amd64 SMP Debian
4.9.30-2+deb9u2~bpo8+1 x86_64 GNU/Linux) on my machine and installed
xen(4.8.1). Also, installed blktap-2.0.93 and configured xen to use it. The xen
guest creation was failing due to an error and I saw that the blktap kernel
module crashes whenever I tried to do so. When looked into it, I found a bug
which is present in the device.c source file (as part of a fix for debian
kernel).

   * What exactly did you do (or not do) that was effective (or
     ineffective)?
        dev_info() invoked inside blktap_device_create() function within
device.c is what causes the crash. The last parameter passed to the function
(i.e.,
test_bit(QUEUE_FLAG_WC, rq->queue_flags)) is the reason why it crashes.
Because, the second argument passed to the test_bit() function is required to
be a pointer whereas rq->queue_flags is of type unsigned integer.
Passing the address instead fixes the issue.
This also seems like a valid fix (though the format string could be better):
https://github.com/OpenXT/xenclient-oe/blob/master/recipes-
kernel/linux/4.9/patches/blktap2.patch#L1229

   * What was the outcome of this action?
        Xen was unable to create a tapdisk because of the above problem, after
fix the this issue was resolved.

   * What outcome did you expect instead?
        After my fix, the outcome was as expected.



-- System Information:
Debian Release: 8.8
  APT prefers oldstable-updates
  APT policy: (500, 'oldstable-updates'), (500, 'oldstable')
Architecture: amd64 (x86_64)

Kernel: Linux 4.9.0-0.bpo.3-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages blktap-dkms depends on:
ii  dkms            2.3-2~bpo8+1
ii  libc6-dev       2.19-18+deb8u10
ii  linux-libc-dev  4.9.30-2+deb9u2~bpo8+1

Versions of packages blktap-dkms recommends:
ii  linux-headers-amd64  4.9+80~bpo8+1

blktap-dkms suggests no packages.



More information about the Pkg-xen-devel mailing list