From b76ce3cd0db40c11ea6371d967d356774f4f706b Mon Sep 17 00:00:00 2001 From: Florian Pose Date: Mon, 26 Jun 2023 11:44:22 +0200 Subject: [PATCH] Improved help on ioctl() version magic mismatch. --- tool/MasterDevice.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/tool/MasterDevice.cpp b/tool/MasterDevice.cpp index 32c31478..f32ef1ad 100644 --- a/tool/MasterDevice.cpp +++ b/tool/MasterDevice.cpp @@ -1,8 +1,6 @@ /***************************************************************************** * - * $Id$ - * - * Copyright (C) 2006-2009 Florian Pose, Ingenieurgemeinschaft IgH + * Copyright (C) 2006-2023 Florian Pose, Ingenieurgemeinschaft IgH * * This file is part of the IgH EtherCAT Master. * @@ -86,7 +84,13 @@ void MasterDevice::open(Permissions perm) stringstream err; err << "ioctl() version magic is differing: " << deviceName.str() << ": " << module_data.ioctl_version_magic - << ", ethercat tool: " << EC_IOCTL_VERSION_MAGIC; + << ", ethercat tool: " << EC_IOCTL_VERSION_MAGIC << endl + << "A probable reason is that the command-line tool" << endl + << "you are using is built with a different" << endl + << "source code version than the currently loaded" << endl + << "kernel module. Please install an updated version" << endl + << "of either the tool (ethercat) or the kernel" << endl + << "module (ec_master.ko)."; throw MasterDeviceException(err); } masterCount = module_data.master_count;