summaryrefslogtreecommitdiffstats
path: root/config.tests
diff options
context:
space:
mode:
authorAlex Blasche <alexander.blasche@theqtcompany.com>2016-03-21 12:21:11 +0100
committerAlex Blasche <alexander.blasche@theqtcompany.com>2016-04-06 05:44:48 +0000
commit96d291cbdefb8f0d731eb32b0c1cca613b6006c3 (patch)
tree2d58a175cb6690734085406326506bb898df198f /config.tests
parent04b75569f36eec14662505a08bf8c1d565cb10fe (diff)
Make socketcan backend compile on pre 3.6 kernels
The CanFD implementation was introduced by the Linux 3.6 kernel. This change makes the socketcan backend compile on the older Linux kernel build platforms. If a socketcan backend was compiled against the most recent kernel headers but run on an ancient kernel, the missing support is dynamically detected by virtue of returned error code from ioctl et al. Task-number: QTBUG-51932 Change-Id: I5c3601877fa6e882f24d7fa3588dae473a325b9b Reviewed-by: Rolf Eike Beer <eb@emlix.com> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
Diffstat (limited to 'config.tests')
-rw-r--r--config.tests/socketcan_fd/main.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/config.tests/socketcan_fd/main.cpp b/config.tests/socketcan_fd/main.cpp
index d499f4b..966c390 100644
--- a/config.tests/socketcan_fd/main.cpp
+++ b/config.tests/socketcan_fd/main.cpp
@@ -39,6 +39,9 @@
int main()
{
canfd_frame frame;
+ int fd_payload = CANFD_MAX_DLEN;
+ fd_payload = CAN_RAW_FD_FRAMES;
+ fd_payload = CANFD_MTU;
return 0;
}