From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [PATCH v2] vhost: fix eventfd_link.ko insertion failure problem Date: Tue, 24 Nov 2015 19:05:42 +0100 Message-ID: <3118012.BOtUj3c8T2@xps13> References: <1446789877-11656-1-git-send-email-xiaobo.chi@nokia.com> <1447225043-15404-1-git-send-email-xiaobo.chi@nokia.com> <20151111070721.GX2326@yliu-dev.sh.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev@dpdk.org To: Xiaobo Chi Return-path: Received: from mail-wm0-f45.google.com (mail-wm0-f45.google.com [74.125.82.45]) by dpdk.org (Postfix) with ESMTP id 275648E8A for ; Tue, 24 Nov 2015 19:07:01 +0100 (CET) Received: by wmww144 with SMTP id w144so37602294wmw.0 for ; Tue, 24 Nov 2015 10:07:01 -0800 (PST) In-Reply-To: <20151111070721.GX2326@yliu-dev.sh.intel.com> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" > > Problem:if I firstly insert my kmod_test.ko, then insert eventfd_link.ko, > > error will happen with hint " Device or resource busy". This is because > > the default minor device number, 0, has been occupied by my kmod_test.ko . > > > > root@distro:~/test$ lsmod > > Module Size Used by > > kmod_test 927 0 > > vboxsf 35930 4 > > vboxguest 222130 1 vboxsf > > microcode 10315 0 > > autofs4 25051 0 > > root@distro:~/test$ insmod ./eventfd_link.ko > > insmod: ERROR: could not insert module ./eventfd_link.ko: Device or > > resource busy > > > > Explanation: For miscdevices, the major device_no is same, so the minor > > device_no should be set to ditinguish different misc devices; if not set > > the minor, it may fail while insmod due to the default minor value, 0, has > > been used by other miscdevice. MISC_DYNAMIC_MINOR means to let Linux > > kernel dynamically assign one minor devide number while loading. > > > > Signed-off-by: Xiaobo Chi > Acked-by: Yuanhan Liu Applied, thanks