Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

trouble compiling against 4.13.9 #5

Closed
rmonk opened this issue Oct 31, 2017 · 6 comments
Closed

trouble compiling against 4.13.9 #5

rmonk opened this issue Oct 31, 2017 · 6 comments

Comments

@rmonk
Copy link

rmonk commented Oct 31, 2017

I'm on Fedora 26, running 4.13.9-200.fc26.x86_64

When trying to build, I was getting errors related to bi_error not existing. After some research, it seems that it's been renamed to bi_status? I replaced those in the kblock.c. Now, however, I get:

/root/rpmbuild/BUILD/iomemory-vsl-3.2.15.1700/driver_source/kblock.c:1779:5: error: implicit declaration of function 'blk_queue_bounce'; did you mean 'blk_queue_io_opt'? [-Werror=implicit-function-declaration]
blk_queue_bounce(queue, &bio);
^~~~~~~~~~~~~~~~

I tried looking for this, but it seems it's been removed? I do see it in the map for the kernel, but there's no prototype in the includes.

I'm sure I'm doing something wrong, but I can't seem to figure it out, any help would be appreciated.

@snuf
Copy link
Collaborator

snuf commented Oct 31, 2017

Hi Richard,

Thanks for your bug, don't think you're doing anything wrong!

Indeed, my auto-compile also noticed that in 4.13.7 that bi_error had "evaporated" and was moved to bi_status, however bi_status is a different type than bi_error was, so just renaming it might yield some interesting results (probably not looking at elixir, but might later down the line). Had unfortunately not come around to committing the change and have auto-test run.

With regard to blk_queue_bounce I'm curious if you have CONFIG_BOUNCE in your kernel config and would love to know if this is a stock kernel for Fedora ?
grep BOUNCE /boot/config-
I love elixir

Hope to get to the first point by the end of the day if time permits, the second one I'm curious about but will see if there is a way to get around it.

Cheers,

Funs

@rmonk
Copy link
Author

rmonk commented Oct 31, 2017

Totally stock:
uname -a : Linux wasabi.lan 4.13.9-200.fc26.x86_64 #1 SMP Mon Oct 23 13:52:45 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
rpm -q kernel: kernel-4.13.9-200.fc26.x86_64

It looks like bounce is enabled:
host # grep BOUNCE /boot/config-4.13.9-200.fc26.x86_64
CONFIG_BOUNCE=y

This is what I saw that made me think I was doing things wrong:
host # pwd
/usr/src/kernels/4.13.9-200.fc26.x86_64
[root@wasabi 4.13.9-200.fc26.x86_64]# grep -iR blk_queue_bounce *
include/linux/blkdev.h:extern void blk_queue_bounce_limit(struct request_queue *, u64);
Module.symvers:0x00000000 blk_queue_bounce_limit vmlinux EXPORT_SYMBOL
grep: scripts/dtc/include-prefixes/powerpc: No such file or directory
grep: scripts/dtc/include-prefixes/nios2: No such file or directory
System.map:ffffffff813f87b0 T blk_queue_bounce_limit
System.map:ffffffff814110d0 T blk_queue_bounce
System.map:ffffffff81d5bf90 r __ksymtab_blk_queue_bounce_limit
System.map:ffffffff81d8b554 r __kstrtab_blk_queue_bounce_limit

The System.map shows the function, but I don't see the prototype or definition anywhere.

I added in the function definitions from elixir and got a little farther:
make[1]: Entering directory '/usr/src/kernels/4.13.9-200.fc26.x86_64'
make[2]: *** No rule to make target '/root/rpmbuild/BUILD/iomemory-vsl-3.2.15.1700/driver_source/kfio/x86_64_cc72_libkfio.o', needed by '/root/rpmbuild/BUILD/iomemory-vsl-3.2.15.1700/driver_source/iomemory-vsl.o'. Stop.
make[1]: *** [Makefile:1516: module/root/rpmbuild/BUILD/iomemory-vsl-3.2.15.1700/driver_source] Error 2
make[1]: Leaving directory '/usr/src/kernels/4.13.9-200.fc26.x86_64'
make: *** [Makefile:82: modules] Error 2

Looks like there's not a prebuilt libkfio for gcc 7.2?

I symlinked the gcc 6.3 object to 7.2 and built the module. It detected the card! So far, I was able to mount the partition and read from it without any errors and it seems to be working.

[12669.675623] iomemory_vsl: loading out-of-tree module taints kernel.
[12669.675668] iomemory_vsl: module license 'Proprietary' taints kernel.
[12669.675670] Disabling lock debugging due to kernel taint
[12669.676071] iomemory_vsl: module verification failed: signature and/or required key missing - tainting kernel
[12669.677468] <6>fioinf VSL configuration hash: 50cc3bdba9fe52b90d1821e59d81452e4a6eac09
[12669.677574] <6>fioinf
[12669.677574] <6>fioinf Copyright (c) 2006-2014 Fusion-io, Inc. (acquired by SanDisk Corp. 2014)
[12669.677574] <6>fioinf Copyright (c) 2014-2016 SanDisk Corp. and/or all its affiliates. All rights reserved.
[12669.677575] <6>fioinf For Terms and Conditions see the License file included
[12669.677575] <6>fioinf with this driver package.
[12669.677575] <6>fioinf
[12669.677576] <6>fioinf ioDrive driver 3.2.15.1700 pinnacles@3dd0050df54c loading...
[12669.678015] fioinf CPU online: 0
[12669.678015] fioinf CPU online: 1
[12669.678016] fioinf CPU online: 2
[12669.678016] fioinf CPU online: 3
[12669.678125] <6>fioinf ioDrive 0000:02:00.0: mapping controller on BAR 5
[12669.678190] <6>fioinf ioDrive 0000:02:00.0: MSI enabled
[12669.678192] <6>fioinf ioDrive 0000:02:00.0: using MSI interrupts
[12669.708264] <6>fioinf ioDrive 0000:02:00.0.0: Starting master controller
[12669.752756] <6>fioinf ioDrive 0000:02:00.0.0: PMP Address: 1 1 1
[12669.796930] <6>fioinf ioDrive 0000:02:00.0.0: SMP Controller Firmware APP version 1.0.35 0
[12669.796933] <6>fioinf ioDrive 0000:02:00.0.0: SMP Controller Firmware BOOT version 0.0.9 1
[12670.149012] <6>fioinf ioDrive 0000:02:00.0.0: Required PCIE bandwidth 2.000 GBytes per sec
[12670.149015] <6>fioinf ioDrive 0000:02:00.0.0: Board serial number is 1239D8858
[12670.149017] <6>fioinf ioDrive 0000:02:00.0.0: Adapter serial number is 1239D8858
[12670.149021] <6>fioinf ioDrive 0000:02:00.0.0: Default capacity 365.000 GBytes
[12670.149023] <6>fioinf ioDrive 0000:02:00.0.0: Default sector size 512 bytes
[12670.149025] <6>fioinf ioDrive 0000:02:00.0.0: Rated endurance 4.00 PBytes
[12670.149027] <6>fioinf ioDrive 0000:02:00.0.0: 100C temp range hardware found
[12670.149029] <6>fioinf ioDrive 0000:02:00.0.0: Maximum capacity 395.000 GBytes
[12670.501051] <6>fioinf ioDrive 0000:02:00.0.0: Firmware version 7.1.17 116786 (0x700411 0x1c832)
[12670.501054] <6>fioinf ioDrive 0000:02:00.0.0: Platform version 16
[12670.501056] <6>fioinf ioDrive 0000:02:00.0.0: Firmware VCS version 116786 [0x1c832]
[12670.501066] <6>fioinf ioDrive 0000:02:00.0.0: Firmware VCS uid 0xaeb15671994a45642f91efbb214fa428e4245f8a
[12670.504248] <6>fioinf ioDrive 0000:02:00.0.0: Powercut flush: Enabled
[12670.790806] <6>fioinf ioDrive 0000:02:00.0.0: PCIe power monitor enabled (master). Limit set to 24.750 watts.
[12670.790808] <6>fioinf ioDrive 0000:02:00.0.0: Thermal monitoring: Enabled
[12670.790810] <6>fioinf ioDrive 0000:02:00.0.0: Hardware temperature alarm set for 100C.
[12670.862820] <6>fioinf ioDrive 0000:02:00.0: Found device fct0 (Fusion-io ioDrive2 365GB 0000:02:00.0) on pipeline 0
[12672.594059] <6>fioinf Fusion-io ioDrive2 365GB 0000:02:00.0: probed fct0
[12672.678873] <6>fioinf Fusion-io ioDrive2 365GB 0000:02:00.0: sector_size=512
[12672.678880] <6>fioinf Fusion-io ioDrive2 365GB 0000:02:00.0: setting channel range data to [2 .. 2047]
[12672.894195] <6>fioinf Fusion-io ioDrive2 365GB 0000:02:00.0: Found metadata in EBs 616-616, loading...
[12673.099191] <6>fioinf Fusion-io ioDrive2 365GB 0000:02:00.0: setting recovered append point 616+228114432
[12673.105235] <6>fioinf Fusion-io ioDrive2 365GB 0000:02:00.0: Creating device of size 365000000000 bytes with 712890625 sectors of 512 bytes (368477301 mapped).
[12673.106739] fioinf Fusion-io ioDrive2 365GB 0000:02:00.0: Creating block device fioa: major: 252 minor: 0 sector size: 512...
[12673.109799] fioa: fioa1 fioa2
[12673.110069] <6>fioinf Fusion-io ioDrive2 365GB 0000:02:00.0: Attach succeeded.

@snuf
Copy link
Collaborator

snuf commented Oct 31, 2017

Ha nice spelunking there!

The missing libkfio I usually copy *cough* so that works indeed. Odd that it's showing the function in the map but not in your source. Looking at some more elixir these are the places it should be, I'm downloading Fedora26 atm to have a look myself too.

@rmonk
Copy link
Author

rmonk commented Oct 31, 2017

As a data point, that method seemed to work fine. I transferred ~ 170G of data off the iodrive with 0 issues.

@Fett2
Copy link

Fett2 commented Dec 27, 2017

rmonk, I am running into a similar issue as you. When you say

I added in the function definitions from elixir and got a little farther:

Can you tell me what functions you added, and to where?

@snuf
Copy link
Collaborator

snuf commented Dec 28, 2017

finally checked it in....

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants